šŸ“¦āž”šŸ¦‹ Store and retrieve files on the Atmosphere

ignore shellcheck issues

+4
+4
src/commands/handle.sh
··· 22 22 fi 23 23 } 24 24 25 + # shellcheck disable=SC2154 25 26 [[ $_output_json == 1 ]] && atfile.die "Command not available as JSON" 26 27 27 28 actor="$(echo "$uri" | cut -d "/" -f 3)" 28 29 key="$(echo "$uri" | cut -d "/" -f 4)" 29 30 31 + # shellcheck disable=SC2154 30 32 atfile.util.create_dir "$_path_blobs_tmp" 31 33 32 34 if [[ -n "$actor" && -n "$key" ]]; then 33 35 atfile.util.override_actor "$actor" 34 36 37 + # shellcheck disable=SC2154 35 38 atfile.say.debug "Getting record...\n↳ NSID: $_nsid_upload\n↳ Repo: $_username\n↳ Key: $key" 36 39 record="$(com.atproto.repo.getRecord "$_username" "$_nsid_upload" "$key")" 37 40 error="$(atfile.util.get_xrpc_error $? "$record")" ··· 41 44 blob_uri="$(atfile.util.build_blob_uri "$_username" "$blob_cid")" 42 45 file_type="$(echo "$record" | jq -r '.value.file.mimeType')" 43 46 47 + # shellcheck disable=SC2154 44 48 if [[ $_os == "linux"* ]] && \ 45 49 [ -x "$(command -v xdg-mime)" ] && \ 46 50 [ -x "$(command -v xdg-open)" ] && \