Size of all files in a directory
Size of current directory
Size of top-level directories within current directory
Add the following flags to modify search conditions:
- -R = recursive list
- -a = list all
- -s = show file size
- -l = show with details
ls | grep "<file/directory name>"
|
Add the following flags to modify search conditions:
- -r = recursive list
- -w = only match whole words
- | = use in search string as an OR
grep "<search string>" my/directory/
grep "<search string>" my/directory/myfile.txt
|
If you’ve got a list of environment variables in a .env file, this will assign them all to your existing environment:
export $(grep -v '^#' .env | xargs)
|