From 4570c4b5f4e284d064907003adbfaf78a032b6ec Mon Sep 17 00:00:00 2001 From: defnotken Date: Tue, 26 Aug 2025 11:14:35 -0500 Subject: [PATCH] Testing out tag and release --- .../workflows/lightless-tag-and-release.yml | 40 +++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/lightless-tag-and-release.yml diff --git a/.github/workflows/lightless-tag-and-release.yml b/.github/workflows/lightless-tag-and-release.yml new file mode 100644 index 0000000..8acca0e --- /dev/null +++ b/.github/workflows/lightless-tag-and-release.yml @@ -0,0 +1,40 @@ +name: Tag and Release Lightless + +on: + push: + branches: [ master ] + +jobs: + tag-and-release: + runs-on: ubuntu-latest + + steps: + - name: checkout lightless + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: get version from lightless proj + id: get_version + run: | + VERSION=$(xmllint --xpath "string(//Version)" LightlessSync/LightlessSync.csproj) + echo "VERSION=$VERSION" >> $GITHUB_ENV + + - name: Create Git tag + run: | + git config user.name "GitHub Action" + git config user.email "action@github.com" + git tag "v${VERSION}" + git push origin "v${VERSION}" + env: + VERSION: ${{ env.VERSION }} + + - name: Create GitHub Release + uses: softprops/action-gh-release@v2 + with: + tag_name: v${{ env.VERSION }} + name: ${{ env.VERSION }} + draft: false + prerelease: false + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file