From 844df73c8fa8440e657f7900ec89cdedb7c4c312 Mon Sep 17 00:00:00 2001 From: Jim Myhrberg Date: Sun, 25 Apr 2021 23:04:03 +0100 Subject: [PATCH] fix(cli): correctly default to master branch if no git ref is given Previously it would build master, but not include "master" in the final output archive's file name. --- build-emacs-for-macos | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build-emacs-for-macos b/build-emacs-for-macos index 4ca5b68..7b3b667 100755 --- a/build-emacs-for-macos +++ b/build-emacs-for-macos @@ -81,7 +81,7 @@ class Build def initialize(root_dir, ref = nil, options = {}) @root_dir = root_dir - @ref = ref + @ref = ref || 'master' @options = options @gcc_info = GccInfo.new end @@ -402,7 +402,7 @@ class Build def meta return @meta if @meta - ref_sha = options[:git_sha] || ref || 'master' + ref_sha = options[:git_sha] || ref info "Fetching info for git ref: #{ref_sha}" url = format(LATEST_URL, ref_sha) commit_json = http_get(url)