mirror of
https://github.com/opdavies/build-configs.git
synced 2025-01-22 10:17:32 +00:00
Ensure run.local files are located relative to the
...run file Prevent erroring if `run` is being executed within a sub-directory, like `assets`.
This commit is contained in:
parent
ac8246704e
commit
4e255cd667
|
@ -119,7 +119,8 @@ function _run {
|
|||
{% endif %}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
|
@ -159,7 +159,8 @@ function _run {
|
|||
}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
|
@ -35,7 +35,8 @@ function start {
|
|||
}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT="Task completed in %3lR"
|
||||
time "${@:-help}"
|
||||
|
|
|
@ -25,7 +25,8 @@ function help {
|
|||
}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
|
@ -103,12 +103,13 @@ function _run {
|
|||
--entrypoint "${command}" \
|
||||
--no-deps \
|
||||
--rm \
|
||||
${TTY} \
|
||||
"${TTY}" \
|
||||
"${service}" "${@}"
|
||||
}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
|
@ -103,12 +103,13 @@ function _run {
|
|||
--entrypoint "${command}" \
|
||||
--no-deps \
|
||||
--rm \
|
||||
${TTY} \
|
||||
"${TTY}" \
|
||||
"${service}" "${@}"
|
||||
}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
|
@ -121,12 +121,13 @@ function _run {
|
|||
--entrypoint "${command}" \
|
||||
--no-deps \
|
||||
--rm \
|
||||
${TTY} \
|
||||
"${TTY}" \
|
||||
"${service}" "${@}"
|
||||
}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
|
@ -105,7 +105,8 @@ function _run {
|
|||
}
|
||||
|
||||
# Include any local tasks.
|
||||
[[ -e run.local ]] && source run.local
|
||||
# https://stackoverflow.com/a/6659698
|
||||
[[ -e "${BASH_SOURCE%/*}/run.local" ]] && source "${BASH_SOURCE%/*}/run.local"
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
Loading…
Reference in a new issue