Is it possible to create a soft link on my desktop which opens with the target path instead of the link's path?

short: no, you cannot do it this way

long: a desktop launcher may work for you.

Unix-style symbolic links have only a target directory; there is no separate property for source directory. You can read about symbolic links in

  • What is a symbolic link made from? Understanding the structure of symlinks
  • Advantage of symlinks over Windows style shortcuts

As the question points out, the source directory is the desktop directory.

A comment mentions Create a symbolic link relative to the current directory, but that is not relevant to the question.

The question refers to the behavior of shortcuts in Microsoft Windows. With a desktop launcher, you can imitate this behavior (referring to Desktop Entry Specification, in the section Recognized desktop entry keys):

Exec
Program to execute, possibly with arguments. See the Exec key for details on how this key works. The Exec key is required if DBusActivatable is not set to true. Even if DBusActivatable is true, Exec should be specified for compatibility with implementations that do not understand DBusActivatable.

Path
If entry is of type Application, the working directory to run the program in.

Unix symbolic links are constants, while Windows shortcuts can have (like Apollo Domain during the 1980s) embedded variables. While the desktop specification goes into some detail regarding what is legal in Exec (special variables), it lacks detail on where your environment variables might be used. So implementations will differ.

Fortunately, the question as posed only requires constants, and launchers are the place to look for solutions.

Tags:

Linux

Ln