It eases the way of creating cron jobs of backup scripts. Just put this line as cron job, and all your backups are called sequentially. Allows you to forget, when in time, call this backup, just focus on your scripting. Also maintains the way of calling a single backup script when It's needed.
Same but will only returns the invalid file (great when emailing the list to the team).
Find the PID of a process of that namespace and pass it to -i The other options ensure the mount, IPC, net, PID, etc namespaces are entered. This is nice because it does not matter which tool you use to create the namespace, this command will always work and give you a shell.
This is a no brainer command to make a direcory, substitute with the name of your directory. Show Sample Output
While they are few config options and even fewer useful details regarding what actually is being sent by the time machine 'backupd' process, this can at least tell you its doing something, how much it's doing, and exactly how often. Via macosxhints, http://xrl.us/begrwa, which in turn was via comments Show Sample Output
If (when) you forget to "svn rm" files from your repository, use this to let your repository know you want those files gone. Of course this works with adding and reverting too.
I used 110 as the port number in examples for clarity. backslash+lessthan or backslash+b marks 'edge of the word'. Show Sample Output
Digital cameras embed EXIF data into the images they create indicating which orientation the photo was taken in. Some viewers and editors are smart enough to read this, but many are not (and web browsers ignore it). jhead is one of not many tools available that can losslessly rotate jpeg images. This command reads the EXIF orientation of each image, and rotates it if necessary. Show Sample Output
export THISOS="`uname -s`" if [ "$THISOS" = "SunOS" ] then export THISRELEASE="`uname -r`" ping1() { ping -s $1 56 1 | egrep "^64"; } elif [ "$THISOS" = "AIX" ] then export THISRELEASE="`uname -v`.`uname -r`" ping1() { ping -w ${2:-1} $1 56 1 | egrep "^64"; } elif [ "$THISOS" = "Linux" ] then export THISRELEASE="`uname -r`" ping1() { ping -c 1 -w ${2:-1} $1 | egrep "^64"; } fi
Emulate (more or less) Git equivalent of
git log --format='tformat:%h %an (%cr) %s'
Show Sample Output
This command clones an image three times and creates a 'tile' image that can be used for a repeating pattern wallpaper. Add 'rm $f $of $off' to the end for cleanup (command was too long to submit with it). See this link for an example: http://meathive.deviantart.com/art/Easy-Photography-Hack-314846774
I tested this command on Ubuntu. Show Sample Output
requires superuser privileges
On the server side, open port 8080:
nc -l -p 8080
Use full to hack STB or device without any remote control server
get files without extensions, get ASCII and utf-8 as "text/plain" Show Sample Output
scrot, curl, egrep, sed, xsel, libnotify-bin must be installed. P.S. Sorry for so long command Show Sample Output
May need to use pavucontrol to set sound to correct things, use when ffmpeg is running.
Check your IP address using www.whatismyip.org from the command line
This command won't delete resource forks from an HFS file system, only from file systems that don't natively support resource forks.
commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.
Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.
» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10
Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):
Subscribe to the feed for: