Restructure the repository per session
session1/ now holds the whole live lab (content, platforms, docs, answer key, README); session2/ keeps the design for the second workshop. The root README indexes both and states that session2 modifies session1 rather than duplicating it. build-bundle.sh builds from session1 and still produces a flat archive, so the documented paths inside a deployment (platforms/<p>/lab.sh) are unchanged. .gitignore follows the move.
This commit is contained in:
+3
-2
@@ -13,6 +13,7 @@ set -euo pipefail
|
||||
ROOT=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd -P)
|
||||
TARGET=${1:-all}
|
||||
OUT=${2:-$ROOT/dist}
|
||||
SRC="$ROOT/session1"
|
||||
|
||||
info() { printf '[*] %s\n' "$*"; }
|
||||
ok() { printf '[ok] %s\n' "$*"; }
|
||||
@@ -22,14 +23,14 @@ build() {
|
||||
local stage="$OUT/norbourg-$platform"
|
||||
local archive="$OUT/norbourg-$platform.tar.gz"
|
||||
|
||||
[[ -d $ROOT/platforms/$platform ]] || { echo "no such platform: $platform" >&2; return 1; }
|
||||
[[ -d $SRC/platforms/$platform ]] || { echo "no such platform in session1: $platform" >&2; return 1; }
|
||||
|
||||
rm -rf "$stage"
|
||||
mkdir -p "$stage"
|
||||
|
||||
# Shared content + one platform + docs + answers. Generated and transient
|
||||
# paths are excluded: they are rebuilt by the host's own commands.
|
||||
tar -C "$ROOT" -cf - \
|
||||
tar -C "$SRC" -cf - \
|
||||
--exclude='.git' \
|
||||
--exclude='__pycache__' \
|
||||
--exclude='*.pyc' \
|
||||
|
||||
Reference in New Issue
Block a user