├── .github ├── CODEOWNERS ├── FUNDING.yml ├── renovate.json ├── PUBLISHING.md └── workflows │ ├── fix-checks.yaml │ ├── apply-format.yaml │ ├── dump-api.yaml │ ├── build-changelog-renovate-bot.yaml │ ├── publish-kotlin.yaml │ ├── build-kotlin.yaml │ ├── build-kotlin-dispatcher.yaml │ └── generate-version-tag.yaml ├── semver-project-gradle-plugin ├── testFunctional │ ├── resources │ │ ├── push-tag │ │ │ ├── last-tag.txt │ │ │ ├── expect-version.txt │ │ │ ├── settings.gradle.kts │ │ │ └── build.gradle.kts │ │ ├── github-variables │ │ │ ├── last-tag.txt │ │ │ ├── build.gradle.kts │ │ │ ├── library │ │ │ │ └── build.gradle.kts │ │ │ ├── gradle.properties │ │ │ └── settings.gradle.kts │ │ ├── tags-order │ │ │ └── random │ │ │ │ ├── last-tag.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ └── build.gradle.kts │ │ ├── properties │ │ │ ├── log-on-all-projects │ │ │ │ ├── last-tag.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── build.gradle.kts │ │ │ │ ├── settings.gradle.kts │ │ │ │ ├── library-one │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── library-two │ │ │ │ │ └── build.gradle.kts │ │ │ ├── empty │ │ │ │ ├── auto 1_0_0+hash │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ ├── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ └── settings.gradle.kts │ │ │ │ ├── auto v1_0_0+hash │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto 1_0_0+timestamp │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ ├── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ └── settings.gradle.kts │ │ │ │ └── auto v1_0_0+timestamp │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── library │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ ├── log-only-on-root-project │ │ │ │ ├── last-tag.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── build.gradle.kts │ │ │ │ ├── settings.gradle.kts │ │ │ │ ├── library-one │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── library-two │ │ │ │ │ └── build.gradle.kts │ │ │ ├── scope │ │ │ │ ├── auto 1_0_0 to 1_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ ├── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ └── settings.gradle.kts │ │ │ │ ├── auto v1_0_0 to v1_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── major v1_0_0 to v2_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── minor v1_0_0 to v1_1_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── patch v1_0_0 to v1_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── malformed buildAndFail (1) │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto v1_0_0-beta.5 to v1_0_0-beta.6 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto v1_0_0-alpha.1 to v1_0_0-alpha.2 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── library │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ └── build.gradle.kts │ │ │ ├── stage │ │ │ │ ├── beta v1_0_0 to v1_0_1-beta_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── gradle.properties │ │ │ │ ├── alpha v1_0_0 to v1_0_1-alpha_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── final v1_0_0-alpha_1 to v1_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── gradle.properties │ │ │ │ ├── alpha v1_0_0-alpha-1 to v1_0_1-alpha_2 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── snapshot v1_0_0-rc_3 to v1_0_0-SNAPSHOT │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── gradle.properties │ │ │ │ └── snapshot v1_0_0-alpha_1 to v1_0_0-SNAPSHOT │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── gradle.properties │ │ │ └── stage+scope │ │ │ │ ├── auto+auto │ │ │ │ ├── auto+auto v1_0_0 to v1_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto+auto v1_0_0-rc.11 to v1_0_0-rc.12 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── auto+auto v1_0_0-alpha.1 to v1_0_0-alpha.2 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── rc+auto │ │ │ │ ├── rc+auto v1_0_0 to v1_0_1-rc.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── rc+auto v1_0_0-rc.11 to v1_0_0-rc.12 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── rc+auto v1_0_0-alpha.1 to v1_0_0-rc.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto+major │ │ │ │ ├── auto+major v1_0_0 to v2_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto+major v1_0_0-rc.11 to v2_0_0-rc.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── auto+major v1_0_0-alpha.1 to v2_0_0-alpha.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto+minor │ │ │ │ ├── auto+minor v1_0_0 to v1_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto+minor v1_0_0-rc.11 to v1_1_0-rc.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── auto+minor v1_0_0-alpha.1 to v1_1_0-alpha.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto+patch │ │ │ │ ├── auto+patch v1_0_0 to v1_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── auto+patch v1_0_0-rc.11 to v1_0_1-rc.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── auto+patch v1_0_0-alpha.1 to v1_0_1-alpha.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── final+auto │ │ │ │ ├── final+auto v1_0_0 to v1_0_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── final+auto v1_2_0 to v1_2_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── final+auto v1_0_0-rc.11 to v1_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── final+auto v1_0_0-alpha.1 to v1_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── alpha+auto │ │ │ │ ├── alpha+auto v1_0_0 to v1_0_1-alpha.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── alpha+auto v1_0_0-rc.11 buildAndFail │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── alpha+auto v1_0_0-alpha.1 to v1_0_0-alpha.2 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── beta+auto │ │ │ │ ├── beta+auto v1_0_0 to v1_0_1-beta.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── beta+auto v1_0_0-rc.11 buildAndFail │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── beta+auto v1_0_0-alpha.1 to v1_0_0-beta.1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── alpha+major │ │ │ │ ├── alpha+major v1_0_0 to v2_0_0-alpha_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── library │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── alpha+minor │ │ │ │ └── alpha+minor v1_0_0 to v1_1_0-alpha_1 │ │ │ │ │ ├── last-tag.txt │ │ │ │ │ ├── expect-version.txt │ │ │ │ │ ├── settings.gradle.kts │ │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ │ └── build.gradle.kts │ │ │ │ └── alpha+patch │ │ │ │ └── alpha+patch v1_0_0 to v1_0_1-alpha_1 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ └── build.gradle.kts │ │ ├── version-build-dir │ │ │ ├── clean v1_0_0 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ └── build.gradle.kts │ │ │ ├── clean v1_0_0 configuration phase │ │ │ │ ├── last-tag.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ ├── build.gradle.kts │ │ │ │ └── gradle.properties │ │ │ ├── clean-with-no-tag-current-commit (hash) │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ └── build.gradle.kts │ │ │ └── no-clean-with-no-tag-current-commit (dirty) │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ └── build.gradle.kts │ │ ├── version-mapping │ │ │ ├── v0_2_0+2_0_10 │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── last-tag.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ └── build.gradle.kts │ │ │ └── v1_0_0 to v1_0_0+1_9_0 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── expect-version.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ └── build.gradle.kts │ │ ├── gradle-features │ │ │ ├── build cache clean v1_0_0 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── src │ │ │ │ │ └── main │ │ │ │ │ │ └── kotlin │ │ │ │ │ │ └── Main.kt │ │ │ │ ├── build.gradle.kts │ │ │ │ ├── gradle.properties │ │ │ │ └── settings.gradle.kts │ │ │ ├── android build cache clean v1_0_0 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── gradle.properties │ │ │ │ ├── settings.gradle.kts │ │ │ │ └── build.gradle.kts │ │ │ ├── configuration cache clean v1_0_0 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── src │ │ │ │ │ └── main │ │ │ │ │ │ └── kotlin │ │ │ │ │ │ └── Main.kt │ │ │ │ ├── build.gradle.kts │ │ │ │ ├── settings.gradle.kts │ │ │ │ └── gradle.properties │ │ │ ├── project isolation clean v1_0_0 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── build.gradle.kts │ │ │ │ ├── library-a │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── library-b │ │ │ │ │ └── build.gradle.kts │ │ │ │ ├── gradle.properties │ │ │ │ └── settings.gradle.kts │ │ │ └── android configuration cache clean v1_0_0 │ │ │ │ ├── last-tag.txt │ │ │ │ ├── ARGUMENTS.txt │ │ │ │ ├── settings.gradle.kts │ │ │ │ ├── gradle.properties │ │ │ │ └── build.gradle.kts │ │ └── examples │ │ │ ├── one-project │ │ │ ├── settings.gradle.kts │ │ │ ├── build.gradle.kts │ │ │ └── gradle.properties │ │ │ └── multi-project │ │ │ ├── library-nine │ │ │ └── build.gradle.kts │ │ │ ├── library-ten │ │ │ └── build.gradle.kts │ │ │ ├── gradle.properties │ │ │ ├── library-five-b │ │ │ └── build.gradle.kts │ │ │ ├── library-four-b │ │ │ └── build.gradle.kts │ │ │ ├── library-one-a │ │ │ └── build.gradle.kts │ │ │ ├── library-six-c │ │ │ └── build.gradle.kts │ │ │ ├── library-two-b │ │ │ └── build.gradle.kts │ │ │ ├── library-eight-c │ │ │ └── build.gradle.kts │ │ │ ├── library-seven-c │ │ │ └── build.gradle.kts │ │ │ ├── library-three-b │ │ │ └── build.gradle.kts │ │ │ └── settings.gradle.kts │ └── kotlin │ │ └── com │ │ └── javiersc │ │ └── semver │ │ └── project │ │ └── gradle │ │ └── plugin │ │ ├── VersionMappingTest.kt │ │ └── PushSemverTagTaskTest.kt ├── MODULE.md ├── main │ └── kotlin │ │ └── com │ │ └── javiersc │ │ └── semver │ │ └── project │ │ └── gradle │ │ └── plugin │ │ ├── internal │ │ ├── InitialVersion.kt │ │ ├── getProjectTagPrefix.kt │ │ ├── git │ │ │ └── GitRef.kt │ │ ├── Checkers.kt │ │ ├── SemVerMessages.kt │ │ └── SemverProperty.kt │ │ ├── VersionMapper.kt │ │ ├── VersionProperty.kt │ │ ├── GitRefs.kt │ │ ├── extensions │ │ └── isVersionExtensions.kt │ │ ├── tasks │ │ ├── PushSemverTagTask.kt │ │ ├── CreateSemverTagTask.kt │ │ └── WriteSemverTask.kt │ │ ├── SemverProjectPlugin.kt │ │ └── SemverExtension.kt ├── test │ └── kotlin │ │ └── com │ │ └── javiersc │ │ └── semver │ │ └── project │ │ └── gradle │ │ └── plugin │ │ ├── GitBranchTest.kt │ │ ├── VersionTest.kt │ │ └── ExtensionTests.kt ├── testFixtures │ └── kotlin │ │ └── com │ │ └── javiersc │ │ └── semver │ │ └── project │ │ └── gradle │ │ └── plugin │ │ └── GitUtils.kt └── build.gradle.kts ├── gradle-version ├── MODULE.md ├── build.gradle.kts └── main │ └── kotlin │ └── com │ └── javiersc │ └── gradle │ └── version │ └── IsExtensions.kt ├── semver-settings-gradle-plugin ├── testFunctional │ ├── resources │ │ ├── multi-project │ │ │ ├── library-one │ │ │ │ └── build.gradle.kts │ │ │ ├── build.gradle.kts │ │ │ ├── library-two │ │ │ │ └── build.gradle.kts │ │ │ ├── library-three │ │ │ │ └── build.gradle.kts │ │ │ └── settings.gradle.kts │ │ ├── multi-project-basic │ │ │ ├── library-one │ │ │ │ ├── build.gradle.kts │ │ │ │ └── gradle.properties │ │ │ ├── library-two │ │ │ │ ├── build.gradle.kts │ │ │ │ └── gradle.properties │ │ │ ├── gradle.properties │ │ │ └── settings.gradle.kts │ │ ├── project-with-included-build │ │ │ ├── library-one │ │ │ │ ├── build.gradle.kts │ │ │ │ └── gradle.properties │ │ │ ├── build-logic │ │ │ │ ├── module-a │ │ │ │ │ ├── build.gradle.kts │ │ │ │ │ └── gradle.properties │ │ │ │ ├── gradle.properties │ │ │ │ └── settings.gradle.kts │ │ │ ├── gradle.properties │ │ │ └── settings.gradle.kts │ │ └── multi-project-with-included-build │ │ │ ├── library-one │ │ │ └── build.gradle.kts │ │ │ ├── build.gradle.kts │ │ │ ├── library-two │ │ │ └── build.gradle.kts │ │ │ ├── library-three │ │ │ └── build.gradle.kts │ │ │ └── settings.gradle.kts │ └── kotlin │ │ └── com │ │ └── javiersc │ │ └── semver │ │ └── settings │ │ └── gradle │ │ └── plugin │ │ ├── utils │ │ └── createGitIgnore.kt │ │ ├── ProjectTest.kt │ │ └── MultiProjectTest.kt ├── MODULE.md ├── api │ └── semver-settings-gradle-plugin.api ├── main │ └── kotlin │ │ └── com │ │ └── javiersc │ │ └── semver │ │ └── settings │ │ └── gradle │ │ └── plugin │ │ ├── SemverSettingsPlugin.kt │ │ └── SemverSettingsExtension.kt └── build.gradle.kts ├── .docs ├── docs │ ├── assets │ │ └── favicon.png │ └── css │ │ └── all.css ├── changelogs │ ├── CHANGELOG_0.4.0.md │ ├── CHANGELOG_0.2.0.md │ └── CHANGELOG_0.3.0.md └── mkdocs.yml ├── gradle ├── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties └── libs.versions.toml ├── .gitignore ├── semver-gradle-plugin ├── api │ └── semver-gradle-plugin.api ├── MODULE.md ├── main │ └── kotlin │ │ └── com │ │ └── javiersc │ │ └── semver │ │ └── gradle │ │ └── plugin │ │ └── SemverPlugin.kt └── build.gradle.kts ├── settings.gradle.kts ├── .gitattributes ├── LICENSE.txt ├── gradle.properties └── gradlew.bat /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | * @JavierSegoviaCordoba 2 | -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | github: JavierSegoviaCordoba 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/push-tag/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/github-variables/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/tags-order/random/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.1.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-on-all-projects/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v0_2_0+2_0_10/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | build 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+hash/last-tag.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+hash/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-only-on-root-project/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto 1_0_0 to 1_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v0_2_0+2_0_10/last-tag.txt: -------------------------------------------------------------------------------- 1 | 0.2.0+2.0.10 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/build cache clean v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+hash/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | printSemver 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+timestamp/last-tag.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+timestamp/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0 to v1_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/push-tag/expect-version.txt: -------------------------------------------------------------------------------- 1 | 0.1.0-rc.13 2 | v0.1.0-rc.13 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v1_0_0 to v1_0_0+1_9_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+timestamp/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | printSemver 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/malformed buildAndFail (1)/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/beta v1_0_0 to v1_0_1-beta_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/push-tag/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/tags-order/random/expect-version.txt: -------------------------------------------------------------------------------- 1 | 0.1.0-rc.13 2 | v0.1.0-rc.13 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android build cache clean v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/build cache clean v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | writeSemver 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/configuration cache clean v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/project isolation clean v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-on-all-projects/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0 to v1_0_1-alpha_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0 configuration phase/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | v1.0.0 3 | -------------------------------------------------------------------------------- /gradle-version/MODULE.md: -------------------------------------------------------------------------------- 1 | # Module gradle-version 2 | 3 | Semantic versioning implementation with Gradle version ordering rules 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android build cache clean v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | writeSemver 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/configuration cache clean v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | assemble 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-only-on-root-project/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto 1_0_0 to 1_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | 1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0 to v1_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 2.0.0 2 | v2.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.1.0 2 | v1.1.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/final v1_0_0-alpha_1 to v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/tags-order/random/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | build -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project/library-one/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | -------------------------------------------------------------------------------- /.docs/docs/assets/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JavierSegoviaCordoba/semver-gradle-plugin/HEAD/.docs/docs/assets/favicon.png -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/one-project/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android configuration cache clean v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v0.9.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+hash/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | printSemver -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-beta.5 to v1_0_0-beta.6/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-beta.5 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0 to v1_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0 to v1_0_1-rc.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean-with-no-tag-current-commit (hash)/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v0_2_0+2_0_10/expect-version.txt: -------------------------------------------------------------------------------- 1 | 0.2.0+2.0.10 2 | 0.2.0+2.0.10 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v1_0_0 to v1_0_0+1_9_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | build -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-basic/library-one/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-basic/library-two/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JavierSegoviaCordoba/semver-gradle-plugin/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android configuration cache clean v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | printSemver 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/project isolation clean v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | printSemver --stacktrace 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+hash/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.3+HASH 2 | 1.0.0.3+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+hash/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.3+HASH 2 | v1.0.0.3+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+timestamp/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | printSemver -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-alpha.1 to v1_0_0-alpha.2/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0 to v2_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0 to v1_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0 to v1_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0 to v1_0_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_2_0 to v1_2_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.2.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0-alpha-1 to v1_0_1-alpha_2/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/final v1_0_0-alpha_1 to v1_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | v1.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-rc_3 to v1_0_0-SNAPSHOT/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.3 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/no-clean-with-no-tag-current-commit (dirty)/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+timestamp/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+DIRTY 2 | 1.0.0.2+DIRTY 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+timestamp/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+DIRTY 2 | v1.0.0.2+DIRTY 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto 1_0_0 to 1_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=auto 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0 to v1_0_1-alpha.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0 to v1_0_1-beta.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-alpha_1 to v1_0_0-SNAPSHOT/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0 configuration phase/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | v1.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v0_2_0+2_0_10/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v1_0_0 to v1_0_0+1_9_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0+1.9.0 2 | v1.0.0+1.9.0 3 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/library-one/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | -------------------------------------------------------------------------------- /.github/renovate.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": [ 3 | "github>JavierSegoviaCordoba/reusable-workflows//.github/renovate-reusable.json" 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+minor/alpha+minor v1_0_0 to v1_1_0-alpha_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+patch/alpha+patch v1_0_0 to v1_0_1-alpha_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0 to v1_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-rc.11 buildAndFail/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-rc.11 to v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-rc.11 to v1_0_0-rc.12/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/beta v1_0_0 to v1_0_1-beta_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-beta.1 2 | v1.0.1-beta.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0 configuration phase/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | build -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v1_0_0 to v1_0_0+1_9_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-with-included-build/library-one/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/build-logic/module-a/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | -------------------------------------------------------------------------------- /gradle/libs.versions.toml: -------------------------------------------------------------------------------- 1 | [versions] 2 | hubdle = "0.18.0" 3 | 4 | [plugins] 5 | javiersc-hubdle = { id = "com.javiersc.hubdle", version.ref = "hubdle" } 6 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+hash/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/malformed buildAndFail (1)/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-rc.11 buildAndFail/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-rc.11 to v1_0_0-rc.12/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0 to v2_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 2.0.0 2 | v2.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-rc.11 to v2_0_0-rc.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0 to v1_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.1.0 2 | v1.1.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-rc.11 to v1_1_0-rc.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0 to v1_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-rc.11 to v1_0_1-rc.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-rc.11 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0 to v1_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-alpha.1 to v1_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_2_0 to v1_2_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.2.1 2 | v1.2.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-alpha.1 to v1_0_0-rc.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0 to v1_0_1-alpha_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-alpha.1 2 | v1.0.1-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean-with-no-tag-current-commit (hash)/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | build -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-nine/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-ten/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+timestamp/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto 1_0_0 to 1_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-beta.5 to v1_0_0-beta.6/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-beta.6 2 | v1.0.0-beta.6 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 2.0.0 2 | v2.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.1.0 2 | v1.1.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1 2 | v1.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-alpha.1 to v2_0_0-alpha.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-alpha.1 to v1_1_0-alpha.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-alpha.1 to v1_0_1-alpha.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-alpha.1 to v1_0_0-beta.1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0-alpha.1 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-alpha.1 to v1_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | v1.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-rc.11 to v1_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | v1.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0 to v1_0_1-alpha_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/beta v1_0_0 to v1_0_1-beta_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/final v1_0_0-alpha_1 to v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/no-clean-with-no-tag-current-commit (dirty)/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | build -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .gradle 2 | **/.gradle/**/* 3 | 4 | .idea/ 5 | .kotlin/ 6 | 7 | build 8 | **/build/**/* 9 | 10 | coverage-error.log 11 | local.properties 12 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+hash/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+hash/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0 to v1_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-alpha.1 to v1_0_0-alpha.2/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-alpha.2 2 | v1.0.0-alpha.2 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 4.0.0 2 | w4.0.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 3.1.0 2 | w3.1.0 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 3.0.1 2 | w3.0.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0 to v1_0_1-rc.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-rc.1 2 | v1.0.1-rc.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0-alpha-1 to v1_0_1-alpha_2/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-alpha.2 2 | v1.0.0-alpha.2 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-rc_3 to v1_0_0-SNAPSHOT/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-SNAPSHOT 2 | v1.0.0-SNAPSHOT 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/tags-order/random/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0 configuration phase/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean-with-no-tag-current-commit (hash)/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+HASH 2 | v1.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+timestamp/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+timestamp/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto 1_0_0 to 1_0_1/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=major -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=minor -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+HASH 2 | v1.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=patch -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-alpha.1 to v1_0_0-rc.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-rc.1 2 | v1.0.0-rc.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-rc.11 to v1_0_0-rc.12/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-rc.12 2 | v1.0.0-rc.12 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0-alpha-1 to v1_0_1-alpha_2/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-alpha_1 to v1_0_0-SNAPSHOT/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-SNAPSHOT 2 | v1.0.0-SNAPSHOT 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-rc_3 to v1_0_0-SNAPSHOT/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean-with-no-tag-current-commit (hash)/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/no-clean-with-no-tag-current-commit (dirty)/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+DIRTY 2 | v1.0.0.2+DIRTY 3 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+hash/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+hash/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+HASH 2 | v1.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/malformed buildAndFail (1)/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=fdfadsaa -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+HASH 2 | v1.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0 to v1_0_1-alpha.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-beta.1 2 | v1.0.1-beta.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/last-tag.txt: -------------------------------------------------------------------------------- 1 | v1.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0 to v1_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-rc.11 to v1_0_0-rc.12/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-rc.12 2 | v1.0.0-rc.12 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0 to v2_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-rc.11 to v2_0_0-rc.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 2.0.0-rc.1 2 | v2.0.0-rc.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0 to v1_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-rc.11 to v1_1_0-rc.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.1.0-rc.1 2 | v1.1.0-rc.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0 to v1_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-rc.11 to v1_0_1-rc.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-rc.1 2 | v1.0.1-rc.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0 to v1_0_1-beta.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-beta.1 2 | v1.0.1-beta.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0 to v1_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_2_0 to v1_2_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0 to v1_0_1-rc.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0 to v1_0_1-alpha_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/beta v1_0_0 to v1_0_1-beta_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=beta -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/final v1_0_0-alpha_1 to v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=final -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-alpha_1 to v1_0_0-SNAPSHOT/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/no-clean-with-no-tag-current-commit (dirty)/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto 1_0_0+timestamp/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+timestamp/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto 1_0_0 to 1_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0 to v1_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-alpha.1 to v1_0_0-alpha.2/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-beta.5 to v1_0_0-beta.6/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 3.0.0.2+HASH 2 | w3.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 3.0.0.2+HASH 2 | w3.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 3.0.0.2+HASH 2 | w3.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 2.0.0-alpha.1 2 | v2.0.0-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+minor/alpha+minor v1_0_0 to v1_1_0-alpha_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.1.0-alpha.1 2 | v1.1.0-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+patch/alpha+patch v1_0_0 to v1_0_1-alpha_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-alpha.1 2 | v1.0.1-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0 to v1_0_1-beta.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-alpha.1 to v1_0_0-beta.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-beta.1 2 | v1.0.0-beta.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-rc.11 buildAndFail/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-rc.11 to v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-alpha.1 to v1_0_0-rc.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-rc.11 to v1_0_0-rc.12/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project/library-two/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | 5 | semver { 6 | tagPrefix.set("o") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0 to v1_0_1-alpha.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-alpha.2 2 | v1.0.0-alpha.2 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-rc.11 buildAndFail/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/library/last-tag.txt: -------------------------------------------------------------------------------- 1 | w3.0.0 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+minor/alpha+minor v1_0_0 to v1_1_0-alpha_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+patch/alpha+patch v1_0_0 to v1_0_1-alpha_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0-alpha.2 2 | v1.0.0-alpha.2 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-rc.11 to v1_0_0-rc.12/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-alpha.1 to v2_0_0-alpha.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 2.0.0-alpha.1 2 | v2.0.0-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-rc.11 to v2_0_0-rc.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-alpha.1 to v1_1_0-alpha.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.1.0-alpha.1 2 | v1.1.0-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-rc.11 to v1_1_0-rc.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-alpha.1 to v1_0_1-alpha.1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.1-alpha.1 2 | v1.0.1-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-rc.11 to v1_0_1-rc.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-alpha.1 to v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0-alpha-1 to v1_0_1-alpha_2/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/push-tag/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-alpha.1 to v2_0_0-alpha.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-alpha.1 to v1_1_0-alpha.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-alpha.1 to v1_0_1-alpha.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-alpha.1 to v1_0_0-beta.1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-alpha_1 to v1_0_0-SNAPSHOT/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=snapshot -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-rc_3 to v1_0_0-SNAPSHOT/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=snapshot -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/tags-order/random/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-with-included-build/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/one-project/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-alpha.1 to v1_0_0-alpha.2/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-beta.5 to v1_0_0-beta.6/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=major -Psemver.tagPrefix=w 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=major -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=minor -Psemver.tagPrefix=w 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=minor -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=patch -Psemver.tagPrefix=w 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.scope=patch -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-with-included-build/library-two/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | 5 | semver { 6 | tagPrefix.set("o") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/build cache clean v1_0_0/src/main/kotlin/Main.kt: -------------------------------------------------------------------------------- 1 | package com.example.main 2 | 3 | fun main() { 4 | println("Hello, World") 5 | } 6 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-on-all-projects/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-on-all-projects/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library-one") 4 | include(":library-two") 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/expect-version.txt: -------------------------------------------------------------------------------- 1 | 2.0.0-alpha.1 2 | v2.0.0-alpha.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/expect-version.txt: -------------------------------------------------------------------------------- 1 | 1.0.0.2+HASH 2 | v1.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0 to v1_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0 to v1_0_1-rc.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=rc -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.caching=true 2 | org.gradle.configuration-cache=true 3 | org.gradle.configuration-cache.parallel=true 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-five-b/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("b") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-four-b/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("b") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-one-a/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("a") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-six-c/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("c") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-two-b/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("b") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/one-project/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.caching=true 2 | org.gradle.configuration-cache=true 3 | org.gradle.configuration-cache.parallel=true 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+hash/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-only-on-root-project/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-only-on-root-project/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library-one") 4 | include(":library-two") 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 3.1.0-beta.1 2 | w3.1.0-beta.1 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0 to v2_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=major -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0 to v1_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=minor -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0 to v1_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=patch -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0 to v1_0_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=final -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_2_0 to v1_2_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=final -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-eight-c/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("c") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-seven-c/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("c") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/library-three-b/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("b") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/github-variables/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | kotlin("jvm") 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/configuration cache clean v1_0_0/src/main/kotlin/Main.kt: -------------------------------------------------------------------------------- 1 | package com.example.main 2 | 3 | fun main() { 4 | println("Hello, World") 5 | } 6 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/empty/auto v1_0_0+timestamp/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-on-all-projects/library-one/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-on-all-projects/library-two/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0 to v1_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0 to v1_0_1-alpha.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=beta -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/library/expect-version.txt: -------------------------------------------------------------------------------- 1 | 3.0.0.2+HASH 2 | w3.0.0.2+HASH 3 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0 to v1_0_1-beta.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=beta -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-rc.11 buildAndFail/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=beta -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-rc.11 to v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=final -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-alpha.1 to v1_0_0-rc.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=rc -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-rc.11 to v1_0_0-rc.12/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=rc -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /.github/PUBLISHING.md: -------------------------------------------------------------------------------- 1 | # Publishing 2 | 3 | Check [publishing](https://github.com/JavierSegoviaCordoba/hubdle/blob/main/.github/PUBLISHING.md) 4 | from [JavierSC Hubdle](https://github.com/JavierSegoviaCordoba/hubdle/) 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/github-variables/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | kotlin("jvm") 4 | } 5 | 6 | semver { 7 | tagPrefix.set("w") 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-only-on-root-project/library-one/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/log-only-on-root-project/library-two/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0 to v1_0_1/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/malformed buildAndFail (1)/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-rc.11 buildAndFail/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.scope=major -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+minor/alpha+minor v1_0_0 to v1_1_0-alpha_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.scope=minor -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+patch/alpha+patch v1_0_0 to v1_0_1-alpha_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.scope=patch -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-rc.11 to v1_0_0-rc.12/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-rc.11 to v2_0_0-rc.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=major -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-rc.11 to v1_1_0-rc.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=minor -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-rc.11 to v1_0_1-rc.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=patch -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-alpha.1 to v1_0_0-beta.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=beta -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-alpha.1 to v1_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=final -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0 to v1_0_1-alpha_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/beta v1_0_0 to v1_0_1-beta_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/final v1_0_0-alpha_1 to v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/github-variables/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-beta.5 to v1_0_0-beta.6/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=auto -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-alpha.1 to v2_0_0-alpha.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=major -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-alpha.1 to v1_1_0-alpha.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=minor -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-alpha.1 to v1_0_1-alpha.1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=auto -Psemver.scope=patch -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project/library-three/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | 5 | semver { 6 | tagPrefix.set("t") 7 | mapVersion { version -> "12.13.14" } 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-alpha.1 to v1_0_0-alpha.2/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/alpha v1_0_0-alpha-1 to v1_0_1-alpha_2/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-rc_3 to v1_0_0-SNAPSHOT/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean-with-no-tag-current-commit (hash)/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/build cache clean v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | kotlin("jvm") 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/project isolation clean v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | java 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-alpha.1 to v1_0_0-alpha.2/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/auto v1_0_0-beta.5 to v1_0_0-beta.6/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0 to v1_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0 to v2_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0 to v1_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0 to v1_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0 to v1_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_2_0 to v1_2_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0 to v1_0_1-rc.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-alpha_1 to v1_0_0-SNAPSHOT/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/no-clean-with-no-tag-current-commit (dirty)/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include(":library") 4 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0 to v1_0_1-beta.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-rc.11 to v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-rc.11 to v1_0_0-rc.12/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-basic/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/configuration cache clean v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | kotlin("jvm") 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/project isolation clean v1_0_0/library-a/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | java 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/project isolation clean v1_0_0/library-b/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | java 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0 to v1_0_1-alpha.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-rc.11 buildAndFail/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=beta -Psemver.scope=minor -Psemver.tagPrefix=w 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+minor/alpha+minor v1_0_0 to v1_1_0-alpha_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+patch/alpha+patch v1_0_0 to v1_0_1-alpha_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-rc.11 to v1_0_0-rc.12/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-rc.11 to v2_0_0-rc.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-rc.11 to v1_1_0-rc.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-rc.11 to v1_0_1-rc.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-rc.11 buildAndFail/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/final+auto/final+auto v1_0_0-alpha.1 to v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/rc+auto/rc+auto v1_0_0-alpha.1 to v1_0_0-rc.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-with-included-build/library-three/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | java 3 | } 4 | 5 | semver { 6 | tagPrefix.set("t") 7 | mapVersion { version -> "12.13.14" } 8 | } 9 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /.github/workflows/fix-checks.yaml: -------------------------------------------------------------------------------- 1 | name: fix-checks 2 | 3 | on: 4 | workflow_dispatch: 5 | 6 | jobs: 7 | fix-checks: 8 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/fix-checks.yaml@main 9 | secrets: inherit 10 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/build cache clean v1_0_0/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v1_0_0 - library w3_0_0 to w4_0_0/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/major v1_0_0 to v2_0_0 - library w3_0_0 to w3_0_0/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_0_0 - library w3_0_0 to w3_1_0/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/minor v1_0_0 to v1_1_0 - library w3_0_0 to w3_0_0/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_0- library w3_0_0 to w3_0_1/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/scope/patch v1_0_0 to v1_0_1- library w3_0_0 to w3_0_0/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+auto/alpha+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/ARGUMENTS.txt: -------------------------------------------------------------------------------- 1 | createSemverTag -Psemver.stage=alpha -Psemver.scope=major -Psemver.tagPrefix=v 2 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+auto/auto+auto v1_0_0-alpha.1 to v1_0_0-alpha.2/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+major/auto+major v1_0_0-alpha.1 to v2_0_0-alpha.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+minor/auto+minor v1_0_0-alpha.1 to v1_1_0-alpha.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/auto+patch/auto+patch v1_0_0-alpha.1 to v1_0_1-alpha.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/beta+auto/beta+auto v1_0_0-alpha.1 to v1_0_0-beta.1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-basic/library-one/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=o 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-basic/library-two/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=t 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/beta v1_0_0 to v1_0_1-beta_1/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /.github/workflows/apply-format.yaml: -------------------------------------------------------------------------------- 1 | name: apply-format 2 | 3 | on: 4 | workflow_dispatch: 5 | 6 | jobs: 7 | apply-format: 8 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/apply-format.yaml@main 9 | secrets: inherit 10 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android build cache clean v1_0_0/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/build cache clean v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | dependencyResolutionManagement { 4 | repositories { 5 | mavenCentral() 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/final v1_0_0-alpha_1 to v1_0_0/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/build-logic/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=z 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/library-one/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=o 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-rc_3 to v1_0_0-SNAPSHOT/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/configuration cache clean v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | dependencyResolutionManagement { 4 | repositories { 5 | mavenCentral() 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage/snapshot v1_0_0-alpha_1 to v1_0_0-SNAPSHOT/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0 configuration phase/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | 9 | println("SEMVER: $version") 10 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-build-dir/clean v1_0_0 configuration phase/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/build-logic/module-a/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.project.tagPrefix=f 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/github-variables/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | dependencyResolutionManagement { 4 | repositories { 5 | mavenCentral() 6 | } 7 | } 8 | 9 | include(":library") 10 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | } 8 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-basic/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "multi-project" 2 | 3 | plugins { 4 | id("com.javiersc.semver") 5 | } 6 | 7 | include( 8 | ":library-one", 9 | ":library-two", 10 | ) 11 | -------------------------------------------------------------------------------- /.docs/docs/css/all.css: -------------------------------------------------------------------------------- 1 | code { 2 | font-weight: 600; 3 | } 4 | 5 | @media screen and (min-width: 76.1875em) { 6 | .md-nav--primary .md-nav__title { 7 | display: none; 8 | } 9 | } 10 | 11 | .md-nav__link--active { 12 | font-weight: bold; 13 | } 14 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/alpha+major v1_0_0 to v2_0_0-alpha_1 - library w3_0_0 to w3_0_0/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/properties/stage+scope/alpha+major/v1_0_0 to v1_0_0 - library beta+minor w3_0_0 to w3_1_0-beta_1/library/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("w") 7 | } 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/MODULE.md: -------------------------------------------------------------------------------- 1 | # Module semver-project-gradle-plugin 2 | 3 | ### Apply the plugin 4 | 5 | ```kotlin 6 | // build.gradle.kts 7 | plugins { 8 | id("com.javiersc.semver") version "$version" 9 | } 10 | ``` 11 | 12 | Check the README.md for more info 13 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android build cache clean v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | dependencyResolutionManagement { 4 | repositories { 5 | mavenCentral() 6 | google() 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v0_2_0+2_0_10/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | mapVersion { gradleVersion -> 7 | "${gradleVersion.copy(metadata = "2.0.10")}" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/MODULE.md: -------------------------------------------------------------------------------- 1 | # Module semver-settings-gradle-plugin 2 | 3 | ### Apply the plugin 4 | 5 | ```kotlin 6 | // settings.gradle.kts 7 | plugins { 8 | id("com.javiersc.semver") version "$version" 9 | } 10 | ``` 11 | 12 | Check the README.md for more info 13 | -------------------------------------------------------------------------------- /semver-gradle-plugin/api/semver-gradle-plugin.api: -------------------------------------------------------------------------------- 1 | public final class com/javiersc/semver/gradle/plugin/SemverPlugin : org/gradle/api/Plugin { 2 | public fun ()V 3 | public synthetic fun apply (Ljava/lang/Object;)V 4 | public fun apply (Lorg/gradle/api/plugins/PluginAware;)V 5 | } 6 | 7 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android configuration cache clean v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | dependencyResolutionManagement { 4 | repositories { 5 | mavenCentral() 6 | google() 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /.github/workflows/dump-api.yaml: -------------------------------------------------------------------------------- 1 | name: dump-api 2 | 3 | on: 4 | workflow_dispatch: 5 | 6 | jobs: 7 | dump-api: 8 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/dump-api.yaml@main 9 | with: 10 | restore-kotlin-native-cache: false 11 | secrets: inherit 12 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/internal/InitialVersion.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.internal 2 | 3 | import com.javiersc.gradle.version.GradleVersion 4 | 5 | internal val InitialVersion: GradleVersion = GradleVersion("0.1.0") 6 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/configuration cache clean v1_0_0/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.configuration-cache=true 2 | org.gradle.configuration-cache.parallel=true 3 | org.gradle.configuration-cache-problems=warn 4 | org.gradle.configuration-cache.max-problems=100 5 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "multi-project" 2 | 3 | plugins { 4 | id("com.javiersc.semver") 5 | } 6 | 7 | includeBuild( 8 | "build-logic", 9 | ) 10 | 11 | include( 12 | ":library-one", 13 | ) 14 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-9.0.0-bin.zip 4 | networkTimeout=10000 5 | validateDistributionUrl=true 6 | zipStoreBase=GRADLE_USER_HOME 7 | zipStorePath=wrapper/dists 8 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/version-mapping/v1_0_0 to v1_0_0+1_9_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | } 4 | 5 | semver { 6 | tagPrefix.set("v") 7 | mapVersion { gradleVersion -> 8 | "${gradleVersion.copy(metadata = "1.9.0")}" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android configuration cache clean v1_0_0/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.configuration-cache=true 3 | org.gradle.configuration-cache.parallel=true 4 | org.gradle.configuration-cache-problems=warn 5 | org.gradle.configuration-cache.max-problems=100 6 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/project isolation clean v1_0_0/gradle.properties: -------------------------------------------------------------------------------- 1 | semver.tagPrefix=v 2 | org.gradle.caching=true 3 | org.gradle.configuration-cache=true 4 | org.gradle.configuration-cache.parallel=true 5 | org.gradle.isolated-projects=true 6 | org.gradle.unsafe.isolated-projects=true 7 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/project isolation clean v1_0_0/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | dependencyResolutionManagement { 4 | repositories { 5 | mavenCentral() 6 | } 7 | } 8 | 9 | include( 10 | "library-a", 11 | "library-b", 12 | ) 13 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "multi-project" 2 | 3 | plugins { 4 | id("com.javiersc.semver") 5 | } 6 | 7 | semver { 8 | tagPrefix.set("v") 9 | } 10 | 11 | include( 12 | ":library-one", 13 | ":library-two", 14 | ":library-three", 15 | ) 16 | -------------------------------------------------------------------------------- /.github/workflows/build-changelog-renovate-bot.yaml: -------------------------------------------------------------------------------- 1 | name: build-changelog-renovate-bot 2 | 3 | on: 4 | push: 5 | branches: 6 | - 'renovate/**' 7 | 8 | jobs: 9 | add-updated-dependencies-to-changelog: 10 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/build-changelog-renovate-bot.yaml@main 11 | secrets: inherit 12 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/multi-project-with-included-build/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "multi-project" 2 | 3 | plugins { 4 | id("com.javiersc.semver") 5 | } 6 | 7 | semver { 8 | tagPrefix.set("v") 9 | } 10 | 11 | include( 12 | ":library-one", 13 | ":library-two", 14 | ":library-three", 15 | ) 16 | -------------------------------------------------------------------------------- /.github/workflows/publish-kotlin.yaml: -------------------------------------------------------------------------------- 1 | name: publish-kotlin 2 | 3 | on: 4 | push: 5 | tags: 6 | - '**' 7 | 8 | jobs: 9 | publish: 10 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/publish-kotlin.yaml@main 11 | with: 12 | publish-maven-central: true 13 | publish-gradle-plugin-portal: true 14 | secrets: inherit 15 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/VersionMapper.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.gradle.version.GradleVersion 4 | import java.io.Serializable 5 | 6 | public fun interface VersionMapper : Serializable { 7 | 8 | public fun map(version: GradleVersion): String 9 | } 10 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/VersionProperty.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import org.gradle.api.provider.Provider 4 | 5 | public class VersionProperty(private val version: Provider) : Provider by version { 6 | 7 | override fun toString(): String = "${version.orNull}" 8 | } 9 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/examples/multi-project/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | rootProject.name = "sandbox-project" 2 | 3 | include( 4 | ":library-one-a", 5 | ":library-two-b", 6 | ":library-three-b", 7 | ":library-four-b", 8 | ":library-five-b", 9 | ":library-six-c", 10 | ":library-seven-c", 11 | ":library-eight-c", 12 | ":library-nine", 13 | ":library-ten", 14 | ) 15 | -------------------------------------------------------------------------------- /semver-gradle-plugin/MODULE.md: -------------------------------------------------------------------------------- 1 | # Module semver-gradle-plugin 2 | 3 | ### Apply the plugin 4 | 5 | On projects: 6 | 7 | ```kotlin 8 | // build.gradle.kts 9 | plugins { 10 | id("com.javiersc.semver") version "$version" 11 | } 12 | ``` 13 | 14 | On settings: 15 | 16 | ```kotlin 17 | // settings.gradle.kts 18 | plugins { 19 | id("com.javiersc.semver") version "$version" 20 | } 21 | ``` 22 | 23 | Check the README.md for more info 24 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/resources/project-with-included-build/build-logic/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | import com.javiersc.semver.settings.gradle.plugin.SemverSettingsExtension 2 | 3 | rootProject.name = "build-logic" 4 | 5 | plugins { 6 | id("com.javiersc.semver") 7 | } 8 | 9 | configure { 10 | gitDir.set(rootDir.parentFile.resolve(".git")) 11 | } 12 | 13 | include( 14 | "module-a", 15 | ) 16 | -------------------------------------------------------------------------------- /.github/workflows/build-kotlin.yaml: -------------------------------------------------------------------------------- 1 | name: build-kotlin 2 | 3 | on: 4 | push: 5 | branches: 6 | - main 7 | paths-ignore: 8 | - '**.md' 9 | 10 | pull_request: 11 | branches: 12 | - main 13 | paths-ignore: 14 | - '**.md' 15 | 16 | jobs: 17 | build: 18 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/build-kotlin.yaml@main 19 | with: 20 | allow-github-actor-bots: false 21 | secrets: inherit 22 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/internal/getProjectTagPrefix.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.internal 2 | 3 | import com.javiersc.semver.project.gradle.plugin.semverExtension 4 | import org.gradle.api.Project 5 | import org.gradle.api.provider.Provider 6 | 7 | internal val Project.projectTagPrefix: Provider 8 | get() = provider { projectTagPrefixProperty.orNull ?: semverExtension.tagPrefix.get() } 9 | -------------------------------------------------------------------------------- /settings.gradle.kts: -------------------------------------------------------------------------------- 1 | pluginManagement { 2 | val hubdleVersion: String = 3 | file("$rootDir/gradle/libs.versions.toml") 4 | .readLines() 5 | .first { it.contains("hubdle") } 6 | .split("\"")[1] 7 | 8 | repositories { 9 | gradlePluginPortal() 10 | mavenCentral() 11 | google() 12 | } 13 | 14 | plugins { 15 | id("com.javiersc.hubdle") version hubdleVersion 16 | } 17 | } 18 | 19 | plugins { 20 | id("com.javiersc.hubdle") 21 | } 22 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | gradlew text eol=lf 2 | 3 | * text eol=lf 4 | 5 | *.7z binary 6 | *.bat text eol=crlf 7 | *.eot binary 8 | *.fla binary 9 | *.flv binary 10 | *.gif binary 11 | *.gz binary 12 | *.ico binary 13 | *.jar binary 14 | *.jpeg binary 15 | *.jpg binary 16 | *.mov binary 17 | *.mp3 binary 18 | *.mp4 binary 19 | *.pdf binary 20 | *.png binary 21 | *.pyc binary 22 | *.swf binary 23 | *.ttf binary 24 | *.webm binary 25 | *.webp binary 26 | *.woff binary 27 | *.zip binary 28 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android build cache clean v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | id("com.android.application") 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | 10 | android { 11 | compileSdk = 31 12 | 13 | defaultConfig { 14 | applicationId = "com.example.myapp" 15 | namespace = "com.example.myapp" 16 | minSdk = 21 17 | versionCode = "$version".first().toInt() 18 | versionName = "$version" 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/resources/gradle-features/android configuration cache clean v1_0_0/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.javiersc.semver") 3 | id("com.android.application") 4 | } 5 | 6 | semver { 7 | tagPrefix.set("v") 8 | } 9 | 10 | android { 11 | compileSdk = 31 12 | 13 | defaultConfig { 14 | applicationId = "com.example.myapp" 15 | namespace = "com.example.myapp" 16 | minSdk = 21 17 | versionCode = "$version".first().toInt() 18 | versionName = "$version" 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/kotlin/com/javiersc/semver/settings/gradle/plugin/utils/createGitIgnore.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.settings.gradle.plugin.utils 2 | 3 | import java.io.File 4 | 5 | fun File.createGitIgnore() { 6 | resolve(".gitignore").apply { 7 | createNewFile() 8 | writeText( 9 | """ 10 | |.gradle/ 11 | |.idea/ 12 | |.kotlin/ 13 | |build/ 14 | |local.properties 15 | |environment/ 16 | |""" 17 | .trimMargin() 18 | ) 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright 2024 Javier Segovia Córdoba 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | https://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. 14 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/internal/git/GitRef.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.internal.git 2 | 3 | internal sealed class GitRef { 4 | 5 | data class Head(val commit: Commit) : GitRef() 6 | 7 | data class Commit(val message: String, val fullMessage: String, val hash: String) : GitRef() 8 | 9 | data class Tag(val name: String, val refName: String, val commit: Commit) : GitRef() 10 | 11 | data class Branch( 12 | val name: String, // example: `main` 13 | val refName: String, // example: `refs/heads/main` 14 | val commits: List, 15 | val tags: List, 16 | ) : GitRef() 17 | } 18 | -------------------------------------------------------------------------------- /gradle-version/build.gradle.kts: -------------------------------------------------------------------------------- 1 | hubdle { 2 | config { 3 | analysis() 4 | coverage() 5 | documentation { // 6 | api() 7 | } 8 | explicitApi() 9 | languageSettings { // 10 | experimentalCoroutinesApi() 11 | } 12 | publishing() 13 | } 14 | kotlin { 15 | jvm { 16 | features { 17 | coroutines() 18 | jvmVersion(JavaVersion.VERSION_11) 19 | kotest() 20 | } 21 | test { 22 | dependencies { // 23 | implementation(hubdle.kotest.property) 24 | } 25 | } 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /.github/workflows/build-kotlin-dispatcher.yaml: -------------------------------------------------------------------------------- 1 | name: build-kotlin-dispatcher 2 | 3 | on: 4 | workflow_dispatch: 5 | inputs: 6 | gradle-args: 7 | description: 'Gradle args for every step' 8 | default: '' 9 | required: false 10 | publish-all-docs: 11 | description: 'Publish all docs instead of only API docs and reports' 12 | required: false 13 | default: false 14 | type: boolean 15 | 16 | jobs: 17 | build: 18 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/build-kotlin.yaml@main 19 | with: 20 | gradle-args: '${{ github.event.inputs.gradle-args }}' 21 | allow-github-actor-bots: false 22 | publish-all-docs: '${{ github.event.inputs.publish-all-docs }}' 23 | secrets: inherit 24 | -------------------------------------------------------------------------------- /semver-gradle-plugin/main/kotlin/com/javiersc/semver/gradle/plugin/SemverPlugin.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.gradle.plugin 2 | 3 | import com.javiersc.semver.project.gradle.plugin.SemverProjectPlugin 4 | import com.javiersc.semver.settings.gradle.plugin.SemverSettingsPlugin 5 | import org.gradle.api.Plugin 6 | import org.gradle.api.Project 7 | import org.gradle.api.initialization.Settings 8 | import org.gradle.api.plugins.PluginAware 9 | import org.gradle.kotlin.dsl.apply 10 | 11 | public class SemverPlugin : Plugin { 12 | override fun apply(target: PluginAware) { 13 | when (target) { 14 | is Project -> target.pluginManager.apply(SemverProjectPlugin::class) 15 | is Settings -> target.pluginManager.apply(SemverSettingsPlugin::class) 16 | else -> error("Semver cannot be applied to ${target::class}") 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /.github/workflows/generate-version-tag.yaml: -------------------------------------------------------------------------------- 1 | name: generate-version-tag 2 | 3 | on: 4 | workflow_dispatch: 5 | if: github.ref == 'refs/heads/main' 6 | inputs: 7 | stage: 8 | description: 'Stage' 9 | required: true 10 | default: 'auto' 11 | type: choice 12 | options: 13 | - 'alpha' 14 | - 'beta' 15 | - 'rc' 16 | - 'final' 17 | - 'auto' 18 | scope: 19 | description: 'Scope' 20 | required: true 21 | default: 'auto' 22 | type: choice 23 | options: 24 | - 'patch' 25 | - 'minor' 26 | - 'major' 27 | - 'auto' 28 | 29 | jobs: 30 | generate: 31 | uses: JavierSegoviaCordoba/reusable-workflows/.github/workflows/generate-version-tag.yaml@main 32 | with: 33 | stage: '${{ github.event.inputs.stage }}' 34 | scope: '${{ github.event.inputs.scope }}' 35 | secrets: inherit 36 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/internal/Checkers.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.internal 2 | 3 | import com.javiersc.gradle.version.GradleVersion 4 | import org.gradle.api.Project 5 | 6 | internal fun Project.checkScopeCorrectness() { 7 | val scope = scopeProperty.orNull 8 | check(scope in Scope.entries.map(Scope::toString) || scope.isNullOrBlank()) { 9 | "`scope` value must be one of ${Scope.entries.map(Scope::toString)} or empty" 10 | } 11 | } 12 | 13 | internal fun checkVersionIsHigherOrSame( 14 | version: String, 15 | lastVersionInCurrentBranch: GradleVersion, 16 | ) { 17 | GradleVersion.safe(version).getOrNull()?.let { calculatedVersion -> 18 | check(calculatedVersion >= lastVersionInCurrentBranch) { 19 | "The next version($calculatedVersion) should be higher or the same as the current " + 20 | "one($lastVersionInCurrentBranch)" 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/test/kotlin/com/javiersc/semver/project/gradle/plugin/GitBranchTest.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.semver.project.gradle.plugin.internal.git.GitRef 4 | import com.javiersc.semver.project.gradle.plugin.internal.git.currentBranch 5 | import com.javiersc.semver.project.gradle.plugin.internal.git.headRef 6 | import io.kotest.matchers.shouldBe 7 | import kotlin.test.Test 8 | 9 | internal class GitBranchTest { 10 | 11 | @Test 12 | internal fun `current branch`() { 13 | initialCommitAnd { 14 | resolve("Second commit.txt").createNewFile() 15 | git.add().addFilepattern(".").call() 16 | git.commit().setMessage("Second commit").call() 17 | 18 | git.headRef.name.shouldBe(git.currentBranch.refName) 19 | 20 | git.currentBranch.commits.map(GitRef.Commit::message) shouldBe 21 | listOf("Second commit", "Initial commit") 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /.docs/changelogs/CHANGELOG_0.4.0.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | 3 | ## [0.4.0-alpha.1] - 2023-01-04 4 | 5 | ### Added 6 | 7 | - `Project.isAlpha: Provider` extension 8 | - `Project.isNotAlpha: Provider` extension 9 | - `Project.isBeta: Provider` extension 10 | - `Project.isNotBeta: Provider` extension 11 | - `Project.isDev: Provider` extension 12 | - `Project.isNotDev: Provider` extension 13 | - `Project.isRC: Provider` extension 14 | - `Project.isNotRC: Provider` extension 15 | - `Project.isSnapshot: Provider` extension 16 | - `Project.isNotSnapshot: Provider` extension 17 | 18 | ### Changed 19 | 20 | - `SNAPSHOT` is treated now as non-special stage (higher than `rc`) 21 | 22 | ### Updated 23 | 24 | - `org.eclipse.jgit:org.eclipse.jgit -> 6.4.0.202211300538-r` 25 | - `com.javiersc.hubdle:com.javiersc.hubdle.gradle.plugin -> 0.2.0-alpha.46` 26 | - `gradle -> 7.6` 27 | 28 | [0.4.0-alpha.1]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.3.0-alpha.5...0.4.0-alpha.1 29 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/GitRefs.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | /** 4 | * @param message The short message of the commit 5 | * @param fullMessage The full message of the commit including the body 6 | * @param hash The hash of the commit 7 | * @param timestampEpochSecond The timestamp of the commit in epoch seconds 8 | * @param tags The tags associated with the commit 9 | */ 10 | public data class Commit( 11 | val message: String, 12 | val fullMessage: String, 13 | val hash: String, 14 | val timestampEpochSecond: Long, 15 | val tags: List, 16 | ) { 17 | override fun toString(): String = 18 | """ 19 | $fullMessage 20 | 21 | hash: $hash, tags: ${tags.joinToString()} 22 | """ 23 | .trimIndent() 24 | } 25 | 26 | /** 27 | * @param name The name of the tag, example: `v1.0.0` 28 | * @param refName The name of the ref, example: `refs/tags/v1.0.0` 29 | */ 30 | public data class Tag(val name: String, val refName: String) { 31 | override fun toString(): String = name 32 | } 33 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/api/semver-settings-gradle-plugin.api: -------------------------------------------------------------------------------- 1 | public abstract class com/javiersc/semver/settings/gradle/plugin/SemverSettingsExtension { 2 | public static final field Companion Lcom/javiersc/semver/settings/gradle/plugin/SemverSettingsExtension$Companion; 3 | public static final field ExtensionName Ljava/lang/String; 4 | public fun (Lorg/gradle/api/model/ObjectFactory;)V 5 | public final fun getCommitsMaxCount ()Lorg/gradle/api/provider/Property; 6 | public abstract fun getGitDir ()Lorg/gradle/api/file/DirectoryProperty; 7 | public final fun getTagPrefix ()Lorg/gradle/api/provider/Property; 8 | public final fun isEnabled ()Lorg/gradle/api/provider/Property; 9 | public final fun mapVersion (Lcom/javiersc/semver/project/gradle/plugin/VersionMapper;)V 10 | } 11 | 12 | public final class com/javiersc/semver/settings/gradle/plugin/SemverSettingsExtension$Companion { 13 | } 14 | 15 | public final class com/javiersc/semver/settings/gradle/plugin/SemverSettingsPlugin : org/gradle/api/Plugin { 16 | public fun ()V 17 | public synthetic fun apply (Ljava/lang/Object;)V 18 | public fun apply (Lorg/gradle/api/initialization/Settings;)V 19 | } 20 | 21 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/kotlin/com/javiersc/semver/project/gradle/plugin/VersionMappingTest.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.gradle.testkit.test.extensions.GradleTestKitTest 4 | import com.javiersc.semver.project.gradle.plugin.internal.git.headRevCommitInBranch 5 | import kotlin.test.Test 6 | 7 | internal class VersionMappingTest : GradleTestKitTest() { 8 | 9 | @Test 10 | fun `0_2_0+2_0_10`() { 11 | gradleTestKitTest("version-mapping/v0_2_0+2_0_10") { 12 | projectDir.generateInitialCommitAddVersionTag() 13 | 14 | withArgumentsFromTXT() 15 | build() 16 | projectDir.assertVersionFromExpectVersionFiles() 17 | } 18 | } 19 | 20 | @Test 21 | fun `v1_0_0 to v1_0_0+1_9_0`() { 22 | gradleTestKitTest("version-mapping/v1_0_0 to v1_0_0+1_9_0") { 23 | projectDir.generateInitialCommitAddVersionTagAndAddNewCommit() 24 | git.tag().setObjectId(git.headRevCommitInBranch).setName("v1.0.0").call() 25 | 26 | withArgumentsFromTXT() 27 | build() 28 | projectDir.assertVersionFromExpectVersionFiles() 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/main/kotlin/com/javiersc/semver/settings/gradle/plugin/SemverSettingsPlugin.kt: -------------------------------------------------------------------------------- 1 | @file:Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE") 2 | 3 | package com.javiersc.semver.settings.gradle.plugin 4 | 5 | import com.javiersc.semver.project.gradle.plugin.SemverExtension 6 | import org.gradle.api.Plugin 7 | import org.gradle.api.initialization.Settings 8 | import org.gradle.kotlin.dsl.configure 9 | 10 | public class SemverSettingsPlugin : Plugin { 11 | 12 | override fun apply(target: Settings) { 13 | val semver: SemverSettingsExtension = SemverSettingsExtension.register(target) 14 | target.gradle.beforeProject { project -> 15 | project.pluginManager.apply("com.javiersc.semver") 16 | project.pluginManager.withPlugin("com.javiersc.semver") { 17 | project.configure { 18 | this.isEnabled.set(semver.isEnabled) 19 | this.gitDir.set(semver.gitDir) 20 | this.commitsMaxCount.set(semver.commitsMaxCount) 21 | this.tagPrefix.set(semver.tagPrefix) 22 | this.versionMapper.set(semver.versionMapper) 23 | } 24 | } 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/internal/SemVerMessages.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.internal 2 | 3 | import com.javiersc.gradle.logging.extensions.quietColored 4 | import com.javiersc.gradle.logging.extensions.warnColored 5 | import com.javiersc.gradle.version.GradleVersion 6 | import com.javiersc.kotlin.stdlib.AnsiColor 7 | import com.javiersc.semver.project.gradle.plugin.SemverProjectPlugin 8 | import org.gradle.api.logging.Logger 9 | import org.gradle.api.logging.Logging 10 | 11 | internal fun semverWarningMessage(message: Any) = defaultLogger.warnColored { "$message" } 12 | 13 | internal fun semverMessage(message: Any, color: AnsiColor = AnsiColor.Foreground.Purple) = 14 | defaultLogger.quietColored(color) { "$message" } 15 | 16 | internal fun warningLastVersionIsNotHigherVersion(last: GradleVersion?, higher: GradleVersion?) { 17 | val message = 18 | """|There is an old tag with a higher version than the last tag version: 19 | | - Old tag version -> $last 20 | | - Last tag version -> $higher 21 | """ 22 | .trimMargin() 23 | 24 | if (last != null && higher != null && last < higher) { 25 | semverMessage(message = message, color = AnsiColor.Foreground.Yellow) 26 | } 27 | } 28 | 29 | private val defaultLogger: Logger = Logging.getLogger(SemverProjectPlugin::class.java) 30 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFixtures/kotlin/com/javiersc/semver/project/gradle/plugin/GitUtils.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.semver.project.gradle.plugin.internal.AdditionalVersionData 4 | import com.javiersc.semver.project.gradle.plugin.internal.calculateAdditionalVersionData 5 | import com.javiersc.semver.project.gradle.plugin.internal.git.GitRef 6 | import com.javiersc.semver.project.gradle.plugin.internal.git.commitsInCurrentBranch 7 | import com.javiersc.semver.project.gradle.plugin.internal.git.headCommit 8 | import com.javiersc.semver.project.gradle.plugin.internal.git.lastCommitInCurrentBranch 9 | import com.javiersc.semver.project.gradle.plugin.internal.git.lastVersionCommitInCurrentBranch 10 | import com.javiersc.semver.project.gradle.plugin.internal.git.versionTagsInCurrentBranch 11 | import org.eclipse.jgit.api.Git 12 | 13 | internal fun Git.calculateAdditionalVersionData( 14 | tagPrefix: String, 15 | checkIsClean: Boolean = true, 16 | ): AdditionalVersionData? = 17 | calculateAdditionalVersionData( 18 | clean = status().call().isClean, 19 | checkClean = checkIsClean, 20 | lastCommitInCurrentBranch = lastCommitInCurrentBranch?.hash, 21 | commitsInCurrentBranch = commitsInCurrentBranch.map(GitRef.Commit::hash), 22 | isThereVersionTags = versionTagsInCurrentBranch(tagPrefix).isNotEmpty(), 23 | headCommit = headCommit.commit.hash, 24 | lastVersionCommitInCurrentBranch = lastVersionCommitInCurrentBranch(tagPrefix)?.hash, 25 | ) 26 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/build.gradle.kts: -------------------------------------------------------------------------------- 1 | hubdle { 2 | config { 3 | analysis() 4 | coverage() 5 | documentation { // 6 | api() 7 | } 8 | explicitApi() 9 | publishing { 10 | gradlePortal { // 11 | isEnabled = false 12 | } 13 | } 14 | } 15 | kotlin { 16 | jvm { 17 | features { // 18 | jvmVersion(JavaVersion.VERSION_17) 19 | kotest() 20 | } 21 | 22 | main { 23 | dependencies { 24 | api(projects.gradleVersion) 25 | implementation(hubdle.eclipse.jgit) 26 | } 27 | } 28 | 29 | testIntegration { 30 | dependencies { // 31 | implementation(hubdle.eclipse.jgit) 32 | } 33 | } 34 | 35 | testFunctional { 36 | dependencies { // 37 | implementation(hubdle.eclipse.jgit) 38 | } 39 | } 40 | 41 | testFixtures { 42 | dependencies { // 43 | implementation(hubdle.eclipse.jgit) 44 | } 45 | } 46 | } 47 | } 48 | 49 | gradle { 50 | plugin { 51 | pluginUnderTestDependencies( 52 | hubdle.android.tools.build.gradle, 53 | hubdle.jetbrains.kotlin.gradle.plugin, 54 | projects.semverGradlePlugin, 55 | projects.semverProjectGradlePlugin, 56 | projects.semverSettingsGradlePlugin, 57 | ) 58 | } 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /semver-gradle-plugin/build.gradle.kts: -------------------------------------------------------------------------------- 1 | hubdle { 2 | config { 3 | analysis() 4 | coverage() 5 | documentation { api() } 6 | explicitApi() 7 | publishing() 8 | } 9 | kotlin { 10 | jvm { 11 | features { // 12 | jvmVersion(JavaVersion.VERSION_17) 13 | kotest() 14 | } 15 | 16 | main { 17 | dependencies { 18 | api(projects.semverProjectGradlePlugin) 19 | api(projects.semverSettingsGradlePlugin) 20 | } 21 | } 22 | } 23 | } 24 | 25 | gradle { 26 | plugin { 27 | gradlePlugin { 28 | plugins { 29 | create("SemverPlugin") { 30 | id = "com.javiersc.semver" 31 | displayName = "Semver" 32 | description = "Manage project versions automatically with git tags" 33 | implementationClass = "com.javiersc.semver.gradle.plugin.SemverPlugin" 34 | tags.set( 35 | listOf( 36 | "semver", 37 | "semantic versioning", 38 | "semantic version", 39 | "git tags", 40 | "git version", 41 | ) 42 | ) 43 | } 44 | } 45 | } 46 | 47 | pluginUnderTestDependencies( 48 | hubdle.android.tools.build.gradle, 49 | hubdle.jetbrains.kotlin.gradle.plugin, 50 | ) 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/build.gradle.kts: -------------------------------------------------------------------------------- 1 | hubdle { 2 | config { 3 | analysis() 4 | coverage() 5 | documentation { // 6 | api() 7 | } 8 | explicitApi() 9 | publishing { 10 | gradlePortal { // 11 | isEnabled = false 12 | } 13 | } 14 | } 15 | kotlin { 16 | jvm { 17 | features { // 18 | jvmVersion(JavaVersion.VERSION_17) 19 | kotest() 20 | } 21 | 22 | main { 23 | dependencies { 24 | api(projects.gradleVersion) 25 | api(projects.semverProjectGradlePlugin) 26 | implementation(hubdle.eclipse.jgit) 27 | } 28 | } 29 | 30 | testIntegration { 31 | dependencies { // 32 | implementation(hubdle.eclipse.jgit) 33 | } 34 | } 35 | 36 | testFunctional { 37 | dependencies { // 38 | implementation(hubdle.eclipse.jgit) 39 | } 40 | } 41 | 42 | testFixtures { 43 | dependencies { // 44 | implementation(hubdle.eclipse.jgit) 45 | } 46 | } 47 | } 48 | } 49 | 50 | gradle { 51 | plugin { 52 | pluginUnderTestDependencies( 53 | hubdle.android.tools.build.gradle, 54 | hubdle.jetbrains.kotlin.gradle.plugin, 55 | projects.semverGradlePlugin, 56 | projects.semverProjectGradlePlugin, 57 | projects.semverSettingsGradlePlugin, 58 | ) 59 | } 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/kotlin/com/javiersc/semver/settings/gradle/plugin/ProjectTest.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.settings.gradle.plugin 2 | 3 | import com.javiersc.gradle.testkit.test.extensions.GradleTestKitTest 4 | import com.javiersc.semver.settings.gradle.plugin.utils.createGitIgnore 5 | import io.kotest.matchers.string.shouldContain 6 | import kotlin.test.Test 7 | import org.eclipse.jgit.api.Git 8 | 9 | internal class ProjectTest : GradleTestKitTest() { 10 | 11 | @Test 12 | fun `project with included build`() { 13 | gradleTestKitTest("project-with-included-build") { 14 | val git: Git = Git.init().setDirectory(projectDir).call() 15 | projectDir.createGitIgnore() 16 | git.add().addFilepattern(".").call() 17 | git.commit().setMessage("Initial commit").call() 18 | git.tag().setName("v1.0.0").call() 19 | git.tag().setName("o2.0.3").call() 20 | git.tag().setName("z6.2.1").call() 21 | git.tag().setName("f8.1.7").call() 22 | 23 | val output: String = gradlew("assemble", stacktrace()).output 24 | val outputIncludedBuildRootProject: String = 25 | gradlew(":build-logic:assemble", stacktrace()).output 26 | val outputIncludedBuildModuleA: String = 27 | gradlew(":build-logic:module-a:assemble", stacktrace()).output 28 | 29 | output 30 | .shouldContain("semver for multi-project: v1.0.0") 31 | .shouldContain("semver for library-one: o2.0.3") 32 | outputIncludedBuildRootProject.shouldContain("semver for build-logic: z6.2.1") 33 | outputIncludedBuildModuleA.shouldContain("semver for module-a: f8.1.7") 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/extensions/isVersionExtensions.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.extensions 2 | 3 | import com.javiersc.gradle.version.isAlpha 4 | import com.javiersc.gradle.version.isBeta 5 | import com.javiersc.gradle.version.isDev 6 | import com.javiersc.gradle.version.isNotAlpha 7 | import com.javiersc.gradle.version.isNotBeta 8 | import com.javiersc.gradle.version.isNotDev 9 | import com.javiersc.gradle.version.isNotRC 10 | import com.javiersc.gradle.version.isNotSnapshot 11 | import com.javiersc.gradle.version.isRC 12 | import com.javiersc.gradle.version.isSnapshot 13 | import org.gradle.api.Project 14 | import org.gradle.api.provider.Provider 15 | 16 | public val Project.isAlpha: Provider 17 | get() = provider { version.toString().isAlpha } 18 | 19 | public val Project.isNotAlpha: Provider 20 | get() = provider { version.toString().isNotAlpha } 21 | 22 | public val Project.isBeta: Provider 23 | get() = provider { version.toString().isBeta } 24 | 25 | public val Project.isNotBeta: Provider 26 | get() = provider { version.toString().isNotBeta } 27 | 28 | public val Project.isDev: Provider 29 | get() = provider { version.toString().isDev } 30 | 31 | public val Project.isNotDev: Provider 32 | get() = provider { version.toString().isNotDev } 33 | 34 | public val Project.isRC: Provider 35 | get() = provider { version.toString().isRC } 36 | 37 | public val Project.isNotRC: Provider 38 | get() = provider { version.toString().isNotRC } 39 | 40 | public val Project.isSnapshot: Provider 41 | get() = provider { version.toString().isSnapshot } 42 | 43 | public val Project.isNotSnapshot: Provider 44 | get() = provider { version.toString().isNotSnapshot } 45 | -------------------------------------------------------------------------------- /.docs/mkdocs.yml: -------------------------------------------------------------------------------- 1 | site_name: 'Semver Gradle Plugin' 2 | site_description: 'Gradle plugin to configure automatically the projects version based on git tags' 3 | site_author: 'Javier Segovia Córdoba' 4 | remote_branch: gh-pages 5 | 6 | repo_name: 'semver-gradle-plugin' 7 | repo_url: 'https://github.com/JavierSegoviaCordoba/semver-gradle-plugin' 8 | 9 | copyright: 'Copyright © 2021 Javier Segovia Córdoba' 10 | 11 | theme: 12 | name: 'material' 13 | language: 'en' 14 | favicon: 'assets/favicon.png' 15 | logo: 'assets/logo.svg' 16 | font: 17 | text: 'Fira Sans' 18 | code: 'JetBrains Mono' 19 | palette: 20 | - media: "(prefers-color-scheme: light)" 21 | scheme: default 22 | primary: 'white' 23 | accent: 'white' 24 | toggle: 25 | icon: material/weather-sunny 26 | name: Switch to dark mode 27 | - media: "(prefers-color-scheme: dark)" 28 | primary: 'indigo' 29 | accent: 'light blue' 30 | scheme: slate 31 | toggle: 32 | icon: material/weather-night 33 | name: Switch to light mode 34 | nav: 35 | - Overview: index.md 36 | - Examples: 37 | - Single project: examples/SINGLE_PROJECT/ 38 | - Multi project: examples/MULTI_PROJECT/ 39 | 40 | plugins: 41 | - search 42 | 43 | markdown_extensions: 44 | - admonition 45 | - smarty 46 | - codehilite: 47 | guess_lang: false 48 | linenums: True 49 | - footnotes 50 | - meta 51 | - toc: 52 | permalink: true 53 | - pymdownx.betterem: 54 | smart_enable: all 55 | - pymdownx.caret 56 | - pymdownx.details 57 | - pymdownx.inlinehilite 58 | - pymdownx.magiclink 59 | - pymdownx.smartsymbols 60 | - pymdownx.superfences 61 | - tables 62 | 63 | extra: 64 | social: 65 | - icon: fontawesome/brands/github 66 | link: https://github.com/JavierSegoviaCordoba 67 | - icon: fontawesome/brands/twitter 68 | link: https://twitter.com/JavierSegoviaCo 69 | 70 | extra_css: 71 | - css/all.css 72 | -------------------------------------------------------------------------------- /gradle-version/main/kotlin/com/javiersc/gradle/version/IsExtensions.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.gradle.version 2 | 3 | import com.javiersc.gradle.version.GradleVersion.SpecialStage 4 | 5 | public val GradleVersion.isAlpha: Boolean 6 | get() = stage?.name?.lowercase() == "alpha" 7 | 8 | public val String.isAlpha: Boolean 9 | get() = lowercase().substringBeforeLast(".").endsWith("alpha") 10 | 11 | public val GradleVersion.isNotAlpha: Boolean 12 | get() = !isAlpha 13 | 14 | public val String.isNotAlpha: Boolean 15 | get() = !isAlpha 16 | 17 | public val GradleVersion.isBeta: Boolean 18 | get() = stage?.name?.lowercase() == "beta" 19 | 20 | public val String.isBeta: Boolean 21 | get() = lowercase().substringBeforeLast(".").endsWith("beta") 22 | 23 | public val GradleVersion.isNotBeta: Boolean 24 | get() = !isBeta 25 | 26 | public val String.isNotBeta: Boolean 27 | get() = !isBeta 28 | 29 | public val GradleVersion.isDev: Boolean 30 | get() = stage?.name?.lowercase() == SpecialStage.dev 31 | 32 | public val String.isDev: Boolean 33 | get() = lowercase().substringBeforeLast(".").endsWith(SpecialStage.dev) 34 | 35 | public val GradleVersion.isNotDev: Boolean 36 | get() = !isDev 37 | 38 | public val String.isNotDev: Boolean 39 | get() = !isDev 40 | 41 | public val GradleVersion.isRC: Boolean 42 | get() = stage?.name?.lowercase() == SpecialStage.rc 43 | 44 | public val String.isRC: Boolean 45 | get() = lowercase().substringBeforeLast(".").endsWith(SpecialStage.rc) 46 | 47 | public val GradleVersion.isNotRC: Boolean 48 | get() = !isRC 49 | 50 | public val String.isNotRC: Boolean 51 | get() = !isRC 52 | 53 | public val GradleVersion.isSnapshot: Boolean 54 | get() = stage?.name?.lowercase() == SpecialStage.snapshot 55 | 56 | public val String.isSnapshot: Boolean 57 | get() = lowercase().endsWith(SpecialStage.snapshot) 58 | 59 | public val GradleVersion.isNotSnapshot: Boolean 60 | get() = !isSnapshot 61 | 62 | public val String.isNotSnapshot: Boolean 63 | get() = !isSnapshot 64 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/main/kotlin/com/javiersc/semver/settings/gradle/plugin/SemverSettingsExtension.kt: -------------------------------------------------------------------------------- 1 | @file:Suppress("INVISIBLE_MEMBER", "INVISIBLE_REFERENCE") 2 | 3 | package com.javiersc.semver.settings.gradle.plugin 4 | 5 | import com.javiersc.semver.project.gradle.plugin.VersionMapper 6 | import com.javiersc.semver.project.gradle.plugin.internal.DefaultTagPrefix 7 | import java.io.File 8 | import javax.inject.Inject 9 | import org.gradle.api.file.DirectoryProperty 10 | import org.gradle.api.initialization.Settings 11 | import org.gradle.api.model.ObjectFactory 12 | import org.gradle.api.provider.Property 13 | import org.gradle.api.provider.Provider 14 | import org.gradle.kotlin.dsl.create 15 | import org.gradle.kotlin.dsl.property 16 | 17 | public abstract class SemverSettingsExtension @Inject constructor(objects: ObjectFactory) { 18 | 19 | public val isEnabled: Property = objects.property().convention(true) 20 | 21 | public abstract val gitDir: DirectoryProperty 22 | 23 | public val commitsMaxCount: Property = objects.property().convention(-1) 24 | 25 | public val tagPrefix: Property = objects.property().convention(DefaultTagPrefix) 26 | 27 | internal val versionMapper: Property = 28 | objects 29 | .property() 30 | .convention(VersionMapper { version -> version.toString() }) 31 | 32 | public fun mapVersion(transform: VersionMapper) { 33 | versionMapper.set(transform) 34 | } 35 | 36 | public companion object { 37 | 38 | public const val ExtensionName: String = "semver" 39 | 40 | internal fun register(settings: Settings): SemverSettingsExtension { 41 | val semver: SemverSettingsExtension = settings.extensions.create(ExtensionName) 42 | val gitDir: Provider = 43 | settings.providers.provider { settings.rootDir.resolve(".git") } 44 | semver.gitDir.fileProvider(gitDir) 45 | return semver 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /semver-settings-gradle-plugin/testFunctional/kotlin/com/javiersc/semver/settings/gradle/plugin/MultiProjectTest.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.settings.gradle.plugin 2 | 3 | import com.javiersc.gradle.testkit.test.extensions.GradleTestKitTest 4 | import io.kotest.matchers.string.shouldContain 5 | import kotlin.test.Test 6 | import org.eclipse.jgit.api.Git 7 | 8 | internal class MultiProjectTest : GradleTestKitTest() { 9 | 10 | @Test 11 | fun `multi project basic`() { 12 | gradleTestKitTest("multi-project-basic") { 13 | val git = Git.init().setDirectory(projectDir).call() 14 | git.add().addFilepattern(".").call() 15 | git.commit().setMessage("Initial commit").call() 16 | git.tag().setName("v1.0.0").call() 17 | git.tag().setName("o2.0.3").call() 18 | git.tag().setName("t4.7.5").call() 19 | gradlew("printSemver", stacktrace()) 20 | .output 21 | .shouldContain("semver for multi-project: v1.0.0") 22 | .shouldContain("semver for library-one: o2.0.3") 23 | .shouldContain("semver for library-two: t4.7.5") 24 | } 25 | } 26 | 27 | @Test 28 | fun `multi project`() { 29 | gradleTestKitTest("multi-project") { 30 | val git = Git.init().setDirectory(projectDir).call() 31 | git.add().addFilepattern(".").call() 32 | git.commit().setMessage("Initial commit").call() 33 | git.tag().setName("v1.0.0").call() 34 | git.tag().setName("w3.1.2").call() 35 | git.tag().setName("o2.0.3").call() 36 | git.tag().setName("t4.7.5").call() 37 | gradlew("printSemver", stacktrace()) 38 | .output 39 | .shouldContain("semver for multi-project: w3.1.2") 40 | .shouldContain("semver for library-one: v1.0.0") 41 | .shouldContain("semver for library-two: o2.0.3") 42 | .shouldContain("semver for library-three: t12.13.14") 43 | } 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/tasks/PushSemverTagTask.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.tasks 2 | 3 | import com.javiersc.semver.project.gradle.plugin.internal.projectTagPrefix 4 | import com.javiersc.semver.project.gradle.plugin.internal.tagPrefixProperty 5 | import com.javiersc.semver.project.gradle.plugin.services.GitBuildService 6 | import org.gradle.api.DefaultTask 7 | import org.gradle.api.Project 8 | import org.gradle.api.provider.Property 9 | import org.gradle.api.provider.Provider 10 | import org.gradle.api.tasks.Internal 11 | import org.gradle.api.tasks.TaskAction 12 | import org.gradle.kotlin.dsl.register 13 | import org.gradle.work.DisableCachingByDefault 14 | 15 | @DisableCachingByDefault 16 | public abstract class PushSemverTagTask : DefaultTask() { 17 | 18 | init { 19 | group = "semver" 20 | } 21 | 22 | @get:Internal internal abstract val tagPrefixProperty: Property 23 | 24 | @get:Internal internal abstract val projectTagPrefix: Property 25 | 26 | @get:Internal internal abstract val version: Property 27 | 28 | @get:Internal internal abstract val gitTagBuildService: Property 29 | 30 | @TaskAction 31 | public fun run() { 32 | gitTagBuildService 33 | .get() 34 | .pushTag(tagPrefixProperty.get(), projectTagPrefix.get(), version.get()) 35 | } 36 | 37 | public companion object { 38 | 39 | public const val NAME: String = "pushSemverTag" 40 | 41 | internal fun register(project: Project, gitTagBuildService: Provider) { 42 | project.tasks.register(NAME).configure { task -> 43 | task.tagPrefixProperty.set(project.tagPrefixProperty) 44 | task.projectTagPrefix.set(project.projectTagPrefix) 45 | task.version.set(project.version.toString()) 46 | task.gitTagBuildService.set(gitTagBuildService) 47 | task.usesService(gitTagBuildService) 48 | } 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/testFunctional/kotlin/com/javiersc/semver/project/gradle/plugin/PushSemverTagTaskTest.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.gradle.testkit.test.extensions.GradleTestKitTest 4 | import com.javiersc.semver.project.gradle.plugin.internal.git.tagName 5 | import io.kotest.matchers.collections.shouldContain 6 | import io.kotest.matchers.collections.shouldHaveSize 7 | import io.kotest.matchers.collections.shouldNotBeEmpty 8 | import java.io.File 9 | import kotlin.test.Test 10 | import org.eclipse.jgit.api.Git 11 | import org.eclipse.jgit.lib.Ref 12 | import org.eclipse.jgit.storage.file.FileRepositoryBuilder 13 | import org.eclipse.jgit.transport.URIish 14 | 15 | class PushSemverTagTaskTest : GradleTestKitTest() { 16 | 17 | @Test 18 | fun `push tag`() { 19 | gradleTestKitTest("push-tag") { 20 | projectDir.generateInitialCommitAddVersionTagAndAddNewCommit() 21 | 22 | val generatedDir: File = projectDir.resolve("build/generated/").apply(File::mkdirs) 23 | 24 | val remoteBuildGitDir: File = generatedDir.resolve(".git").apply(File::mkdirs) 25 | 26 | val remoteGit = 27 | Git( 28 | FileRepositoryBuilder() 29 | .setGitDir(remoteBuildGitDir) 30 | .readEnvironment() 31 | .findGitDir() 32 | .build() 33 | ) 34 | 35 | git.repository.directory.copyRecursively(remoteBuildGitDir) 36 | 37 | git.remoteSetUrl() 38 | .setRemoteName("origin") 39 | .setRemoteUri(URIish(remoteBuildGitDir.toURI().toString())) 40 | .call() 41 | 42 | gradlew("pushSemverTag", "-Psemver.tagPrefix=v") 43 | 44 | remoteGit 45 | .tagList() 46 | .call() 47 | .map(Ref::tagName) 48 | .shouldNotBeEmpty() 49 | .shouldHaveSize(2) 50 | .shouldContain("v1.0.0") 51 | .shouldContain("v1.0.1") 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /.docs/changelogs/CHANGELOG_0.2.0.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | 3 | ## [0.2.0-alpha.2] - 2022-06-18 4 | 5 | ### Fixed 6 | 7 | - high configuration time 8 | - `semverCreateTag` does not belong to the `semver` group 9 | - `semverPushTag` does not create the tag 10 | 11 | ## [0.2.0-alpha.1] - 2022-06-14 12 | 13 | ### Added 14 | 15 | - `semverPrint` task which prints the version and generates the `build/semver/version.txt`. 16 | - `semver` plugin extension which has `tagPrefix` to indicate the project tag prefix. 17 | - configuration cache support 18 | - project isolation support 19 | 20 | ### Changed 21 | 22 | - the plugin must be applied individually to each project instead of only in the root project. 23 | - `project.version` is now a `LazyVersion`, to get the string use `toString` method. 24 | - `createSemverTag` name to `semverCreateTag`. 25 | - `pushSemverTag` name to `semverPushTag`. 26 | - `semver.tagPrefix` is no longer used to indicate a project version. Now it is used to filter which 27 | projects are going to bump the version based on it and the value in the property `tagPrefix` in 28 | the semver plugin extension. 29 | 30 | ### Removed 31 | 32 | - applying the plugin to the root project only configures the root project and not all projects. 33 | - `build/semver/version.txt` is no longer generated in configuration phase. 34 | - the old way to change the version in multi-project builds (`-PprojectName:semver.scope=patch"`). 35 | 36 | ### Updated 37 | 38 | - `org.jetbrains.kotlinx:binary-compatibility-validator -> 0.10.1` 39 | - `org.eclipse.jgit:org.eclipse.jgit -> 6.2.0.202206071550-r` 40 | - `com.javiersc.kotlin:kotlin-stdlib -> 0.1.0-alpha.5` 41 | - `org.jetbrains.kotlinx:kotlinx-coroutines-core -> 1.6.2` 42 | - `com.javiersc.gradle-plugins:all-plugins -> 0.1.0-rc.43` 43 | - `io.kotest:kotest-assertions-core -> 5.3.0` 44 | - `org.jetbrains.kotlin:kotlin-gradle-plugin -> 1.6.21` 45 | - `gradle -> 7.4.2` 46 | 47 | [0.2.0-alpha.2]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.2.0-alpha.1...0.2.0-alpha.2 48 | 49 | [0.2.0-alpha.1]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.1.0-alpha.10...0.2.0-alpha.1 50 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/test/kotlin/com/javiersc/semver/project/gradle/plugin/VersionTest.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.gradle.version.GradleVersion 4 | import com.javiersc.semver.project.gradle.plugin.internal.git.GitCache 5 | import io.kotest.matchers.booleans.shouldBeTrue 6 | import io.kotest.matchers.shouldBe 7 | import kotlin.test.Test 8 | 9 | internal class VersionTest { 10 | 11 | @Test 12 | fun `last version in current branch`() { 13 | initialCommitAnd { 14 | fun cache() = GitCache(gitDir = git.repository.directory) 15 | 16 | resolve("2 commit.txt").createNewFile() 17 | git.add().addFilepattern(".").call() 18 | git.commit().setMessage("2 commit").call() 19 | git.tag().setName("v1.0.0").call() 20 | cache().lastVersionInCurrentBranch("v").shouldBe(GradleVersion("1.0.0")) 21 | 22 | git.tag().setName("v1.0.0-alpha.1").call() 23 | cache().lastVersionInCurrentBranch("v").shouldBe(GradleVersion("1.0.0")) 24 | 25 | resolve("3 commit.txt").createNewFile() 26 | git.add().addFilepattern(".").call() 27 | git.commit().setMessage("3 commit").call() 28 | git.tag().setName("v1.0.0-alpha.2").call() 29 | cache().lastVersionInCurrentBranch("v").shouldBe(GradleVersion("1.0.0-alpha.2")) 30 | 31 | resolve("4 commit.txt").createNewFile() 32 | git.add().addFilepattern(".").call() 33 | git.commit().setMessage("4 commit").call() 34 | 35 | var isWarningLastVersionIsNotHigherVersion = false 36 | cache().lastVersionInCurrentBranch("v") { isWarningLastVersionIsNotHigherVersion = it } 37 | isWarningLastVersionIsNotHigherVersion.shouldBeTrue() 38 | 39 | resolve("5 commit.txt").createNewFile() 40 | git.add().addFilepattern(".").call() 41 | git.commit().setMessage("5 commit").call() 42 | git.tag().setName("v2.0.0-rc.2").call() 43 | cache().lastVersionInCurrentBranch("v").shouldBe(GradleVersion("2.0.0-rc.2")) 44 | } 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /.docs/changelogs/CHANGELOG_0.3.0.md: -------------------------------------------------------------------------------- 1 | # Changelog 2 | 3 | ## [0.3.0-alpha.5] - 2022-11-04 4 | 5 | ### Added 6 | 7 | - `semver.project.tagPrefix` Gradle Project property to set tag prefix instead of using the property 8 | from the extension (`SemverExtension::tagPrefix`). If both are set, the first one has preference. 9 | 10 | ### Updated 11 | 12 | - `com.javiersc.hubdle:com.javiersc.hubdle.gradle.plugin -> 0.2.0-alpha.43` 13 | - `org.eclipse.jgit:org.eclipse.jgit -> 6.3.0.202209071007-r` 14 | - `gradle -> 7.5.1` 15 | 16 | ## [0.3.0-alpha.4] - 2022-07-10 17 | 18 | ### Fixed 19 | 20 | - `githubEnv*` properties are not `SNAKE_CASE` in `PrintSemverTask` 21 | 22 | ## [0.3.0-alpha.3] - 2022-07-10 23 | 24 | ### Fixed 25 | 26 | - each `githubEnv*` property in `PrintSemverTask` 27 | 28 | ### Updated 29 | 30 | - `com.javiersc.hubdle:com.javiersc.hubdle.gradle.plugin -> 0.2.0-alpha.19` 31 | 32 | ## [0.3.0-alpha.2] - 2022-07-09 33 | 34 | ### Added 35 | 36 | - `githubEnv` boolean option to `PrintSemverTask` 37 | - `githubOutput` boolean option to `PrintSemverTask` 38 | 39 | ### Changed 40 | 41 | - `printSemver` can't be cacheable 42 | 43 | ### Updated 44 | 45 | - `com.javiersc.hubdle:com.javiersc.hubdle.gradle.plugin -> 0.2.0-alpha.18` 46 | - `org.jetbrains.kotlin:kotlin-gradle-plugin -> 1.7.10` 47 | - `com.android.application:com.android.application.gradle.plugin -> 7.2.1` 48 | 49 | ## [0.3.0-alpha.1] - 2022-07-03 50 | 51 | ### Changed 52 | 53 | - `printSemver` name to `printSemver`. 54 | - `semverCreateTag` name to `createSemverTag`. 55 | - `semverPushTag` name to `pushSemverTag`. 56 | 57 | ### Updated 58 | 59 | - `org.jetbrains.kotlinx:kotlinx-coroutines-core -> 1.6.3` 60 | 61 | [0.3.0-alpha.5]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.3.0-alpha.4...0.3.0-alpha.5 62 | 63 | [0.3.0-alpha.4]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.3.0-alpha.3...0.3.0-alpha.4 64 | 65 | [0.3.0-alpha.3]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.3.0-alpha.2...0.3.0-alpha.3 66 | 67 | [0.3.0-alpha.2]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.3.0-alpha.1...0.3.0-alpha.2 68 | 69 | [0.3.0-alpha.1]: https://github.com/JavierSegoviaCordoba/semver-gradle-plugin/compare/0.2.0-alpha.2...0.3.0-alpha.1 70 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/tasks/CreateSemverTagTask.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.tasks 2 | 3 | import com.javiersc.semver.project.gradle.plugin.internal.projectTagPrefix 4 | import com.javiersc.semver.project.gradle.plugin.internal.tagPrefixProperty 5 | import com.javiersc.semver.project.gradle.plugin.services.GitBuildService 6 | import org.gradle.api.DefaultTask 7 | import org.gradle.api.Project 8 | import org.gradle.api.Task 9 | import org.gradle.api.provider.Property 10 | import org.gradle.api.provider.Provider 11 | import org.gradle.api.tasks.Internal 12 | import org.gradle.api.tasks.TaskAction 13 | import org.gradle.api.tasks.TaskProvider 14 | import org.gradle.kotlin.dsl.register 15 | import org.gradle.work.DisableCachingByDefault 16 | 17 | @DisableCachingByDefault 18 | public abstract class CreateSemverTagTask : DefaultTask() { 19 | 20 | @get:Internal internal abstract val tagPrefixProperty: Property 21 | 22 | @get:Internal internal abstract val projectTagPrefix: Property 23 | 24 | @get:Internal internal abstract val version: Property 25 | 26 | @get:Internal internal abstract val gitTagBuildService: Property 27 | 28 | init { 29 | group = "semver" 30 | } 31 | 32 | @TaskAction 33 | public fun run() { 34 | gitTagBuildService 35 | .get() 36 | .createTag(tagPrefixProperty.get(), projectTagPrefix.get(), version.get()) 37 | } 38 | 39 | public companion object { 40 | 41 | public const val NAME: String = "createSemverTag" 42 | 43 | internal fun register(project: Project, gitTagBuildService: Provider) { 44 | val printSemverTask: TaskProvider = project.tasks.named(PrintSemverTask.NAME) 45 | val writeSemverTask: TaskProvider = project.tasks.named(WriteSemverTask.NAME) 46 | project.tasks.register(NAME).configure { task -> 47 | task.tagPrefixProperty.set(project.tagPrefixProperty) 48 | task.projectTagPrefix.set(project.projectTagPrefix) 49 | task.version.set(project.version.toString()) 50 | task.gitTagBuildService.set(gitTagBuildService) 51 | task.usesService(gitTagBuildService) 52 | task.dependsOn(printSemverTask) 53 | task.dependsOn(writeSemverTask) 54 | } 55 | } 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/SemverProjectPlugin.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.semver.project.gradle.plugin.internal.checkScopeCorrectness 4 | import com.javiersc.semver.project.gradle.plugin.services.GitBuildService 5 | import com.javiersc.semver.project.gradle.plugin.tasks.CreateSemverTagTask 6 | import com.javiersc.semver.project.gradle.plugin.tasks.PrintSemverTask 7 | import com.javiersc.semver.project.gradle.plugin.tasks.PushSemverTagTask 8 | import com.javiersc.semver.project.gradle.plugin.tasks.WriteSemverTask 9 | import com.javiersc.semver.project.gradle.plugin.valuesources.VersionValueSource 10 | import org.gradle.api.Plugin 11 | import org.gradle.api.Project 12 | import org.gradle.api.plugins.BasePlugin 13 | import org.gradle.api.provider.Provider 14 | import org.gradle.kotlin.dsl.apply 15 | 16 | public class SemverProjectPlugin : Plugin { 17 | 18 | override fun apply(target: Project) { 19 | target.config() 20 | } 21 | 22 | private fun Project.config() { 23 | pluginManager.apply(BasePlugin::class) 24 | 25 | SemverExtension.register(this) 26 | 27 | if (semverExtension.isEnabled.get()) { 28 | val gitTagBuildService: Provider = GitBuildService.register(this) 29 | checkScopeCorrectness() 30 | configureVersion() 31 | configureBuildServicesAndTasks(gitTagBuildService) 32 | } 33 | } 34 | 35 | private fun Project.configureBuildServicesAndTasks( 36 | gitTagBuildService: Provider 37 | ) { 38 | PrintSemverTask.register(this) 39 | WriteSemverTask.register(this) 40 | CreateSemverTagTask.register(this, gitTagBuildService) 41 | PushSemverTagTask.register(this, gitTagBuildService) 42 | } 43 | 44 | private fun Project.configureVersion() { 45 | val gradleVersionProvider: Provider = VersionValueSource.register(this) 46 | version = VersionProperty(gradleVersionProvider) 47 | 48 | // It is possible third party plugin breaks lazy configuration by calling `project.version` 49 | // too early, applying the calculated version in `afterEvaluate` fix it sometimes. 50 | afterEvaluate { proj -> 51 | val gradleVersionProviderProj: Provider = VersionValueSource.register(proj) 52 | proj.version = VersionProperty(gradleVersionProviderProj) 53 | } 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | #################################################################################################### 2 | ### CONFIGURATION ### 3 | #################################################################################################### 4 | root.project.name=semver-gradle-plugin-project 5 | main.project.name=semver-gradle-plugin 6 | project.group=com.javiersc.semver 7 | #################################################################################################### 8 | ### CODE ANALYSIS ### 9 | #################################################################################################### 10 | analysis.qodana.projectKey=37xWn 11 | analysis.sonar.organization=javiersc 12 | analysis.sonar.projectKey=com.javiersc.gradle:semver-gradle-plugin 13 | analysis.sonar.projectName=semver-gradle-plugin 14 | #################################################################################################### 15 | ### POM ### 16 | #################################################################################################### 17 | pom.name=Semver Gradle Plugin 18 | pom.description=Gradle plugin to configure automatically the projects version based on git tags 19 | pom.url=https://github.com/JavierSegoviaCordoba/semver-gradle-plugin 20 | pom.license.name=The Apache License, Version 2.0 21 | pom.license.url=https://www.apache.org/licenses/LICENSE-2.0.txt 22 | pom.developer.id=JavierSegoviaCordoba 23 | pom.developer.name=Javier Segovia Cordoba 24 | pom.developer.email=javier@segoviacordoba.com 25 | pom.scm.url=https://github.com/JavierSegoviaCordoba/semver-gradle-plugin 26 | pom.scm.connection=scm:git:git@github.com:JavierSegoviaCordoba/semver-gradle-plugin.git 27 | pom.scm.developerConnection=scm:git:git@github.com:JavierSegoviaCordoba/semver-gradle-plugin.git 28 | #################################################################################################### 29 | ### Gradle ### 30 | #################################################################################################### 31 | kotlin.code.style=official 32 | org.gradle.caching=true 33 | org.gradle.configuration-cache=true 34 | org.gradle.configuration-cache.parallel=true 35 | org.gradle.configuration-cache.problems=warn 36 | org.gradle.configureondemand=true 37 | org.gradle.jvmargs=-Xmx2048m 38 | org.gradle.parallel=true 39 | signing.gnupg.executable=gpg 40 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/SemverExtension.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.semver.project.gradle.plugin.internal.DefaultTagPrefix 4 | import com.javiersc.semver.project.gradle.plugin.internal.git.GitCache 5 | import com.javiersc.semver.project.gradle.plugin.internal.semverWarningMessage 6 | import java.io.File 7 | import javax.inject.Inject 8 | import org.gradle.api.Project 9 | import org.gradle.api.file.DirectoryProperty 10 | import org.gradle.api.model.ObjectFactory 11 | import org.gradle.api.provider.Property 12 | import org.gradle.api.provider.Provider 13 | import org.gradle.api.provider.ProviderFactory 14 | import org.gradle.kotlin.dsl.create 15 | import org.gradle.kotlin.dsl.getByType 16 | import org.gradle.kotlin.dsl.property 17 | 18 | public abstract class SemverExtension 19 | @Inject 20 | constructor(objects: ObjectFactory, providers: ProviderFactory) { 21 | 22 | public val isEnabled: Property = objects.property().convention(true) 23 | 24 | public abstract val gitDir: DirectoryProperty 25 | 26 | public val commits: Provider> = 27 | providers.provider { 28 | val gitDir: File? = gitDir.orNull?.asFile?.takeIf { it.exists() } 29 | if (gitDir == null) { 30 | semverWarningMessage("There is no git directory") 31 | return@provider emptyList() 32 | } 33 | GitCache(gitDir = gitDir, maxCount = commitsMaxCount).commitsInTheCurrentBranchPublicApi 34 | } 35 | 36 | public val commitsMaxCount: Property = objects.property().convention(-1) 37 | 38 | public val tagPrefix: Property = objects.property().convention(DefaultTagPrefix) 39 | 40 | internal val versionMapper: Property = 41 | objects 42 | .property() 43 | .convention(VersionMapper { version -> version.toString() }) 44 | 45 | public fun mapVersion(transform: VersionMapper) { 46 | versionMapper.set(transform) 47 | } 48 | 49 | public companion object { 50 | 51 | public const val ExtensionName: String = "semver" 52 | 53 | internal fun register(project: Project) { 54 | project.extensions.create(ExtensionName) 55 | val gitDir: Provider = project.provider { project.rootDir.resolve(".git") } 56 | project.semverExtension.gitDir.fileProvider(gitDir) 57 | } 58 | } 59 | } 60 | 61 | internal val Project.semverExtension: SemverExtension 62 | get() = extensions.getByType() 63 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/internal/SemverProperty.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.internal 2 | 3 | import java.util.Properties 4 | import org.gradle.api.Project 5 | import org.gradle.api.provider.Provider 6 | 7 | internal const val DefaultTagPrefix = "" 8 | 9 | internal val Project.projectTagPrefixProperty: Provider 10 | get() = getSemverProperty(SemverProperty.ProjectTagPrefix) 11 | 12 | internal val Project.tagPrefixProperty: Provider 13 | get() = 14 | providers.provider { 15 | getSemverProperty(SemverProperty.TagPrefix).orNull ?: DefaultTagPrefix 16 | } 17 | 18 | internal val Project.stageProperty: Provider 19 | get() = getSemverProperty(SemverProperty.Stage) 20 | 21 | internal val Project.scopeProperty: Provider 22 | get() = getSemverProperty(SemverProperty.Scope) 23 | 24 | internal val Project.remoteProperty: Provider 25 | get() = getSemverProperty(SemverProperty.Remote) 26 | 27 | internal val Project.checkCleanProperty: Provider 28 | get() = 29 | providers.provider { 30 | getSemverProperty(SemverProperty.CheckClean).orNull?.toBoolean() ?: true 31 | } 32 | 33 | internal val Project.commitsMaxCount: Provider 34 | get() = getSemverProperty(SemverProperty.CommitsMaxCount).map(String::toInt) 35 | 36 | internal val Project.logOnlyOnRootProject: Provider 37 | get() = 38 | providers.provider { 39 | getSemverProperty(SemverProperty.LogOnlyOnRootProject).orNull?.toBoolean() ?: false 40 | } 41 | 42 | internal enum class SemverProperty(val key: String) { 43 | ProjectTagPrefix("semver.project.tagPrefix"), 44 | TagPrefix("semver.tagPrefix"), 45 | Stage("semver.stage"), 46 | Scope("semver.scope"), 47 | Remote("semver.remote"), 48 | CheckClean("semver.checkClean"), 49 | CommitsMaxCount("semver.commitsMaxCount"), 50 | LogOnlyOnRootProject("semver.logOnlyOnRootProject"), 51 | } 52 | 53 | internal enum class Stage(private val value: String) { 54 | Auto("auto"), 55 | Final("final"); 56 | 57 | operator fun invoke(): String = value 58 | } 59 | 60 | internal enum class Scope(private val value: String) { 61 | Auto("auto"), 62 | Major("major"), 63 | Minor("minor"), 64 | Patch("patch"); 65 | 66 | override fun toString(): String = value 67 | } 68 | 69 | private fun Project.getSemverProperty(semverProperty: SemverProperty): Provider = 70 | when { 71 | gradle.startParameter.projectProperties[semverProperty.key] != null -> { 72 | provider { gradle.startParameter.projectProperties[semverProperty.key] } 73 | } 74 | projectDir.resolve("gradle.properties").exists() -> { 75 | provider { 76 | Properties() 77 | .apply { 78 | projectDir.resolve("gradle.properties").inputStream().use { load(it) } 79 | } 80 | .getProperty(semverProperty.key) 81 | } 82 | } 83 | else -> { 84 | providers.gradleProperty(semverProperty.key) 85 | } 86 | } 87 | -------------------------------------------------------------------------------- /gradlew.bat: -------------------------------------------------------------------------------- 1 | @rem 2 | @rem Copyright 2015 the original author or authors. 3 | @rem 4 | @rem Licensed under the Apache License, Version 2.0 (the "License"); 5 | @rem you may not use this file except in compliance with the License. 6 | @rem You may obtain a copy of the License at 7 | @rem 8 | @rem https://www.apache.org/licenses/LICENSE-2.0 9 | @rem 10 | @rem Unless required by applicable law or agreed to in writing, software 11 | @rem distributed under the License is distributed on an "AS IS" BASIS, 12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | @rem See the License for the specific language governing permissions and 14 | @rem limitations under the License. 15 | @rem 16 | @rem SPDX-License-Identifier: Apache-2.0 17 | @rem 18 | 19 | @if "%DEBUG%"=="" @echo off 20 | @rem ########################################################################## 21 | @rem 22 | @rem Gradle startup script for Windows 23 | @rem 24 | @rem ########################################################################## 25 | 26 | @rem Set local scope for the variables with windows NT shell 27 | if "%OS%"=="Windows_NT" setlocal 28 | 29 | set DIRNAME=%~dp0 30 | if "%DIRNAME%"=="" set DIRNAME=. 31 | @rem This is normally unused 32 | set APP_BASE_NAME=%~n0 33 | set APP_HOME=%DIRNAME% 34 | 35 | @rem Resolve any "." and ".." in APP_HOME to make it shorter. 36 | for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi 37 | 38 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 39 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" 40 | 41 | @rem Find java.exe 42 | if defined JAVA_HOME goto findJavaFromJavaHome 43 | 44 | set JAVA_EXE=java.exe 45 | %JAVA_EXE% -version >NUL 2>&1 46 | if %ERRORLEVEL% equ 0 goto execute 47 | 48 | echo. 1>&2 49 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2 50 | echo. 1>&2 51 | echo Please set the JAVA_HOME variable in your environment to match the 1>&2 52 | echo location of your Java installation. 1>&2 53 | 54 | goto fail 55 | 56 | :findJavaFromJavaHome 57 | set JAVA_HOME=%JAVA_HOME:"=% 58 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 59 | 60 | if exist "%JAVA_EXE%" goto execute 61 | 62 | echo. 1>&2 63 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2 64 | echo. 1>&2 65 | echo Please set the JAVA_HOME variable in your environment to match the 1>&2 66 | echo location of your Java installation. 1>&2 67 | 68 | goto fail 69 | 70 | :execute 71 | @rem Setup the command line 72 | 73 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 74 | 75 | 76 | @rem Execute Gradle 77 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* 78 | 79 | :end 80 | @rem End local scope for the variables with windows NT shell 81 | if %ERRORLEVEL% equ 0 goto mainEnd 82 | 83 | :fail 84 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 85 | rem the _cmd.exe /c_ return code! 86 | set EXIT_CODE=%ERRORLEVEL% 87 | if %EXIT_CODE% equ 0 set EXIT_CODE=1 88 | if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% 89 | exit /b %EXIT_CODE% 90 | 91 | :mainEnd 92 | if "%OS%"=="Windows_NT" endlocal 93 | 94 | :omega 95 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/test/kotlin/com/javiersc/semver/project/gradle/plugin/ExtensionTests.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin 2 | 3 | import com.javiersc.gradle.version.isAlpha 4 | import com.javiersc.gradle.version.isBeta 5 | import com.javiersc.gradle.version.isDev 6 | import com.javiersc.gradle.version.isNotAlpha 7 | import com.javiersc.gradle.version.isNotBeta 8 | import com.javiersc.gradle.version.isNotDev 9 | import com.javiersc.gradle.version.isNotRC 10 | import com.javiersc.gradle.version.isNotSnapshot 11 | import com.javiersc.gradle.version.isRC 12 | import com.javiersc.gradle.version.isSnapshot 13 | import io.kotest.matchers.booleans.shouldBeFalse 14 | import io.kotest.matchers.booleans.shouldBeTrue 15 | import kotlin.test.Test 16 | 17 | class ExtensionTests { 18 | 19 | @Test 20 | fun `is version`() { 21 | "1.0.0-alpha.1".isAlpha.shouldBeTrue() 22 | "1.0.0-alpha.1".isNotAlpha.shouldBeFalse() 23 | "1.0.0-alpha.1".isBeta.shouldBeFalse() 24 | "1.0.0-alpha.1".isNotBeta.shouldBeTrue() 25 | "1.0.0-alpha.1".isDev.shouldBeFalse() 26 | "1.0.0-alpha.1".isNotDev.shouldBeTrue() 27 | "1.0.0-alpha.1".isRC.shouldBeFalse() 28 | "1.0.0-alpha.1".isNotRC.shouldBeTrue() 29 | "1.0.0-alpha.1".isSnapshot.shouldBeFalse() 30 | "1.0.0-alpha.1".isNotSnapshot.shouldBeTrue() 31 | 32 | "1.0.0-beta.1".isAlpha.shouldBeFalse() 33 | "1.0.0-beta.1".isNotAlpha.shouldBeTrue() 34 | "1.0.0-beta.1".isBeta.shouldBeTrue() 35 | "1.0.0-beta.1".isNotBeta.shouldBeFalse() 36 | "1.0.0-beta.1".isDev.shouldBeFalse() 37 | "1.0.0-beta.1".isNotDev.shouldBeTrue() 38 | "1.0.0-beta.1".isRC.shouldBeFalse() 39 | "1.0.0-beta.1".isNotRC.shouldBeTrue() 40 | "1.0.0-beta.1".isSnapshot.shouldBeFalse() 41 | "1.0.0-beta.1".isNotSnapshot.shouldBeTrue() 42 | 43 | "1.0.0-dev.1".isAlpha.shouldBeFalse() 44 | "1.0.0-dev.1".isNotAlpha.shouldBeTrue() 45 | "1.0.0-dev.1".isBeta.shouldBeFalse() 46 | "1.0.0-dev.1".isNotBeta.shouldBeTrue() 47 | "1.0.0-dev.1".isDev.shouldBeTrue() 48 | "1.0.0-dev.1".isNotDev.shouldBeFalse() 49 | "1.0.0-dev.1".isRC.shouldBeFalse() 50 | "1.0.0-dev.1".isNotRC.shouldBeTrue() 51 | "1.0.0-dev.1".isSnapshot.shouldBeFalse() 52 | "1.0.0-dev.1".isNotSnapshot.shouldBeTrue() 53 | 54 | "1.0.0-rc.1".isAlpha.shouldBeFalse() 55 | "1.0.0-rc.1".isNotAlpha.shouldBeTrue() 56 | "1.0.0-rc.1".isBeta.shouldBeFalse() 57 | "1.0.0-rc.1".isNotBeta.shouldBeTrue() 58 | "1.0.0-rc.1".isDev.shouldBeFalse() 59 | "1.0.0-rc.1".isNotDev.shouldBeTrue() 60 | "1.0.0-rc.1".isRC.shouldBeTrue() 61 | "1.0.0-rc.1".isNotRC.shouldBeFalse() 62 | "1.0.0-rc.1".isSnapshot.shouldBeFalse() 63 | "1.0.0-rc.1".isNotSnapshot.shouldBeTrue() 64 | 65 | "1.0.0-SNAPSHOT".isAlpha.shouldBeFalse() 66 | "1.0.0-SNAPSHOT".isNotAlpha.shouldBeTrue() 67 | "1.0.0-SNAPSHOT".isBeta.shouldBeFalse() 68 | "1.0.0-SNAPSHOT".isNotBeta.shouldBeTrue() 69 | "1.0.0-SNAPSHOT".isDev.shouldBeFalse() 70 | "1.0.0-SNAPSHOT".isNotDev.shouldBeTrue() 71 | "1.0.0-SNAPSHOT".isRC.shouldBeFalse() 72 | "1.0.0-SNAPSHOT".isNotRC.shouldBeTrue() 73 | "1.0.0-SNAPSHOT".isSnapshot.shouldBeTrue() 74 | "1.0.0-SNAPSHOT".isNotSnapshot.shouldBeFalse() 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /semver-project-gradle-plugin/main/kotlin/com/javiersc/semver/project/gradle/plugin/tasks/WriteSemverTask.kt: -------------------------------------------------------------------------------- 1 | package com.javiersc.semver.project.gradle.plugin.tasks 2 | 3 | import com.javiersc.semver.project.gradle.plugin.internal.projectTagPrefix 4 | import javax.inject.Inject 5 | import org.gradle.api.DefaultTask 6 | import org.gradle.api.Project 7 | import org.gradle.api.file.ProjectLayout 8 | import org.gradle.api.file.RegularFileProperty 9 | import org.gradle.api.model.ObjectFactory 10 | import org.gradle.api.provider.Property 11 | import org.gradle.api.tasks.CacheableTask 12 | import org.gradle.api.tasks.Input 13 | import org.gradle.api.tasks.OutputFile 14 | import org.gradle.api.tasks.TaskAction 15 | import org.gradle.api.tasks.TaskProvider 16 | import org.gradle.api.tasks.testing.Test 17 | import org.gradle.jvm.tasks.Jar 18 | import org.gradle.kotlin.dsl.register 19 | import org.gradle.kotlin.dsl.withType 20 | import org.gradle.language.base.plugins.LifecycleBasePlugin.ASSEMBLE_TASK_NAME 21 | import org.gradle.language.base.plugins.LifecycleBasePlugin.BUILD_TASK_NAME 22 | import org.gradle.language.base.plugins.LifecycleBasePlugin.CHECK_TASK_NAME 23 | 24 | @CacheableTask 25 | public abstract class WriteSemverTask 26 | @Inject 27 | constructor(objects: ObjectFactory, layout: ProjectLayout) : DefaultTask() { 28 | 29 | init { 30 | group = "semver" 31 | } 32 | 33 | @get:Input public abstract val tagPrefix: Property 34 | 35 | @get:Input public abstract val version: Property 36 | 37 | @OutputFile 38 | public val semverFile: RegularFileProperty = 39 | objects.fileProperty().convention(layout.buildDirectory.file("semver/version.txt")) 40 | 41 | @TaskAction 42 | public fun run() { 43 | val semver: String = version.get() 44 | val prefix: String = tagPrefix.get() 45 | val semverWithPrefix = "$prefix$semver" 46 | 47 | semverFile.get().asFile.apply { 48 | parentFile.mkdirs() 49 | createNewFile() 50 | writeText( 51 | """ 52 | |$semver 53 | |$semverWithPrefix 54 | | 55 | """ 56 | .trimMargin() 57 | ) 58 | } 59 | } 60 | 61 | public companion object { 62 | 63 | public const val NAME: String = "writeSemver" 64 | 65 | internal fun register(project: Project): TaskProvider { 66 | val writeSemverTask: TaskProvider = 67 | project.tasks.register(NAME) 68 | 69 | writeSemverTask.configure { task -> 70 | task.tagPrefix.set(project.projectTagPrefix) 71 | task.version.set(project.version.toString()) 72 | } 73 | 74 | project.tasks.named(ASSEMBLE_TASK_NAME).configure { task -> 75 | task.dependsOn(writeSemverTask) 76 | } 77 | project.tasks.named(BUILD_TASK_NAME).configure { task -> 78 | task.dependsOn(writeSemverTask) 79 | } 80 | project.tasks.named(CHECK_TASK_NAME).configure { task -> 81 | task.dependsOn(writeSemverTask) 82 | } 83 | project.tasks.withType().configureEach { task -> task.dependsOn(writeSemverTask) } 84 | project.tasks.withType().configureEach { task -> task.dependsOn(writeSemverTask) } 85 | 86 | return writeSemverTask 87 | } 88 | } 89 | } 90 | --------------------------------------------------------------------------------