Repository navigation
Conversation
"Create link to this" on files and folders and "Create link here" on
folders and folder backgrounds, registered per user under
HKCU\Software\Classes. Each opens Symlinker with the form prefilled
through the existing command-line options.
- Toggle in a new settings menu next to About, off by default
- Entries are rewritten on startup when they point at another exe
(ClickOnce moves it on every update) or use other menu text
- Hidden in the Store build, where registry writes are virtualized
- LaunchOptions restores the backslash of a quoted drive root ("C:\")
Closes #7
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
…text-menu-80674e # Conflicts: # Symlinker/Properties/Resources.Designer.cs
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds optional Explorer right-click entries that open Symlinker with the form filled in. Closes #7.
--mode file --target "%1"--mode folder --target "%1"--location "%1"--location "%V"The link name already fills in from the target (#38), so "Create link to this" leaves only the link location to pick. The field order stays as it is (link location first, then target).
How it works
ExplorerMenuwrites classic shell verbs per user underHKCU\Software\Classes(*\shell,Directory\shell,Directory\Background\shell), so no admin is needed. Each entry uses the exe's icon andMultiSelectModel=Single(one window per right-click; bulk links are Create Bulk Links #6).%VforC:\as"C:\", which Windows splits intoC:"and which would swallow any arguments after it. The path is always the last argument, andLaunchOptions.Parseturns a trailing quote on--location/--targetback into a backslash. Paths with spaces were already fine.Elevation.IsPackaged()). Registry writes from a packaged app are virtualized, so Explorer would never see them. The manifest is untouched.MainWindowstays glue; the logic is inExplorerMenu, tested against a throwawayHKCU\Software\SymlinkerTests\<guid>key.Known limitations
Possible follow-up: Store version
The Store build would need its own context menu handler instead of registry verbs:
IExplorerCommand(title, icon,Invokethat starts Symlinker with the same arguments), ideally withIExplorerCommandStateto hide "Create link here" on files.desktop4:FileExplorerContextMenus(ItemType*,DirectoryandDirectory\Background) plus acom:ExtensionSurrogateServerorExeServerregistering the CLSID.Strings
New:
TooltipSettings,MenuExplorerIntegration,ExplorerMenuLinkTo,ExplorerMenuLinkHere,ExplorerMenuFailed, inResources.resxand all 8 translations, with typed properties added toResources.Designer.cs. The menu item sizes to its text, so German, Italian and French fit.Testing
dotnet test --project Symlinker.Tests: 195 passed, line, branch and method coverage at 100%.TrySetEnabledandRefresh, and the registered command lines parsed back throughCommandLineToArgvWintoLaunchOptions(spaces, drive root).HKCU\Software\Classesheld the expected label, icon and command, andShell.Applicationlisted "Create link to this" on a file and both entries on a folder.C:\filled the location asC:\.🤖 Generated with Claude Code