[latex3-commits] [git/LaTeX3-latex3-graphics-def] develop: Set up for development branch releases (79cc11c)

Joseph Wright joseph.wright at morningstar2.co.uk
Thu Jan 7 15:42:12 CET 2021


Repository : https://github.com/latex3/graphics-def
On branch  : develop
Link       : https://github.com/latex3/graphics-def/commit/79cc11cb0db907bb7deeecae03680c76ff0ab3a1

>---------------------------------------------------------------

commit 79cc11cb0db907bb7deeecae03680c76ff0ab3a1
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Thu Jan 7 14:42:12 2021 +0000

    Set up for development branch releases


>---------------------------------------------------------------

79cc11cb0db907bb7deeecae03680c76ff0ab3a1
 build.lua | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/build.lua b/build.lua
index c2bc17e..2bad946 100644
--- a/build.lua
+++ b/build.lua
@@ -22,6 +22,31 @@ specialformats["latex-dev"] = specialformats["latex-dev"] or
      luatex = {binary="luahbtex",format = "lualatex-dev"}
   }
 
+-- Allow for 'dev' release
+--
+-- See stackoverflow.com/a/12142066/212001
+-- Also luaotfload build.lua: getting the Travis-CI version right is 'fun'
+do
+  local tag = os.getenv'TRAVIS_TAG'
+  if tag and tag ~= "" then
+    master_branch = not string.match(tag, '^dev-')
+  else
+    local branch = os.getenv'TRAVIS_BRANCH'
+    if not branch then
+      local f = io.popen'git rev-parse --abbrev-ref HEAD'
+      branch = f:read'*a':sub(1,-2)
+      assert(f:close())
+    end
+    master_branch = string.match(branch, '^master')
+  end
+  if not master_branch then
+    tdsroot = "latex-dev"
+    print("Creating/installing dev-version in " .. tdsroot)
+    ctanpkg = "graphics-def-dev"
+    ctanzip = ctanpkg
+  end
+end
+
 -- Find and run the build system
 kpse.set_program_name ("kpsewhich")
 if not release_date then





More information about the latex3-commits mailing list.