Track CaSILE refactoring of init process

parent 6d7ff8de
......@@ -8,6 +8,7 @@ variables:
MAKEFLAGS: --output-sync=target
- make init
- test -n "${CI_COMMIT_TAG}" || make update_toolkits
- make debug
......@@ -53,35 +53,22 @@ SILE = /home/caleb/projects/sile/sile
$(call prepend,SILEPATH,/home/caleb/projects/sile/ )
# CI runners need help getting the branch name because of funky checkouts
BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
ifeq ($(BRANCH),HEAD)
ifeq ($(shell git rev-parse master),$(shell git rev-parse HEAD))
BRANCH = master
# CaSILE only includes actual tags, for VC output we want fancy branch names treated as if tagged
ALLTAGS := $(strip $(CI_COMMIT_TAG) $(shell git tag --points-at HEAD | xargs echo) $(and $(findstring /,$(BRANCH)),$(BRANCH)))
# If this commit is tagged or an a special branch, run special rules for it
ALLTAGS := $(strip $(shell git tag --points-at HEAD | xargs echo) $(and $(findstring /,$(BRANCH)),$(BRANCH)))
ifneq ($(ALLTAGS),)
DIFF = false
# Use first segment of tags as target names (sort is to deduplicate)
TARGETS = $(sort $(subst /,,$(dir $(ALLTAGS))))
# Use last segment of tag names as formats
FORMATS = $(sort $(notdir $(ALLTAGS)))
TAGNAME = $(firstword $(sort $(notdir $(ALLTAGS))))
FORMATS := $(sort $(notdir $(ALLTAGS)))
TAGNAME := $(firstword $(FORMATS))
# Else not directly on any tags
# If not on a tagged release, don't stick with pinned toolkit versions
init: update_toolkits
# If we are not on the master branch, guess the parent and output to a directory
ifneq ($(BRANCH),master)
PARENT ?= $(shell git merge-base master $(BRANCH))
......@@ -162,7 +149,7 @@ $(UPDATATAGTARGETS): update_%_tags:
git tag $$tag
init: init_avadanlik
init_toolkits: init_avadanlik
.PHONY: init_avadanlik
init_avadanlik: time_warp_avadanlik $(AVADANLIKDIR)/yarn.lock $(OUTPUTDIR)
......@@ -176,12 +163,12 @@ update_toolkits: update_avadanlik
update_avadanlik: init_avadanlik
git submodule update --init --remote -- $(AVADANLIKDIR)
$(call time_warp,$(AVADANLIKDIR))
cd $(AVADANLIKDIR) && yarn upgrade
cd $(AVADANLIKDIR) && yarn install
time_warp: time_warp_avadanlik
.PHONY: time_warp_avadanlik
time_warp_avadanlik: init_avadanlik
$(call time_warp,$(AVADANLIKDIR))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment