File tree Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Release squid
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*'
7+
8+ jobs :
9+ build_and_publish :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - name : Checkout
13+ uses : actions/checkout@v4
14+
15+ - name : Install Node.js
16+ uses : actions/setup-node@v4
17+ with :
18+ node-version : 20
19+
20+ - name : Install squid CLI
21+ run : npm i -g @subsquid/cli
22+
23+ - name : npm install
24+ run : npm i
25+
26+ - name : update squid.yml
27+ run : |
28+ # Get the tag from GitHub
29+ TAG=$(echo ${{ github.ref }} | sed 's/refs\/tags\///')
30+
31+ # Extract the numeric part of the tag
32+ VERSION=$(echo $TAG | sed 's/v//')
33+
34+ # Update the version in squid.yaml
35+ sed -i "s/^version: .*/version: $VERSION/" squid.yaml
36+
37+ # Optional: Print the updated version for verification
38+ echo "Updated squid.yaml version to: $VERSION"
39+
40+ - name : Build and deploy squid
41+ run : squid build && squid deploy .
You can’t perform that action at this time.
0 commit comments