How to merge Windows 11 taskbar icons when they have different targets?

I’ve created a PowerShell script that updates Spicetify whenever I open Spotify via the shortcut in my “C:UsersUSERNAMEAppDataRoamingMicrosoftWindowsStart MenuPrograms” directory. The script consists of some code that closes Spotify, updates Spicetify and the Spicetify Marketplace, and finally it reopens Spotify. Here’s the code below that does this:

spicetify.ps1

# Close Spotify if it's running
Stop-Process -Name "Spotify" -Force -ErrorAction SilentlyContinue

# Update Spicetify
spicetify
spicetify backup
spicetify upgrade
Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/spicetify/spicetify-marketplace/main/resources/install.ps1" | Invoke-Expression
spicetify restore backup apply

# Reopen Spotify after updates
Start-Process "$env:APPDATASpotifySpotify.exe" -WindowStyle Normal

To make the Spotify shortcut in the “C:UsersUSERNAMEAppDataRoamingMicrosoftWindowsStart MenuPrograms” directory to run my script instead of the Spotify executable, I set the “target” of the shortcut to: “PowerShell -WindowStyle hidden -ExecutionPolicy Bypass -File “C:UsersUSERNAMEspicetify.ps1”” which then starts my script and immediately minimizes the window. Once the script finishes successfully, Spotify opens with Spicetfiy applied.

Here’s an image of the “Target” where I paste “PowerShell -WindowStyle hidden -ExecutionPolicy Bypass -File “C:UsersUSERNAMEspicetify.ps1”“:

Now the issue arises. If I have the Spotify shortcut pinned to my taskbar AND I have the Spotify application open, the taskbar will show 2 icons for “Spotify”, one of them is the shortcut that runs my script and the other is the actual Spotify application.

Here’s an image of the two Spotify taskbar icons:

The left icon is the actual Spotify application and the right one is my shortcut script.

I have noticed that some applications do this as well(e.g Parsec), but most seem to replace taskbar’s icon with the running application icon. I’m not entirely sure if the reason why they aren’t combined into one icon is because of the different targets or not, so I didn’t exactly know how to title this question on the post without all these details I’ve given. So, is there some way to make my shortcut script icon on the taskbar get replaced by the actual Spotify application icon so that there’s not 2 icons for the same application on the taskbar?

I attempted to go to the installation path of Spotify to try to run my script on the actual executable for Spotify, but you can’t seem to change the target or run a command in parallel to the application’s startup.

Here’s an image of the actual Spotify executable properties:

I’ve also checked that my taskbar settings are set to combine buttons automatically:

I also know (but haven’t attempted) that you can run commands automatically via the Windows Task Scheduler whenever an application like Spotify is started.

If there is no way to do what I’m looking to do, then I’ll go the Windows Task Scheduler route instead.

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật