Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

Commit d9d4256

Browse files
authored
fix: cortex version on windows (#761)
1 parent 6c98e04 commit d9d4256

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

.github/workflows/cortex-build.yml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -182,17 +182,16 @@ jobs:
182182
with:
183183
submodules: recursive
184184

185+
- name: Install jq
186+
uses: dcarbone/install-jq-action@v2.0.1
187+
185188
- name: "Update version by tag"
189+
shell: bash
186190
run: |
187-
cd cortex-js
188-
# Remove the v prefix
189-
tag_version=${GITHUB_REF#refs/tags/v}
190-
191-
# Replace the old version with the new version in package.json
192-
jq --arg version "$tag_version" '.version = $version' ./package.json > /tmp/package.json && mv /tmp/package.json ./package.json
193-
194-
# Print the new version
195-
echo "Updated package.json version to: $tag_version"
191+
echo "Version: ${{ inputs.new_version }}"
192+
# Update the version in package.json
193+
jq --arg version "${{ inputs.new_version }}" '.version = $version' package.json > /tmp/package.json
194+
mv /tmp/package.json package.json
196195
197196
- uses: actions/setup-dotnet@v3
198197
if: runner.os == 'Windows'

0 commit comments

Comments
 (0)