Batch script to convert a Subversion (SVN) symlink text file into NTFS symbolic link
I would recommend getting into VBScript and Windows Script Host. Say, I had a file called C:\Temp\Hello.txt
and I wanted to create a link C:\Temp\Sample
. I'll create a script named MakeSample.vbs
as follows:
Set WshShell = CreateObject("Wscript.shell")Set oMyShortcut = WshShell.CreateShortcut("C:\Temp\Sample2.lnk")oMyShortcut.WindowStyle = 3oMyShortcut.TargetPath = "C:\Temp\Hello.txt"oMyShortCut.Save
Reading a LINK file would be straightforward in VBScript, for example:
Set fso = CreateObject("Scripting.FileSystemObject")Set f = fso.OpenTextFile("C:\Temp\linkfile.")txt = f.ReadAllf.CloseMsgBox txt
I think it should be relatively straightforward to hack something up using the above as a starting point.