Skip to content

Commit 62487b6

Browse files
committed
refactor: update subgraph configuration and build scripts
1 parent 5bd0c1f commit 62487b6

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ node_modules
22
build
33
generated
44
yarn.lock
5-
subgraph.test.yaml
5+
subgraph.yaml
66
test-stack/.env
77
tests/.bin
88
tests/.latest.json

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,14 @@
77
"scripts": {
88
"prepare": "husky",
99
"generate:typechain": "typechain --target ethers-v6 --out-dir generated/typechain './node_modules/@iexec/poco/build/contracts/*.json' --ts-nocheck",
10-
"build": "dotenv -e .env -- sh -c 'rm -rf generated && rm -rf build && npm run generate:typechain && graph codegen && graph build --network ${NETWORK_NAME:-bellecour}'",
10+
"codegen": " npm run generate:typechain && graph codegen subgraph.template.yaml",
11+
"build": "dotenv -e .env -- sh -c 'npm run codegen && graph build subgraph.template.yaml --network ${NETWORK_NAME:-bellecour}'",
1112
"test": "npm run test:unit && npm run test:e2e",
1213
"test:unit": "graph test unit",
1314
"test:e2e": "mocha tests/e2e/**/*.ts",
1415
"coverage": "graph test -- -c",
1516
"create": "dotenv -e .env -- sh -c 'graph create ${NETWORK_NAME:-bellecour}/poco --node ${GRAPHNODE_URL:-http://localhost:8020}'",
16-
"deploy": "dotenv -e .env -- sh -c 'graph deploy ${NETWORK_NAME:-bellecour}/poco --node ${GRAPHNODE_URL:-http://localhost:8020} --ipfs ${IPFS_URL:-http://localhost:5001} --version-label ${VERSION_LABEL:-bellecour/poco-v5}'",
17+
"deploy": "dotenv -e .env -- sh -c 'graph deploy ${NETWORK_NAME:-bellecour}/poco subgraph.template.yaml --node ${GRAPHNODE_URL:-http://localhost:8020} --ipfs ${IPFS_URL:-http://localhost:5001} --network ${NETWORK_NAME:-bellecour} --version-label ${VERSION_LABEL:-bellecour/poco-v5}'",
1718
"deploy-chainX": "dotenv -e .env -- sh -c 'graph deploy ${SUBGRAPH_SLUG} subgraph.template.yaml --deploy-key ${SUBGRAPH_DEPLOY_KEY} --network ${SUBGRAPH_NETWORK_NAME} --version-label ${VERSION_LABEL}'",
1819
"all": "npm run build && npm run create && npm run deploy",
1920
"stop-test-stack": "cd test-stack && docker compose down --remove-orphans --volumes",
File renamed without changes.

0 commit comments

Comments
 (0)