Set-ItemProperty : Cannot find path
I am running PDQ deploy. I have made a new package with 1 PowerShell step. I have the PowerShell.ps1 in question located on the network share that all of the other(working) packages are also using. The script in question is working great locally, no problems when I pull the .ps1 from the file share to the local machine and run it. The purpose of the script is to change the registry key value of the path noted to '2'.
When I attempt to deploy it to a machine I get a an error noted below, which is confusing because that registry key exists, I've checked manually on the machine I'm testing.
The script in question is only one line as you can see below. The ExecutionPolicy is being bypassed and all that good stuff.
It is very likely that I'm just incorrectly using some of the cmdlets, however, I wanted to post here to use this opportunity to learn as I've had similar problems deploying .ps1 scripts in the past. I surmise that for some reason the deploy user(domain admin) account can't see the registry of the computer I'm deploying to? Any help would be appreciated.
Set-ItemProperty -Path Registry::HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Feeds -Name ShellFeedsTaskbarViewMode -Value 2
Set-ItemProperty : Cannot find path 'HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Feeds' because it
does not exist.
At C:\windows\AdminArsenal\PDQDeployRunner\service-1\exec\FeedKill.ps1:2 char:1
+ Set-ItemProperty -Path Registry::HKEY_CURRENT_USER\SOFTWARE\Microsoft ...
+ CategoryInfo : ObjectNotFound: (HKEY_CURRENT_US...ntVersion\Feeds:String) [Set-ItemProperty], ItemNotFo
+ FullyQualifiedErrorId : PathNotFound,Microsoft.PowerShell.Commands.SetItemPropertyCommand