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
#Sync all verbose with progress from remote server to local. This is intended as a one shot sync, not to be scheduled as a cron job. Written for use with FreeNAS 8.2 as non-standard ports take a bit of work to get working. | |
#XXXX after the p flag should be replaced with the port. | |
rsync -avPz -e "ssh -pXXXX $portNumber" user@remote:/path/to/files/ /local/path/ |
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
#tar files in current directory modified since 1 day ago | |
find . -mtime -1 -exec tar --no-recursion -czf name.tgz {} + |
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
man foobar | less +/searched_string |
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
#Removes all of the punctuation in any item in a list. The characters to be removed are a string, "punctuation" from your list, "list" | |
list = [''.join(c for c in s if c not in punctuation) for s in list] |
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
sudo fsck -Af -M |
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
cat /etc/passwd | cut -d: -f1 | grep -v \# |
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
top -m io -o total #include virtual memory & paging | |
top -m io #smaller scope |
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
#Add this line before the "pip install..." command to bypass annoying errors on build with clang 3.4 Xcode tools | |
ARCHFLAGS="-Wno-error=unused-command-line-argument-hard-error-in-future" |
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
#In order to output all kernel devices, just run this | |
dmesg | |
#Alternate | |
camcontrol devlist |
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 . -name '*.py' | xargs wc -l |
OlderNewer