You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Before beginning to work on a contribution, please read the Guidelines.
Install
npm install -g ethlint
solium -V
For backward-compatibility, you can still use npm install -g solium.
If you're currently using the solium package for npm install, it is highly recommended that you move to ethlint. The solium package will not receive updates after December, 2019. There are no differences between the updates pushed to ethlint and solium packages.
Usage
In the root directory of your DApp, run:
solium --init
This creates 2 files for you:
.soliumignore - contains names of files and directories to ignore while linting
.soliumrc.json - contains configuration that tells Solium how to lint your project. You should modify this file to configure rules, plugins and sharable configs.
Solium does not strictly adhere to Solidity Style Guide. It aims to promote coding practices agreed upon by the community at large.
Lint
solium -f foobar.sol
solium -d contracts/
Configure with comments
Comment Directives can be used to configure Solium to ignore specific pieces of code.
They follow the pattern solium-disable<optional suffix>.
If you only use the directive, Solium disables all rules for the marked code. If that's not desirable, specify the rules to disable after the directive, separated by comma.