Last active
May 13, 2019 09:17
-
-
Save vjrj/772c5149d1e07d91041b260851401ef3 to your computer and use it in GitHub Desktop.
An small script to format a row for LA Node Components
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Sample usage: | |
# $ la-components-table-row.sh "Elurikkus - Estonia" https://elurikkus.ee/en https://elurikkus.ee/en/collections/ https://elurikkus.ee/generic-hub/ https://elurikkus.ee/biocache-service/ https://elurikkus.ee/bie-hub/ https://elurikkus.ee/bie-index/ https://elurikkus.ee/lists/ https://elurikkus.ee/regions/ | |
# to get: | |
# | [Elurikkus - Estonia](https://elurikkus.ee/en) | [✓](https://elurikkus.ee/en/collections/) | [✓](https://elurikkus.ee/generic-hub/) | [✓](https://elurikkus.ee/biocache-service/) | [✓](https://elurikkus.ee/bie-hub/) | [✓](https://elurikkus.ee/bie-index/) | [✓](https://elurikkus.ee/lists/) | [✓](https://elurikkus.ee/regions/) | | |
# Order: | |
# | NodeName | Collectory | Biocache | BiocacheService | Species | SpeciesService | SpeciesLists | Regions | Images | Spatial | CAS | Sightings | Alerts | Volunteer | | |
function p { | |
if [[ $1 != "x" ]] ; then echo -n "| [✓]($1) " ; else echo -n "| "; fi | |
} | |
echo -n "| [$1]($2) "; for var in "${@:3}" ; do p $var; done; echo "|" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment