Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6af944ba3f | ||
|
|
d082fc0eab |
@@ -32,8 +32,18 @@ jobs:
|
|||||||
git config --local user.name "Stevan Freeborn"
|
git config --local user.name "Stevan Freeborn"
|
||||||
- name: Run versionize
|
- name: Run versionize
|
||||||
id: versionize
|
id: versionize
|
||||||
run: versionize -i --exit-insignificant-commits --workingDir ./src/BGR.Console --commit-suffix "[skip ci]"
|
run: |
|
||||||
|
VERSION=$(versionize -i --exit-insignificant-commits --workingDir ./src/BGR.Console --commit-suffix "[skip ci]")
|
||||||
|
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
|
- name: Ensure csproj version is updated
|
||||||
|
if: steps.versionize.outcome == 'success'
|
||||||
|
run: |
|
||||||
|
VERSION="${{ steps.versionize.outputs.version }}"
|
||||||
|
NUMERIC="${VERSION#v}"
|
||||||
|
sed -i "s|<Version>.*</Version>|<Version>${NUMERIC}</Version>|" src/BGR.Console/BGR.Console.csproj
|
||||||
|
git add src/BGR.Console/BGR.Console.csproj
|
||||||
|
git diff --cached --quiet || git commit --amend --no-edit
|
||||||
- name: Upload changelog
|
- name: Upload changelog
|
||||||
if: steps.versionize.outcome == 'success'
|
if: steps.versionize.outcome == 'success'
|
||||||
uses: actions/upload-artifact@v7
|
uses: actions/upload-artifact@v7
|
||||||
@@ -49,6 +59,7 @@ jobs:
|
|||||||
tags: true
|
tags: true
|
||||||
outputs:
|
outputs:
|
||||||
is_new_version: ${{ steps.versionize.outcome == 'success' }}
|
is_new_version: ${{ steps.versionize.outcome == 'success' }}
|
||||||
|
version: ${{ steps.versionize.outputs.version }}
|
||||||
publish:
|
publish:
|
||||||
needs: [version]
|
needs: [version]
|
||||||
if: needs.version.outputs.is_new_version == 'true'
|
if: needs.version.outputs.is_new_version == 'true'
|
||||||
@@ -78,11 +89,6 @@ jobs:
|
|||||||
run: dotnet publish src/BGR.Console/BGR.Console.csproj -c Release -r win-x64 --self-contained -o dist/windows-os
|
run: dotnet publish src/BGR.Console/BGR.Console.csproj -c Release -r win-x64 --self-contained -o dist/windows-os
|
||||||
- name: Create zip for windows-os
|
- name: Create zip for windows-os
|
||||||
run: zip -j dist/bgr_windows_x64.zip dist/windows-os/*
|
run: zip -j dist/bgr_windows_x64.zip dist/windows-os/*
|
||||||
- name: Get project version
|
|
||||||
uses: kzrnm/get-net-sdk-project-versions-action@v1
|
|
||||||
id: get-version
|
|
||||||
with:
|
|
||||||
proj-path: src/BGR.Console/BGR.Console.csproj
|
|
||||||
- name: Download changlog
|
- name: Download changlog
|
||||||
uses: actions/download-artifact@v8
|
uses: actions/download-artifact@v8
|
||||||
with:
|
with:
|
||||||
@@ -92,8 +98,8 @@ jobs:
|
|||||||
uses: softprops/action-gh-release@v3
|
uses: softprops/action-gh-release@v3
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.ACTIONS_PAT }}
|
token: ${{ secrets.ACTIONS_PAT }}
|
||||||
name: bgr v${{ steps.get-version.outputs.version }}
|
name: bgr ${{ needs.version.outputs.version }}
|
||||||
tag_name: v${{ steps.get-version.outputs.version }}
|
tag_name: ${{ needs.version.outputs.version }}
|
||||||
draft: false
|
draft: false
|
||||||
body_path: src/BGR.Console/CHANGELOG.md
|
body_path: src/BGR.Console/CHANGELOG.md
|
||||||
files: |
|
files: |
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
{
|
{
|
||||||
"sdk": {
|
"sdk": {
|
||||||
|
"version": "10.0.301",
|
||||||
"rollForward": "latestFeature"
|
"rollForward": "latestFeature"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<AssemblyTitle>BGR.Console</AssemblyTitle>
|
<AssemblyTitle>BGR.Console</AssemblyTitle>
|
||||||
<Product>BGR.Console</Product>
|
<Product>BGR.Console</Product>
|
||||||
<Description>A command-line app for removing backgrounds from images.</Description>
|
<Description>A command-line app for removing backgrounds from images.</Description>
|
||||||
<Version>0.0.0</Version>
|
<Version>0.1.0</Version>
|
||||||
<Authors>Stevan Freeborn</Authors>
|
<Authors>Stevan Freeborn</Authors>
|
||||||
<PublishSingleFile>true</PublishSingleFile>
|
<PublishSingleFile>true</PublishSingleFile>
|
||||||
<SelfContained>true</SelfContained>
|
<SelfContained>true</SelfContained>
|
||||||
|
|||||||
Reference in New Issue
Block a user