Skip to content
Snippets Groups Projects
Commit a37fa305 authored by Nikolaos Kakouros's avatar Nikolaos Kakouros
Browse files

wip

parent f8c79667
No related branches found
No related tags found
No related merge requests found
......@@ -50,12 +50,6 @@ cd "$PROJECT_DIR"
. "$_HEADSTART_CORE_DIR/headstart-load-libs.bash" "$@" \
"${_HEADSTART_CORE_DIR#$PROJECT_DIR/}/"{commands,}
tmp_dir="${_HEADSTART_SCRIPT_NAME~~}_TMP_DIR"
declare -gx _HEADSTART_TMP_DIR="${!tmp_dir}"
declare -gx _HEADSTART_VENDOR_DIR="${_HEADSTART_CORE_DIR}/vendor"
declare -gx HEADSTART_RESOURCES_DIR="${HEADSTART_RESOURCES_DIR-resources}"
declare -gx _HEADSTART_CMD="${_GO_CMD##*/}"
declare -gx _HEADSTART_PROJECT_CONFIG="${HEADSTART_PROJECT_CONFIG-data/config/project.conf}"
declare -gx _HEADSTART_CORE_LOCK="${HEADSTART_CORE_LOCK-data/config/.core.lock}"
......@@ -64,9 +58,17 @@ declare -x _GO_HELP_HIJACK=true
declare -x GO_TAB_COMPLETIONS_PATTERN=''
. "$_GO_USE_MODULES" 'core'
core_get_installed_version
core_parse_project_config
function headstart_bootstrap() {
tmp_dir="${_HEADSTART_SCRIPT_NAME~~}_TMP_DIR"
declare -gx _HEADSTART_TMP_DIR="${!tmp_dir}"
declare -gx _HEADSTART_VENDOR_DIR="${_HEADSTART_CORE_DIR}/vendor"
declare -gx HEADSTART_RESOURCES_DIR="${HEADSTART_RESOURCES_DIR-resources}"
core_parse_project_config
}
function headstart() {
local trace=false
......@@ -137,7 +139,6 @@ function headstart() {
. "$_GO_USE_MODULES" 'system'
set_standard_outputs
set_trace "$debug"
set_debug_levels "$verbosity"
unset verbosity
......
......@@ -127,7 +127,7 @@ function abort() {
function warn() {
@required [string] message
COLUMNS=91 @go.printf "${UI_Color_Magenta}Warning: %b%s${UI_Color_Default}\n" "$message" >&"${STDERR}"
COLUMNS=100 @go.printf "${UI_Color_Magenta}Warning: %b%s${UI_Color_Default}\n" "$message" >&"${STDERR}"
}
function set_standard_outputs() {
......@@ -147,7 +147,7 @@ function set_standard_outputs() {
exec 9>&2
exec 1>&2
if [ "$debug" = ffffalse ]; then
if [[ "${debug-false}" == ffffalse ]]; then
# We do not want to output every command run in the scripts to the screen.
# We only want to do that if the user requested it for debugging purposes.
# Otherwise, we need to output only informational text with the `info`
......@@ -168,3 +168,5 @@ function color_stderr() {
@required [string] command
"$@" 2> >(while read line; do echo -e "\e[01;31merror: $line\e[0m" >&2; done)
}
set_standard_outputs
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment