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

Option to remove individual pinned apps from the startmenu (ie. Grammarly and Spotify) #41

Open
projektilski opened this issue Mar 18, 2024 · 13 comments
Assignees
Labels
enhancement New feature or request

Comments

@projektilski
Copy link

Hi, can you implement an option to remove Grammarly and Spotify?

@Raphire
Copy link
Owner

Raphire commented Mar 18, 2024

Heya,

Could you confirm that they're actually installed on the system? My guess is that they're just pinned to the start menu, and will not be installed until you click them. Similar to your other issue #40.

@Raphire Raphire self-assigned this Mar 18, 2024
@Raphire Raphire added the bug Something isn't working label Mar 18, 2024
@projektilski
Copy link
Author

projektilski commented Mar 19, 2024

They are not installed, but the uninstall option is available when right click on them.
Grammaryl, Spotify, and LinkedIn are spamming the Start Menu on a brand new profile.

EDIT: Spotify is installed and exe is located in the AppData folder, it offers an uninstall option. LinkedIn was downloading something when clicked but it did not open, uninstall was available. Grammary does not offer an uninstall option and points to Microsoft Store.

@Raphire
Copy link
Owner

Raphire commented Mar 20, 2024

It's interesting that the behaviour is so different between the 3 apps.

Could you confirm if they're actually recognized as installed and removable by running the following commands in powershell:

Spotify: Get-AppxPackage *spotify*

This is what I get after installing spotify:
image

LinkedIn: Get-AppxPackage *linkedin*

This is what I get after installing linkedin:
image

Grammarly: winget list grammarly

This is what I get after installing grammarly
image

@Raphire
Copy link
Owner

Raphire commented Mar 20, 2024

I have done some additional testing by doing a few fresh installs. In those installs Grammarly, LinkedIn, Spotify, and Luminar Neo do show up in the start menu, but none are installed. I also couldn't find any files related to Spotify, or any of the other 3 apps.

@projektilski
Copy link
Author

Hi, I did some testing also. If I understand correctly, your script removes apps for all users. When I create a new user on the same machine, all those apps are listed in Start Menu, but are not actually installed. Right click on them offers uninstall option, but what it actually does is to remove the pinned item.
So the real issue is how to remove those unwanted pinned items for new users.

p.s. I found a new app Journal which is not pinned in Start Menu but it is listed under All apps. It can be uninstalled via Powershell using Microsoft.MicrosoftJournal manifes name.

@Raphire
Copy link
Owner

Raphire commented Mar 21, 2024

Hi, I did some testing also. If I understand correctly, your script removes apps for all users. When I create a new user on the same machine, all those apps are listed in Start Menu, but are not actually installed. Right click on them offers uninstall option, but what it actually does is to remove the pinned item.
So the real issue is how to remove those unwanted pinned items for new users.

Exactly right, the UI does act as if they are installed (as they show an uninstall option), but they're not.

The annoying part is that these app links are, at least for a script like this, much harder to remove than the actual apps if they were installed. I'm looking into ways to have this script be able to unpin individual apps, but right now the only way I have found that works is replacing the whole start menu layout all together.

p.s. I found a new app Journal which is not pinned in Start Menu but it is listed under All apps. It can be uninstalled via Powershell using Microsoft.MicrosoftJournal manifes name.

I'll be adding support for this app to the script, thanks for bringing that to my attention 😀

@Raphire Raphire changed the title Option to remove Grammarly and Spotify Option to remove individuel pinned apps from the startmenu (ie. Grammarly and Spotify) Mar 25, 2024
@Raphire Raphire changed the title Option to remove individuel pinned apps from the startmenu (ie. Grammarly and Spotify) Option to remove individual pinned apps from the startmenu (ie. Grammarly and Spotify) Mar 25, 2024
@Raphire Raphire added enhancement New feature or request and removed bug Something isn't working labels Mar 25, 2024
@Raphire
Copy link
Owner

Raphire commented Mar 25, 2024

I've renamed the issue (and definitely didn't make a spelling mistake) to better reflect the feature requested.

@miladhatami1393
Copy link

Hi, I did some testing also. If I understand correctly, your script removes apps for all users. When I create a new user on the same machine, all those apps are listed in Start Menu, but are not actually installed. Right click on them offers uninstall option, but what it actually does is to remove the pinned item.
So the real issue is how to remove those unwanted pinned items for new users.

p.s. I found a new app Journal which is not pinned in Start Menu but it is listed under All apps. It can be uninstalled via Powershell using Microsoft.MicrosoftJournal manifes

@Raphire
Copy link
Owner

Raphire commented May 21, 2024

Hi, I did some testing also. If I understand correctly, your script removes apps for all users. When I create a new user on the same machine, all those apps are listed in Start Menu, but are not actually installed. Right click on them offers uninstall option, but what it actually does is to remove the pinned item. So the real issue is how to remove those unwanted pinned items for new users.

That's correct, the items are not installed so they cannot be removed. They only exist as a pinned item in the start menu binary. This binary (start2.bin) is stored per user at: C:\Users\{USERNAME}\AppData\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\LocalState

As the file is a binary it cannot be edited easily. That's why Win11Debloat can only clear the entire start menu by replacing this file with another.

p.s. I found a new app Journal which is not pinned in Start Menu but it is listed under All apps. It can be uninstalled via Powershell using Microsoft.MicrosoftJournal manifes

Win11Debloat should be able to uninstall this already. It's actually marked to be uninstalled as part of the default setting.

@sean-sauve
Copy link

@Raphire Instead of using start2.bin from another user, you could use Export-StartLayout and Import-StartLayout. That would make it easier for people to review and change over a bin file.

https://learn.microsoft.com/en-us/powershell/module/startlayout/import-startlayout

https://learn.microsoft.com/en-us/windows/configuration/start/layout?tabs=intune-10%2Cintune-11&pivots=windows-11

You could also have a "remove" function that exports the current start menu, opens the json and removes the lines for Spotify and saves it, and then imports the modified layout. Cost/benefit might be low on building that, but by working with structured data that Posh can understand it opens up more possibilities. These json files are also how Intune works to apply start menu configs, so you'd be in good company.

@Raphire
Copy link
Owner

Raphire commented Aug 28, 2024

@Raphire Instead of using start2.bin from another user, you could use Export-StartLayout and Import-StartLayout. That would make it easier for people to review and change over a bin file.

https://learn.microsoft.com/en-us/powershell/module/startlayout/import-startlayout

https://learn.microsoft.com/en-us/windows/configuration/start/layout?tabs=intune-10%2Cintune-11&pivots=windows-11

You could also have a "remove" function that exports the current start menu, opens the json and removes the lines for Spotify and saves it, and then imports the modified layout. Cost/benefit might be low on building that, but by working with structured data that Posh can understand it opens up more possibilities. These json files are also how Intune works to apply start menu configs, so you'd be in good company.

Unfortunately I don't think the Import-StartLayout cmdlet works for Windows 11.

It seems that for Windows 11 the layout you get from the Export-StartLayout cmdlet can only be applied by supported tools like InTune using policies. Even if I was able to do the same with the script, it would lead to a bad user experience, because according to the page you linked this would mean the start menu layout cannot be changed anymore by the user, quote:

Users can change the order of the pinned elements, pin, or unpin items. When a user signs in again, the Start layout specified in the policy setting is reapplied, without retaining any user changes.

If there is a different way to apply a Start layout I'd be happy to implement it into the script.

@sean-sauve
Copy link

Good point, I didn't know this didn't work for Windows 11 sorry.

@Raphire
Copy link
Owner

Raphire commented Aug 28, 2024

Good point, I didn't know this didn't work for Windows 11 sorry.

No worries! I appreciate you taking the time to look into this issue, it's just a shame Microsoft locked simple stuff like this down.

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

No branches or pull requests

4 participants