Question: I needed to create symbolic links / references to file from one repository to another.

I found the solution [git: symlink/reference to a file in an external repository](https://stackoverflow.com/questions/15844542/git-symlink-reference-to-a-file-in-an-external-repository/27770463#27770463), which worked for me partially. But problem with this solution is that although the link was created, it seems to be bound to the one commit of the file. After the file is updated, commited and pushed, I cannot see the changes reflected in the other repository.

Does anybody know the other way how to create the symbolic link to the file in another repository in git, that would work like symbolic link in linux?

Answer: 
This really appears to be a misunderstanding around how submodules work rather than an issue with symlinks. I highly suggest that you give the [Submodules chapter of Pro Git](https://git-scm.com/book/en/v2/Git-Tools-Submodules) a read.

For the purposes of this explanation let's define a few terms:

* `A` will be the repository containing the target of your symlink (the link itself).
* `B` will be the repository containing the source of that symlink.
* `C` will be the submodule in `A` referencing `B`.

So you did a `git submodule add B` from `A` creating `C`, then did something along the lines of `ln -s B/file file` so that you have a symlink in `A` called `file` pointing to `file` within `C`. Everything works.

The problem, as described, appears to be that you then update `file` in `B` and push that change, however in `A` the symlink still shows the original content of `file`. The problem is that the `C` is *just a clone of `B`*: Just like any other clone of a repository the contents on disk do not change when you change what they were cloned from (eg: if you clone a repo from github and then somebody updates that repo on github the files on your local machine aren't changed). The solution is to update `C` and `A`: Go into `C`, pull the changes you want from `B`, then go to `A` and commit the change to the submodule.

Some people do find this process quite heavy. If that's the case for you the other answer you linked to does lay out a number of other ways of doing what you wish via scripting (or you could even script the submodule update process if you want).
I faced a similar issue where i couldnt modify the symlink path. but i was able to modify the link path directly on azuredevops file editor while retaining the integrity of the symlink.