Skip to content

Commit

Permalink
Adding GitHub action to build and publish all feature branches to dev…
Browse files Browse the repository at this point in the history
… extension
  • Loading branch information
Robthreefold committed Apr 13, 2024
1 parent a257418 commit 583cb92
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 4 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/publish-dev.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Example workflow using Snyk
on:
push:
branches-ignore: main

env:
PUBLISHER_ID: ${{ secrets.PUBLISHER_ID }}
AZURE_TOKEN: ${{ secrets.AZURE_TOKEN }}

jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
name: Extract Version number
- id: set_version
run: |
content=`cat ./vss-extension-dev.json`
content="${content//'%'/'%25'}"
content="${content//$'\n'/'%0A'}"
content="${content//$'\r'/'%0D'}"
echo "::set-output name=vssextensiondevjson::$content"
name: Publish Visual Studio extension
- run : |
npm install -g tfx-cli
npx tfx extension create --output-path --manifest-globs vss-extension-dev.json
npx tfx extension publish --auth-type pat -t $AZURE_TOKEN --publisher $PUBLISHER_ID --vsix ./SnykProfessionalServices.snyk-artifactory-upload-dev-${{fromJson(steps.set_version.outputs.vssextensiondevjson).version}}.vsix
3 changes: 1 addition & 2 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ env:
AZURE_TOKEN: ${{ secrets.AZURE_TOKEN }}

jobs:
develop:

publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules
.dccache
*.vsix
2 changes: 0 additions & 2 deletions task/.gitignore

This file was deleted.

0 comments on commit 583cb92

Please sign in to comment.