|
| 1 | +name: Automated Workflow |
| 2 | +"on": |
| 3 | + push: |
| 4 | + branches: |
| 5 | + - master |
| 6 | +jobs: |
| 7 | + about: |
| 8 | + runs-on: ubuntu-latest |
| 9 | + steps: |
| 10 | + - name: Checkout |
| 11 | + uses: actions/checkout@v2 |
| 12 | + - name: Jaid/action-sync-node-meta |
| 13 | + |
| 14 | + with: |
| 15 | + direction: overwrite-github |
| 16 | + githubToken: "${{ secrets.GITHUB }}" |
| 17 | + release: |
| 18 | + runs-on: ubuntu-latest |
| 19 | + steps: |
| 20 | + - name: Checkout |
| 21 | + uses: actions/checkout@v2 |
| 22 | + - name: Semantic Release |
| 23 | + uses: cycjimmy/semantic-release-action@v2 |
| 24 | + id: semantic |
| 25 | + with: |
| 26 | + extra_plugins: | |
| 27 | + @semantic-release/changelog |
| 28 | + @semantic-release/npm |
| 29 | + @semantic-release/git |
| 30 | + @semantic-release/github |
| 31 | + env: |
| 32 | + GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" |
| 33 | + NPM_TOKEN: "${{ secrets.NPM_TOKEN }}" |
| 34 | + outputs: |
| 35 | + new_release_published: "${{ steps.semantic.outputs.new_release_published }}" |
| 36 | + new_release_version: "${{ steps.semantic.outputs.new_release_version }}" |
| 37 | + cdn: |
| 38 | + runs-on: ubuntu-latest |
| 39 | + needs: release |
| 40 | + if: needs.release.outputs.new_release_published == 'true' |
| 41 | + env: |
| 42 | + VERSION: "${{ needs.release.outputs.new_release_version }}" |
| 43 | + steps: |
| 44 | + - name: Checkout |
| 45 | + uses: actions/checkout@v2 |
| 46 | + - name: setup nodejs |
| 47 | + uses: actions/setup-node@v2 |
| 48 | + with: |
| 49 | + node-version: 14.15.4 |
| 50 | + - name: yarn install |
| 51 | + run: > |
| 52 | + echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > |
| 53 | + .npmrc |
| 54 | +
|
| 55 | + yarn install |
| 56 | + - name: yarn build |
| 57 | + run: yarn build |
| 58 | + - name: upload bundle as version |
| 59 | + uses: CoCreate-app/CoCreate-s3@master |
| 60 | + with: |
| 61 | + aws-key-id: "${{ secrets.AWSACCESSKEYID }}" |
| 62 | + aws-access-key: "${{ secrets.AWSSECERTACCESSKEY }}" |
| 63 | + bucket: testcrudbucket |
| 64 | + source: ./dist |
| 65 | + destination: "/kanban/${{env.VERSION}}" |
| 66 | + acl: public-read |
| 67 | + - name: upload bundle as latest |
| 68 | + uses: CoCreate-app/CoCreate-s3@master |
| 69 | + with: |
| 70 | + aws-key-id: "${{ secrets.AWSACCESSKEYID }}" |
| 71 | + aws-access-key: "${{ secrets.AWSSECERTACCESSKEY }}" |
| 72 | + bucket: testcrudbucket |
| 73 | + source: ./dist |
| 74 | + destination: /kanban/latest |
| 75 | + acl: public-read |
| 76 | + invalidations: true |
| 77 | + docs: |
| 78 | + runs-on: ubuntu-latest |
| 79 | + steps: |
| 80 | + - name: Checkout |
| 81 | + uses: actions/checkout@v2 |
| 82 | + |
| 83 | + - name: update documentation |
| 84 | + uses: CoCreate-app/CoCreate-docs@master |
0 commit comments