aboutsummaryrefslogtreecommitdiffstats
path: root/docs/Formula-Cookbook.md
diff options
context:
space:
mode:
authorEricFromCanada2017-03-25 22:36:09 -0400
committerEricFromCanada2017-03-25 22:36:09 -0400
commit59fab56afdf6129c37ff30eb842bf7bff41348e0 (patch)
tree3ea812481db220be1d8158cc99bc53d8d2107ae7 /docs/Formula-Cookbook.md
parent422afa0b49bae84e707cb3f66faf2da32cb4c462 (diff)
downloadbrew-59fab56afdf6129c37ff30eb842bf7bff41348e0.tar.bz2
docs: update sample formula
Also works around bug in Jekyll where a URL with a "#" will cause links in the same paragraph to not have their extensions replaced by using "#" instead.
Diffstat (limited to 'docs/Formula-Cookbook.md')
-rw-r--r--docs/Formula-Cookbook.md12
1 files changed, 10 insertions, 2 deletions
diff --git a/docs/Formula-Cookbook.md b/docs/Formula-Cookbook.md
index 84a472e0d..fc0a5d1f6 100644
--- a/docs/Formula-Cookbook.md
+++ b/docs/Formula-Cookbook.md
@@ -59,10 +59,18 @@ class Foo < Formula
# depends_on "cmake" => :build
def install
- system "./configure", "--prefix=#{prefix}", "--disable-debug", "--disable-dependency-tracking"
+ # ENV.deparallelize
+ system "./configure", "--disable-debug",
+ "--disable-dependency-tracking",
+ "--disable-silent-rules",
+ "--prefix=#{prefix}"
# system "cmake", ".", *std_cmake_args
system "make", "install"
end
+
+ test do
+ system "false"
+ end
end
```
@@ -259,7 +267,7 @@ Check the top of the e.g. `./configure` output. Some configure scripts do not re
### Add a test to the formula
-Please add a [`test do`](http://www.rubydoc.info/github/Homebrew/brew/master/Formula#test-class_method) block to the formula. This will be run by `brew test foo` and the [Brew Test Bot](Brew-Test-Bot.md).
+Add a valid test to the [`test do`](http://www.rubydoc.info/github/Homebrew/brew/master/Formula&num;test-class_method) block of the formula. This will be run by `brew test foo` and the [Brew Test Bot](Brew-Test-Bot.md).
The
[`test do`](http://www.rubydoc.info/github/Homebrew/brew/master/Formula#test-class_method)