|
11 | 11 |
|
12 | 12 | steps: |
13 | 13 | - name: Checkout |
14 | | - uses: actions/checkout@v2 |
| 14 | + uses: actions/checkout@v4 |
15 | 15 |
|
16 | 16 | - name: Determine the elixir version |
17 | 17 | run: echo "ELIXIR_VERSION=$(grep -h elixir .tool-versions | awk '{ print $2 }' | awk -F - '{print $1}')" >> $GITHUB_ENV |
|
26 | 26 | otp-version: ${{ env.OTP_VERSION }} |
27 | 27 |
|
28 | 28 | - name: Restore the deps cache |
29 | | - uses: actions/cache@v1 |
| 29 | + uses: actions/cache@v4 |
30 | 30 | id: deps-cache |
31 | 31 | with: |
32 | 32 | path: deps |
|
35 | 35 | ${{ runner.os }}-${{ env.ELIXIR_VERSION }}-${{ env.OTP_VERSION }}-${{ env.MIX_ENV }}-deps- |
36 | 36 |
|
37 | 37 | - name: Restore the _build cache |
38 | | - uses: actions/cache@v1 |
| 38 | + uses: actions/cache@v4 |
39 | 39 | id: build-cache |
40 | 40 | with: |
41 | 41 | path: _build |
@@ -71,10 +71,12 @@ jobs: |
71 | 71 | MIX_ENV: dev |
72 | 72 | needs: |
73 | 73 | - bless |
| 74 | + permissions: |
| 75 | + contents: write |
74 | 76 |
|
75 | 77 | steps: |
76 | 78 | - name: Checkout |
77 | | - uses: actions/checkout@v2 |
| 79 | + uses: actions/checkout@v4 |
78 | 80 |
|
79 | 81 | - name: Determine the elixir version |
80 | 82 | run: echo "ELIXIR_VERSION=$(grep -h elixir .tool-versions | awk '{ print $2 }' | awk -F - '{print $1}')" >> $GITHUB_ENV |
|
89 | 91 | otp-version: ${{ env.OTP_VERSION }} |
90 | 92 |
|
91 | 93 | - name: Restore the deps cache |
92 | | - uses: actions/cache@v1 |
| 94 | + uses: actions/cache@v4 |
93 | 95 | id: deps-cache |
94 | 96 | with: |
95 | 97 | path: deps |
|
98 | 100 | ${{ runner.os }}-${{ env.ELIXIR_VERSION }}-${{ env.OTP_VERSION }}-${{ env.MIX_ENV }}-deps- |
99 | 101 |
|
100 | 102 | - name: Restore the _build cache |
101 | | - uses: actions/cache@v1 |
| 103 | + uses: actions/cache@v4 |
102 | 104 | id: build-cache |
103 | 105 | with: |
104 | 106 | path: _build |
@@ -133,28 +135,14 @@ jobs: |
133 | 135 |
|
134 | 136 | - name: Create a GitHub Release |
135 | 137 | id: create_release |
136 | | - uses: NFIBrokerage/create-release@v2 |
| 138 | + uses: elgohr/Github-Release-Action@v5 |
137 | 139 | env: |
138 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 140 | + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
139 | 141 | with: |
140 | | - tag_name: ${{ env.TAG }} |
141 | | - release_name: Release ${{ env.TAG }} |
142 | | - draft: false |
| 142 | + title: Release ${{ env.TAG }} |
143 | 143 | prerelease: false |
144 | 144 |
|
145 | 145 | - name: Publish library |
146 | 146 | run: mix hex.publish --yes |
147 | 147 | env: |
148 | 148 | HEX_API_KEY: ${{ secrets.HEX_PUBLISH_KEY }} |
149 | | - |
150 | | - - name: Notify ops channel of build success |
151 | | - run: > |
152 | | - curl |
153 | | - -X POST |
154 | | - -H 'Content-type:application/json' |
155 | | - -d "{\"text\":\":hexpm: package published for $REPOSITORY $(git tag -ln $TAG)\"}" |
156 | | - $SLACK_WEBHOOK |
157 | | - env: |
158 | | - SLACK_WEBHOOK: ${{ secrets.OPS_CHANNEL_SLACK_WEBHOOK }} |
159 | | - |
160 | | -# Generated by Elixir.Gaas.Generators.Simple.Actions.LibraryCi |
0 commit comments