From 12ce9bc97c63c2b075f3b51b92263d7d21298562 Mon Sep 17 00:00:00 2001 From: Xi Zhang Date: Thu, 12 Oct 2023 18:52:34 -0500 Subject: [PATCH 1/2] Add publish workflow --- .github/workflows/publish.yaml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .github/workflows/publish.yaml diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml new file mode 100644 index 00000000..91ae3067 --- /dev/null +++ b/.github/workflows/publish.yaml @@ -0,0 +1,26 @@ +name: publish + +on: + push: + tags: + - clients/js/[0-9].[0-9]+.[0-9]+ + - contracts/[0-9].[0-9]+.[0-9]+ + - integrations/hardhat/[0-9].[0-9]+.[0-9]+ + +jobs: + publish: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: "18" + - name: Extract package from tag + id: extract-tag + run: | + echo "NPM_PACKAGE=$(echo ${{ github.ref_name }} | grep -oE '(clients/js|contracts|integrations/hardhat)')" >> $GITHUB_OUTPUT + - name: Publish ${{ github.ref_name }} to NPM + uses: JS-DevTools/npm-publish@v2 + with: + token: ${{ secrets.NPM_TOKEN }} + package: ${{ steps.extract-tag.outputs.NPM_PACKAGE }} From 935c1217ec3bb60024dd81bbccbe78b22e45315f Mon Sep 17 00:00:00 2001 From: Xi Zhang Date: Fri, 13 Oct 2023 11:25:44 -0500 Subject: [PATCH 2/2] Update documentation --- .github/workflows/publish.yaml | 6 +++--- CONTRIBUTING.md | 4 ++-- README.md | 11 ++++++++++- 3 files changed, 15 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 91ae3067..34d9f5bc 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -3,9 +3,9 @@ name: publish on: push: tags: - - clients/js/[0-9].[0-9]+.[0-9]+ - - contracts/[0-9].[0-9]+.[0-9]+ - - integrations/hardhat/[0-9].[0-9]+.[0-9]+ + - clients/js/v[0-9].[0-9]+.[0-9]+ + - contracts/v[0-9].[0-9]+.[0-9]+ + - integrations/hardhat/v[0-9].[0-9]+.[0-9]+ jobs: publish: diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index fa79ada2..b9af0051 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -65,9 +65,9 @@ if the issue is not reported yet, [file a new one]. ## Development -### Building and Testing +### Building -Building and testing are documented in our +Building documentation lies at the top-level [README](https://github.com/oasisprotocol/sapphire-paratime/blob/main/README.md). ### Contributing Code diff --git a/README.md b/README.md index e2353afe..8d00f97c 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,15 @@ development environments - [`runtime`](./runtime/): the Sapphire Paratime as based off of the [Oasis SDK](https://github.com/oasisprotocol/oasis-sdk) +## Release + +### Clients + +JS libraries should be updated with a version bump in the `package.json` +file and a respective tag in the pattern of `{{path}}/v{{semver}}`, such as +`clients/js/v1.1.1`. + + ## Contributing Developers are encouraged to contribute their improvements to the Sapphire @@ -47,4 +56,4 @@ See our [Contributing Guidelines](CONTRIBUTING.md). Oasis remains committed to unlocking the full potential of privacy applications on Web3. -Join the [Privacy4Web3 Hackathon](https://oasisprotocol.org/p4w3-hackathon) today! +Build with [us](https://oasisprotocol.org/opl#how-to-get-started) today!