Skip to content

Commit e859c6d

Browse files
authored
fix: remove subgraph task (#5)
We don't have a subgraph for solidity empty, so the subgraph tasks fail with: ``` Executing task: make subgraph Deploying the subgraph... /bin/sh: 1: cannot create subgraph/subgraph.config.json: Directory nonexistent make: *** [Makefile:75: subgraph] Error 2 * The terminal process "/usr/bin/bash '-c', 'make subgraph'" failed to launch (exit code: 2). * Terminal will be reused by tasks, press any key to close it. ``` <img width="2032" alt="image" src="https://github.com/settlemint/solidity-empty/assets/62167899/b1078364-a2a0-4bfe-8968-6332ff9363bc">
1 parent 62d07b9 commit e859c6d

File tree

2 files changed

+0
-28
lines changed

2 files changed

+0
-28
lines changed

.vscode/tasks.json

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,6 @@
6666
"command": "make cast",
6767
"problemMatcher": []
6868
},
69-
{
70-
"label": "subgraph",
71-
"type": "shell",
72-
"command": "make subgraph",
73-
"problemMatcher": []
74-
},
7569
{
7670
"label": "help",
7771
"type": "shell",

Makefile

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -69,28 +69,6 @@ cast:
6969
@echo "Interacting with EVM via Cast..."
7070
@cast $(SUBCOMMAND)
7171

72-
subgraph:
73-
@echo "Deploying the subgraph..."
74-
@rm -Rf subgraph/subgraph.config.json
75-
@DEPLOYED_ADDRESS=$$(grep "Deployed to:" deployment.txt | awk '{print $$3}') yq e -p=json -o=json '.datasources[0].address = env(DEPLOYED_ADDRESS) | .chain = env(BTP_NETWORK_NAME)' subgraph/subgraph.config.template.json > subgraph/subgraph.config.json
76-
@cd subgraph && pnpm graph-compiler --config subgraph.config.json --include node_modules/@openzeppelin/subgraphs/src/datasources subgraph/datasources --export-schema --export-subgraph
77-
@cd subgraph && yq e '.specVersion = "0.0.4"' -i generated/solidity-token-erc20.subgraph.yaml
78-
@cd subgraph && yq e '.description = "Solidity Token ERC20"' -i generated/solidity-token-erc20.subgraph.yaml
79-
@cd subgraph && yq e '.repository = "https://github.com/settlemint/solidity-token-erc20"' -i generated/solidity-token-erc20.subgraph.yaml
80-
@cd subgraph && yq e '.indexerHints.prune = "auto"' -i generated/solidity-token-erc20.subgraph.yaml
81-
@cd subgraph && yq e '.features = ["nonFatalErrors", "fullTextSearch", "ipfsOnEthereumContracts"]' -i generated/solidity-token-erc20.subgraph.yaml
82-
@cd subgraph && pnpm graph codegen generated/solidity-token-erc20.subgraph.yaml
83-
@cd subgraph && pnpm graph build generated/solidity-token-erc20.subgraph.yaml
84-
@eval $$(curl -H "x-auth-token: $${BTP_SERVICE_TOKEN}" -s $${BTP_CLUSTER_MANAGER_URL}/ide/foundry/$${BTP_SCS_ID}/env | sed 's/^/export /'); \
85-
if [ "$${BTP_MIDDLEWARE}" == "" ]; then \
86-
echo "You have not launched a graph middleware for this smart contract set, aborting..."; \
87-
exit 1; \
88-
else \
89-
cd subgraph; \
90-
pnpm graph create --node $${BTP_MIDDLEWARE} $${BTP_SCS_NAME}; \
91-
pnpm graph deploy --version-label v1.0.$$(date +%s) --node $${BTP_MIDDLEWARE} --ipfs $${BTP_IPFS}/api/v0 $${BTP_SCS_NAME} generated/solidity-token-erc20.subgraph.yaml; \
92-
fi
93-
9472
help:
9573
@echo "Forge help..."
9674
@forge --help

0 commit comments

Comments
 (0)