|
1 | | -# This workflow will run on merge of a PR or push to master |
2 | | -# It will run the integration developement checklist and if that passes |
3 | | -# creates a new release with the Release and Tag name both being the |
4 | | -# package.json version and will with a created tgz file and the SHA256 has in the release body |
5 | | - |
6 | | - |
7 | 1 | name: Release Current Version |
8 | 2 |
|
9 | 3 | on: |
10 | 4 | push: |
11 | | - branches: [ master ] |
| 5 | + branches: [ master, main ] |
12 | 6 |
|
13 | 7 | jobs: |
14 | | - release-current-version: |
15 | | - runs-on: ubuntu-latest |
16 | | - container: 'centos:7' |
17 | | - |
18 | | - steps: |
19 | | - - uses: actions/checkout@v2 |
20 | | - - uses: actions/setup-node@v1 |
21 | | - - name: Get NPM Version |
22 | | - id: package-version |
23 | | - uses: martinbeentjes/npm-get-version-action@95bc31c6dd3145896c110e382f840bb1e750d09c |
24 | | - - name: Create Build |
25 | | - id: create_build |
26 | | - run: | |
27 | | - npm install && |
28 | | - cd .. && |
29 | | - tar --exclude="./${{ github.event.repository.name }}/.git" --exclude="./${{ github.event.repository.name }}/.gitignore" --exclude="./${{ github.event.repository.name }}/package-lock.json" --exclude="./${{ github.event.repository.name }}/.github" -czvf "${{ github.event.repository.name }}-${{ steps.package-version.outputs.current-version }}.tgz" "./${{ github.event.repository.name }}" && |
30 | | - echo "::set-output name=build_hash::$(sha256sum '${{ github.event.repository.name }}-${{ steps.package-version.outputs.current-version }}.tgz' | grep -oE '^[^ ]*' )" && |
31 | | - cd ${{ github.event.repository.name }} |
32 | | - - name: Polarity Integration Development Checklist |
33 | | - id: int-dev-checklist |
34 | | - uses: polarityio/polarity-integration-development-checklist@v1.0.0 |
35 | | - with: |
36 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
37 | | - - name: Create Versioned Release |
38 | | - id: create_versioned_release |
39 | | - uses: actions/create-release@v1 |
40 | | - env: |
41 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
42 | | - with: |
43 | | - tag_name: ${{ steps.package-version.outputs.current-version}} |
44 | | - release_name: ${{ steps.package-version.outputs.current-version}} |
45 | | - body: | |
46 | | - SHA256: ${{ steps.create_build.outputs.build_hash }} |
47 | | - draft: false |
48 | | - prerelease: false |
49 | | - - name: Upload Release Asset |
50 | | - id: upload-release-asset |
51 | | - uses: actions/upload-release-asset@v1 |
52 | | - env: |
53 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
54 | | - with: |
55 | | - upload_url: ${{ steps.create_versioned_release.outputs.upload_url }} |
56 | | - asset_path: ../${{ github.event.repository.name }}-${{ steps.package-version.outputs.current-version}}.tgz |
57 | | - asset_name: ${{ github.event.repository.name }}-${{ steps.package-version.outputs.current-version}}.tgz |
58 | | - asset_content_type: application/gzip |
| 8 | + Run: |
| 9 | + uses: polarityio/polarity-github-actions/.github/workflows/release-server-versions-for-int-store.yml@master |
| 10 | + # with: |
| 11 | + # use-integration-development-checklist: false |
0 commit comments