<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Find on Cheat Sheet</title><link>/tags/find/</link><description>Recent content in Find on Cheat Sheet</description><generator>Hugo</generator><language>en</language><lastBuildDate>Sun, 24 May 2026 00:00:00 +0000</lastBuildDate><atom:link href="/tags/find/index.xml" rel="self" type="application/rss+xml"/><item><title>find</title><link>/linux/cli/find/</link><pubDate>Sun, 24 May 2026 00:00:00 +0000</pubDate><guid>/linux/cli/find/</guid><description>&lt;h1 id="find"&gt;&lt;code&gt;find&lt;/code&gt;&lt;a class="anchor" href="#find"&gt;#&lt;/a&gt;&lt;/h1&gt;
&lt;h3 id="general-usage"&gt;General Usage&lt;a class="anchor" href="#general-usage"&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="background-color:#f7f7f7;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;find &amp;lt;path&amp;gt; &amp;lt;expression&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id="common-flags"&gt;Common Flags&lt;a class="anchor" href="#common-flags"&gt;#&lt;/a&gt;&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;-name&lt;/code&gt;&lt;/strong&gt;: Search by filename pattern (eg. &lt;code&gt;-name '*.log'&lt;/code&gt;). Single quotes are recommended to prevent the shell from expanding wildcards prematurely.
&lt;ul&gt;
&lt;li&gt;&lt;a href="../../linux/shell/process-order/"&gt;Shell Processing Order&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;-type&lt;/code&gt;&lt;/strong&gt;: Filter by file type
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;f&lt;/code&gt;: file&lt;/li&gt;
&lt;li&gt;&lt;code&gt;d&lt;/code&gt;: directory&lt;/li&gt;
&lt;li&gt;&lt;code&gt;l&lt;/code&gt;: symbolic link&lt;/li&gt;
&lt;li&gt;&lt;code&gt;s&lt;/code&gt;: socket&lt;/li&gt;
&lt;li&gt;&lt;code&gt;p&lt;/code&gt;: named pipe (FIFO)&lt;/li&gt;
&lt;li&gt;&lt;code&gt;b&lt;/code&gt;: block device&lt;/li&gt;
&lt;li&gt;&lt;code&gt;c&lt;/code&gt;: character device&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;-print&lt;/code&gt;&lt;/strong&gt;: Display results to standard output (default).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;-print0&lt;/code&gt;&lt;/strong&gt;: Separate results with a null character (&lt;code&gt;\0&lt;/code&gt;). Useful for filenames with spaces.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;-exec&lt;/code&gt;&lt;/strong&gt;: Execute a command on the search results.
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;\;&lt;/code&gt; (Individual Execution):&lt;/strong&gt; Runs the command once for each result. The semicolon must be escaped (&lt;code&gt;\;&lt;/code&gt;) because it is a shell reserved character.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code&gt;+&lt;/code&gt; (Batch Execution):&lt;/strong&gt; Collects results and runs the command once with multiple arguments (similar to &lt;code&gt;xargs&lt;/code&gt;). Better for performance.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;</description></item></channel></rss>