Replace
'/tmp/file 1.txt' '/tmp/file 2.jpg'
with
"$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS"
for Nautilus script
Or with
%F
for Thunar action
If you linking the symlinks itself, but want to link to source files instead of symlinks, use
"`readlink -m "$i"`"
instead of
"$i"
like this:
for i in '/tmp/file 1.txt' '/tmp/file 2.jpg'; do ln -s "`readlink -m "$i"`" "$i LINK"; done
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Show Sample Output
Ideal for shuffling e.g. photo's with Imagemagick's montage, for instance in combination with: montage -density 300 -resize 512x384 -mode concatenate -tile 7x7 shuffled/* shuffled/output.pdf you can generate a PDF montage of 7x7 random photo's per page with properly scaled images. If there are other files than photo's in your folder, replace pattern './*' with for instance './*.jpeg' to select the file type you want.
if you wanted to create a new folder called "red" that was a symbolic link from /home/music/ to /home/hobbies/art then you would type: ln -s /home/hobbies/art /home/music/red
It's useful mostly for your custom scripts, which running on specific host and tired on ssh'ing every time when you need one simple command (i use it for update remote apt repository, when new package have to be downloaded from another host). Don't forget to set up authorization by keys, for maximum comfort. Show Sample Output
Remove your BASH history and then link it to /dev/null
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: