Skip to content

Commit

Permalink
[#227] Add installation instruction info
Browse files Browse the repository at this point in the history
  • Loading branch information
pnatashap committed Jan 16, 2024
1 parent cddf3cb commit 8fe48f1
Showing 1 changed file with 39 additions and 8 deletions.
47 changes: 39 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,37 @@ Read
[_PDD in Action_](http://www.yegor256.com/2017/04/05/pdd-in-action.html)
and watch [this webinar](https://www.youtube.com/watch?v=nsYGC2aUwfQ).

You should have [Ruby installed](https://www.ruby-lang.org/en/documentation/installation/).
## Installation
<details><summary>

### Prerequisites: `Ruby installed` and `Libmagic`
</summary>
<details><summary>

#### Ruby version 2.7+
</summary>
[Ruby installation instruction](https://www.ruby-lang.org/en/documentation/installation/)
</details>
<details>
<summary>

#### Libmagic library
</summary>

**For \*nix**
```bash
$ apt install libmagic-dev
```
**For Mac**
```bash
$ brew install libmagic
```
**For Windows**
Unfortunately, there is no easy way to install, please use WSL

</details>
</details>

Then, install our gem:

```bash
Expand All @@ -38,9 +68,10 @@ Run it locally and read its output:
$ pdd --help
```

## Usage
You can exclude & include certain number of files from the search via these options:

```
```bash
$ pdd --exclude=glob
```

Expand All @@ -55,7 +86,7 @@ $ pdd --exclude=src/**/* # exclude all files in src/

You can include too:

```
```bash
$ pdd --include=glob
```

Expand All @@ -80,9 +111,9 @@ to the leading space in every consecutive line):
[related code]
```

`[]` - Replace with apropriate data (see text enclosed in brackets)
`[]` - Replace with appropriate data (see text enclosed in brackets)

`<>` - Omitable (enclosed data can be left out)
`<>` - Optional (enclosed data can be left out)

Example:

Expand Down Expand Up @@ -142,7 +173,7 @@ and put a dummy `#1` marker everywhere.
You can specify post-parsing rules for your puzzles, in command line,
for example:

```
```bash
$ pdd --rule=min-estimate:60 --rule=max-estimate:120
```

Expand Down Expand Up @@ -217,13 +248,13 @@ Make sure your build is green before you contribute
your pull request. You will need to have [Ruby](https://www.ruby-lang.org/en/) 2.3+ and
[Bundler](https://bundler.io/) installed. Then:

```
```bash
$ bundle install
$ bundle exec rake
```

Next, install and run overcommit to install hooks (required once)
```
```bash
$ gem install overcommit -v '=0.58.0'
$ overcommit --install
```
Expand Down

0 comments on commit 8fe48f1

Please sign in to comment.