Skip to content

docs: enhance docs #233

docs: enhance docs

docs: enhance docs #233

Workflow file for this run

name: CI
on:
push:
branches-ignore:
- "release-please*"
jobs:
release-please:
runs-on: ubuntu-latest
outputs:
release_created_sdk: ${{ steps.release.outputs['packages/sdk--release_created'] }}
release_created_sdk_react_provider: ${{ steps.release.outputs['packages/sdk-react-provider--release_created'] }}
release_created: ${{ steps.release.outputs.release_created }}
releases_created: ${{ steps.release.outputs.releases_created }}
pr_created: ${{ steps.release.outputs.prs_created }}
tag_name: ${{ steps.release.outputs.tag_name }}
sha: ${{ steps.release.outputs.sha }}
steps:
- uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.GITHUB_TOKEN }}
# target-branch: chore/my-please-release-testbranch
- name: echo values
run: |
echo "Release created SDK: ${{ steps.release.outputs['packages/sdk--release_created'] }}"
echo "Release created React Provider: ${{ steps.release.outputs['packages/sdk-react-provider--release_created'] }}"
echo "Releases created: ${{ steps.release.outputs.releases_created }}"
echo "PR created: ${{ steps.release.outputs.prs_created }}"
echo "Release tag_name: ${{ steps.release.outputs.tag_name }}"
echo "Release sha: ${{ steps.release.outputs.sha }}"
build:
env:
CI: "true"
needs: [release-please]
name: Build, Test, Lint and Publish
timeout-minutes: 15
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Cache PNPM install and Turbo
uses: ./.github/actions/cache-setup
- name: Build
run: pnpm build
- name: Commit and Push Documentation
if: github.ref == 'refs/heads/main'
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "[email protected]"
git add ./apps/developer/docs/packages/
if [ -n "$(git status --porcelain)" ]; then
git commit -m "docs: update generated documentation"
git push
else
echo "No changes to commit"
fi
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
if: github.ref == 'refs/heads/main'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./apps/developer/build
- name: Test
run: pnpm test
- name: Lint
run: pnpm lint
- name: Publish SDK
#run: pnpm --filter @monerium/sdk pub:pre
run: pnpm --filter @monerium/sdk publish --access public
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
if: ${{ needs.release-please.outputs.release_created_sdk }}
- name: Publish React Provider
# run: pnpm --filter @monerium/sdk-react-provider pub:pre
run: pnpm --filter @monerium/sdk-react-provider publish --access public
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
if: ${{ needs.release-please.outputs.release_created_sdk_react_provider }}