aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Vandenberg2012-03-04 16:52:50 -0800
committerAdam Vandenberg2012-03-05 21:14:39 -0800
commit89edada6b2381a64d758e17814cba0d0551f85b8 (patch)
tree5be88c5e5980974e3fb4b71c4318ae7de21b2d4a
parentfcb33f7c5493fa12b1e99ab713edec332a9c7bab (diff)
downloadhomebrew-89edada6b2381a64d758e17814cba0d0551f85b8.tar.bz2
Move specialized formulae base classes into a new file
-rw-r--r--Library/Homebrew/formula.rb16
-rw-r--r--Library/Homebrew/formula_specialties.rb16
2 files changed, 17 insertions, 15 deletions
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb
index 06863c136..44cf0d3b8 100644
--- a/Library/Homebrew/formula.rb
+++ b/Library/Homebrew/formula.rb
@@ -2,6 +2,7 @@ require 'download_strategy'
require 'formula_support'
require 'hardware'
require 'extend/fileutils'
+require 'formula_specialties'
# Derive and define at least @url, see Library/Formula for examples
@@ -764,18 +765,3 @@ private
end
end
end
-
-# See youtube-dl.rb for an example
-class ScriptFileFormula < Formula
- def install
- bin.install Dir['*']
- end
-end
-
-# See flac.rb for an example
-class GithubGistFormula < ScriptFileFormula
- def initialize name='__UNKNOWN__', path=nil
- super name, path
- @version=File.basename(File.dirname(url))[0,6]
- end
-end
diff --git a/Library/Homebrew/formula_specialties.rb b/Library/Homebrew/formula_specialties.rb
new file mode 100644
index 000000000..6aa469081
--- /dev/null
+++ b/Library/Homebrew/formula_specialties.rb
@@ -0,0 +1,16 @@
+# Base classes for specialized types of formulae.
+
+# See youtube-dl.rb for an example
+class ScriptFileFormula < Formula
+ def install
+ bin.install Dir['*']
+ end
+end
+
+# See flac.rb for an example
+class GithubGistFormula < ScriptFileFormula
+ def initialize name='__UNKNOWN__', path=nil
+ super name, path
+ @version=File.basename(File.dirname(url))[0,6]
+ end
+end