summaryrefslogtreecommitdiff
path: root/save_artifact.sh
diff options
context:
space:
mode:
authorCzarek Nakamoto <cyjan@mrcyjanek.net>2023-12-31 00:05:42 +0100
committerCzarek Nakamoto <cyjan@mrcyjanek.net>2023-12-31 00:05:42 +0100
commitdab29fefff3b2623e6b1f9f16d27cb1e385423c1 (patch)
treebc7c3707e23f344a8c0b610eab80902c1ad3fc06 /save_artifact.sh
parent5b25551b7f347e19266e4bc19983bf50d01f73d9 (diff)
CI: don't push downloaded cache
Diffstat (limited to 'save_artifact.sh')
-rwxr-xr-xsave_artifact.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/save_artifact.sh b/save_artifact.sh
index c28fd37..a58d6d2 100755
--- a/save_artifact.sh
+++ b/save_artifact.sh
@@ -5,6 +5,13 @@ registry_user=mrcyjanek
cache_name="$1"
cache_key="$2"
path_to_file_="$3"
+
+if [[ -f "/tmp/cache_hit_$(echo "$3" | md5sum)" ]];
+then
+ echo "was cached $1 $2 $(basename $path_to_file_)"
+ exit 0
+fi
+
path_to_file="$3.xz"
basename="$(basename $path_to_file)"