Skip to content
Permalink
Browse files
Check for pre- or -pre in tag. Add GIT_ID to extension name for night…
…ly build (#109)
  • Loading branch information
Shanedell committed Aug 27, 2021
1 parent bada450 commit 72a91fbad3e8eabefbdbdc6ed37a7a37167f3a39
Showing 3 changed files with 21 additions and 6 deletions.
@@ -22,10 +22,16 @@ jobs:
- name: Check formatting
run: |
yarn run prettier src -c
- name: Get filename
run: |
GIT_ID=$(git describe)
VSIX_FILE="daffodil-debugger-${GIT_ID}.vsix"
echo "VSIX_FILE=${VSIX_FILE}" >> $GITHUB_ENV
- name: Create vsix
run: |
yarn run package -o extension-nightly.vsix
yarn run package -o ${{env.VSIX_FILE}}
- name: Deploy release
uses: WebFreak001/deploy-nightly@v1.1.0
@@ -34,7 +40,7 @@ jobs:
with:
upload_url: https://uploads.github.com/repos/jw3/example-daffodil-vscode/releases/45167120/assets{?name,label}
release_id: 45167120
asset_path: ${{github.workspace}}/extension-nightly.vsix
asset_name: daffodil-debugger-nightly.vsix
asset_path: ${{github.workspace}}/${{env.VSIX_FILE}}
asset_name: ${{env.VSIX_FILE}}
asset_content_type: vsix
max_releases: 1
max_releases: 5
@@ -22,6 +22,15 @@ jobs:
- name: Check if git tag matches package version
run: if [[ ${{env.GIT_TAG}} != ${{env.LIB_VERSION}} ]]; then exit 1; else exit 0; fi
shell: bash

- name: Check if pre-release
run: |
if [[ ${{env.GIT_TAG}} == *"pre-"* || ${{env.GIT_TAG}} == *"-pre"* ]]; then
echo "PRE_RELEASE=true" >> $GITHUB_ENV
else
echo "PRE_RELEASE=false" >> $GITHUB_ENV
fi
shell: bash

- name: Create backend package
run: |
@@ -50,7 +59,7 @@ jobs:
uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: false
prerelease: "${{ env.PRE_RELEASE }}"
files: |
${{github.workspace}}/daffodil-debugger-${{env.GIT_TAG}}.vsix
${{github.workspace}}/server/core/target/universal/daffodil-debugger-*.zip
@@ -1,7 +1,7 @@
{
"name": "daffodil-debugger",
"displayName": "Daffodil Debugger",
"version": "0.0.14",
"version": "0.0.14-pre1",
"publisher": "jw3",
"description": "Daffodil Schema Debugger: debug DFDL schema files using Apache Daffodil.",
"license": "Apache-2.0",

0 comments on commit 72a91fb

Please sign in to comment.