-
Hello! I'm trying out the Nyx versioning, and ran into an issue, where I don't quite understand the output. The situation is as follows: I've made a sample (local) repository, made some commits into it (having them named in accordance with Conventional Commits) and finally ran nyx to see the result. However the result were not as I would expect. For the record, here's how the commit tree looks like: and here's the output: Now here's the thing I don't quite understand. I would expect for that repository, that the "infer" command would output the current version as "1.2.2", as there are one "Breaking Change", two "feat" and two "fix" commits. Instead it out put current version as "1.1.0". Have I misinterpreted the documentation, or perhaps skipped some other configuration step? I would kindly ask for clarifiaction. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
Hi @Szejgu , version increments are shrinked so only the most significant numbers (the minor in this case) since the last tagged commit are bumped. It would yield to the behavior you expected if you run Nyx at every commit to tag a new release. |
Beta Was this translation helpful? Give feedback.
-
Ah, I see. So just to make sure that I understood correctly: Nyx will "count" the version in relation to the previous tag in the repository, and the currently checked-out commit, right? If the tag in my example would be "3.1.2", and the current commit wouldv'e been a "feat", then the "infer" would yield version "3.2.0", correct? |
Beta Was this translation helpful? Give feedback.
-
Correct. In other words Nyx sets the boundaries of the scope by determining the set of significant commits which are, indeed, the current one (HEAD) back to the latest tagged commit excluded. |
Beta Was this translation helpful? Give feedback.
Correct. In other words Nyx sets the boundaries of the scope by determining the set of significant commits which are, indeed, the current one (HEAD) back to the latest tagged commit excluded.
Then it figures out which identifier was supposed to be bumped by any commit by inspecting the commit message and determines the least increment, considering that incrementing a number resets the least significants to 0.