-
Notifications
You must be signed in to change notification settings - Fork 2
24 lines (22 loc) · 938 Bytes
/
update-readme.yml
File metadata and controls
24 lines (22 loc) · 938 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
name: Update Readme
on: [workflow_dispatch]
jobs:
update-readme:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: echo ::set-env name=RELEASE_VERSION::${GITHUB_REF#refs/tags/*}
- run: >
cat ./README.md
| sed
-e "s/https\:\/\/deno.land\/x\/functional\@[v0-9\.]*/https\:\/\/deno.land\/x\/functional\@${RELEASE_VERSION}/"
-e "s/https\:\/\/x.nest.land\/functional\@[v0-9\.]*/https\:\/\/x.nest.land\/functional\@${RELEASE_VERSION}/"
| tee ./README.md > /dev/null
&& echo $RELEASE_VERSION
&& git config --local user.email "action@github.com"
&& git config --local user.name "GitHub Action"
&& git add .
&& git commit --amend --no-edit
&& git push
https://${{ env.GITHUB_ACTOR }}:${{ secrets.GITHUB_TOKEN }}@github.com/sebastienfilion/functional.git
HEAD:master --force