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

strict: false flag seems to not work #20

Closed
joonasjarvinen92 opened this issue Mar 30, 2023 · 4 comments
Closed

strict: false flag seems to not work #20

joonasjarvinen92 opened this issue Mar 30, 2023 · 4 comments
Assignees
Labels
bug Something isn't working to be confirmed

Comments

@joonasjarvinen92
Copy link

Describe the bug

Hi! I tried adding a strict: false flag to the pipeline but the PATCH version seems to not increment when there are no matching keywords.

Output with debug
[ paste output of the command with -d flag here ]

Expected behavior

If the strict flag is false, the PATCH number should increment without matching keywords.

Additional context

  • Noticed the warning about the strict flag

image

  • Not sure if the !params.varStrict in code should be without negation?
if !params.varStrict && !s.Force.Strict {
	s.Semver.Patch++
	debugPrint(fmt.Sprintln("Incrementing patch (DEFAULT) on ", strings.TrimSuffix(commit.Message, "\n"), "| Semver:", s.getSemver()))
}
@lukaszraczylo
Copy link
Owner

Could you try doing the same with the strict mode in yaml file?

For example

version: 1
force:
  major: 1
  existing: false
  strict: false
wording:
  patch:
    - update
    - initial
    - fix
  minor:
    - change
    - improve
  major:
    - breaking
  release:
    - release-candidate

@lukaszraczylo
Copy link
Owner

Released update (1.10.109), now, the strict mode should work if the parameter is supplied :)

@joonasjarvinen92
Copy link
Author

Sorry this was my bad, I had the strict flag set to true in the config file and false in the action. Now it works great!

@lukaszraczylo
Copy link
Owner

Not a problem - at least motivated me to add the missing flags to the action as well :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working to be confirmed
Projects
None yet
Development

No branches or pull requests

2 participants