Open ccrvincent opened 5 years ago
Follow-up:
I manually bumped the version in pipeline-state
and got this:
bumped locally from 1.1.3-pr.project-pr-chad-pipeline-test.2 to 1.1.3-pr.project-pr-chad-pipeline-test.1
But if I switch the period in the pre
to a hyphen, it works just fine.
Looks like period is an invalid character in pre
, as the pre
value will not match properly but will get applied after the "bump".
If using a hyphen is acceptable, should we just update the README?
Using the hyphen requires some sed
work on both sides, as most of our other tools took the semver spec on pre-release notation rather literally, and are expecting the period.
Got it. Well, the bug probably lies in pre_bump.go
- we don't have a whole lot of bandwidth to work on each of the resources, but I'd be happy to review a PR. The handling of v.Pre
seems a bit sketch - it looks like it has 0
and 1
indices hardcoded, whereas it should probably be handling an arbitrary length and only expecting the last 'pre' part to be numeric.
Config:
When the increment-pr task runs, I get the same output as the input:
bumped locally from 1.1.2-pr.project-pr-chad-pipeline-test.1 to 1.1.2-pr.project-pr-chad-pipeline-test.1
Any idea why the patch isn't bumping? Does it not like/allow a period?
The value of pre can be anything you like; the value will be pre-pended (hah) to a numeric value.