find . -name "rc.conf" -print
http://www.athabascau.ca/html/depts/compserv/webunit/HOWTO/find.htm
Recursively find files with certain contents limited to file type
grep -r --include=*.java "stringtofind" .
List processes and their memory
ps -eo size,pid,user,command --sort -size | awk '{ hr=$1/1024 ; printf("%13.2f Mb ",hr) } { for ( x=4 ; x<=NF ; x++ ) { printf("%s ",$x) } print "" }'
Free memory
free
This will remove all .svn folders in the current directory and below
find . -name .svn -print0 | xargs -0 rm -rf
This will add a folder without its descendants (non recursively)
svn add --depth=empty folder1/folder2
Add all unknown files
svn status | grep "^?" | awk '{print $2}' | xargs svn add
To extract the contents of a tar file use:
tar xvzf foo.tgz
Compress a dir to archive:
tar -cvzpf archive.tgz /home/example/public_html/folder
Human readable free space
df -h
Enable modules
sudo a2enmod
sudo vi /opt/local/var/db/postgresql84/defaultdb/pg_hba.conf
sudo /opt/local/etc/LaunchDaemons/org.macports.postgresql84-server/postgresql84-server.wrapper start
sudo /opt/local/etc/LaunchDaemons/org.macports.postgresql84-server/postgresql84-server.wrapper stop
sudo /opt/local/share/mysql5/mysql/mysql.server start
Run VisualVM:
/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home/bin/jvisualvm
We focus on user experience and design. We seek out the most simple and essential solution. We believe that machines should work for people. We think that knowledge should be free and accessible to all. We hope you agree :-)