Windos/BurntToast

FEATURE REQUEST: Add cmdlet to send toasts system-wide and over the network

bcurran3 opened this issue ยท 6 comments

REF: #33 and #35

There are many instances where sending a toast message to any and all logged in users by a remote sysadmin would be useful.

I propose a new cmdlet, alias, and/or -computer switch that would implement this.

Working proof of concept:
https://github.com/bcurran3/BurntToast/blob/bcurran3-patch-2-global-toast/BurntToast/Public/New-GlobalBurntToastNotification.ps1

image

This POC cmdlet works globally on the locally run system using $env:COMPUTERNAME. Changing it to a remote NETBIOS computer name will pop up the toast notification on that computer if WinRM is running on it. This POC cmdlet is not designed to test for WinRM status on remote computers.

DISCLAIMER: This will only work if the sender has admin access on local (?) and remote computers.

p.s. My skills are not refined enough to implement via a PR.

OK, I couldn't leave well enough alone and modified New-GlobalBurntToastNotification.ps1 to take a -computername switch to further along the POC. No doubt my ADD will kick in more and commit me to change the WinRM checking to work over the network....

@Windos if you want to grab some time I can implement this as part of New-BurntToastNotification directly so there's no need for a secondary cmdlet to do this over the network. Would be good to discuss some implementation details before I get to work here though.

Was this ever implemented ?

Is this working without install the module on each machine?

Can this be used with the latest version?

@lexcorp Yes, works fine with v0.8.5. I have it implemented via some Chocolatey add-ons I created:
https://community.chocolatey.org/packages/chocolatey-toast-notifications.extension
https://community.chocolatey.org/packages/choco-toast-notifications.hook

My use is specific to Chocolatey, but if you look at the code it's easily modifiable for other uses.