I have created .ps1(powershell) script to copy the files to %userprofile%. that is tested and working fine in os. when we are publishing the app-v package included with ps1 script.the script is running fine. but i didn't able to see the file any where. more over could you please help me to ans the below queries. 1) Diff b\w (PublishPackage) and (AddPackage). when the scripts will execute if we add the two locations? 2)Where can we see the userprofile date which was copied with the help of any scripts(vbs,ps1,cmd,bat..etc) Much thanks in advance..
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Community Chosen Answer

1

1. AddPackage - When the script is placed in Addpackage script type, it gets executed when the App-V package is added or registered to the machine. It gets executed when running the below command.

Add-AppvClientPackage "name" -DynamicDeploymentConfiguration "path to the deploymentconfig.xml"

PublishPackage - The script gets executed when the package is being published to the machine during Publish-AppvClientPackage event.

deploymentconfig.xml file can be used along with the Add-AppvClientPackage only. Userconfig.xml can be used along with Publish-AppvClientPackage only.If package is being published global using -global, Userconfig.xml cannot be used only deploymentconfig.xml can be used.

2.And coming to  script to copy the files to %userprofile%, I guess you would have kept the script to run in systemcontext(machineconfiguration in DeploymentConfig.xml) that's what it has failed. Keep it in the Userconfiguration (Sourcesection)- Publishpackage (script type) section inside the DeploymentConfig.xml. This would run the script in user context so that %userprofile% entries are populated.

NOTE: If you keep script in UserConfiguration section, then it should be tested only in domain joined machines. It will not work in local account.


Answered 10/29/2015 by: apptopack
Red Belt

Please log in to comment

Answers

0
You can use powershell to check for the updated userprofile files. Sample scripts are available in Technet gallery.
Answered 11/02/2015 by: apptopack
Red Belt

Please log in to comment
Answer this question or Comment on this question for clarity