diff options
author | Erich Eckner <git@eckner.net> | 2022-09-13 22:52:20 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2022-09-13 22:52:20 +0200 |
commit | b8216f6dd92c288beaee2252e81efabfc3fd983e (patch) | |
tree | 9cbedcaf6407b8c5c29b8ee97658ad8f3adcfebb | |
parent | 037dda12bc82dad91fc6b76f0a811028b026c33e (diff) | |
download | airgapd-b8216f6dd92c288beaee2252e81efabfc3fd983e.tar.xz |
bin/curl: remove old wishes
-rwxr-xr-x | bin/curl | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -28,6 +28,12 @@ fi if [ -s "${work_dir}/files/${url}" ]; then cp "${work_dir}/files/${url}" "${file}" + if [ -s "${work_dir}/wishlist" ]; then + grep -vxF "${url}" "${work_dir}/wishlist" \ + | sponge "${work_dir}/wishlist" + git -C "${work_dir}" add 'wishlist' + git -C "${work_dir}" commit 'wishlist' -m 'removed old wish' + fi exit fi @@ -40,4 +46,4 @@ fi | sponge "${work_dir}/wishlist" git -C "${work_dir}" add 'wishlist' -git -C "${work_dir}" commit -m 'new wishes' +git -C "${work_dir}" commit 'wishlist' -m 'new wishes' |