Last active
October 30, 2016 10:10
-
-
Save hansspiess/2e4a8bb1e4b233c06064 to your computer and use it in GitHub Desktop.
useful terminal commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# find all php.ini files on machine from terminal. | |
mdfind php.ini | grep php.ini | |
# copy local file to remote machine via scp | |
scp -P 92 /path/filename.ext [email protected]:~/path | |
# delete non-empty directory | |
rm -rf <dirname> | |
# unzip zip file in current dir | |
unzip file.zip -d . | |
# add symlinks to php.ini to every subfolder of current dir | |
find -type d -exec ln -s $PWD/php.ini {}/php.ini \; | |
# | | | | | | |
# 1 2 3 4 5 | |
# | |
# 1 walks a file hierarchy, option -d walks only dirs | |
# 2 at each step, execute following utility program | |
# 3 ln creates a linked file, option -s means create a symlink | |
# 4 $PWD holds the absolute pathname of the current working directory | |
# 5 to be understood... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment