---
title: "linux 在某个文件中查找"
author: "mjtfly"
date: "2010-05-29T17:28:17Z"
tags: []
categories: ["操作系统"]
slug: "linux"
draft: false
lastmod: "2010-05-29T17:28:17Z"
id: 678849
url: "https://mjtfly.iteye.com/blog/678849"
---

查找当前目录下所有后缀为.html文件中包含test字符串的文件，并显示行：

 

find . -name "\*.html" -exec grep -nH "test" {} \\;