Skip to content

Instantly share code, notes, and snippets.

@zerok
Created July 3, 2010 18:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zerok/462752 to your computer and use it in GitHub Desktop.
Save zerok/462752 to your computer and use it in GitHub Desktop.
dotless homebrew formula
require 'formula'
class Dotless < Formula
homepage "http://www.dotlesscss.com/"
url "http://www.dotlesscss.com:8081/repository/download/bt3/.lastPinned/dotless-v1.1.0.2-16-ge76501f.zip?guest=1"
md5 "6bd2ccf37e670c6734a076f6c6c34f2d"
version "1.1.0.2"
def install
mono_path = `/usr/bin/which mono`.strip
if mono_path.size == 0
fail "You have to install mono first.\n" +\
"You can find the framework release on http://www.go-mono.com/mono-downloads/download.html"
end
File.open('dotless', 'w+') do |fp|
fp.write <<EOF
#!/bin/bash
exec #{mono_path} #{libexec}/dotless.Compiler.exe $@
EOF
end
FileUtils.chmod 0755, 'dotless'
bin.install('dotless')
lib.install(Dir.glob('*.dll'))
libexec.install(Dir.glob('*.exe'))
(share + 'dotless').mkpath
(share + 'dotless').install(Dir.glob('*.txt'))
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment