@@ -11,13 +11,16 @@ jobs:
11
11
name : Check if package version has been upgraded
12
12
runs-on : ubuntu-latest
13
13
outputs :
14
- version : ${{ steps.version-updated.outputs.current-package- version }}
15
- has_updated : ${{ steps.version-updated.outputs.has- updated }}
14
+ version : ${{ steps.version-updated.outputs.current-version }}
15
+ has_updated : ${{ steps.version-updated.outputs.current-version != steps.version- updated.outputs.previous-version }}
16
16
steps :
17
-
17
+ - uses : actions/checkout@v2
18
+ with :
19
+ fetch-depth : 2
20
+ - uses : salsify/action-detect-and-tag-new-version@v2
18
21
id : version-updated
19
- env :
20
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
22
+ with :
23
+ create-tag : false
21
24
publish-docs :
22
25
name : Publish Docs
23
26
runs-on : ubuntu-latest
@@ -33,11 +36,11 @@ jobs:
33
36
registry-url : " https://registry.npmjs.org"
34
37
- uses : pnpm/action-setup@v2
35
38
with :
36
- version : 8
39
+ version : 9
37
40
run_install : false
38
41
- uses : actions/checkout@v3
39
42
with :
40
- fetch-depth : 0
43
+ fetch-depth : 2
41
44
ref : ${{ github.ref }}
42
45
- name : Install and Build
43
46
run : |
@@ -92,13 +95,13 @@ jobs:
92
95
fi
93
96
git config user.name github-actions
94
97
git config user.email [email protected]
95
- echo //registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN} > .npmrc
96
98
EXTRA_ARGS=""
97
99
if [[ $VERSION == *"alpha."* ]] || [[ $VERSION == *"beta."* ]] || [[ $VERSION == *"rc."* ]]; then
98
100
echo "Is pre-release version"
99
101
EXTRA_ARGS="$EXTRA_ARGS --dist-tag next"
100
102
fi
101
- npx lerna publish ${VERSION} --yes --force-publish $EXTRA_ARGS
103
+ echo //registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN} > .npmrc
104
+ pnpm exec lerna publish ${VERSION} --yes --force-publish $EXTRA_ARGS
102
105
env :
103
106
VERSION : ${{ needs.check_if_version_upgraded.outputs.version }}
104
107
NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
0 commit comments