Skip to content

Commit

Permalink
build: update node; use preinstall and local deps
Browse files Browse the repository at this point in the history
  • Loading branch information
chadoh committed Aug 8, 2023
1 parent b0bebf6 commit b9c3415
Show file tree
Hide file tree
Showing 5 changed files with 114 additions and 52 deletions.
2 changes: 1 addition & 1 deletion .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# paths = ["/path/to/override"] # path dependency overrides

[alias] # command aliases
install_soroban = "install --git https://github.com/stellar/soroban-tools --rev cb3c44f9d8080917a7cb019d6be25019f6cf78c3 --root ./target soroban-cli --debug"
install_soroban = "install --version 0.9.1 --root ./target soroban-cli --debug"
b = "build --target wasm32-unknown-unknown --release"
# c = "check"
# t = "test"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- run: cargo install_soroban
- uses: actions/setup-node@v3
with:
node-version: 18.x
node-version: 18.14.2
cache: 'npm'
- run: |
mkdir -p .soroban-example-dapp
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
18
18.17
148 changes: 106 additions & 42 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 5 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,15 @@
"setup": "./initialize.sh ${NETWORK:-futurenet} && npm install",
"clean": "rm -rf .next .soroban .soroban-example-dapp",
"reset": "npm run clean && npm run setup",
"postinstall": "cargo build --target wasm32-unknown-unknown --release && ./target/bin/soroban contract bindings typescript --wasm ./target/wasm32-unknown-unknown/release/soroban_crowdfund_contract.wasm --id $(cat ./.soroban-example-dapp/crowdfund_id) --output-dir ./node_modules/crowdfund-contract --network $(cat ./.soroban-example-dapp/network) --contract-name crowdfund-contract && ./target/bin/soroban contract bindings typescript --wasm ./target/wasm32-unknown-unknown/release/abundance_token.wasm --id $(cat ./.soroban-example-dapp/abundance_token_id) --output-dir ./node_modules/abundance-token --network $(cat ./.soroban-example-dapp/network) --contract-name abundance-token"
"preinstall": "./target/bin/soroban contract build && ./target/bin/soroban contract bindings typescript --wasm ./target/wasm32-unknown-unknown/release/soroban_crowdfund_contract.wasm --id $(cat ./.soroban-example-dapp/crowdfund_id) --output-dir ./.soroban-example-dapp/crowdfund-contract --network $(cat ./.soroban-example-dapp/network) --contract-name crowdfund-contract && ./target/bin/soroban contract bindings typescript --wasm ./target/wasm32-unknown-unknown/release/abundance_token.wasm --id $(cat ./.soroban-example-dapp/abundance_token_id) --output-dir ./.soroban-example-dapp/abundance-token --network $(cat ./.soroban-example-dapp/network) --contract-name abundance-token"
},
"dependencies": {
"@radix-ui/react-dialog": "1.0.2",
"@stellar/freighter-api": "^1.5.1",
"abundance-token": "file:./.soroban-example-dapp/abundance-contract",
"axios": "^0.27.2",
"bigint-conversion": "^2.4.1",
"crowdfund-contract": "file:./.soroban-example-dapp/crowdfund-contract",
"humanize-duration": "^3.27.3",
"moment": "^2.29.4",
"next": "^13.4.4",
Expand All @@ -33,12 +35,8 @@
"eslint-config-next": "^13.3.1",
"typescript": "5.1.3"
},
"optionalDependencies": {
"crowdfund-contract": "*",
"abundance-token": "*"
},
"engines": {
"node": ">=17",
"npm": ">=8"
"node": ">=18.14.2",
"npm": ">=9.5.0"
}
}

0 comments on commit b9c3415

Please sign in to comment.