An upcoming project at work is replacing a commercial off-the-shelf NAS appliance. The new system will be a full Linux based system without the proprietary interface and firmware kludges. We plan to use the opportunity to reorganize file directories. Through many years of usage the NAS has become rather disorganized.
The office workstations used to access this storage are Windows. A project goal is to minimize work flow disruptions with user desktop shortcuts after the directory reorganization. The first phase is reading all shortcut links to learn about work flows affected by reorganizing directories. The second phase is bulk changing affected shortcuts.
I was surprised that no native shortcut management tool exists.
My first instinct then was to find all shortcuts. One challenge is learning a Windows method to find all
lnk files. Not a pointy-clicky method but scriptable. Windows does not have an equivalent command line find tool. I found a clunky work-around:
cd c:\ dir *.lnk /b /s | find /v "" > lnk.txt
This provided me a list of all
lnk files on a system.
I still knew nothing about the targets of those shortcut files. Or how to modify the targets.
I looked for a simple and trustworthy tool for listing the target of all shortcuts. I found a few
exe programs but with Windows there is a serious trust issue with running unknown software. I found a couple of perl and python scripts but that requires perl and python to be installed on the Windows systems, which is not guaranteed or wanted.
I found the perl and python scripts to be somewhat hit and miss.
Being Windows, is the program trustworthy? I don’t know but being GPL, I hope so.