diff options
| author | Xavier Lacoste | 2014-12-09 10:31:06 +0100 |
|---|---|---|
| committer | Mike McQuaid | 2014-12-09 15:54:22 +0000 |
| commit | fd8a877bfba84f62ff015c13070dff81cd89d516 (patch) | |
| tree | 8710f845a505d2095e1941c4d3f565a13bf6bf6b | |
| parent | 9fd2e15422a2d593e6ffaf26e4bb5b3251bec403 (diff) | |
| download | homebrew-fd8a877bfba84f62ff015c13070dff81cd89d516.tar.bz2 | |
Formula for queequeg small grammar checker
Closes #34819.
Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
| -rw-r--r-- | Library/Formula/queequeg.rb | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/Library/Formula/queequeg.rb b/Library/Formula/queequeg.rb new file mode 100644 index 000000000..bd3a82007 --- /dev/null +++ b/Library/Formula/queequeg.rb @@ -0,0 +1,35 @@ +require "formula" + +class Queequeg < Formula + homepage "http://queequeg.sourceforge.net/" + url "https://downloads.sourceforge.net/project/queequeg/queequeg/queequeg-0.91/queequeg-0.91.tar.gz" + sha1 "e0ceae717a297ee866e38ae7fd10c216df1232e9" + + depends_on :python if MacOS.version <= :snow_leopard + depends_on "wordnet" + + def install + # Build the dictionary + system "make", "dict", "WORDNETDICT=#{Formula["wordnet"].opt_prefix}/dict" + + # Install python files and dictionary into libexec + install_list = ["abstfilter.py", "constraint.py", "convdict.py", + "dictionary.py", "document.py", + "grammarerror.py", "markupbase_rev.py", "output.py", + "postagfix.py", "pstring.py", "qq", "regpat.py", + "sentence.py", "sgmllib_rev.py", "texparser.py", "unification.py"] + libexec.install install_list + if File.exist? "dict.cdb" + libexec.install "dict.cdb" + else + libexec.install "dict.txt" + end + # Write a wrapper for qq + bin.write_exec_script "#{libexec}/qq" + end + + test do + (testpath/"filename").write "This is a test." + system "#{bin}/qq", "#{testpath}/filename" + end +end |
