bash_notes
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
bash_notes [2022/04/06 22:36] – [list file names within a specific range] raju | bash_notes [2022/11/08 20:28] – [documentation links] raju | ||
---|---|---|---|
Line 1: | Line 1: | ||
===== tasks ===== | ===== tasks ===== | ||
- | ==== list file names within a specific range ==== | + | ==== dummy ==== |
- | In bash, we can use a " | + | * [[list files within a specific range]] |
- | < | + | ===== dummy ===== |
- | $ echo file{18..21}.txt | + | ==== useful links ==== |
- | file18.txt file19.txt file20.txt file21.txt | + | * https:// |
- | </code> | + | * https:// |
+ | * https:// | ||
+ | * http:// | ||
- | The " | + | ==== documentation links ==== |
+ | * ignoredups, erasedups - https://www.gnu.org/ | ||
- | Ref: | + | ==== what is the difference between "ls > dirlist 2>& |
- | * https:// | + | |
- | * https:// | + | |
- | Possible usages: | ||
- | |||
- | To list files | ||
- | < | ||
- | ls file{18..21}.txt | ||
- | </ | ||
- | |||
- | Use a for loop to run a command on each of them | ||
- | < | ||
- | for file in file{18..21}.txt | ||
- | ... | ||
- | </ | ||
- | |||
- | tags | list file names with a range | ||
- | |||
- | ===== dummy ===== | ||
- | ==== useful links ==== | ||
- | * https:// | ||
===== getopts ===== | ===== getopts ===== | ||
==== useful articles ==== | ==== useful articles ==== |
bash_notes.txt · Last modified: 2023/12/28 08:49 by raju