Skip to content

Commit

Permalink
Merge branch 'main' of github.com:NEAR-DevHub/neardevhub-contract int…
Browse files Browse the repository at this point in the history
…o web4-blog
  • Loading branch information
Tguntenaar committed Oct 10, 2024
2 parents 29b1fe1 + 083fdde commit 80fa027
Show file tree
Hide file tree
Showing 31 changed files with 1,250 additions and 3,338 deletions.
7 changes: 6 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
{
"image": "ghcr.io/near/near-devcontainer:latest",
"features": {
"ghcr.io/near/near-devcontainers/features/cargo-near:latest": {},
"ghcr.io/near/near-devcontainers/features/near-cli:latest": {}
},
"customizations": {
"vscode": {
"extensions": [
"dtsvet.vscode-wasm",
"rust-lang.rust-analyzer",
"github.vscode-github-actions"
"github.vscode-github-actions",
"vadimcn.vscode-lldb"
]
}
},
Expand Down
2 changes: 0 additions & 2 deletions .devcontainer/post-create.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
#!/bin/bash

(cd discussions && cargo near build)
(cd community && cargo near build)
(cd community-factory && cargo near build)
cargo near build
8 changes: 2 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,9 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v4
- uses: Swatinem/rust-cache@v1
- uses: Swatinem/rust-cache@v2
- name: Install cargo-near
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: Build discussions contract
run: cd discussions && cargo near build
- name: Build community contract
run: cd community && cargo near build
run: curl --proto '=https' --tlsv1.2 -LsSf https://github.com/near/cargo-near/releases/latest/download/cargo-near-installer.sh | sh
- name: Build community factory contract
run: cd community-factory && cargo near build
- name: Build devhub contract
Expand Down
10 changes: 1 addition & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,7 @@ jobs:
uses: actions/checkout@v4
- uses: Swatinem/rust-cache@v1
- name: Install cargo-near
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: Build discussions contract
run: cd discussions && cargo near build
- name: Build community contract
run: cd community && cargo near build
run: curl --proto '=https' --tlsv1.2 -LsSf https://github.com/near/cargo-near/releases/latest/download/cargo-near-installer.sh | sh
- name: Build community factory contract
run: cd community-factory && cargo near build
- name: Build devhub contract
Expand All @@ -42,7 +38,3 @@ jobs:
output=$(near contract call-function as-transaction "$NEAR_DEVHUB_ACCOUNT_ID" unsafe_self_upgrade file-args ./target/near/devhub.wasm prepaid-gas '200 TeraGas' attached-deposit '0 NEAR' sign-as "$NEAR_DEVHUB_ACCOUNT_ID" network-config "$NEAR_NETWORK_CONNECTION" sign-with-plaintext-private-key --signer-public-key "$NEAR_DEVHUB_ACCOUNT_PUBLIC_KEY" --signer-private-key "$NEAR_DEVHUB_ACCOUNT_PRIVATE_KEY" send)
while [[ ! "$output" == *"Migration done."* ]]; do
echo "$output"
sleep 5
output=$(near contract call-function as-transaction "$NEAR_DEVHUB_ACCOUNT_ID" unsafe_migrate json-args '{}' prepaid-gas '100 TeraGas' attached-deposit '0 NEAR' sign-as "$NEAR_DEVHUB_ACCOUNT_ID" network-config "$NEAR_NETWORK_CONNECTION" sign-with-plaintext-private-key --signer-public-key "$NEAR_DEVHUB_ACCOUNT_PUBLIC_KEY" --signer-private-key "$NEAR_DEVHUB_ACCOUNT_PRIVATE_KEY" send)
done
echo "$output"
Loading

0 comments on commit 80fa027

Please sign in to comment.