Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Native Aware App: Shortcut doesn't remove on delete and loses icon on update #829

Open
jroweboy opened this issue Sep 15, 2016 · 2 comments

Comments

@jroweboy
Copy link

I'm working on integrating squirrel with a native squirrel aware application and I'm having issues with handling shortcuts. On uninstall, my squirrel aware application gets the tries to run Update.exe --removeShortcut="updater.exe" but that fails with the following log. It looks like its its trying to check for the RELEASES file for some reason, but of course since its already uninstalled, its not there anymore.

2016-09-14 22:51:48> Program: Starting Squirrel Updater: --removeShortcut=updater.exe
2016-09-14 22:51:48> Unhandled exception: System.IO.DirectoryNotFoundException: Could not find a part of the path 'C:\Users\jroweboy\AppData\Local\citra\packages\RELEASES'.
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
   at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share)
   at Squirrel.Utility.LoadLocalReleases(String localReleaseFile)
   at Squirrel.UpdateManager.ApplyReleasesImpl.RemoveShortcutsForExecutable(String exeName, ShortcutLocation locations)
   at Squirrel.Update.Program.Deshortcut(String exeName, String shortcutArgs)
   at Squirrel.Update.Program.executeCommandLine(String[] args)
   at Squirrel.Update.Program.main(String[] args)

Another issue I'm facing is the icon on the shortcuts seems to be tied to a specific version of the application. After the first installed version has been updated twice, the icon for the application becomes the default shortcut icon, instead of the application icon (as a quick note, the shortcut still works, its just the wrong icon). Is there some way for me to update the icon without removing it and recreating it on update? It seems like that is a bad way to fix this since if the user has moved the desktop icon, everytime the application updates, it'll move back to the default location.

@jroweboy
Copy link
Author

As for the second issue (application icon becoming the default shortcut icon), I found that by calling Update.exe and removing the shortcut and recreating the shortcut not only fixes it, but it also doesn't move the icon on the desktop, which means its a workaround.

The first part is still an issue though.

@amartens181
Copy link

@jroweboy I had an issue where uninstalling did nothing at all

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants