Background
At work, my team and I use the Adobe RoboHelp software (version 2017) to create end-user documentation. RoboHelp stores some dictionary files inside of our personal user directories here:
%AppData%\..\LocalLow\Adobe\Linguistics\UserDictionaries\RoboHelp Personal Dictionary\en_US\
This folder contains these two text files:
- Added.txt
- Exceptions.txt
The Need
We'd like to include and track these files in our git repository so that we can our share custom terms etc. However, our git repo resides on our D:\ drive at this location:
d:\git\pcdmishelp\
We all use Windows 10.
My First Attempt
I thought perhaps I could create a hard link using the Windows mklink command prompt command between these two folders. I followed the recommendation here: How do I add files from another directory with git?
But when I used this command:
mklink /h "D:\git\pcdmishelp\added.txt" "%AppData%\..\LocalLow\Adobe\Linguistics\UserDictionaries\RoboHelp Personal Dictionary\en_US\added.txt"
I get this message: "The system cannot move the file to a different disk drive."
Apparently this won't work because our repo is on our D:\ drive, but the RoboHelp dictionary files need to be in this C:\ drive location:
%AppData%..\LocalLow\Adobe\Linguistics\UserDictionaries\RoboHelp Personal Dictionary\en_US\
My Second Attempt
Next, I tried was to create a directory junction. Because from this documentation page (https://docs.microsoft.com/en-us/windows/win32/fileio/hard-links-and-junctions) it sounds like it might be work similar to a hard link...?
Junctions
A junction (also called a soft link) differs from a hard link in that the storage objects it references are separate directories, and a junction can link directories located on different local volumes on the same computer. Otherwise, junctions operate identically to hard links. Junctions are implemented through reparse points.
As a test, I tried this command:
mklink /j "D:\git\pcdmishelp\dictionary" "%AppData%\..\LocalLow\Adobe\Linguistics\UserDictionaries\RoboHelp Personal Dictionary\en_US\"
It successfully created the junction and added the exact files from the RoboHelp Personal Dictionary\en\US\ directory into our repository.
However, when I make changes in RoboHelp and add a custom term there, the change never makes it into my repo here:
D:\git\pcdmishelp\dictionary
My Questions
Is there something I'm doing wrong?
Assuming there isn't, and knowing that we cannot change our repository location nor can we change RoboHelp's expected files location, how would you get around this hard link limitation between different drives?
What is the most efficient and hands off way to solve this? (If we can't get hard links to work, we're looking for some automated solution.)