From ae44476b8faea9a5a098d3f8c91b8908e9cef508 Mon Sep 17 00:00:00 2001 From: ikoamu Date: Thu, 4 Apr 2024 08:48:27 +0900 Subject: support no-timestamp file --- create_notes.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'create_notes.sh') diff --git a/create_notes.sh b/create_notes.sh index 9965593..452230e 100755 --- a/create_notes.sh +++ b/create_notes.sh @@ -9,8 +9,7 @@ jq -c '.data.nodes[]' | while read -r nodes; do id=$(echo "${nodes}" | jq -r '.id') file=$(echo "${nodes}" | jq -r '.file') - timestamp=$(echo "${file}" | cut -d'-' -f1) - matching_file=$(find "${org_path}" -name "${timestamp}-*.org" -type f) + matching_file=$(find "${org_path}" -name "${file}" -type f) if [[ -f "${matching_file}" ]]; then cp -p "${matching_file}" "notes/${id}" -- cgit