Table of Contents
Last active
March 17, 2024 23:12
-
-
Save AndrewSavetchuk/1c7de6794ad5fcf36dc85a7c7b8c6539 to your computer and use it in GitHub Desktop.
This command sorts the lines in the input.txt
file:
sort ./input.txt
This command sorts the lines in the input.txt
file and removes duplicates:
sort ./input.txt | uniq
This command sorts the lines in the input.txt
file, removes duplicates and writes the output in the file:
sort ./input.txt | uniq > output.txt
Find files in the current directory and its subdirectories with a name containing the specified string.
find . -name "*string*" -print
Find files in the current directory (not-recursive) with a name containing the specified string.
find . -maxdepth 1 -name "*string*" -print
Find files in the current directory (not-recursive) with a name containing the specified string, but avoid files with a name containing "readme".
find . -maxdepth 1 -name "*string*" ! -name "*readme*" -print
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment