mirror of
https://github.com/lutris/lutris
synced 2024-10-14 11:42:36 +00:00
install script json schema
This commit is contained in:
parent
5a56b1cc2f
commit
ba02405eb2
|
@ -1,8 +1,14 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
SELF_DIR="$(dirname "$0")"
|
SELF_DIR="$(dirname "$0")"
|
||||||
|
if [[ -z "$1" ]]; then
|
||||||
curl -d "$(cat "$SELF_DIR/installer.schema.yml")" \
|
echo "ERROR: No YAML file passed in!"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
base="$(basename "$1")"
|
||||||
|
target="${base%.*}.json"
|
||||||
|
echo "INFO: $1 > $target"
|
||||||
|
curl -d "$(cat "$SELF_DIR/$1")" \
|
||||||
-H "Content-Type: text/plain" \
|
-H "Content-Type: text/plain" \
|
||||||
-H 'Accept: application/json' \
|
-H 'Accept: application/json' \
|
||||||
-o "$SELF_DIR/installer.schema.json" \
|
-o "$SELF_DIR/$target" \
|
||||||
https://www.anyjson.in/api/v2/data/yamltojson
|
https://www.anyjson.in/api/v2/data/yamltojson &> /dev/null
|
||||||
|
|
Loading…
Reference in a new issue