From fac86f0095a3a3ae721e75e89096d2110783ac69 Mon Sep 17 00:00:00 2001 From: Niloofar Date: Wed, 14 Feb 2024 14:11:16 +0800 Subject: [PATCH] fix: version issue --- .github/workflows/release.yaml | 6 +++++- package.json | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 6a41c4947d..475569cc69 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -46,7 +46,11 @@ jobs: - name: Extract Version id: extract_version run: | - version="red" + version=$(cat package.json \ + | grep version \ + | head -1 \ + | awk -F: '{ print $2 }' \ + | sed 's/[",]//g') echo "RELEASE_VERSION=${version}" >> "$GITHUB_OUTPUT" - name: Trigger Quill Icons Park release if: success() diff --git a/package.json b/package.json index e03ce566a0..9879a962d9 100644 --- a/package.json +++ b/package.json @@ -84,7 +84,7 @@ "allIconsNames": "cd ./src/react && tree -J > allIconsNames.ts && bash -c 'echo -e \"export const allIconsNames = $(cat allIconsNames.ts)\" > allIconsNames.ts'", "prepare": "husky install", "prepublish": "npm run build", - "app:version": "echo RELEASE_VERSION=$npm_package_version" + "app:version": "echo $npm_package_version" }, "keywords": [], "devDependencies": {