Update compiling scripts <noupdate>

This commit is contained in:
2024-04-21 15:44:20 +02:00
parent 71b973ff63
commit 63f2aa68fb
3 changed files with 8 additions and 7 deletions

View File

@ -37,7 +37,7 @@ jobs:
- name: Compile - name: Compile
run: | run: |
bash ./compile.sh .compiled .currpdfs bash ./utils/compile.sh src .compiled .currpdfs
- name: Generate README - name: Generate README
run: | run: |

View File

@ -2,8 +2,9 @@
# #
# Commit based .tex compiling # Commit based .tex compiling
# $1 is the output directory. # $1 is the source directory.
# $2 is the directory of the current state of the files. # $2 is the output directory.
# $3 is the directory of the current state of the files.
# #
if [ $# -eq 0 ]; then if [ $# -eq 0 ]; then
@ -13,11 +14,11 @@ fi
shopt -s globstar extglob shopt -s globstar extglob
out_dir=`realpath $1` out_dir=`realpath $2`
old_out_dir=`realpath $2` old_out_dir=`realpath $3`
hash_file="$old_out_dir/.hash" hash_file="$old_out_dir/.hash"
new_hash_file="$out_dir/.hash" new_hash_file="$out_dir/.hash"
work_dir=`realpath src` work_dir=`realpath $1`
mkdir -p $out_dir mkdir -p $out_dir
touch $hash_file touch $hash_file

View File

@ -20,7 +20,7 @@ if __name__ == "__main__":
if METADATA_FILENAME in files: if METADATA_FILENAME in files:
with open(os.path.join(root, METADATA_FILENAME)) as f: with open(os.path.join(root, METADATA_FILENAME)) as f:
metadata = json.load(f) metadata = json.load(f)
dir_name = pathlib.PurePath(root).name dir_name = os.path.relpath(root, args.src_path)
gh_path = os.path.join(args.gh_link, dir_name) gh_path = os.path.join(args.gh_link, dir_name)
if metadata["year"] not in notes_metadata: notes_metadata[metadata["year"]] = {} if metadata["year"] not in notes_metadata: notes_metadata[metadata["year"]] = {}