@graphprotocol/graph-cli 0.43.0-alpha-20230224130144-b280a8f → 0.43.0-alpha-20230306074738-d410a35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,13 +1,27 @@
1
1
  # @graphprotocol/graph-cli
2
2
 
3
- ## 0.43.0-alpha-20230224130144-b280a8f
3
+ ## 0.43.0-alpha-20230306074738-d410a35
4
4
 
5
5
  ### Minor Changes
6
6
 
7
+ - [#1185](https://github.com/graphprotocol/graph-tooling/pull/1185)
8
+ [`d410a35`](https://github.com/graphprotocol/graph-tooling/commit/d410a3501b1ade73b4122f499b1eacde3337e9c7)
9
+ Thanks [@incrypto32](https://github.com/incrypto32)! - Fix graph init failing to add more than one
10
+ contract
11
+
12
+ ## 0.42.3
13
+
14
+ ### Patch Changes
15
+
7
16
  - [#1134](https://github.com/graphprotocol/graph-tooling/pull/1134)
8
- [`b280a8f`](https://github.com/graphprotocol/graph-tooling/commit/b280a8fad6360359a30d9a0e1ad3a5a3d30e3753)
17
+ [`a156355`](https://github.com/graphprotocol/graph-tooling/commit/a156355351f51f242bc2fa005125ffebed62eebe)
9
18
  Thanks [@incrypto32](https://github.com/incrypto32)! - Fix Prefix error when using graph init
10
19
 
20
+ - [#1138](https://github.com/graphprotocol/graph-tooling/pull/1138)
21
+ [`eb6815e`](https://github.com/graphprotocol/graph-tooling/commit/eb6815eb4af7c8c4d9a9f2b252dca8e350c81d32)
22
+ Thanks [@incrypto32](https://github.com/incrypto32)! - Fix default value issues with abi and
23
+ startBlock
24
+
11
25
  ## 0.42.2
12
26
 
13
27
  ### Patch Changes
@@ -119,11 +119,9 @@ AddCommand.flags = {
119
119
  }),
120
120
  abi: core_1.Flags.string({
121
121
  summary: 'Path to the contract ABI.',
122
- default: '*Download from Etherscan*',
123
122
  }),
124
123
  'start-block': core_1.Flags.string({
125
124
  summary: 'The block number to start indexing events from.',
126
- default: '*Zero*',
127
125
  }),
128
126
  'contract-name': core_1.Flags.string({
129
127
  summary: 'Name of the contract.',
@@ -752,7 +752,7 @@ async function addAnotherContract({ protocolInstance, directory, }) {
752
752
  const ProtocolContract = protocolInstance.getContract();
753
753
  let contract = '';
754
754
  for (;;) {
755
- contract = await core_1.ux.prompt(`Contract ${ProtocolContract.identifierName()}`, {
755
+ contract = await core_1.ux.prompt(`\nContract ${ProtocolContract.identifierName()}`, {
756
756
  required: true,
757
757
  });
758
758
  const { valid, error } = (0, validation_1.validateContract)(contract, ProtocolContract);
@@ -761,23 +761,26 @@ async function addAnotherContract({ protocolInstance, directory, }) {
761
761
  }
762
762
  this.log(`✖ ${error}`);
763
763
  }
764
- const localAbi = await core_1.ux.prompt('Provide local ABI path? (y/n)', {
764
+ const localAbi = await core_1.ux.prompt('\nProvide local ABI path? (y/n)', {
765
765
  required: true,
766
766
  type: 'single',
767
767
  });
768
768
  abiFromFile = localAbi.toLowerCase() === 'y';
769
769
  let abiPath = '';
770
770
  if (abiFromFile) {
771
- abiPath = await core_1.ux.prompt('ABI file (path)', { required: true });
771
+ abiPath = await core_1.ux.prompt('\nABI file (path)', { required: true });
772
772
  }
773
- const contractName = await core_1.ux.prompt('Contract Name', { required: true, default: 'Contract' });
773
+ const contractName = await core_1.ux.prompt('\nContract Name', {
774
+ required: true,
775
+ default: 'Contract',
776
+ });
774
777
  // Get the cwd before process.chdir in order to switch back in the end of command execution
775
778
  const cwd = process.cwd();
776
779
  try {
777
780
  if (fs_1.default.existsSync(directory)) {
778
781
  process.chdir(directory);
779
782
  }
780
- const commandLine = ['add', contract, '--contract-name', contractName];
783
+ const commandLine = [contract, '--contract-name', contractName];
781
784
  if (abiFromFile) {
782
785
  if (abiPath.includes(directory)) {
783
786
  commandLine.push('--abi', path_1.default.normalize(abiPath.replace(directory, '')));
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.43.0-alpha-20230224130144-b280a8f",
2
+ "version": "0.43.0-alpha-20230306074738-d410a35",
3
3
  "commands": {
4
4
  "add": {
5
5
  "id": "add",
@@ -21,15 +21,13 @@
21
21
  "name": "abi",
22
22
  "type": "option",
23
23
  "summary": "Path to the contract ABI.",
24
- "multiple": false,
25
- "default": "*Download from Etherscan*"
24
+ "multiple": false
26
25
  },
27
26
  "start-block": {
28
27
  "name": "start-block",
29
28
  "type": "option",
30
29
  "summary": "The block number to start indexing events from.",
31
- "multiple": false,
32
- "default": "*Zero*"
30
+ "multiple": false
33
31
  },
34
32
  "contract-name": {
35
33
  "name": "contract-name",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@graphprotocol/graph-cli",
3
- "version": "0.43.0-alpha-20230224130144-b280a8f",
3
+ "version": "0.43.0-alpha-20230306074738-d410a35",
4
4
  "description": "CLI for building for and deploying to The Graph",
5
5
  "license": "(Apache-2.0 OR MIT)",
6
6
  "engines": {