How can I zip/compress a symlink?

You can store symlinks as symlinks (as opposed to a copy of the file/directory they point to) using the –symlinks parameter of the standard zip. Assuming foo is a directory containing symlinks: zip –symlinks -r foo.zip foo/ Rar equivalent: rar a -ol foo.rar foo/ tar stores them as is by default. tar czpvf foo.tgz foo/ … Read more

memcache vs memcached?

The short answer: Either one is what you are looking for, but my first choice would be memcache (the first one you listed), purely based on its correct use of nomenclature. Now here’s how I came to that conclusion: Here is a quick backgrounder in naming conventions (for those unfamiliar), which explains the frustration by … Read more

How to remove invalid characters from filenames?

One way would be with sed: mv ‘file’ $(echo ‘file’ | sed -e ‘s/[^A-Za-z0-9._-]/_/g’) Replace file with your filename, of course. This will replace anything that isn’t a letter, number, period, underscore, or dash with an underscore. You can add or remove characters to keep as you like, and/or change the replacement character to anything … Read more