Skip to content

Commit

Permalink
Merge branch 'main' into refactoring/bes-228-introduce-classes
Browse files Browse the repository at this point in the history
  • Loading branch information
gas1cent committed Jan 12, 2024
2 parents d626d9f + ce63dd9 commit c419c47
Show file tree
Hide file tree
Showing 6 changed files with 43 additions and 29 deletions.
4 changes: 4 additions & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname "$0")/_/husky.sh"

npx --no-install commitlint --edit $1
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npx lint-staged
10 changes: 10 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
The MIT License (MIT)
Copyright © 2024 Wonderland

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


39 changes: 10 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
[![image](https://img.shields.io/npm/v/@defi-wonderland/natspec-smells.svg?style=flat-square)](https://www.npmjs.org/package/@defi-wonderland/natspec-smells)
[![Version](https://img.shields.io/npm/v/@defi-wonderland/natspec-smells?label=Version)](https://www.npmjs.com/package/@defi-wonderland/natspec-smells)
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/defi-wonderland/natspec-smells/blob/main/LICENSE)

# Natspec Smells

Some description will be written here.
Just like code, documentation can smell, too. `natspec-smells` aims to help automatically identify missing or incomplete natspec.

## Usage

Expand All @@ -14,33 +15,13 @@ npx @defi-wonderland/natspec-smells --contracts ./solidity

## Options

### `--contracts` (Required)

Relative path to your solidity files.

### `--root`

Root directory to be used.

Default: `./`

### `--enforceInheritdoc`

Whether `@inheritdoc` is used or not.

Default: `true`

### `--constructorNatspec`

Whether to enforce natspec for constructors.

Default: `false`

### `--ignore`

Glob pattern of files and directories to exclude from processing.

Default: `[]`
| Option | Description | Required | Default |
| -------------------- | ------------------------------------------------------------------------- | -------- | ------- |
| `contracts` | Relative path to your solidity files. | Yes | |
| `root` | Root directory to be used. | No | `./` |
| `enforceInheritdoc` | Whether `@inheritdoc` is used or not. | No | `true` |
| `constructorNatspec` | Whether to enforce natspec for constructors. | No | `false` |
| `ignore` | List of glob pattern of files and directories to exclude from processing. | No | `[]` |

## Contributors

Expand Down
5 changes: 5 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
"build": "tsc",
"lint:check": "prettier --check .",
"lint:fix": "sort-package-json && prettier --write .",
"prepack": "pinst --disable",
"postpack": "pinst --enable",
"prepare": "husky install",
"start": "ts-node ./src/main.ts",
"test": "jest ./test"
},
Expand All @@ -27,8 +30,10 @@
"@faker-js/faker": "^8.3.1",
"@types/jest": "29.5.11",
"@types/node": "20.10.7",
"husky": "8.0.3",
"jest": "29.7.0",
"lint-staged": "13.2.2",
"pinst": "3.0.0",
"prettier": "2.8.8",
"sort-package-json": "2.4.1",
"ts-jest": "29.1.1",
Expand Down
10 changes: 10 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1970,6 +1970,11 @@ human-signals@^4.3.0:
resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-4.3.1.tgz#ab7f811e851fca97ffbd2c1fe9a958964de321b2"
integrity sha512-nZXjEF2nbo7lIw3mgYjItAfgQXog3OjJogSbKa2CQIIvSGWcKgeJnQlNXip6NglNzYH45nSRiEVimMvYL8DDqQ==

[email protected]:
version "8.0.3"
resolved "https://registry.yarnpkg.com/husky/-/husky-8.0.3.tgz#4936d7212e46d1dea28fef29bb3a108872cd9184"
integrity sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg==

ignore@^5.2.4:
version "5.3.0"
resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.3.0.tgz#67418ae40d34d6999c95ff56016759c718c82f78"
Expand Down Expand Up @@ -3077,6 +3082,11 @@ pidtree@^0.6.0:
resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.6.0.tgz#90ad7b6d42d5841e69e0a2419ef38f8883aa057c"
integrity sha512-eG2dWTVw5bzqGRztnHExczNxt5VGsE6OwTeCG3fdUf9KBsZzO3R5OIIIzWR+iZA0NtZ+RDVdaoE2dK1cn6jH4g==

[email protected]:
version "3.0.0"
resolved "https://registry.yarnpkg.com/pinst/-/pinst-3.0.0.tgz#80dec0a85f1f993c6084172020f3dbf512897eec"
integrity sha512-cengSmBxtCyaJqtRSvJorIIZXMXg+lJ3sIljGmtBGUVonMnMsVJbnzl6jGN1HkOWwxNuJynCJ2hXxxqCQrFDdw==

pirates@^4.0.4:
version "4.0.6"
resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.6.tgz#3018ae32ecfcff6c29ba2267cbf21166ac1f36b9"
Expand Down

0 comments on commit c419c47

Please sign in to comment.