as a shell script, the possibilities are endless... #!/bin/bash echo doing something very evil! exit [2Aecho doing something very nice! Show Sample Output
In this example, I’m creating a wrapper for apt-get that assumes yes every time — but the command could be anything.
If your `date` command has `-r` option, you don't need `stat`
Writes hybrid ISO directly to USB stick; replace /dev/sdb with USB device in question and the ISO image link with the link of your choice
--delete will delete copies on remote to match local if deleted on local --stats will output the results -z zip -a archive -A preserve ACL -x don't cross filesystem boundaries -h human readable -e specify the remote shell to use
AWS provides a method to audit for obsolete AWS security groups. From their documentation: "Describes the stale security group rules for security groups in a specified VPC. Rules are stale when they reference a deleted security group in a peer VPC, or a security group in a peer VPC for which the VPC peering connection has been deleted." Show Sample Output
Change video orientation in metadata only
scan whole specific network for active online ips Show Sample Output
spectrum protect's dsmc command shows file names and total amount of restore. This command shows which files are actually open and their siz in GB and highlights the change to the previous output Show Sample Output
Transpose parameter: 0 = 90CounterCLockwise and Vertical Flip (default) 1 = 90Clockwise 2 = 90CounterClockwise 3 = 90Clockwise and Vertical Flip
Derived from current time down to minutes. Show Sample Output
Use xargs command to make one line.
This command lists all currently installed packages in ubuntu in a single line, for example to use later with apt install. Show Sample Output
include in the list human readable hidden files too:
file .* *|grep 'ASCII text'|sort -rk2
more reliable command:
ls|xargs file|grep 'ASCII text'|sort -rk2
and include hidden files:
ls -a|xargs file|grep 'ASCII text'|sort -rk2
GNU grep's PCRE(Perl-compatible regular expressions).
Delete the beginning of each line until first match of given character, in this case it's ":" Does it on all lines. The given character is deleted also, and can be a space.
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: