From 10b305d4d8d1b29fb5b9df4cb23151b3eb722187 Mon Sep 17 00:00:00 2001 From: "Jason P. Scharf" Date: Sat, 28 Oct 2017 10:33:24 -0400 Subject: [PATCH] Fix for 'no such file' by using version variable (#22) * Fix for 'no such file' - Used version variable in the url and install paths for stable --- gitea.rb | 6 +++--- lgtm.rb | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/gitea.rb b/gitea.rb index 181ff5d..725bcd4 100644 --- a/gitea.rb +++ b/gitea.rb @@ -5,9 +5,9 @@ class Gitea < Formula head "https://github.com/go-gitea/gitea.git" stable do - url "https://dl.gitea.io/gitea/1.2.1/gitea-1.2.1-darwin-10.6-amd64" - sha256 `curl -s https://dl.gitea.io/gitea/1.2.1/gitea-1.2.1-darwin-10.6-amd64.sha256`.split(" ").first version "1.2.1" + url "https://dl.gitea.io/gitea/#{version}/gitea-#{version}-darwin-10.6-amd64" + sha256 `curl -s https://dl.gitea.io/gitea/#{version}/gitea-#{version}-darwin-10.6-amd64.sha256`.split(" ").first end devel do @@ -43,7 +43,7 @@ class Gitea < Formula when build.devel? bin.install "#{buildpath}/gitea-master-darwin-10.6-amd64" => "gitea" else - bin.install "#{buildpath}/gitea-1.1.4-darwin-10.6-amd64" => "gitea" + bin.install "#{buildpath}/gitea-#{version}-darwin-10.6-amd64" => "gitea" end end end diff --git a/lgtm.rb b/lgtm.rb index 0c66706..1d78c1f 100644 --- a/lgtm.rb +++ b/lgtm.rb @@ -5,9 +5,9 @@ class Lgtm < Formula head "https://github.com/go-gitea/lgtm.git" stable do - url "https://dl.gitea.io/lgtm/1.0.0/lgtm-1.0.0-darwin-10.6-amd64" - sha256 `curl -s https://dl.gitea.io/lgtm/1.0.0/lgtm-1.0.0-darwin-10.6-amd64.sha256`.split(" ").first version "1.0.0" + url "https://dl.gitea.io/lgtm/#{version}/lgtm-#{version}-darwin-10.6-amd64" + sha256 `curl -s https://dl.gitea.io/lgtm/#{version}/lgtm-#{version}-darwin-10.6-amd64.sha256`.split(" ").first end devel do @@ -43,7 +43,7 @@ class Lgtm < Formula when build.devel? bin.install "#{buildpath}/lgtm-master-darwin-10.6-amd64" => "lgtm" else - bin.install "#{buildpath}/lgtm-1.0.0-darwin-10.6-amd64" => "lgtm" + bin.install "#{buildpath}/lgtm-#{version}-darwin-10.6-amd64" => "lgtm" end end end