PoshNotify icon indicating copy to clipboard operation
PoshNotify copied to clipboard

Change application name from default, via parameter -ApplicationName

Open pcgeek86 opened this issue 6 years ago • 6 comments

On Windows 10, the notification toast has the application name showing as Windows PowerShell. Would it be possible to change the application name from "Windows PowerShell" to something else? Does the underlying API allow for this?

pcgeek86 avatar Feb 02 '19 20:02 pcgeek86

Yeah, it's possible but it's a whole thing. Basically it requires a shortcut in the start menu with an embedded AppId (full name for searching is AppUserModelId).

You can use Get-StartApps to see what's available on your system.

I've done some work trying to make custom AppId's more available to people:

https://king.geek.nz/2018/02/04/burnttoast-appid-installer/

https://king.geek.nz/2018/03/03/burnttoast-wix/

An alternative may be attribution, it'll still show PowerShell but you can put some text next to it.

attribution gif

https://king.geek.nz/2018/10/05/crouton-9-attribution/

... I'm on phone, please forgive typos or bad markdown

Windos avatar Feb 02 '19 21:02 Windos

Note in that gif, it shows BurntToast instead of PowerShell because I'm using my custom AppId.

Windos avatar Feb 02 '19 21:02 Windos

Oh yikes, that does sound involved, but a wrapper may be helpful to package up "fake" AppIds that can be used for this purpose. Appx management is thankfully straightforward with PowerShell.

Maybe use a dynamic parameter to detect Windows, and make the option only available on that platform?

pcgeek86 avatar Feb 02 '19 21:02 pcgeek86

Maybe use a dynamic parameter to detect Windows, and make the option only available on that platform?

The consistency-obsessed guy in me is scared of this tbh... but the customer-obsessed guy in me hears you

TylerLeonhardt avatar Feb 04 '19 01:02 TylerLeonhardt

@TylerLeonhardt I'm not a big fan of dynamic parameters either, due to the well-known discoverability issues, but this scenario seems like the right fit for them. Maybe just make it a regular parameter and ignore it for non-Windows platforms?

pcgeek86 avatar Feb 07 '19 22:02 pcgeek86

Note it clearly in the help (certainly), and maybe warn (or verbose) a message about it being unsupported if used on mac/linux?

Just need to get the mechanism for bringing that through to the OS reliably. Honestly if we can solve it here, it'll be a huge boon for BurntToast too.

Windos avatar Feb 07 '19 22:02 Windos