zsh snippets

for loop of all files in a directory The following snippet shows all files in Loop_dir. Loop_dir="path_to_dir" for entry in "$Loop_dir"/* do echo "$entry" done cf) Check argument is set or not process tree ps -aef —forest Find from all files in the directory Find all lines from files in the current directory find ./ -type f -print | xargs grep 'foo' Delete prefix of files in a directory Here is a pioneer.