Skip to content

Commit 0ebc217

Browse files
MuntasirSZNAntoineGS
authored andcommitted
feat(ci): make version updates automatic in util.lua
1 parent 1f87b56 commit 0ebc217

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.github/workflows/update-copilot-nodejs.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ jobs:
2121
- name: Download latest LSP
2222
run: |
2323
curl -s https://api.github.com/repos/github/copilot-language-server-release/releases/latest | grep "browser_download_url.*copilot-language-server-js-.*zip" | cut -d : -f 2,3 | tr -d \" | wget -vi -
24+
export COPILOT_LATEST_RELEASE_VER=$(curl -s https://api.github.com/repos/github/copilot-language-server-release/releases | jq -r '.[0].tag_name')
25+
sed -i.bak -E "s/(version = \")[^\"]+(\",)/\1$COPILOT_LATEST_RELEASE_VER\2/" "lua/copilot/util.lua"
26+
rm lua/copilot/util.lua.bak
2427
2528
- name: Unzip LSP
2629
run: |

0 commit comments

Comments
 (0)