diff --git a/.github/workflows/publish-dev.yaml b/.github/workflows/publish-dev.yaml new file mode 100644 index 0000000..9097236 --- /dev/null +++ b/.github/workflows/publish-dev.yaml @@ -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 diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index ad593b2..30024e3 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -8,8 +8,7 @@ env: AZURE_TOKEN: ${{ secrets.AZURE_TOKEN }} jobs: - develop: - + publish: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a92ffe2 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +node_modules +.dccache +*.vsix \ No newline at end of file diff --git a/task/.gitignore b/task/.gitignore deleted file mode 100644 index 836c910..0000000 --- a/task/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -node_modules -.dccache \ No newline at end of file