aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/gitfs.rb
diff options
context:
space:
mode:
authorDragos Tiselice2014-12-17 15:21:45 +0200
committerMike McQuaid2014-12-22 11:51:27 +0000
commitdf0b9c89a5ce9114905518fb8788ccbccd8fda29 (patch)
tree9d5ac20ff6b6637f849ece0c1362a81d5a418355 /Library/Formula/gitfs.rb
parent646e40f444749d1423fbbca8a9484c853d46113a (diff)
downloadhomebrew-df0b9c89a5ce9114905518fb8788ccbccd8fda29.tar.bz2
gitfs 0.2.5 (new formula)
Closes #35053.
Diffstat (limited to 'Library/Formula/gitfs.rb')
-rw-r--r--Library/Formula/gitfs.rb63
1 files changed, 63 insertions, 0 deletions
diff --git a/Library/Formula/gitfs.rb b/Library/Formula/gitfs.rb
new file mode 100644
index 000000000..630d1c7c4
--- /dev/null
+++ b/Library/Formula/gitfs.rb
@@ -0,0 +1,63 @@
+require "formula"
+
+class Gitfs < Formula
+ homepage "http://www.presslabs.com/gitfs"
+ url "https://github.com/PressLabs/gitfs/archive/0.2.5.tar.gz"
+ sha1 "a54056c1ba4095daae63e3a6e3c2505943691a34"
+
+ head "https://github.com/PressLabs/gitfs.git"
+
+ depends_on :python if MacOS.version <= :snow_leopard
+
+ depends_on "libgit2" => "with-libssh2"
+ depends_on :osxfuse
+
+ resource "fusepy" do
+ url "https://pypi.python.org/packages/source/f/fusepy/fusepy-2.0.2.tar.gz"
+ sha1 "d838388a122006614cd699cbcc5aa681194a5ae1"
+ end
+
+ resource "pygit2" do
+ url "https://pypi.python.org/packages/source/p/pygit2/pygit2-0.21.4.tar.gz"
+ sha1 "f7d677de26c56ab0f23edd7fe6812ec23b79b8f6"
+ end
+
+ resource "atomiclong" do
+ url "https://pypi.python.org/packages/source/a/atomiclong/atomiclong-0.1.1.tar.gz"
+ sha1 "4b3cab22c1910426fff41eef4cc69f418ec78a35"
+ end
+
+ resource "cffi" do
+ url "https://pypi.python.org/packages/source/c/cffi/cffi-0.8.6.tar.gz"
+ sha1 "4e82390201e6f30e9df8a91cd176df19b8f2d547"
+ end
+
+ resource "pycparser" do
+ url "https://pypi.python.org/packages/source/p/pycparser/pycparser-2.10.tar.gz"
+ sha1 "378a7a987d40e2c1c42cad0b351a6fc0a51ed004"
+ end
+
+ def install
+ ENV.prepend_create_path "PYTHONPATH", libexec/"vendor/lib/python2.7/site-packages"
+ %w[fusepy pygit2 atomiclong cffi pycparser].each do |r|
+ resource(r).stage do
+ system "python", *Language::Python.setup_install_args(libexec/"vendor")
+ end
+ end
+
+ ENV.prepend_create_path "PYTHONPATH", libexec/"lib/python2.7/site-packages"
+ system "python", *Language::Python.setup_install_args(libexec)
+
+ bin.install Dir[libexec/"bin/*"]
+ bin.env_script_all_files(libexec/"bin", :PYTHONPATH => ENV["PYTHONPATH"])
+ end
+
+ def caveats; <<-EOS.undent
+ gitfs clones repos in /var/lib/gitfs. You can either create it with
+ sudo mkdir -m 1777 /var/lib/gitfs or use another folder with the
+ repo_path argument.
+
+ Also make sure OSXFUSE is properly installed by running brew info osxfuse.
+ EOS
+ end
+end