{"action":"created","comment":{"url":"https://api.github.com/repos/protofire/eth-cli/pulls/comments/195698569","pull_request_review_id":129119742,"id":195698569,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5NTY5ODU2OQ==","diff_hunk":"@@ -1,10 +1,92 @@\n #!/usr/bin/env node\n \n-require('yargs')\n+/**\n+ * Networks available\n+ */\n+let networks = {\n+  mainnet: 'https://mainnet.infura.io',\n+  ropsten: 'https://ropsten.infura.io',\n+  rinkeby: 'https://rinkeby.infura.io',\n+  kovan: 'https://kovan.infura.io',\n+  sokol: 'https://sokol.poa.network',\n+  poa: 'https://core.poa.network',\n+  local: 'http://localhost:8545'\n+}\n+\n+let yargs = require('yargs')\n   .option('url', {\n     description: 'URL of the ethereum node to connect',\n-    default: 'http://localhost:8545'\n+    default: 'http://localhost:8545',\n+    type: 'string'\n+  })\n+  .option('mainnet', {\n+    describe: `Url of the mainnet ethereum node to connect: ${networks.mainnet}`,\n+    type: 'boolean'\n+  })\n+  .option('ropsten', {\n+    describe: `Url of the ropsten ethereum node to connect: ${networks.ropsten}`,\n+    type: 'boolean'\n+  })\n+  .option('rinkeby', {\n+    describe: `Url of the rinkeby ethereum node to connect: ${networks.rinkeby}`,\n+    type: 'boolean'\n+  })\n+  .option('kovan', {\n+    describe: `Url of the kovan ethereum node to connect: ${networks.kovan}`,\n+    type: 'boolean'\n+  })\n+  .option('sokol', {\n+    describe: `Url of the sokol ethereum node to connect: ${networks.sokol}`,\n+    type: 'boolean'\n   })\n+  .option('poa', {\n+    describe: `Url of the poa ethereum node to connect:  ${networks.poa}`,\n+    type: 'boolean'\n+  })\n+  .option('local', {\n+    describe: `Url of the local ethereum node to connect:  ${networks.local}`,\n+    type: 'boolean'\n+  })\n+  .check(function(argv) {\n+    // Mantain the amount of networks in argv\n+    let networksInArgv = 0","path":"src/index.js","position":54,"original_position":54,"commit_id":"76f353b0bfcf56ccbecd26e91b84bb7a68b33987","original_commit_id":"76f353b0bfcf56ccbecd26e91b84bb7a68b33987","user":{"login":"mariano-aguero","id":1144028,"node_id":"MDQ6VXNlcjExNDQwMjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1144028?v=4","gravatar_id":"","url":"https://api.github.com/users/mariano-aguero","html_url":"https://github.com/mariano-aguero","followers_url":"https://api.github.com/users/mariano-aguero/followers","following_url":"https://api.github.com/users/mariano-aguero/following{/other_user}","gists_url":"https://api.github.com/users/mariano-aguero/gists{/gist_id}","starred_url":"https://api.github.com/users/mariano-aguero/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mariano-aguero/subscriptions","organizations_url":"https://api.github.com/users/mariano-aguero/orgs","repos_url":"https://api.github.com/users/mariano-aguero/repos","events_url":"https://api.github.com/users/mariano-aguero/events{/privacy}","received_events_url":"https://api.github.com/users/mariano-aguero/received_events","type":"User","site_admin":false},"body":"If we remove that validation, we will allow a command to support the duplicity of parameters, example:\r\n\r\n`$ eth repl --ropsten --mainnet`\r\n\r\nIn that case it will take the last parameter. Something to take into account.\r\nThere is a boolean variable called 'optionUrlIsNotDefault ' that could be used to check if the url is already set or not. Dou you agree?\r\n","created_at":"2018-06-15T10:53:35Z","updated_at":"2018-06-15T10:53:35Z","html_url":"https://github.com/protofire/eth-cli/pull/9#discussion_r195698569","pull_request_url":"https://api.github.com/repos/protofire/eth-cli/pulls/9","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/protofire/eth-cli/pulls/comments/195698569"},"html":{"href":"https://github.com/protofire/eth-cli/pull/9#discussion_r195698569"},"pull_request":{"href":"https://api.github.com/repos/protofire/eth-cli/pulls/9"}},"in_reply_to_id":195560330},"pull_request":{"url":"https://api.github.com/repos/protofire/eth-cli/pulls/9","id":194591773,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk0NTkxNzcz","html_url":"https://github.com/protofire/eth-cli/pull/9","diff_url":"https://github.com/protofire/eth-cli/pull/9.diff","patch_url":"https://github.com/protofire/eth-cli/pull/9.patch","issue_url":"https://api.github.com/repos/protofire/eth-cli/issues/9","number":9,"state":"open","locked":false,"title":"Added shortcuts for useful networks","user":{"login":"mariano-aguero","id":1144028,"node_id":"MDQ6VXNlcjExNDQwMjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1144028?v=4","gravatar_id":"","url":"https://api.github.com/users/mariano-aguero","html_url":"https://github.com/mariano-aguero","followers_url":"https://api.github.com/users/mariano-aguero/followers","following_url":"https://api.github.com/users/mariano-aguero/following{/other_user}","gists_url":"https://api.github.com/users/mariano-aguero/gists{/gist_id}","starred_url":"https://api.github.com/users/mariano-aguero/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mariano-aguero/subscriptions","organizations_url":"https://api.github.com/users/mariano-aguero/orgs","repos_url":"https://api.github.com/users/mariano-aguero/repos","events_url":"https://api.github.com/users/mariano-aguero/events{/privacy}","received_events_url":"https://api.github.com/users/mariano-aguero/received_events","type":"User","site_admin":false},"body":"Fixes issue #5 ","created_at":"2018-06-13T13:45:38Z","updated_at":"2018-06-15T10:53:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e1c1e081a5c6f37bc34f77815c61f53bd558d6fe","assignee":{"login":"mariano-aguero","id":1144028,"node_id":"MDQ6VXNlcjExNDQwMjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1144028?v=4","gravatar_id":"","url":"https://api.github.com/users/mariano-aguero","html_url":"https://github.com/mariano-aguero","followers_url":"https://api.github.com/users/mariano-aguero/followers","following_url":"https://api.github.com/users/mariano-aguero/following{/other_user}","gists_url":"https://api.github.com/users/mariano-aguero/gists{/gist_id}","starred_url":"https://api.github.com/users/mariano-aguero/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mariano-aguero/subscriptions","organizations_url":"https://api.github.com/users/mariano-aguero/orgs","repos_url":"https://api.github.com/users/mariano-aguero/repos","events_url":"https://api.github.com/users/mariano-aguero/events{/privacy}","received_events_url":"https://api.github.com/users/mariano-aguero/received_events","type":"User","site_admin":false},"assignees":[{"login":"mariano-aguero","id":1144028,"node_id":"MDQ6VXNlcjExNDQwMjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1144028?v=4","gravatar_id":"","url":"https://api.github.com/users/mariano-aguero","html_url":"https://github.com/mariano-aguero","followers_url":"https://api.github.com/users/mariano-aguero/followers","following_url":"https://api.github.com/users/mariano-aguero/following{/other_user}","gists_url":"https://api.github.com/users/mariano-aguero/gists{/gist_id}","starred_url":"https://api.github.com/users/mariano-aguero/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mariano-aguero/subscriptions","organizations_url":"https://api.github.com/users/mariano-aguero/orgs","repos_url":"https://api.github.com/users/mariano-aguero/repos","events_url":"https://api.github.com/users/mariano-aguero/events{/privacy}","received_events_url":"https://api.github.com/users/mariano-aguero/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":962541732,"node_id":"MDU6TGFiZWw5NjI1NDE3MzI=","url":"https://api.github.com/repos/protofire/eth-cli/labels/in%20progress","name":"in progress","color":"ededed","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/protofire/eth-cli/pulls/9/commits","review_comments_url":"https://api.github.com/repos/protofire/eth-cli/pulls/9/comments","review_comment_url":"https://api.github.com/repos/protofire/eth-cli/pulls/comments{/number}","comments_url":"https://api.github.com/repos/protofire/eth-cli/issues/9/comments","statuses_url":"https://api.github.com/repos/protofire/eth-cli/statuses/76f353b0bfcf56ccbecd26e91b84bb7a68b33987","head":{"label":"mariano-aguero:feature/add-shortcuts-for-networks","ref":"feature/add-shortcuts-for-networks","sha":"76f353b0bfcf56ccbecd26e91b84bb7a68b33987","user":{"login":"mariano-aguero","id":1144028,"node_id":"MDQ6VXNlcjExNDQwMjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1144028?v=4","gravatar_id":"","url":"https://api.github.com/users/mariano-aguero","html_url":"https://github.com/mariano-aguero","followers_url":"https://api.github.com/users/mariano-aguero/followers","following_url":"https://api.github.com/users/mariano-aguero/following{/other_user}","gists_url":"https://api.github.com/users/mariano-aguero/gists{/gist_id}","starred_url":"https://api.github.com/users/mariano-aguero/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mariano-aguero/subscriptions","organizations_url":"https://api.github.com/users/mariano-aguero/orgs","repos_url":"https://api.github.com/users/mariano-aguero/repos","events_url":"https://api.github.com/users/mariano-aguero/events{/privacy}","received_events_url":"https://api.github.com/users/mariano-aguero/received_events","type":"User","site_admin":false},"repo":{"id":137220335,"node_id":"MDEwOlJlcG9zaXRvcnkxMzcyMjAzMzU=","name":"eth-cli","full_name":"mariano-aguero/eth-cli","owner":{"login":"mariano-aguero","id":1144028,"node_id":"MDQ6VXNlcjExNDQwMjg=","avatar_url":"https://avatars1.githubusercontent.com/u/1144028?v=4","gravatar_id":"","url":"https://api.github.com/users/mariano-aguero","html_url":"https://github.com/mariano-aguero","followers_url":"https://api.github.com/users/mariano-aguero/followers","following_url":"https://api.github.com/users/mariano-aguero/following{/other_user}","gists_url":"https://api.github.com/users/mariano-aguero/gists{/gist_id}","starred_url":"https://api.github.com/users/mariano-aguero/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mariano-aguero/subscriptions","organizations_url":"https://api.github.com/users/mariano-aguero/orgs","repos_url":"https://api.github.com/users/mariano-aguero/repos","events_url":"https://api.github.com/users/mariano-aguero/events{/privacy}","received_events_url":"https://api.github.com/users/mariano-aguero/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mariano-aguero/eth-cli","description":"A collection of CLI tools to help with ethereum learning and development.","fork":true,"url":"https://api.github.com/repos/mariano-aguero/eth-cli","forks_url":"https://api.github.com/repos/mariano-aguero/eth-cli/forks","keys_url":"https://api.github.com/repos/mariano-aguero/eth-cli/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mariano-aguero/eth-cli/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mariano-aguero/eth-cli/teams","hooks_url":"https://api.github.com/repos/mariano-aguero/eth-cli/hooks","issue_events_url":"https://api.github.com/repos/mariano-aguero/eth-cli/issues/events{/number}","events_url":"https://api.github.com/repos/mariano-aguero/eth-cli/events","assignees_url":"https://api.github.com/repos/mariano-aguero/eth-cli/assignees{/user}","branches_url":"https://api.github.com/repos/mariano-aguero/eth-cli/branches{/branch}","tags_url":"https://api.github.com/repos/mariano-aguero/eth-cli/tags","blobs_url":"https://api.github.com/repos/mariano-aguero/eth-cli/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mariano-aguero/eth-cli/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mariano-aguero/eth-cli/git/refs{/sha}","trees_url":"https://api.github.com/repos/mariano-aguero/eth-cli/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mariano-aguero/eth-cli/statuses/{sha}","languages_url":"https://api.github.com/repos/mariano-aguero/eth-cli/languages","stargazers_url":"https://api.github.com/repos/mariano-aguero/eth-cli/stargazers","contributors_url":"https://api.github.com/repos/mariano-aguero/eth-cli/contributors","subscribers_url":"https://api.github.com/repos/mariano-aguero/eth-cli/subscribers","subscription_url":"https://api.github.com/repos/mariano-aguero/eth-cli/subscription","commits_url":"https://api.github.com/repos/mariano-aguero/eth-cli/commits{/sha}","git_commits_url":"https://api.github.com/repos/mariano-aguero/eth-cli/git/commits{/sha}","comments_url":"https://api.github.com/repos/mariano-aguero/eth-cli/comments{/number}","issue_comment_url":"https://api.github.com/repos/mariano-aguero/eth-cli/issues/comments{/number}","contents_url":"https://api.github.com/repos/mariano-aguero/eth-cli/contents/{+path}","compare_url":"https://api.github.com/repos/mariano-aguero/eth-cli/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mariano-aguero/eth-cli/merges","archive_url":"https://api.github.com/repos/mariano-aguero/eth-cli/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mariano-aguero/eth-cli/downloads","issues_url":"https://api.github.com/repos/mariano-aguero/eth-cli/issues{/number}","pulls_url":"https://api.github.com/repos/mariano-aguero/eth-cli/pulls{/number}","milestones_url":"https://api.github.com/repos/mariano-aguero/eth-cli/milestones{/number}","notifications_url":"https://api.github.com/repos/mariano-aguero/eth-cli/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mariano-aguero/eth-cli/labels{/name}","releases_url":"https://api.github.com/repos/mariano-aguero/eth-cli/releases{/id}","deployments_url":"https://api.github.com/repos/mariano-aguero/eth-cli/deployments","created_at":"2018-06-13T13:36:01Z","updated_at":"2018-06-13T13:36:02Z","pushed_at":"2018-06-14T19:59:17Z","git_url":"git://github.com/mariano-aguero/eth-cli.git","ssh_url":"git@github.com:mariano-aguero/eth-cli.git","clone_url":"https://github.com/mariano-aguero/eth-cli.git","svn_url":"https://github.com/mariano-aguero/eth-cli","homepage":"https://www.npmjs.com/package/eth-cli","size":134,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"protofire:master","ref":"master","sha":"5e33dc1cd123625b39c8df88d7b16db2c24e02a9","user":{"login":"protofire","id":32464792,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyNDY0Nzky","avatar_url":"https://avatars1.githubusercontent.com/u/32464792?v=4","gravatar_id":"","url":"https://api.github.com/users/protofire","html_url":"https://github.com/protofire","followers_url":"https://api.github.com/users/protofire/followers","following_url":"https://api.github.com/users/protofire/following{/other_user}","gists_url":"https://api.github.com/users/protofire/gists{/gist_id}","starred_url":"https://api.github.com/users/protofire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/protofire/subscriptions","organizations_url":"https://api.github.com/users/protofire/orgs","repos_url":"https://api.github.com/users/protofire/repos","events_url":"https://api.github.com/users/protofire/events{/privacy}","received_events_url":"https://api.github.com/users/protofire/received_events","type":"Organization","site_admin":false},"repo":{"id":114293374,"node_id":"MDEwOlJlcG9zaXRvcnkxMTQyOTMzNzQ=","name":"eth-cli","full_name":"protofire/eth-cli","owner":{"login":"protofire","id":32464792,"node_id":"MDEyOk9yZ2FuaXphdGlvbjMyNDY0Nzky","avatar_url":"https://avatars1.githubusercontent.com/u/32464792?v=4","gravatar_id":"","url":"https://api.github.com/users/protofire","html_url":"https://github.com/protofire","followers_url":"https://api.github.com/users/protofire/followers","following_url":"https://api.github.com/users/protofire/following{/other_user}","gists_url":"https://api.github.com/users/protofire/gists{/gist_id}","starred_url":"https://api.github.com/users/protofire/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/protofire/subscriptions","organizations_url":"https://api.github.com/users/protofire/orgs","repos_url":"https://api.github.com/users/protofire/repos","events_url":"https://api.github.com/users/protofire/events{/privacy}","received_events_url":"https://api.github.com/users/protofire/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/protofire/eth-cli","description":"A collection of CLI tools to help with ethereum learning and development.","fork":false,"url":"https://api.github.com/repos/protofire/eth-cli","forks_url":"https://api.github.com/repos/protofire/eth-cli/forks","keys_url":"https://api.github.com/repos/protofire/eth-cli/keys{/key_id}","collaborators_url":"https://api.github.com/repos/protofire/eth-cli/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/protofire/eth-cli/teams","hooks_url":"https://api.github.com/repos/protofire/eth-cli/hooks","issue_events_url":"https://api.github.com/repos/protofire/eth-cli/issues/events{/number}","events_url":"https://api.github.com/repos/protofire/eth-cli/events","assignees_url":"https://api.github.com/repos/protofire/eth-cli/assignees{/user}","branches_url":"https://api.github.com/repos/protofire/eth-cli/branches{/branch}","tags_url":"https://api.github.com/repos/protofire/eth-cli/tags","blobs_url":"https://api.github.com/repos/protofire/eth-cli/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/protofire/eth-cli/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/protofire/eth-cli/git/refs{/sha}","trees_url":"https://api.github.com/repos/protofire/eth-cli/git/trees{/sha}","statuses_url":"https://api.github.com/repos/protofire/eth-cli/statuses/{sha}","languages_url":"https://api.github.com/repos/protofire/eth-cli/languages","stargazers_url":"https://api.github.com/repos/protofire/eth-cli/stargazers","contributors_url":"https://api.github.com/repos/protofire/eth-cli/contributors","subscribers_url":"https://api.github.com/repos/protofire/eth-cli/subscribers","subscription_url":"https://api.github.com/repos/protofire/eth-cli/subscription","commits_url":"https://api.github.com/repos/protofire/eth-cli/commits{/sha}","git_commits_url":"https://api.github.com/repos/protofire/eth-cli/git/commits{/sha}","comments_url":"https://api.github.com/repos/protofire/eth-cli/comments{/number}","issue_comment_url":"https://api.github.com/repos/protofire/eth-cli/issues/comments{/number}","contents_url":"https://api.github.com/repos/protofire/eth-cli/contents/{+path}","compare_url":"https://api.github.com/repos/protofire/eth-cli/compare/{base}...{head}","merges_url":"https://api.github.com/repos/protofire/eth-cli/merges","archive_url":"https://api.github.com/repos/protofire/eth-cli/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/protofire/eth-cli/downloads","issues_url":"https://api.github.com/repos/protofire/eth-cli/issues{/number}","pulls_url":"https://api.github.com/repos/protofire/eth-cli/pulls{/number}","milestones_url":"https://api.github.com/repos/protofire/eth-cli/milestones{/number}","notifications_url":"https://api.github.com/repos/protofire/eth-cli/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/protofire/eth-cli/labels{/name}","releases_url":"https://api.github.com/repos/protofire/eth-cli/releases{/id}","deployments_url":"https://api.github.com/repos/protofire/eth-cli/deployments","created_at":"2017-12-14T20:27:35Z","updated_at":"2018-06-14T20:25:05Z","pushed_at":"2018-06-14T20:25:03Z","git_url":"git://github.com/protofire/eth-cli.git","ssh_url":"git@github.com:protofire/eth-cli.git","clone_url":"https://github.com/protofire/eth-cli.git","svn_url":"https://github.com/protofire/eth-cli","homepage":"https://www.npmjs.com/package/eth-cli","size":127,"stargazers_count":11,"watchers_count":11,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"archived":false,"open_issues_count":4,"license":null,"forks":2,"open_issues":4,"watchers":11,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/protofire/eth-cli/pulls/9"},"html":{"href":"https://github.com/protofire/eth-cli/pull/9"},"issue":{"href":"https://api.github.com/repos/protofire/eth-cli/issues/9"},"comments":{"href":"https://api.github.com/repos/protofire/eth-cli/issues/9/comments"},"review_comments":{"href":"https://api.github.com/repos/protofire/eth-cli/pulls/9/comments"},"review_comment":{"href":"https://api.github.com/repos/protofire/eth-cli/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/protofire/eth-cli/pulls/9/commits"},"statuses":{"href":"https://api.github.com/repos/protofire/eth-cli/statuses/76f353b0bfcf56ccbecd26e91b84bb7a68b33987"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"mariano-aguero"}}