Commit 47717542 authored by Vojtech Myslivec's avatar Vojtech Myslivec 🚀

Add possibility to create temp files in cache root

parent cd648a8b
......@@ -60,11 +60,18 @@ cache_init() {
cache_destroy() {
rm -f "$CRYPTO_WRAPPER_ROOT"/key_*
rm -f "$CRYPTO_WRAPPER_ROOT"/hash_*
rm -f "$CRYPTO_WRAPPER_ROOT"/temp_*
[ -d "$CRYPTO_WRAPPER_ROOT" ] && rmdir "$CRYPTO_WRAPPER_ROOT"
return 0
}
# create empty temporary file in cache root
cache_mktemp() {
mktemp "$CRYPTO_WRAPPER_ROOT/temp_XXXXXX"
}
# key should be sha256 hash (HASH_TYPE)
cache_set() {
local key="$1"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment