diff options
author | Přemysl Eric Janouch <p@janouch.name> | 2023-12-13 09:33:47 +0100 |
---|---|---|
committer | Přemysl Eric Janouch <p@janouch.name> | 2023-12-13 11:56:27 +0100 |
commit | f144006daea838f3095880444d48e2941447e4e7 (patch) | |
tree | 00d6ced5702337e55063a32fdaf7e4c04d9348f8 /test.sh | |
parent | 286b43d1733e00c49e6246669896cde0340f990b (diff) | |
download | gallery-f144006daea838f3095880444d48e2941447e4e7.tar.gz gallery-f144006daea838f3095880444d48e2941447e4e7.tar.xz gallery-f144006daea838f3095880444d48e2941447e4e7.zip |
Add some API methods
Diffstat (limited to 'test.sh')
-rwxr-xr-x | test.sh | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -5,7 +5,21 @@ rm -rf $target $input mkdir -p $target cp -ra $HOME/Pictures/Anime $input + ./gallery init $target ./gallery import $target $input ./gallery thumbnail $target ./gallery dhash $target $HOME/Projects/fiv/build/hash +./gallery tag $target autotagger "DanBooru autotagger" \ + < ../build-db/autotagger.tsv + +./gallery run $target :8080 & +web=$! + +echo '{"path":"/tmp/Gi"}' | \ +curl http://localhost:8080/api/browse -X POST --data-binary @- +echo '{"sha1":"d53fc82162fd19a6e7b92b401b08b7505dbf3dfd"}' | \ +curl http://localhost:8080/api/info -X POST --data-binary @- + +kill $web +wait $web |