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

What does "pac solution version" do? #116

Closed
adhishrajgupta opened this issue Sep 24, 2021 · 1 comment
Closed

What does "pac solution version" do? #116

adhishrajgupta opened this issue Sep 24, 2021 · 1 comment
Labels
documentation Improvements or additions to documentation

Comments

@adhishrajgupta
Copy link

How and when is the pac solution version command supposed to be used? The documentation on that is very sparse so will appreciate any guidance on that.

@davidjenni
Copy link
Member

davidjenni commented Nov 1, 2021

@adhishrajgupta pac solution version purpose is to mutate the patch version in a local solution.xml file (result of an extracted/unpacked solution.zip in the local file system).

It has 4 strategies to increment the patch part of the major.minor.patch triple found in solution.xml.
All follow the same flow:

  1. determine from the "version persistence" the last assigned patch version
  2. increment it by 1
  3. mutate/update the local solution.xml in the local git repo's file system
  4. store new version back into that "version persistence":

The 4 different version persistence strategies are:

  • git tags: last assigned version is assigned a git tag in the local repo and pushed to the remote/origin repo
  • filetracking: creates and maintains a local .csv file (needs to be saved and/or committed to git repo)
  • solution: directly use the version triple found in the solution.xml
  • directly use a CI/CD system's build id variable, e.g. for Azure DevOps: Build.BuildId with the --patchversion parameter

There's existing documentation, although not very rich:
https://docs.microsoft.com/en-us/powerapps/developer/data-platform/cli/reference/solution-command

@davidjenni davidjenni added the documentation Improvements or additions to documentation label Nov 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants