mirror of
https://github.com/fluencelabs/fluence-js.git
synced 2025-04-25 09:52:12 +00:00
Use summary to print versions (#196)
This commit is contained in:
parent
3ef88d9905
commit
bc276f0ec7
34
.github/workflows/snapshot.yml
vendored
34
.github/workflows/snapshot.yml
vendored
@ -71,8 +71,8 @@ jobs:
|
|||||||
id: version
|
id: version
|
||||||
run: |
|
run: |
|
||||||
SHA=${{ github.event.pull_request.head.sha }}
|
SHA=${{ github.event.pull_request.head.sha }}
|
||||||
echo "::set-output name=sha::${SHA::7}"
|
echo "sha=${SHA::7}" >> $GITHUB_OUTPUT
|
||||||
echo "::set-output name=branch::${GITHUB_HEAD_REF//[^a-zA-Z0-9-]/-}"
|
echo "branch=${GITHUB_HEAD_REF//[^a-zA-Z0-9-]/-}" >> $GITHUB_OUTPUT
|
||||||
|
|
||||||
- name: Set package version
|
- name: Set package version
|
||||||
id: build
|
id: build
|
||||||
@ -83,31 +83,19 @@ jobs:
|
|||||||
ATTEMPT: ${{ github.run_attempt }}
|
ATTEMPT: ${{ github.run_attempt }}
|
||||||
run: |
|
run: |
|
||||||
node ci.js bump-version ${{ env.BRANCH }}-${{ env.SHA }}-${{ env.RUN }}-${{ env.ATTEMPT }}
|
node ci.js bump-version ${{ env.BRANCH }}-${{ env.SHA }}-${{ env.RUN }}-${{ env.ATTEMPT }}
|
||||||
echo "::set-output name=version::$(node ci.js get-version)"
|
echo "version=$(node ci.js get-version)" >> $GITHUB_OUTPUT
|
||||||
|
|
||||||
- name: Publish to self-hosted npm repo
|
- name: Publish to self-hosted npm repo
|
||||||
run: pnpm --no-git-checks --registry https://npm.fluence.dev -r publish --tag e2e -filter '@fluencelabs/*'
|
run: pnpm --no-git-checks --registry https://npm.fluence.dev -r publish --tag e2e -filter '@fluencelabs/*'
|
||||||
|
|
||||||
- name: Find comment in PR
|
- name: Print versions to check summary
|
||||||
uses: peter-evans/find-comment@v1
|
|
||||||
id: comment
|
|
||||||
with:
|
|
||||||
issue-number: "${{ github.event.pull_request.number }}"
|
|
||||||
comment-author: github-actions[bot]
|
|
||||||
body-includes: "## FluenceJS version is"
|
|
||||||
|
|
||||||
- name: Update comment in PR
|
|
||||||
uses: peter-evans/create-or-update-comment@v1
|
|
||||||
env:
|
env:
|
||||||
FLUENCE_JS_VERSION: ${{ steps.build.outputs.version }}
|
VERSION: ${{ steps.build.outputs.version }}
|
||||||
with:
|
run: |
|
||||||
comment-id: "${{ steps.comment.outputs.comment-id }}"
|
cat <<'SNAPSHOT' >> $GITHUB_STEP_SUMMARY
|
||||||
issue-number: "${{ github.event.pull_request.number }}"
|
## FluenceJS version is [${{ env.VERSION }}](https://npm.fluence.dev/-/web/detail/@fluencelabs/fluence/v/${{ env.VERSION }})
|
||||||
edit-mode: replace
|
To use it run:
|
||||||
body: |
|
|
||||||
## FluenceJS version is [${{ env.FLUENCE_JS_VERSION }}](https://npm.fluence.dev/-/web/detail/@fluencelabs/fluence/v/${{ env.FLUENCE_JS_VERSION }})
|
|
||||||
To install it run:
|
|
||||||
```shell
|
```shell
|
||||||
npm login --registry https://npm.fluence.dev
|
npm i -E @fluencelabs/fluence@${{ env.VERSION }} --registry=https://npm.fluence.dev
|
||||||
npm i -E @fluencelabs/fluence@${{ env.FLUENCE_JS_VERSION }} --registry=https://npm.fluence.dev
|
|
||||||
```
|
```
|
||||||
|
SNAPSHOT
|
||||||
|
Loading…
x
Reference in New Issue
Block a user