File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -269,6 +269,7 @@ _305 TILs and counting..._
269
269
- [ Find Newer Files] ( unix/find-newer-files.md )
270
270
- [ Global Substitution On The Previous Command] ( unix/global-substitution-on-the-previous-command.md )
271
271
- [ Grep For Files Without A Match] ( unix/grep-for-files-without-a-match.md )
272
+ - [ Grep For Multiple Patterns] ( unix/grep-for-multiple-patterns.md )
272
273
- [ Hexdump A Compiled File] ( unix/hexdump-a-compiled-file.md )
273
274
- [ Kill Everything Running On A Certain Port] ( unix/kill-everything-running-on-a-certain-port.md )
274
275
- [ Killing A Frozen SSH Session] ( unix/killing-a-frozen-ssh-session.md )
Original file line number Diff line number Diff line change
1
+ # Grep For Multiple Patterns
2
+
3
+ You can use the ` -e ` flag with the ` grep ` command to search for a pattern.
4
+ Additionally, you can use multiple ` -e ` flags to search for multiple
5
+ patterns. For instance, if you want to search for occurrences of ` ruby ` and
6
+ ` clojure ` in a ` README.md ` file, use the following command:
7
+
8
+ ```
9
+ $ grep -e ruby -e clojure README.md
10
+ ```
11
+
12
+ See ` man grep ` for more details.
You can’t perform that action at this time.
0 commit comments