Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs/user guide #1322

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 29 additions & 4 deletions packages/hint/docs/user-guide/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,16 @@ to report the results.

### Default configuration

To run `webhint` you need a `.hintrc` file. If you don't have one,
To run `webhint` you need a `.hintrc` file. If you do not have one,
`webhint` will use the [`web-recommended` set of hints][web recommended].
This configuration will be equivalent to the following `.hintrc`:

```json
{
"extends": ["web-recommended"]
}
```

### Further reading

Now that you have `webhint` up and running, it is time to learn a bit more
Expand All @@ -90,6 +96,23 @@ about the different pieces:
* [Formatters](./concepts/formatters/)
* [Parsers](./concepts/parsers/)

### Windows and Python

Depending on your environment you could get an error similar to the
following if there is a problem downloading any of the precompiled
native modules:

> gyp ERR! stack Error: Can't find Python executable "python"

The fastest way to have a Windows environment capable of compiling native
Node modules is installing the [`windows-build-tools`][windows build tools].

From an **Elevated PowerShell** run the following:

```bash
npm install --global windows-build-tools
```

### Permission issues during installation

If you receive an `EACCES` error when installing `webhint`, it is caused
Expand All @@ -103,8 +126,9 @@ change default directory]. According to [npm’s documentation][npm use
package manager], if you have node installed using a package
manager like [Homebrew][homebrew] or [nvm][nvm], you may be able to avoid
the trouble of messing with the directories and have the correct
permissions set up right out of the box. As a result, you won’t experience
the error described above even if you install `webhint` globally.
permissions set up right out of the box. As a result, you will not
experience the error described above even if you install `webhint`
globally.

<!-- Link labels: -->

Expand All @@ -114,4 +138,5 @@ the error described above even if you install `webhint` globally.
[npm use package manager]: https://docs.npmjs.com/getting-started/fixing-npm-permissions#option-3-use-a-package-manager-that-takes-care-of-this-for-you
[nvm]: https://github.com/creationix/nvm
[permission issue]: https://github.com/webhintio/hint/issues/308
[web recommended]: https://github.com/webhintio/hint/tree/master/packages/configuration-web-recommended#readme
[web recommended]: https://github.com/webhintio/hint/blob/master/packages/configuration-web-recommended/index.json
[windows build tools]: https://www.npmjs.com/package/windows-build-tools