From: Siraaj Khandkar Date: Sat, 22 Apr 2023 23:21:24 +0000 (-0400) Subject: Switch experiment README to .md X-Git-Url: https://git.xandkar.net/?p=khome.git;a=commitdiff_plain;h=3452aeb7711351462e333efd9610fad5795472f4 Switch experiment README to .md and a title marked with a line of =s instead of leading the #. --- diff --git a/home/bin/x b/home/bin/x index 1b04be6..1687114 100755 --- a/home/bin/x +++ b/home/bin/x @@ -2,12 +2,15 @@ set -e; +README='README.md' + name=$(echo "$@" | sed 's/\s\+/-/g'); timestamp=$(date +'%F--%H-%M-%S'); directory="$HOME/x/$timestamp--$name"; mkdir -p "$directory"; cd "$directory"; -printf '# %s\n' "$name" > README; +printf '%s\n' "$name" > "$README"; +seq 80 | xargs | sed -E 's/\s*[0-9]+\s*/=/g' >> "$README" git init >&2 git commit --allow-empty -m 'Root commit' >&2 git add . >&2