mirror of
https://github.com/joshuaclayton/unused.git
synced 2024-10-26 05:07:35 +03:00
Document installation via Homebrew
This commit is contained in:
parent
9ffc78f721
commit
a18d921f6a
53
README.md
53
README.md
@ -4,6 +4,44 @@ A command line tool in Haskell to identify unused code.
|
||||
|
||||
![Image of Unused Output](http://i.giphy.com/3oEjHGgyV2EDdy1Ogw.gif)
|
||||
|
||||
## Installing
|
||||
|
||||
### Homebrew
|
||||
|
||||
You can install [my formulae] via [Homebrew] with `brew tap`:
|
||||
|
||||
```sh
|
||||
brew tap joshuaclayton/formulae
|
||||
```
|
||||
|
||||
Next, run:
|
||||
|
||||
```sh
|
||||
brew install unused
|
||||
```
|
||||
|
||||
[my formulae]: https://github.com/joshuaclayton/homebrew-formulae
|
||||
[Homebrew]: http://brew.sh/
|
||||
|
||||
Alternatively, you can install by hand.
|
||||
|
||||
### Stack
|
||||
|
||||
This project uses [Haskell] and [Stack].
|
||||
|
||||
Once you have these tools installed:
|
||||
|
||||
```sh
|
||||
stack setup
|
||||
stack install
|
||||
```
|
||||
|
||||
This will generate a binary in `$HOME/.local/bin`; ensure this directory is in
|
||||
your `$PATH`.
|
||||
|
||||
[Haskell]: https://www.haskell.org
|
||||
[Stack]: http://www.haskellstack.org
|
||||
|
||||
## Using Unused
|
||||
|
||||
`unused` reads from a pipe expecting a series of tokens to search the codebase
|
||||
@ -28,20 +66,7 @@ navigate to a directory, run `unused`, and everything works as expected.
|
||||
|
||||
Unused leverages [Ag](https://github.com/ggreer/the_silver_searcher) to
|
||||
analyze the codebase; as such, you'll need to have `ag` available in your
|
||||
`$PATH`.
|
||||
|
||||
## Building and Compiling
|
||||
|
||||
This project uses Haskell and Stack.
|
||||
|
||||
Once you have these tools installed:
|
||||
|
||||
```sh
|
||||
stack install
|
||||
```
|
||||
|
||||
This will generate a binary in `$HOME/.local/bin`; ensure this directory is in
|
||||
your `$PATH`.
|
||||
`$PATH`. This is set as an explicit dependency in Homebrew.
|
||||
|
||||
## Testing
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user