-
Notifications
You must be signed in to change notification settings - Fork 16
pacx webresources push
Push web resources from a local folder to the target environment
pacx wr pushThis command is basically a simple Command Line based replacement for XrmToolbox WebResource Manager
--- work in progress ---
To deploy all the webresources that are in the current folder to the target environment, you can use the following command:
pacx webresources pushThe command will:
- Connect to the target environment
- Compare the the list of files in the current folder with the list of webresources in the target environment
- Upload the webresources that are missing in the target environment
- Update the webresources that are different in the target environment
- Add the webresources to the solution (if not already added previously)
- Publish the webresources
If you want to deploy a specific webresource file, you can specify the path to the file:
pacx webresources push --path "C:\path\to\file.js"
pacx webresources push --path "file.js"If you used pacx wr init to initialize the webresource project, you can use the $ special token to refer to the nearest project root folder, navigating up from the current folder.
It will take only the files that are below <project root folder>/<current solution publisher prefix>_.
For example, imagine to have the following project structure:
Webresources/
new_/
scripts/
account.js
pages/
home/
home.css
home.js
home.html
home_react_source/
src/
...
.wr.pacxAnd you are placed under the Webresources/home_react_source/src folder, by typing:
pacx webresources push -p $It will:
- Navigate up from the current folder until it comes to the folder containing the
.wr.pacxfile - From there, navigates under the
new_folder (assuming thatnewis the customization prefix of the current solution publisher) - Recourse all the folders under
new_, take all the files to deploy them to the target environment
You can also use the $ to target a specific subfolder:
pacx webresources push -p $\scriptsYou can also use the * wildcard in the file name to match for files with a specific extension. For example, the following command will deploy all the files with the .js extension from the current folder:
pacx webresources push