[Cryptech-Commits] [releng/alpha] branch ksng updated: Minor tweaks to branch-based package conflict hacks.

git at cryptech.is git at cryptech.is
Wed Dec 14 22:28:08 UTC 2016


This is an automated email from the git hooks/post-receive script.

sra at hactrn.net pushed a commit to branch ksng
in repository releng/alpha.

The following commit(s) were added to refs/heads/ksng by this push:
     new 05b269a  Minor tweaks to branch-based package conflict hacks.
     new 0da2ab1  Merge branch 'master' into ksng.
05b269a is described below

commit 05b269a88a47d3f9cb3d22d1d638cdff8f012da5
Author: Rob Austein <sra at hactrn.net>
AuthorDate: Wed Dec 14 17:21:51 2016 -0500

    Minor tweaks to branch-based package conflict hacks.
    
    Get conflict indentation right in generated Homebrew formula.
    
    Consider remote branches as well as local ones when constructing
    conflict list, so that we don't omit a conflicting package just
    because we've never checked it out in this build tree.
---
 Makefile                          | 2 +-
 scripts/build-homebrew-formula.py | 5 ++++-
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile
index 3d4fde2..d3318e9 100644
--- a/Makefile
+++ b/Makefile
@@ -16,7 +16,7 @@ PACKAGE_BASE_VERSION := 2.0
 
 GIT_VERSION	 := $(shell git show -s --format=%ct HEAD)
 GIT_BRANCH	 := $(shell git rev-parse --abbrev-ref HEAD)
-GIT_BRANCHES	 := $(notdir $(shell git for-each-ref --format '%(refname)' refs/heads/))
+GIT_BRANCHES	 := $(filter-out HEAD,$(sort $(notdir $(shell git for-each-ref --format '%(refname)' refs/heads/ refs/remotes/))))
 
 # Make voodoo: construct the package name, version number, and list of
 # other package names (constructed on other branches) with which this
diff --git a/scripts/build-homebrew-formula.py b/scripts/build-homebrew-formula.py
index 6d43b45..f2f1f54 100755
--- a/scripts/build-homebrew-formula.py
+++ b/scripts/build-homebrew-formula.py
@@ -92,8 +92,11 @@ end
 with open(args.tarball, "rb") as f:
     digest = hashlib.sha256(f.read()).hexdigest()
 
+conflicts = "".join("  conflicts_with \"{}\", :because => \"firmware and pkcs11 library must match\"\n".format(i)
+                    for i in args.conflicts)
+
 args.formula.write(template.format(
     version   = args.version,
     url       = os.path.join(args.url_base, os.path.basename(args.tarball)),
     sha256    = digest,
-    conflicts = "".join("conflicts_with \"{}\", :because => \"firmware and pkcs11 library must match\"\n".format(i) for i in args.conflicts)))
+    conflicts = conflicts))

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Commits mailing list