Skip to content

Commit

Permalink
fix(semantic-release): add missing semantic release plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
AndyTWF committed Jul 2, 2021
1 parent 27dcc49 commit d9f7851
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 6 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/build.yml
Expand Up @@ -16,6 +16,8 @@ jobs:
steps:
- name: Checkout Code
uses: actions/checkout@v2
with:
persist-credentials: false

# Environment things
- name: Add Msbuild To PATH
Expand Down Expand Up @@ -102,9 +104,10 @@ jobs:
name: UKControllerPlugin.dll
path: ".\\bin\\Release\\UKControllerPlugin.dll"

# If we're building on main, lets do a release'
# If we're building on main, lets do a release
- name: Create Release
if: github.ref == 'refs/heads/main'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx -p @semantic-release/changelog -p semantic-release@17 semantic-release
env:
GITHUB_TOKEN: ${{ secrets.PAT }}
GH_TOKEN: ${{ secrets.PAT }}
run: npx -p @semantic-release/changelog -p @semantic-release/git -p semantic-release@17 semantic-release
2 changes: 1 addition & 1 deletion .github/workflows/plugin_version.ps1
Expand Up @@ -2,7 +2,7 @@ Function Build-Version {
# If we're on main, invoke semantic release to get the next version
if (${env:GITHUB_REF} -eq "refs/heads/main")
{
$semanticRelease = npx -p @semantic-release/changelog -p semantic-release@17 semantic-release --dry-run | Select-String -Pattern "Published release ((0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)"
$semanticRelease = npx -p @semantic-release/changelog -p @semantic-release/git -p semantic-release@17 semantic-release --dry-run | Select-String -Pattern "Published release ((0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?)"
if ($semanticRelease.Matches -eq $null)
{
return "non-release-build"
Expand Down
8 changes: 7 additions & 1 deletion package.json
Expand Up @@ -49,7 +49,7 @@
"@semantic-release/changelog",
{
"changelogFile": "docs/UserGuide/Changelog/Changelog.md",
"changelogTitle": "UK Controller Plugin Changelog"
"changelogTitle": "# UK Controller Plugin Changelog"
}
],
[
Expand All @@ -70,6 +70,12 @@
}
]
}
],
[
"@semantic-release/git",
{
"assets": ["docs/UserGuide/Changelog/Changelog.md"]
}
]
]
}
Expand Down

0 comments on commit d9f7851

Please sign in to comment.