hugo 0.15

Closes Homebrew/homebrew#46364.

Signed-off-by: Alex Dunn <dunn.alex@gmail.com>
This commit is contained in:
Joonas Kuorilehto 2015-11-25 21:30:30 +02:00 committed by Alex Dunn
parent 97787df551
commit e80e96594a

View file

@ -3,8 +3,8 @@ require "language/go"
class Hugo < Formula class Hugo < Formula
desc "Configurable static site generator" desc "Configurable static site generator"
homepage "https://gohugo.io/" homepage "https://gohugo.io/"
url "https://github.com/spf13/hugo/archive/v0.14.tar.gz" url "https://github.com/spf13/hugo/archive/v0.15.tar.gz"
sha256 "67e0fda342e6a35490ce03f5535e30cf04bc06775c47bacf416d96d83cce4535" sha256 "417106a9a52fd1740bcb8a0102684da13da389b9a126eb1829b61cfdf3d86b63"
bottle do bottle do
cellar :any_skip_relocation cellar :any_skip_relocation
@ -17,164 +17,156 @@ class Hugo < Formula
head do head do
url "https://github.com/spf13/hugo.git" url "https://github.com/spf13/hugo.git"
go_resource "golang.org/x/text" do
url "https://github.com/golang/text.git", :revision => "df923bbb63f8ea3a26bb743e2a497abd0ab585f7"
end
end end
depends_on "go" => :build depends_on "go" => :build
go_resource "bitbucket.org/pkg/inflect" do go_resource "bitbucket.org/pkg/inflect" do
url "https://bitbucket.org/pkg/inflect", url "https://bitbucket.org/pkg/inflect",
:using => :hg, :revision => "8961c3750a47b8c0b3e118d52513b97adf85a7e8", :using => :hg
:revision => "8961c3750a47b8c0b3e118d52513b97adf85a7e8"
end end
go_resource "github.com/BurntSushi/toml" do go_resource "github.com/BurntSushi/toml" do
url "https://github.com/BurntSushi/toml.git", url "https://github.com/BurntSushi/toml.git",
:revision => "056c9bc7be7190eaa7715723883caffa5f8fa3e4" :revision => "056c9bc7be7190eaa7715723883caffa5f8fa3e4"
end
go_resource "github.com/dchest/cssmin" do
url "https://github.com/dchest/cssmin.git",
:revision => "a22e1d8daca3c08ffc1604201886e43bac04ceb9"
end
go_resource "github.com/eknkc/amber" do
url "https://github.com/eknkc/amber.git",
:revision => "ee5a5b8364bb73899fdd529d23af6ad9230f8a06"
end
go_resource "github.com/gorilla/websocket" do
url "https://github.com/gorilla/websocket.git",
:revision => "ecff5aabe41f13b4cdf897e3c0c9bbccbe552a29"
end
go_resource "github.com/kardianos/osext" do
url "https://github.com/kardianos/osext.git",
:revision => "8fef92e41e22a70e700a96b29f066cda30ea24ef"
end
go_resource "github.com/mitchellh/mapstructure" do
url "https://github.com/mitchellh/mapstructure.git",
:revision => "442e588f213303bec7936deba67901f8fc8f18b1"
end end
go_resource "github.com/PuerkitoBio/purell" do go_resource "github.com/PuerkitoBio/purell" do
url "https://github.com/PuerkitoBio/purell.git", url "https://github.com/PuerkitoBio/purell.git",
:revision => "d69616f51cdfcd7514d6a380847a152dfc2a749d" :revision => "d69616f51cdfcd7514d6a380847a152dfc2a749d"
end
go_resource "github.com/russross/blackfriday" do
url "https://github.com/russross/blackfriday.git",
:revision => "386ef80f18233ea97960e855a54382ec446c6637"
end
go_resource "github.com/spf13/afero" do
url "https://github.com/spf13/afero.git",
:revision => "e54aac2c6a0e639c31cbfe95944a1e9c01c05606"
end
go_resource "github.com/spf13/cast" do
url "https://github.com/spf13/cast.git",
:revision => "4d07383ffe94b5e5a6fa3af9211374a4507a0184"
end
go_resource "github.com/spf13/cobra" do
url "https://github.com/spf13/cobra.git",
:revision => "c11766b405b388c6bbafaa1c8b3ad2eaf471b7b6"
end
go_resource "github.com/spf13/fsync" do
url "https://github.com/spf13/fsync.git",
:revision => "1fdf08f822b05e59a6515ee151b683c3a02efea5"
end
go_resource "github.com/spf13/jwalterweatherman" do
url "https://github.com/spf13/jwalterweatherman.git",
:revision => "3d60171a64319ef63c78bd45bd60e6eab1e75f8b"
end
go_resource "github.com/spf13/nitro" do
url "https://github.com/spf13/nitro.git",
:revision => "24d7ef30a12da0bdc5e2eb370a79c659ddccf0e8"
end
go_resource "github.com/spf13/viper" do
url "https://github.com/spf13/viper.git",
:revision => "be782f3fee037d2db69c1c8af0e985e81e1ac273"
end
go_resource "github.com/stretchr/testify" do
url "https://github.com/stretchr/testify.git",
:revision => "dab07ac62d4905d3e48d17dc549c684ac3b7c15a"
end
go_resource "github.com/yosssi/ace" do
url "https://github.com/yosssi/ace.git",
:revision => "78e48a2f0ac5fb5a642585f96b03a5f47f7775f5"
end
go_resource "github.com/miekg/mmark" do
url "https://github.com/miekg/mmark.git",
:revision => "8a5a95ecab1c0d187754b4074c0d6f5215a26565"
end
go_resource "gopkg.in/yaml.v2" do
url "https://github.com/go-yaml/yaml.git",
:branch => "v2",
:revision => "49c95bdc21843256fb6c4e0d370a05f24a0bf213"
end
go_resource "gopkg.in/fsnotify.v1" do
url "https://github.com/go-fsnotify/fsnotify.git",
:revision => "6549b98005f3e4026ad9f50ef7d5011f40ba1397"
end end
# dependency for blackfriday go_resource "github.com/cpuguy83/go-md2man" do
go_resource "github.com/shurcooL/sanitized_anchor_name" do url "https://github.com/cpuguy83/go-md2man.git",
url "https://github.com/shurcooL/sanitized_anchor_name.git", :revision => "71acacd42f85e5e82f70a55327789582a5200a90"
:revision => "11a20b799bf22a02808c862eb6ca09f7fb38f84a"
end end
# dependencies for cobra go_resource "github.com/dchest/cssmin" do
go_resource "github.com/spf13/pflag" do url "https://github.com/dchest/cssmin.git",
url "https://github.com/spf13/pflag.git", :revision => "a22e1d8daca3c08ffc1604201886e43bac04ceb9"
:revision => "0ed81a961505a7dfaab5490049a7a324743e6f03"
end end
go_resource "github.com/eknkc/amber" do
url "https://github.com/eknkc/amber.git",
:revision => "144da19a9994994c069f0693294a66dd310e14a4"
end
go_resource "github.com/gorilla/websocket" do
url "https://github.com/gorilla/websocket.git",
:revision => "361d4c0ffd78338ebe0a9e6320cdbe115d7dc026"
end
go_resource "github.com/inconshreveable/mousetrap" do go_resource "github.com/inconshreveable/mousetrap" do
url "https://github.com/inconshreveable/mousetrap.git", url "https://github.com/inconshreveable/mousetrap.git",
:revision => "76626ae9c91c4f2a10f34cad8ce83ea42c93bb75" :revision => "76626ae9c91c4f2a10f34cad8ce83ea42c93bb75"
end end
# dependency for purell go_resource "github.com/kardianos/osext" do
go_resource "github.com/opennota/urlesc" do url "https://github.com/kardianos/osext.git",
url "https://github.com/opennota/urlesc.git", :revision => "10da29423eb9a6269092eebdc2be32209612d9d2"
:revision => "5fa9ff0392746aeae1c4b37fcc42c65afa7a9587"
end end
# dependencies for viper
go_resource "github.com/kr/pretty" do go_resource "github.com/kr/pretty" do
url "https://github.com/kr/pretty.git", url "https://github.com/kr/pretty.git",
:revision => "cb0850c1681cbca3233e84f7e6ec3e4c3f352085" :revision => "e6ac2fc51e89a3249e82157fa0bb7a18ef9dd5bb"
end
go_resource "github.com/xordataexchange/crypt" do
url "https://github.com/xordataexchange/crypt.git",
:revision => "93de65664ef094aa5acff4f5201ac17580370af7"
end
go_resource "github.com/magiconair/properties" do
url "https://github.com/magiconair/properties.git",
:revision => "d5929c67198951106f49f7ea425198d0f1a08f7f"
end end
# dependency for pretty
go_resource "github.com/kr/text" do go_resource "github.com/kr/text" do
url "https://github.com/kr/text.git", url "https://github.com/kr/text.git",
:revision => "6807e777504f54ad073ecef66747de158294b639" :revision => "bb797dc4fb8320488f47bf11de07a733d7233e1f"
end end
# dependencies for crypt go_resource "github.com/magiconair/properties" do
go_resource "github.com/armon/consul-api" do url "https://github.com/magiconair/properties.git",
url "https://github.com/armon/consul-api.git", :revision => "6ac0b95f449268951dd5c100682ea687a9866ea1"
:revision => "dcfedd50ed5334f96adee43fc88518a4f095e15c"
end
go_resource "golang.org/x/crypto" do
url "https://go.googlesource.com/crypto",
:using => :git,
:revision => "4d48e5fa3d62b5e6e71260571bf76c767198ca02"
end
go_resource "github.com/coreos/go-etcd" do
url "https://github.com/coreos/go-etcd.git",
:revision => "73a8ef737e8ea002281a28b4cb92a1de121ad4c6"
end end
# dependency for go-etcd go_resource "github.com/miekg/mmark" do
go_resource "github.com/coreos/etcd" do url "https://github.com/miekg/mmark.git",
url "https://github.com/coreos/etcd.git", :revision => "9dca01c4e2b1ee2b3eab905fbbe8c756b033afc3"
:revision => "b3e6ad136a184afbffd1a803f75955d393c53e21"
end end
go_resource "github.com/mitchellh/mapstructure" do
url "https://github.com/mitchellh/mapstructure.git",
:revision => "281073eb9eb092240d33ef253c404f1cca550309"
end
go_resource "github.com/opennota/urlesc" do
url "https://github.com/opennota/urlesc.git",
:revision => "5fa9ff0392746aeae1c4b37fcc42c65afa7a9587"
end
go_resource "github.com/russross/blackfriday" do
url "https://github.com/russross/blackfriday.git",
:revision => "300106c228d52c8941d4b3de6054a6062a86dda3"
end
go_resource "github.com/shurcooL/sanitized_anchor_name" do
url "https://github.com/shurcooL/sanitized_anchor_name.git",
:revision => "10ef21a441db47d8b13ebcc5fd2310f636973c77"
end
go_resource "github.com/spf13/afero" do
url "https://github.com/spf13/afero.git",
:revision => "0ad340694159e622d71701b0debde0b68ed72f9c"
end
go_resource "github.com/spf13/cast" do
url "https://github.com/spf13/cast.git",
:revision => "ee815aaf958c707ad07547cd62150d973710f747"
end
go_resource "github.com/spf13/cobra" do
url "https://github.com/spf13/cobra.git",
:revision => "1c44ec8d3f1552cac48999f9306da23c4d8a288b"
end
go_resource "github.com/spf13/fsync" do
url "https://github.com/spf13/fsync.git",
:revision => "1a03b59821319ad444dd28ea219e409e2815182e"
end
go_resource "github.com/spf13/jwalterweatherman" do
url "https://github.com/spf13/jwalterweatherman.git",
:revision => "c2aa07df593850a04644d77bb757d002e517a296"
end
go_resource "github.com/spf13/nitro" do
url "https://github.com/spf13/nitro.git",
:revision => "24d7ef30a12da0bdc5e2eb370a79c659ddccf0e8"
end
go_resource "github.com/spf13/pflag" do
url "https://github.com/spf13/pflag.git",
:revision => "08b1a584251b5b62f458943640fc8ebd4d50aaa5"
end
go_resource "github.com/spf13/viper" do
url "https://github.com/spf13/viper.git",
:revision => "e37b56e207dda4d79b9defe0548e960658ee8b6b"
end
go_resource "github.com/yosssi/ace" do
url "https://github.com/yosssi/ace.git",
:revision => "8e090bf0a6119b722012f08062c732d2434fbbb5"
end
go_resource "golang.org/x/text" do
url "https://go.googlesource.com/text.git",
:revision => "e6847002810c51f892a128333573eac5e2a62024"
end
go_resource "gopkg.in/fsnotify.v1" do
url "https://gopkg.in/fsnotify.v1.git",
:revision => "2cdd39bd6129c6a49c74fb07fb9d77ba1271c572"
end
go_resource "gopkg.in/yaml.v2" do
url "https://gopkg.in/yaml.v2.git",
:revision => "53feefa2559fb8dfa8d81baad31be332c97d6c77"
end
def install def install
ENV["GOBIN"] = bin ENV["GOBIN"] = bin
ENV["GOPATH"] = buildpath ENV["GOPATH"] = buildpath
@ -186,8 +178,14 @@ class Hugo < Formula
system "go", "build", "-o", bin/"hugo", "main.go" system "go", "build", "-o", bin/"hugo", "main.go"
system bin/"hugo", "genautocomplete", "--completionfile=#{buildpath}/hugo.sh" # Build bash completion
system bin/"hugo", "gen", "autocomplete", "--completionfile=#{buildpath}/hugo.sh"
bash_completion.install "hugo.sh" bash_completion.install "hugo.sh"
# Build man pages; target dir man/ is hardcoded :(
mkdir_p buildpath/"man/"
system bin/"hugo", "gen", "man"
man1.install Dir["man/*.1"]
end end
test do test do