Search code examples
unixln

Unable to make symlinks effectively with target files of the same names


I have a list of dotFiles at my workarea. For example, .bashrc and .vimrc.

I want to make a symlinks from them to my Home such that their names are the same as in my workarea -folder.

My attempt in pseudo-code

ln workarea/.[a-zA-Z] ~/.*

The problem is to have a bijection from [a-zA-Z] to the files which occur in my Home.

How can you make symlinks with the target files of same name as the original files?


Solution

  • 'man ln' says:

    ln [OPTION]... TARGET... DIRECTORY (3rd form)

    So you need to do something like:

    $ ln -s workarea/.* ~/