diff --git a/README.md b/README.md index d7125915..95ea51df 100644 --- a/README.md +++ b/README.md @@ -324,6 +324,20 @@ Allows specifying a custom version in the `version` field. If there is a use case missing from Builder, feel free to create a feature request. +#### allowDirtyBuild + +Allows the branch of the build to be dirty, and still generate the build. + +```yaml +- uses: webbertakken/unity-builder@ + with: + allowDirtyBuild: true +``` + +Note that it is generally bad practice to modify your branch +in a CI Pipeline. However there are exceptions where this might +be needed. (use with care). + #### customParameters Custom parameters to configure the build. diff --git a/src/model/versioning.test.js b/src/model/versioning.test.js index f850be65..631f563e 100644 --- a/src/model/versioning.test.js +++ b/src/model/versioning.test.js @@ -90,6 +90,16 @@ describe('Versioning', () => { }); }); + describe('isDirtyAllowed', () => { + it('does not throw', () => { + expect(() => Versioning.isDirtyAllowed).not.toThrow(); + }); + + it('returns false by default', () => { + expect(Versioning.isDirtyAllowed).toStrictEqual(false); + }); + }); + describe('descriptionRegex', () => { it('is a valid regex', () => { expect(Versioning.descriptionRegex).toBeInstanceOf(RegExp);