Skip to content

Commit

Permalink
Upgrade deps + explain positional arguments in readme
Browse files Browse the repository at this point in the history
  • Loading branch information
xanderdeseyn committed Nov 4, 2020
1 parent a9d7ab5 commit 7307bdc
Show file tree
Hide file tree
Showing 3 changed files with 177 additions and 69 deletions.
29 changes: 27 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,32 @@ A bit more involved and showcasing the use of parameters for tasks:
```js
module.exports = {
watcher: {
tasks: ["clean", { command: "compile", params: { quiet: true } }],
tasks: ["clean", { command: "compile", params: { quiet: true } }, { command: "test", params: { noCompile: true, testFiles: ["testfile.ts"] } } ],
},
}
```
```

### Positional arguments

Positional arguments are provided in the same way as "normal" arguments (check out the `testFiles` argument in the example above, it's a positional argument).
In order to find the name of a positional argument, simply run `yarn hardhat <YOUR_COMMAND> --help`.
This is an example output for the `test` command:

````
Hardhat version 2.0.2
Usage: hardhat [GLOBAL OPTIONS] test [--no-compile] [...testFiles]
OPTIONS:
--no-compile Don't compile before running this task
POSITIONAL ARGUMENTS:
testFiles An optional list of files to test (default: [])
test: Runs mocha tests
For global options help run: hardhat help
```
14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,16 @@
],
"devDependencies": {
"@types/chai": "^4.1.7",
"@types/fs-extra": "^5.0.4",
"@types/mocha": "^5.2.6",
"@types/node": "^8.10.38",
"@types/fs-extra": "^9.0.3",
"@types/mocha": "^8.0.3",
"@types/node": "^14.14.6",
"chai": "^4.2.0",
"hardhat": "^2.0.0",
"mocha": "^7.1.2",
"mocha": "^8.2.1",
"np": "^7.0.0",
"prettier": "2.0.5",
"ts-node": "^8.1.0",
"tslint": "^5.16.0",
"prettier": "2.1.2",
"ts-node": "^9.0.0",
"tslint": "^6.1.3",
"tslint-config-prettier": "^1.18.0",
"tslint-plugin-prettier": "^2.0.1",
"typescript": "^4.0.3"
Expand Down
Loading

0 comments on commit 7307bdc

Please sign in to comment.