set shellcheck directives
This commit is contained in:
parent
7de612553d
commit
d056ba7701
|
@ -1,2 +1,2 @@
|
|||
#!/usr/bin/env bash
|
||||
# shellcheck shell=bash
|
||||
get_id
|
||||
|
|
|
@ -1,3 +1 @@
|
|||
#!/usr/bin/env bash
|
||||
## Code here runs inside the initialize() function
|
||||
## Use it for anything that you need to run before any other function
|
||||
# shellcheck shell=bash
|
|
@ -1,5 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
# log error message to STDERR
|
||||
# shellcheck shell=bash
|
||||
function error() {
|
||||
echo >&2 "[$(date +'%Y-%m-%dT%H:%M:%S')]: ERROR $*"
|
||||
}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
# get CSRF token (introduced in OpenRefine 3.3)
|
||||
# shellcheck shell=bash
|
||||
function get_csrf() {
|
||||
if [[ "${OPENREFINE_CSRF}" == true ]]; then
|
||||
local response
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
# get project id (derived from project name if needed)
|
||||
# shellcheck shell=bash disable=SC2154
|
||||
function get_id() {
|
||||
local response
|
||||
local projects
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
# get all project metadata and reshape json to print a list
|
||||
# shellcheck shell=bash
|
||||
if ! response="$(curl -fs --get "${OPENREFINE_URL}/command/core/get-all-project-metadata")"; then
|
||||
error "no OpenRefine reachable/running at ${OPENREFINE_URL}"
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue