-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
113 additions
and
136 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: Deploy contract on Dev account | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
|
||
jobs: | ||
deploy-dev: | ||
name: Deploy contract | ||
runs-on: ubuntu-latest | ||
environment: dev.abstract-dao.testnet | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install cargo-near CLI | ||
run: curl --proto '=https' --tlsv1.2 -LsSf https://github.com/near/cargo-near/releases/download/cargo-near-v0.6.4/cargo-near-installer.sh | sh | ||
|
||
- name: Deploy contract to ${{ vars.NEAR_ACCOUNT_ID }} | ||
run: | | ||
cargo near deploy "${{ vars.NEAR_ACCOUNT_ID }}" \ | ||
without-init-call \ | ||
network-config "${{ vars.NEAR_NETWORK }}" \ | ||
sign-with-plaintext-private-key \ | ||
--signer-public-key "${{ vars.NEAR_ACCOUNT_PUBLIC_KEY }}" \ | ||
--signer-private-key "${{ secrets.NEAR_ACCOUNT_PRIVATE_KEY }}" \ | ||
send |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Deploy contract of exact version | ||
run-name: Deploy `${{ inputs.tag }}` version to `${{ inputs.environment }}` by @${{ github.actor }} | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
environment: | ||
description: "Environment to deploy to" | ||
type: environment | ||
required: true | ||
tag: | ||
description: "The tag version of release (v0.1.0)" | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
deploy-tag: | ||
name: Deploy ${{ inputs.tag }} to ${{ inputs.environment }} | ||
environment: ${{ inputs.environment }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository to ${{ inputs.tag }} | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ref/tags/${{ inputs.tag }} | ||
|
||
- name: Install cargo-near CLI | ||
run: curl --proto '=https' --tlsv1.2 -LsSf https://github.com/near/cargo-near/releases/download/cargo-near-v0.6.1/cargo-near-installer.sh | sh | ||
|
||
- name: Deploy contract to ${{ vars.NEAR_ACCOUNT_ID }} | ||
run: | | ||
cargo near deploy "${{ vars.NEAR_ACCOUNT_ID }}" \ | ||
without-init-call \ | ||
network-config "${{ vars.NEAR_NETWORK }}" \ | ||
sign-with-plaintext-private-key \ | ||
--signer-public-key "${{ vars.NEAR_ACCOUNT_PUBLIC_KEY }}" \ | ||
--signer-private-key "${{ secrets.NEAR_ACCOUNT_PRIVATE_KEY }}" \ | ||
send |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Pull Request Test | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
checks: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Check Formatting | ||
run: cargo fmt --check | ||
|
||
- name: Run cargo clippy | ||
run: | | ||
rustup component add clippy | ||
cargo clippy --all-features --workspace --tests -- --warn clippy::all --warn clippy::nursery | ||
- name: Run cargo test | ||
run: cargo test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
types: | ||
- closed | ||
|
||
name: Release Please | ||
|
||
jobs: | ||
release-please: | ||
runs-on: ubuntu-latest | ||
if: github.event_name == 'workflow_dispatch' || (github.event_name == 'pull_request' && github.event.pull_request.merged == true && contains(github.event.pull_request.body, 'I have created a release *beep* *boop*') && github.event.pull_request.user.login == 'denbite') | ||
steps: | ||
- uses: googleapis/release-please-action@v4 | ||
id: release | ||
name: Run release-please command | ||
with: | ||
# this assumes that you have created a personal access token | ||
# (PAT) and configured it as a GitHub action secret named | ||
token: ${{ secrets.REPOSITORY_PERSONAL_ACCESS_TOKEN }} | ||
target-branch: main | ||
config-file: .release-please/config.json | ||
manifest-file: .release-please/.manifest.json | ||
skip-github-release: false | ||
skip-github-pull-request: false |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.