summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormsglm <msglm@techchud.xyz>2023-07-15 05:35:27 -0500
committermsglm <msglm@techchud.xyz>2023-07-15 05:35:27 -0500
commit77d11dc6d1c6aeb37d39ff1db2bed014e9fefa16 (patch)
tree66cad385e5ae5b8bd61cfc0a6c8166760dfa4970
parent4a990b7a0f5c48cf6c7eea7fac31d0640de7d04c (diff)
downloadstashley-1.0.1.tar.gz
stashley-1.0.1.tar.bz2
stashley-1.0.1.zip
wget WARC support addedv1.0.1
-rwxr-xr-xstashley20
1 files changed, 7 insertions, 13 deletions
diff --git a/stashley b/stashley
index 9afce6d..b5c9954 100755
--- a/stashley
+++ b/stashley
@@ -6,15 +6,9 @@ do
if [ "$site" = "youtube" ]
then
yt-dlp --write-info-json --write-description --write-thumbnail --write-annotations --all-subs --ignore-error -f 'bestvideo[height>=720][fps>=60]+bestaudio/bestvideo+bestaudio/best' -o 'YouTube/%(uploader|author)s/%(title)s.%(ext)s' "$url"
- elif [ "$site" = "twitter" ]
+ elif [ "$site" = "website" ]
then
- gallery-dl --write-metadata "$url"
- elif [ "$site" = "instagram" ]
- then
- gallery-dl --write-metadata "$url"
- elif [ "$site" = "toyhouse" ]
- then
- gallery-dl --write-metadata "$url"
+ wget --mirror --warc-file="echo $url|sed -e '//\//slash/g'"
else
gallery-dl --write-metadata "$site":"$url"
fi
@@ -24,16 +18,16 @@ done
fdupes -dIr .
-if [[ ipfs --help == 0 ]]
+if [ "$(ipfs --help)" = 0 ]
then
## Add new content to personality-archive
- personalityName=$(tomlq -r '.name' $1)
+ personalityName=$(tomlq -r '.name' "$1")
ipfs files mkdir /personality-archive
personalityHash=$(ipfs add -Q -r .)
- ipfs files rm -r /personality-archive/$personalityName
- ipfs files cp /ipfs/$personalityHash /personality-archive/$personalityName
+ ipfs files rm -r /personality-archive/"$personalityName"
+ ipfs files cp /ipfs/"$personalityHash" /personality-archive/"$personalityName"
## Update IPNS with new personality-archive
personalityArchiveLocationHash=$(ipfs files stat --hash /personality-archive)
- ipfs name publish $personalityArchiveLocationHash
+ ipfs name publish "$personalityArchiveLocationHash"
fi