readme formating

This commit is contained in:
bux 2022-03-27 01:56:30 +01:00
parent a7204e17a2
commit 5fa192909f

View File

@ -27,13 +27,13 @@ scene rls name > parse > artist / title / year as .tsv > search discogs > .json
# usage # usage
parse rls name as tab separated values parse rls name as tab separated values
``` ```sh
$ echo 'Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC' | ./parse-rls.fish | column -t -s "$(printf '\t')" $ echo 'Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC' | ./parse-rls.fish | column -t -s "$(printf '\t')"
Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC Kraftwerk Autobahn CD Remastered 2009 Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC Kraftwerk Autobahn CD Remastered 2009
``` ```
parse rls name as json parse rls name as json
``` ```sh
$ echo 'Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC' | ./parse-rls.fish -j | jq . $ echo 'Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC' | ./parse-rls.fish -j | jq .
{ {
"artist": "Kraftwerk", "artist": "Kraftwerk",
@ -48,18 +48,18 @@ $ echo 'Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC' | ./parse-rls.fish -j |
``` ```
parse rls name, search local ElasticSearch, output discogs ids parse rls name, search local ElasticSearch, output discogs ids
``` ```sh
$ echo 'Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC' | ./parse-rls.fish | ./search-discogs-elastic.fish | ./out-ids.jq $ echo 'Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC' | ./parse-rls.fish | ./search-discogs-elastic.fish | ./out-ids.jq
{"artist_id":4654,"master_id":2994,"release_id":1966322,"rls":"Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC"} {"artist_id":4654,"master_id":2994,"release_id":1966322,"rls":"Kraftwerk-Autobahn-Remastered-CD-FLAC-2009-BCC"}
``` ```
get rls names from websocket, parse rls name, search with api.discogs.com, write .json get rls names from websocket, parse rls name, search with api.discogs.com, write .json
``` ```sh
$ ./in-ws-predb.ovh.sh | ./parse-rls.fish | search-discogs-api.fish > out.api.json $ ./in-ws-predb.ovh.sh | ./parse-rls.fish | search-discogs-api.fish > out.api.json
``` ```
parse rls name, search local ElasticSearch, write json, filter empty results and convert json to tsv, fallback search with Discogs API, write json parse rls name, search local ElasticSearch, write json, filter empty results and convert json to tsv, fallback search with Discogs API, write json
``` ```sh
$ echo 'Band_Of_Horses-Things_Are_Great-CD-2022-FATHEAD' | ./parse-rls.fish | ./search-discogs-elastic.fish | tee out.es.json | ./out-fallback.jq | ./search-discogs-api.fish > out.api.json $ echo 'Band_Of_Horses-Things_Are_Great-CD-2022-FATHEAD' | ./parse-rls.fish | ./search-discogs-elastic.fish | tee out.es.json | ./out-fallback.jq | ./search-discogs-api.fish > out.api.json
$ jq ._search_result_count out.es.json out.api.json $ jq ._search_result_count out.es.json out.api.json
0 0