<commit_before># Formula Cookbook
Making a formula is easy. Just `brew create URL` and then `brew install $FORMULA` (perhaps with `--debug --verbose`). Basically, a formula is a Ruby file. You can place it anywhere you want (local or remote) and install it by pointing to the file or URL.

We want your formula to be awesome, and the cookbook will tell you how.

## Terminology - Homebrew speak

<table>
  <tbody>
    <tr>
      <th>Formula</th>
      <td>The package definition</td>
      <td><code>/usr/local/Library/Formula/foo.rb</code></td>
    </tr>
    <tr>
      <th>Keg</th>
      <td>The installation prefix of a Formula</td>
      <td><code>/usr/local/Cellar/foo/0.1</code></td>
    </tr>
    <tr>
      <th>opt prefix</th>
      <td>A symlink to the active version of a keg</td>
      <td><code>/usr/local/opt/foo</code></td>
    </tr>
    <tr>
      <th>Cellar</th>
      <td>All kegs are installed here</td>
      <td><code>/usr/local/Cellar</code></td>
    </tr>
    <tr>
      <th>Tap</th>
      <td>An optional repository (git) of Formulae</td>
      <td><code>/usr/local/Library/Taps</code></td>
    </tr>
    <tr>
      <th>Bottle</th>
      <td>Pre-built (binary) Keg that can be unpacked</td>
      <td><code>qt-4.8.4.mountain_lion.bottle.1.tar.gz</code></td>
    </tr>
  </tbody>
</table>

_More general: `brew --prefix` and `brew --repository` instead of `/usr/local` but lets KISS._


## An Introduction

Did you see `/usr/local/.git`? Homebrew is built on Git. This means you can just do your work in `/usr/local` and merge in upstream changes as you go.

Homebrew installs to the `Cellar`, it then symlinks some of the installation into `/usr/local` so that other programs can see what's going on. We suggest you `brew ls` a few of the kegs in your Cellar to see how it is all arranged.

Packages are installed according to their formulae, which live in `$(brew --repository)/Library/Formula`. Check some out. You can view any formula at anytime; e.g. `brew edit wget`.



# Basic Instructions

Make sure you run `brew update` before you start. This turns your Homebrew installation into a Git repository.

Before contributing, make sure your package:

*   meets all our [Acceptable Formulae](Acceptable-Formulae.md) requirements
*   isn't already in Homebrew (check `brew search $FORMULA`)
*   isn't in another [Homebrew tap](https://github.com/Homebrew)
*   isn't already waiting to be merged (check the [issue tracker](https://github.com/Homebrew/homebrew/issues))
*   is still supported by upstream
*   has a stable, tagged version (i.e. not just a GitHub repository with no versions). See [Interesting-Taps-&-Branches](Interesting-Taps-&-Branches.md) for where pre-release and head-only versions belong.

Make sure you search thoroughly (all aliases!). We don’t want you to waste your time.

Be sure to look over the [contributing guidelines](https://github.com/Homebrew/homebrew/blob/master/CONTRIBUTING.md) as well.


## Will we merge your formula?

Probably. But we have rules to keep the quality and goals of Homebrew intact: Please read [Acceptable Formulae](Acceptable-Formulae.md).

## Some Quick Examples Before You Get Started

Formulae aren’t that complicated. [etl](https://github.com/Homebrew/homebrew/blob/master/Library/Formula/etl.rb) is as simple as it gets.

And then [Git](https://github.com/Homebrew/homebrew/tree/master/Library/Formula/git.rb) and [flac](https://github.com/Homebrew/homebrew/tree/master/Library/Formula/flac.rb) show more advanced functionality.

Refer to the [Formula class API documentation](http://www.rubydoc.info/github/Homebrew/homebrew/master/frames) which shows all the stuff you can use in a Formula.

## Grab the URL
<commit_msg>Formula-Cookbook: point to audit --strict.<commit_after># Formula Cookbook
Making a formula is easy. Just `brew create URL` and then `brew install $FORMULA` (perhaps with `--debug --verbose`). Basically, a formula is a Ruby file. You can place it anywhere you want (local or remote) and install it by pointing to the file or URL.

We want your formula to be awesome, and the cookbook will tell you how.

## Terminology - Homebrew speak

<table>
  <tbody>
    <tr>
      <th>Formula</th>
      <td>The package definition</td>
      <td><code>/usr/local/Library/Formula/foo.rb</code></td>
    </tr>
    <tr>
      <th>Keg</th>
      <td>The installation prefix of a Formula</td>
      <td><code>/usr/local/Cellar/foo/0.1</code></td>
    </tr>
    <tr>
      <th>opt prefix</th>
      <td>A symlink to the active version of a keg</td>
      <td><code>/usr/local/opt/foo</code></td>
    </tr>
    <tr>
      <th>Cellar</th>
      <td>All kegs are installed here</td>
      <td><code>/usr/local/Cellar</code></td>
    </tr>
    <tr>
      <th>Tap</th>
      <td>An optional repository (git) of Formulae</td>
      <td><code>/usr/local/Library/Taps</code></td>
    </tr>
    <tr>
      <th>Bottle</th>
      <td>Pre-built (binary) Keg that can be unpacked</td>
      <td><code>qt-4.8.4.mountain_lion.bottle.1.tar.gz</code></td>
    </tr>
  </tbody>
</table>

_More general: `brew --prefix` and `brew --repository` instead of `/usr/local` but lets KISS._


## An Introduction

Did you see `/usr/local/.git`? Homebrew is built on Git. This means you can just do your work in `/usr/local` and merge in upstream changes as you go.

Homebrew installs to the `Cellar`, it then symlinks some of the installation into `/usr/local` so that other programs can see what's going on. We suggest you `brew ls` a few of the kegs in your Cellar to see how it is all arranged.

Packages are installed according to their formulae, which live in `$(brew --repository)/Library/Formula`. Check some out. You can view any formula at anytime; e.g. `brew edit wget`.



# Basic Instructions

Make sure you run `brew update` before you start. This turns your Homebrew installation into a Git repository.

Before contributing, make sure your package:

*   meets all our [Acceptable Formulae](Acceptable-Formulae.md) requirements
*   isn't already in Homebrew (check `brew search $FORMULA`)
*   isn't in another [Homebrew tap](https://github.com/Homebrew)
*   isn't already waiting to be merged (check the [issue tracker](https://github.com/Homebrew/homebrew/issues))
*   is still supported by upstream
*   has a stable, tagged version (i.e. not just a GitHub repository with no versions). See [Interesting-Taps-&-Branches](Interesting-Taps-&-Branches.md) for where pre-release and head-only versions belong.
*   passes all `brew audit --strict --online $FORMULA` tests.

Make sure you search thoroughly (all aliases!). We don’t want you to waste your time.

Be sure to look over the [contributing guidelines](https://github.com/Homebrew/homebrew/blob/master/CONTRIBUTING.md) as well.


## Will we merge your formula?

Probably. But we have rules to keep the quality and goals of Homebrew intact: Please read [Acceptable Formulae](Acceptable-Formulae.md).

## Some Quick Examples Before You Get Started

Formulae aren’t that complicated. [etl](https://github.com/Homebrew/homebrew/blob/master/Library/Formula/etl.rb) is as simple as it gets.

And then [Git](https://github.com/Homebrew/homebrew/tree/master/Library/Formula/git.rb) and [flac](https://github.com/Homebrew/homebrew/tree/master/Library/Formula/flac.rb) show more advanced functionality.

Refer to the [Formula class API documentation](http://www.rubydoc.info/github/Homebrew/homebrew/master/frames) which shows all the stuff you can use in a Formula.

## Grab the URL

{'fraction_non_alphanumeric': 0.12418387741505663, 'fraction_numerical': 0.0015989340439706862, 'mean_word_length': 3.5026994601079786, 'pattern_counts': {'":': 0, '<': 131, '<?xml version=': 0, '>': 131, 'https://': 12, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3384550', 'n_tokens_mistral': 2409, 'n_tokens_neox': 2368, 'n_words': 852}