Improvements for new users.

[UPDATED]   Default submodule to read-only public address.
[ADDED]     Detect when jq is missing and emit a useful message.
[UPDATED]   API submodule update.
This commit is contained in:
Maarten Billemont 2022-02-05 16:59:41 -05:00
parent 15c45ebcac
commit a5e7aab28f
4 changed files with 8 additions and 3 deletions

2
.gitmodules vendored
View file

@ -1,3 +1,3 @@
[submodule "api"]
path = api
url = git@gitlab.com:spectre.app/api.git
url = https://gitlab.com/spectre.app/api.git

View file

@ -43,7 +43,7 @@ Spectre's algorithm and implementation is fully documented and licensed Free Sof
## Components
The source is broken down into several components:
The source is broken down into several components, each hosted in their own repository. Submodules are used to correlate dependencies.
- [api](https://gitlab.com/spectre.app/api): The algorithm's reference implementation and API library. There is a C, Java and W3C interface.
- [cli](https://gitlab.com/spectre.app/cli): The official command-line interface for POSIX systems.

2
api

@ -1 +1 @@
Subproject commit 61bc1b23d37290a23f9250b10aa43cd8d4148e45
Subproject commit 06243e2673ffa4b050c957276d6cb18b0feb981f

View file

@ -69,6 +69,11 @@ spectre_expect() {
done < "$file"
;;
json)
if ! hash jq 2>/dev/null; then
printf >&2 "Error: jq not installed. Please install through your package manager or from https://stedolan.github.io/jq/\n"
exit 1
fi
case $purpose in
a*) result=$(jq -r ".sites.\"$site\".password") ;;
i*) [[ $type && $type != none ]] \