From dcb9cd67d0371efe0e0d4793f80aef23c356fd70 Mon Sep 17 00:00:00 2001 From: Julian Lechner Date: Mon, 7 Jul 2025 14:56:04 +0200 Subject: [PATCH] Create npm-publish-github-packages.yml --- .../workflows/npm-publish-github-packages.yml | 40 +++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/npm-publish-github-packages.yml diff --git a/.github/workflows/npm-publish-github-packages.yml b/.github/workflows/npm-publish-github-packages.yml new file mode 100644 index 0000000..cbde656 --- /dev/null +++ b/.github/workflows/npm-publish-github-packages.yml @@ -0,0 +1,40 @@ +name: Build Solution + +on: + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Repository auschecken + uses: actions/checkout@v4 + + - name: Node.js v22.16.0 einrichten + uses: actions/setup-node@v4 + with: + node-version: '22.16.0' + + - name: Abhängigkeiten installieren + run: npm install + + - name: Build ausführen + run: npm run buildProduction + + - name: Version aus package.json auslesen + id: get_version + run: | + version=$(node -p "require('./package.json').version") + echo "VERSION=$version" >> $GITHUB_ENV + + - name: dist-Ordner umbenennen + run: mv dist "${{ env.VERSION }}" + + - name: Version-Ordner zippen + run: zip -r "${{ env.VERSION }}.zip" "${{ env.VERSION }}" + + - name: Build-Artefakt hochladen + uses: actions/upload-artifact@v4 + with: + name: ${{ env.VERSION }} + path: ${{ env.VERSION }}.zip