tangled
alpha
login
or
join now
zio.sh
/
atfile
37
fork
atom
š¦āš¦ Store and retrieve files on the Atmosphere
37
fork
atom
overview
issues
3
pulls
pipelines
ignore shellcheck issues
ducky.ws
5 months ago
8e95fe69
e2eec51e
1/1
build.yaml
success
7s
+4
1 changed file
expand all
collapse all
unified
split
src
commands
handle.sh
+4
src/commands/handle.sh
reviewed
···
22
22
fi
23
23
}
24
24
25
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
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
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
47
+
# shellcheck disable=SC2154
44
48
if [[ $_os == "linux"* ]] && \
45
49
[ -x "$(command -v xdg-mime)" ] && \
46
50
[ -x "$(command -v xdg-open)" ] && \