File tree Expand file tree Collapse file tree 1 file changed +6
-27
lines changed
Expand file tree Collapse file tree 1 file changed +6
-27
lines changed Original file line number Diff line number Diff line change @@ -123,31 +123,6 @@ papi-generate:
123123 echo " 🔧 Generating PAPI descriptors..."
124124 npm run papi:generate
125125
126- # Run the authorize-and-store example
127- # Parameters: api=[papi|pjs] - choose between Polkadot API (papi) or Polkadot JS (pjs)
128- run-example api = " papi":
129- #!/usr/bin/env bash
130- set -e
131-
132- API_TYPE=" {{ api }} "
133-
134- if [[ " $API_TYPE" != " papi" && " $API_TYPE" != " pjs" ]]; then
135- echo " ❌ Error: api parameter must be 'papi' or 'pjs'"
136- exit 1
137- fi
138-
139- # Determine which example to run
140- if [ " $API_TYPE" == " papi" ]; then
141- EXAMPLE_FILE=" authorize_and_store_papi.js"
142- else
143- EXAMPLE_FILE=" authorize_and_store.js"
144- fi
145-
146- echo " "
147- echo " 🎯 Running $EXAMPLE_FILE example..."
148- echo " ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
149- node $EXAMPLE_FILE
150-
151126# Setup all services needed for testing (IPFS, zombienet, IPFS reconnect, PAPI)
152127# Parameters: api=[papi|pjs] - choose between Polkadot API (papi) or Polkadot JS (pjs)
153128setup-services api = " papi":
@@ -221,8 +196,12 @@ run-authorize-and-store api="papi": build npm-install
221196 just setup-services $API_TYPE
222197
223198 # Run the example
224- just run-example $API_TYPE
225- EXAMPLE_EXIT=$?
199+ if [ " $API_TYPE" == " papi" ]; then
200+ EXAMPLE_FILE=" authorize_and_store_papi.js"
201+ else
202+ EXAMPLE_FILE=" authorize_and_store.js"
203+ fi
204+ node $EXAMPLE_FILE
226205
227206 echo " "
228207 echo " ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
You can’t perform that action at this time.
0 commit comments