Remove npm-packages workflow, adjust branch triggers in workflows
The npm-packages.yml workflow has been removed. The branch triggers in the workflows npm-packages.yml, packages.yml, and all-in-one-web.yml have been changed from 'v3' to 'main'. An unnecessary reference to the deleted workflow file npm-packages.yml is also removed from Elsa.sln.
This commit is contained in:
parent
6b25231218
commit
006db97a66
2
.github/workflows/all-in-one-web.yml
vendored
2
.github/workflows/all-in-one-web.yml
vendored
|
|
@ -3,7 +3,7 @@ on:
|
|||
workflow_dispatch:
|
||||
push:
|
||||
branches:
|
||||
- v3
|
||||
- main
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
|
|
|
|||
136
.github/workflows/npm-packages.yml
vendored
136
.github/workflows/npm-packages.yml
vendored
|
|
@ -1,136 +0,0 @@
|
|||
name: Elsa 3 Workflow Designer
|
||||
on:
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches:
|
||||
- v3
|
||||
paths:
|
||||
- src/designer/**
|
||||
- .github/**
|
||||
pull_request:
|
||||
branches:
|
||||
- v3
|
||||
paths:
|
||||
- src/designer/elsa-workflows-designer/**
|
||||
- .github/**
|
||||
release:
|
||||
types: [ prereleased ]
|
||||
env:
|
||||
NODE_OPTIONS: --max-old-space-size=8096
|
||||
ELSA_VERSION: 3.0.3
|
||||
|
||||
jobs:
|
||||
build_and_pack:
|
||||
name: Build workflow designer package
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
|
||||
- name: Set preview VERSION variable
|
||||
run: echo "VERSION=$ELSA_VERSION-preview.${{ github.run_number }}" >> $GITHUB_ENV
|
||||
if: ${{ github.event_name != 'release' || github.event_name == 'prereleased' }}
|
||||
|
||||
- name: Set release VERSION variable
|
||||
run: echo "VERSION=${{ github.ref_name }}" >> $GITHUB_ENV
|
||||
if: ${{ github.event_name == 'release' }}
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Setup Node
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 18.12.1
|
||||
cache: 'npm'
|
||||
cache-dependency-path: '**/package-lock.json'
|
||||
|
||||
- run: echo $VERSION
|
||||
- run: node --version
|
||||
- run: npm --version
|
||||
|
||||
- name: Build Designer
|
||||
working-directory: ./src/designer/designer_packages/elsa-workflows-designer
|
||||
run: |
|
||||
npm install --force
|
||||
npm version $VERSION --allow-same-version
|
||||
npm run build
|
||||
if: ${{ github.event_name == 'release' || github.event_name == 'push'}}
|
||||
- name: Pack Designer
|
||||
working-directory: ./src/designer/designer_packages/elsa-workflows-designer
|
||||
run: npm pack
|
||||
if: ${{ github.event_name == 'release' || github.event_name == 'push'}}
|
||||
|
||||
- name: Upload Designer Artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: designer-npm-package
|
||||
path: src/designer/designer_packages/elsa-workflows-designer/elsa-*.tgz
|
||||
if: ${{ github.event_name == 'release' || github.event_name == 'push'}}
|
||||
|
||||
publish_npm_preview:
|
||||
name: Publish preview package to feedz
|
||||
needs: build_and_pack
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ github.event_name == 'release' || github.event_name == 'push'}}
|
||||
steps:
|
||||
- name: Download NPM Package
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: designer-npm-package
|
||||
path: designer-package
|
||||
|
||||
- uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 18.12.1
|
||||
registry-url: 'https://f.feedz.io/elsa-workflows/elsa-3/npm/'
|
||||
|
||||
- run: npm publish ./designer-package/*.tgz
|
||||
env:
|
||||
NODE_AUTH_TOKEN: ${{ secrets.FEEDZ_IO_NPM }}
|
||||
|
||||
publish_npm_release:
|
||||
name: Publish release package to npmjs
|
||||
needs: build_and_pack
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ github.event_name == 'release' || github.event_name == 'prereleased' }}
|
||||
steps:
|
||||
- name: Download NPM Package
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: designer-npm-package
|
||||
|
||||
- uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 18.12.1
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
|
||||
- run: npm publish *.tgz
|
||||
env:
|
||||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||
|
||||
update_package_json_version:
|
||||
name: Update Version in Elsa.Workflows.Designer backend module
|
||||
needs: publish_npm_preview
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ github.ref == 'refs/heads/v3' }}
|
||||
steps:
|
||||
- name: Install jq
|
||||
run: sudo apt-get install jq
|
||||
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
token: ${{ secrets.ELSA_CORE_PAT }}
|
||||
|
||||
- name: Update designer version in package.json
|
||||
run: |
|
||||
cd src/modules/Elsa.Workflows.Designer
|
||||
jq '.devDependencies["@elsa-workflows/elsa-workflows-designer"] = $newVersion' --arg newVersion $ELSA_VERSION-preview.${{ github.run_number }} package.json > package.json.tmp
|
||||
mv package.json.tmp package.json
|
||||
git fetch --all
|
||||
git config user.name "GitHub Action"
|
||||
git checkout v3
|
||||
git add package.json
|
||||
git commit -m "Updated designer version to $ELSA_VERSION-preview.${{ github.run_number }}"
|
||||
git push origin v3
|
||||
18
.github/workflows/packages.yml
vendored
18
.github/workflows/packages.yml
vendored
|
|
@ -1,17 +1,17 @@
|
|||
name: Elsa 3 Prerelease
|
||||
name: Elsa 3 Packages
|
||||
on:
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches:
|
||||
- v3
|
||||
- main
|
||||
tags:
|
||||
- preview-*hotfix-* # e.g. preview-1.0.0-hotfix-1
|
||||
- hotfix-* # e.g. 3.0.0-hotfix-1
|
||||
release:
|
||||
types: [ prereleased ]
|
||||
types: [ prereleased, released ]
|
||||
env:
|
||||
feedz_feed_source: 'https://f.feedz.io/elsa-workflows/elsa-3/nuget/index.json'
|
||||
nuget_feed_source: 'https://api.nuget.org/v3/index.json'
|
||||
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build packages
|
||||
|
|
@ -20,12 +20,12 @@ jobs:
|
|||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
- name: Verify commit exists in origin/v3
|
||||
- name: Verify commit exists in origin/main
|
||||
run: |
|
||||
git fetch --no-tags --prune --depth=1 origin +refs/heads/*:refs/remotes/origin/*
|
||||
git branch --remote --contains | grep origin/v3
|
||||
git branch --remote --contains | grep origin/main
|
||||
- name: Set VERSION variable
|
||||
run: |
|
||||
run: |
|
||||
if [[ "${{ github.ref }}" == refs/tags/* ]]; then
|
||||
TAG_NAME=${{ github.ref }} # e.g., refs/tags/preview-740-hotfix-1
|
||||
TAG_NAME=${TAG_NAME#refs/tags/} # remove the refs/tags/ prefix
|
||||
|
|
@ -45,7 +45,7 @@ jobs:
|
|||
name: elsa-nuget-packages
|
||||
path: packages/*nupkg
|
||||
if: ${{ github.event_name == 'release' || github.event_name == 'push'}}
|
||||
|
||||
|
||||
publish_preview_feedz:
|
||||
name: Publish to feedz.io
|
||||
needs: build
|
||||
|
|
|
|||
1
Elsa.sln
1
Elsa.sln
|
|
@ -18,7 +18,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "solution", "solution", "{7D
|
|||
configureawait.props = configureawait.props
|
||||
docker-compose.yml = docker-compose.yml
|
||||
icon.png = icon.png
|
||||
.github\workflows\npm-packages.yml = .github\workflows\npm-packages.yml
|
||||
NuGet.Config = NuGet.Config
|
||||
packages.props = packages.props
|
||||
.github\workflows\packages.yml = .github\workflows\packages.yml
|
||||
|
|
|
|||
Loading…
Reference in a new issue