From c39d05da76d42e61f845675e06b2c03ee1cda561 Mon Sep 17 00:00:00 2001 From: Dylan Lloyd Date: Tue, 12 Sep 2023 15:57:53 -0400 Subject: [PATCH 1/1] simplify submodule management --- .gitmodules | 7 +++++-- Makefile | 14 +++++++------- _config.yml | 4 ++++ mud => mudd | 0 resume | 1 + update-submodules.sh | 7 +++++++ 6 files changed, 24 insertions(+), 9 deletions(-) rename mud => mudd (100%) create mode 160000 resume create mode 100755 update-submodules.sh diff --git a/.gitmodules b/.gitmodules index e9f38f6..f9ecace 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,8 +1,8 @@ [submodule "cellular-automata"] path = cellular-automata url = git@disinclined.org:cellular-automaton.git -[submodule "mud"] - path = mud +[submodule "mudd"] + path = mudd url = git@disinclined.org:mudd.git [submodule "minimax"] path = minimax @@ -10,3 +10,6 @@ [submodule "git"] path = git url = git@disinclined.org:gitweb +[submodule "resume"] + path = resume + url = git@disinclined.org:resume diff --git a/Makefile b/Makefile index bd6c107..325500c 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,14 @@ -default: site +default: build +all: update build -hostname = disinclined.org sitename = disinclined.org +hostname = disinclined.org + +update: + ./update-submodules.sh build site: - git submodule update - cp ~/src/resume/resume.{pdf,html} . + cp resume/resume.{pdf,html} . bundle exec jekyll build -d $(sitename) --trace serve: @@ -20,6 +23,3 @@ deploy: ssh -t $(hostname) tar -xf $(sitename).tgz ssh -t $(hostname) sudo rsync -a ~dylan/$(sitename) /srv/http/ rm $(sitename).tgz - -fix-git-permissions: - ssh -t $(hostname) sudo -u git /var/lib/gitolite3/update-permissions diff --git a/_config.yml b/_config.yml index 38d3751..1053f22 100644 --- a/_config.yml +++ b/_config.yml @@ -17,3 +17,7 @@ jekyll-archives: defaults: values: layout: default + +exclude: + - resume/ + - update-submodules.sh diff --git a/mud b/mudd similarity index 100% rename from mud rename to mudd diff --git a/resume b/resume new file mode 160000 index 0000000..404fa38 --- /dev/null +++ b/resume @@ -0,0 +1 @@ +Subproject commit 404fa38d7df2ef00644f47826e784de543541d67 diff --git a/update-submodules.sh b/update-submodules.sh new file mode 100755 index 0000000..cff896c --- /dev/null +++ b/update-submodules.sh @@ -0,0 +1,7 @@ +#!/usr/bin/env bash + + +eval "$(ssh-agent -s)" +ssh-add ~/.ssh/id_rsa +git submodule update --remote +eval "$(ssh-agent -k)" -- 2.30.2