From 1eea7170f3262e0132e784dd30f9621602d6c3d3 Mon Sep 17 00:00:00 2001 From: Josh Moore Date: Wed, 4 Dec 2024 22:01:41 +0100 Subject: [PATCH] Convert to use of submodules --- .gitmodules | 20 ++++++++++++++++++++ 0.1 | 1 + 0.2 | 1 + 0.3 | 1 + 0.4 | 1 + 0.5 | 1 + Makefile | 5 ----- conf.py | 21 +-------------------- specifications/index.md | 1 - 9 files changed, 26 insertions(+), 26 deletions(-) create mode 100644 .gitmodules create mode 160000 0.1 create mode 160000 0.2 create mode 160000 0.3 create mode 160000 0.4 create mode 160000 0.5 diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 00000000..8f11e937 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,20 @@ +[submodule "0.1"] + path = 0.1 + url = https://github.com/joshmoore/ngff-specifications + branch = 0.1 +[submodule "0.2"] + path = 0.2 + url = https://github.com/joshmoore/ngff-specifications + branch = 0.2 +[submodule "0.3"] + path = 0.3 + url = https://github.com/joshmoore/ngff-specifications + branch = 0.3 +[submodule "0.4"] + path = 0.4 + url = https://github.com/joshmoore/ngff-specifications + branch = 0.4 +[submodule "0.5"] + path = 0.5 + url = https://github.com/joshmoore/ngff-specifications + branch = 0.5 diff --git a/0.1 b/0.1 new file mode 160000 index 00000000..a896990f --- /dev/null +++ b/0.1 @@ -0,0 +1 @@ +Subproject commit a896990fffcdffa844a8113d8cc6f34e354fbe61 diff --git a/0.2 b/0.2 new file mode 160000 index 00000000..52ef8521 --- /dev/null +++ b/0.2 @@ -0,0 +1 @@ +Subproject commit 52ef852122bba505ed6ef130815faea3d766c208 diff --git a/0.3 b/0.3 new file mode 160000 index 00000000..1107cca8 --- /dev/null +++ b/0.3 @@ -0,0 +1 @@ +Subproject commit 1107cca8d9d5dca783786229ff771032de1680f9 diff --git a/0.4 b/0.4 new file mode 160000 index 00000000..3643ec93 --- /dev/null +++ b/0.4 @@ -0,0 +1 @@ +Subproject commit 3643ec93afef70191184a2f0a5465cf85ae41dbf diff --git a/0.5 b/0.5 new file mode 160000 index 00000000..3a49789e --- /dev/null +++ b/0.5 @@ -0,0 +1 @@ +Subproject commit 3a49789eb0f3e8ffe842e1e257af0b80b2a1da8b diff --git a/Makefile b/Makefile index 13d18b31..72426cbc 100644 --- a/Makefile +++ b/Makefile @@ -14,11 +14,6 @@ help: .PHONY: help Makefile clean - -clean: Makefile - rm -rf .cache 0.1 0.2 0.3 0.4 0.5 draft - @$(SPHINXBUILD) -M clean "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - # Catch-all target: route all unknown targets to Sphinx using the new # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). %: Makefile diff --git a/conf.py b/conf.py index f0b80eb2..df98f441 100644 --- a/conf.py +++ b/conf.py @@ -64,26 +64,7 @@ def bikeshed(): import shutil import subprocess - branches = subprocess.check_output( - f"git branch -l v/*", - shell=True, - ).split() - branches = [x.decode("utf-8").strip() for x in branches] - # TODO: generate specifications/index.md - for branch in branches: - version = branch[2:] - os.makedirs(".cache", exist_ok=True) - subprocess.check_call( - #f"git clone --depth=1 --branch v/{version} https://github.com/ome/ngff.git .cache/{version}", - f"git clone --depth=1 --branch {branch} . .cache/{version}", - shell=True, - ) - os.symlink(f".cache/{version}/{version}", f"{version}") - - # TODO: skip this step on a tag - os.symlink("spec", "draft") - - for index_file in ["draft/index.bs"] + glob.glob("[0-9]*/index.bs"): + for index_file in glob.glob("[0-9]*/index.bs"): output_file = index_file.replace("bs", "html") output_dir = os.path.dirname(output_file) target_dir = os.path.join("_bikeshed", output_dir) diff --git a/specifications/index.md b/specifications/index.md index 677e86c8..ee31360f 100644 --- a/specifications/index.md +++ b/specifications/index.md @@ -11,5 +11,4 @@ Version history:
  • 0.3 August 2021
  • 0.4 February 2022
  • 0.5 November 2024
  • -
  • draft