diff options
| author | Paul Buetow <paul@buetow.org> | 2023-03-18 13:24:09 +0200 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2023-03-18 13:24:09 +0200 |
| commit | 5f42d3b0b6a42f10b39f4a88ff76c7fda6f2a8e4 (patch) | |
| tree | c368645c8ea935ca9f29d7660ef9e9f8d9eb159f /lib/git.source.sh | |
| parent | db6bd852dc8e4ad8c41b9489261df6de6a4fba43 (diff) | |
add POST_PUBLISH_HOOK
Diffstat (limited to 'lib/git.source.sh')
| -rw-r--r-- | lib/git.source.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/git.source.sh b/lib/git.source.sh index 1a71ade..8048aad 100644 --- a/lib/git.source.sh +++ b/lib/git.source.sh @@ -15,14 +15,14 @@ git::add_all () { git::_content_dirs_in_git | while read -r content_dir; do log INFO "Adding content from $content_dir to git" - git::_add_all "$message" "$content_dir" & + git::_add_all "$message" "$content_dir" done - wait } git::_add_all () { local -r message="$1"; shift local -r content_dir="$1"; shift + local -r pwd="$(pwd)" cd "$content_dir" || log PANIC "Unable to chdir to $content_dir" find . -type f -not -path '*/\.git*' | while read -r file; do @@ -32,7 +32,7 @@ git::_add_all () { local -r format="$(basename "$content_dir")" git commit -a -m "$message for $format" - cd - + cd "$pwd" } git::sync_all () { |
