Zesk Build Environment Variables
Zesk Build supports environment variables and certain patterns around their usage to assist in documentation and proper usage.
None of these are a requirement unless you use buildEnvironmentLoad or buildEnvironmentGet to access environment
variables or a tool which uses these functions.
The primary pattern is to place environment variables (if you override the default, for example), in:
./bin/env/VARIABLE_NAME.sh
Where VARIABLE_NAME is the name of your environment variable. buildEnvironmentAdd does this for you if you want.
Also buildEnvironmentNames shows all known names within the current application scope.
You can document your environment variables automatically using Type: and a description using comments and the
standard Zesk Build bash comment syntax of # Name: value
So an example environment file is:
#!/usr/bin/env bash
# Type: String
# Category: Documentation
# ID of CloudFront provider for web site, for invalidation
export DOCUMENTATION_CLOUDFRONT_ID
DOCUMENTATION_CLOUDFRONT_ID="${DOCUMENTATION_CLOUDFRONT_ID-}"
The values for Type: match standard types. The Category: simply places the variable in that
documentation
category. The behavior here is to set the environment variable to blank unless it is set already. Most project
environment variables will follow this pattern unless they are derived from other environment variables and the idea is
that this value should come from, you know, the environment.
The exception to this is derived values (based on another environment variable) or values which can be computed easily.
It's important to avoid side effects in the environment loader file unless you are strict about access to the
environment variable solely through the buildEnvironmentLoad and
buildEnvironmentGet calls as it is NOT a requirement to accessing
environment variables, rather a convenience.
Environment variables documented using this scheme can generate their own documentation, and the Type: can be used to
validate environment variables by other tools.
Note that most environment variables will simply inherit the already-set value (as shown in the example above), except
in cases where it more of a project configuration such as APPLICATION_NAME or APPLICATION_JSON — which
tends to be a fixed value.
Project configuration variables:
APPLICATION_NAME,APPLICATION_JSON,APPLICATION_JSON_PREFIX,BUILD_HOOK_EXTENSIONS,APPLICATION_CODE_EXTENSIONS,APPLICATION_CODE
See also:
Amazon Web Services
AWS_ACCESS_KEY_DATE— AWS Access Key Issue Date Date. Date of key expiration which can be checked in pipelines. notesAWS_ACCESS_KEY_ID— AWS Access Key String. Amazon Web Services IAM Identity notesAWS_PROFILE— AWS Profile String. Default profile for Amazon Web Services notesAWS_REGION— AWS Region String. Region for Amazon Web Services notesAWS_SECRET_ACCESS_KEY— AWS Secret Access Key Secret. Private Secret Password for AWS notes
Application
APPLICATION_CODE— Application Code Name String. This is the unique code name of the application. Use notesAPPLICATION_CODE_EXTENSIONS— Application Code File Extension List ColonDelimitedList. List of extensions for code in the application. Required. notesAPPLICATION_CODE_IGNORE— Application Code Ignore Paths ColonDelimitedList. List of path names to ignore for application code. (e.g. notesAPPLICATION_JSON— Application JSON File ApplicationFile. Path to the application configuration JSON notesAPPLICATION_JSON_PREFIX— Application JSON Prefix String. Prefix to place we can store things in the JSON notesAPPLICATION_NAME— Application Name String. This is the display name of the application notesAPPLICATION_OWNER— Application Legal Owner String. The entity which owns or manages the application. Typically the notesBUILD_COMPANY— Company Name String. Legal copyright holder for this codebase notesBUILD_COMPANY_LINK— Company URL URL. Legal copyright holder website for this codebase notesBUILD_HOOK_EXTENSIONS— Build Hook Extension List ColonDelimitedList. List of extensions to run when looking for hooks notesBUILD_MAINTENANCE_CREATED_FILE— Maintenance Created Flag Boolean. When true, means the.env.localfile was created by the notesBUILD_MAINTENANCE_MESSAGE_VARIABLE— Maintenance Variable Message Name EnvironmentVariable. Name of the environment variable (if any) which reflects the notesBUILD_MAINTENANCE_VARIABLE— Maintenance Variable Name EnvironmentVariable. The maintenance variable name which enables (or disabled) maintenance mode. notesBUILD_PROJECT_DEACTIVATE— Project Deactivation Function Function. Set this to a function which cleans up the project notesBUILD_TERM_COLORS_STATE— Terminal Color State String. State to store state of current terminal color state notes
Bash
BUILD_DOCUMENTATION_PATH— Build Documentation Path List DirectoryList. Search path for documentation settings file. notesDISPLAY— X Display String. Environment variable for X windows display. notesEDITOR— Editor Command Callable. Binary for editing files notesHOME— User Home Directory. Current user's home directory. notesLC_TERMINAL— Terminal Application String. LC_TERMINAL typically identifies the terminal application notesMANPATH— Manual Pages Path DirectoryList. A colon:separated list of paths to search for notesPATH— Executable Search Path DirectoryList. A colon:separated list of paths to search for notesPRODUCTION— Production Flag Boolean. Is this a production system? e.g. remove unnecessary runtime checks. notesPROMPT_COMMAND— Prompt function Callable. Command is run before displaying the prompt, receives exit status notesPS1— Bash Command Prompt String. Bash Prompt for terminals notesSHFMT_ARGUMENTS— Shell Formatting Arguments Array. Arguments passed to shfmt when running as a pre-commit hook notesTERM— Terminal Type String. The current terminal type. notesVISUAL— File Preview Executable. Binary for viewing files notes
Bash Prompt
__BASH_PROMPT_MARKERS— Prompt marker list Array:EmptyString. Bash Prompt escape codes for prompt reporting notes__BASH_PROMPT_MODULES— Prompt module list Array:Callable. List of functions to run each prompt command notes__BASH_PROMPT_PREVIOUS— Prompt command previous result Array. Previous result code notes__BASH_PROMPT_SLOW— Prompt command slow threshold PositiveInteger. Bash Prompt slow timer notes
Build Configuration
BUILD_CACHE_HOME— Build Cache Directory Directory. Location for the build system cache files. Defaults to$HOME/.buildnotesBUILD_DEBUG— Debugging Flag CommaDelimitedList. Constant for turning debugging on during build to find errors notesBUILD_DEBUG_LINES— Debugging output lines PositiveInteger. Number of lines of debugging output to send to stderr notesBUILD_ENVIRONMENT_DIRS— Build Environment Directory List DirectoryList. Search directory for environment definition files.:separated. notesBUILD_HOME— Build Home Directory Directory.BUILD_HOMEis.when this code is installed - at notesBUILD_HOOK_DIRS— Build Hook Directory List ApplicationDirectoryList. List of directories to search for hooks. Defaults tobin/hooks:bin/build/hooks. notesBUILD_INSTALL_URL— Build Installation URL URL.BUILD_INSTALL_URLforinstallInstallBuild- source URL for a raw installer. notesBUILD_MAXIMUM_TAGS_PER_VERSION— Maximum Git Tags per Version PositiveInteger. Number of versions tags (d0, d1, d2, etc.) to look notesBUILD_NOTIFY_SOUND— Notification Sound String. Sound for notifications. Set to-for no sound. Defaults notesBUILD_PRECOMMIT_EXTENSIONS— Pre-Commit Extension List List. List of extensions for which build hooks may be written notesBUILD_RELEASE_NOTES— Release Notes Application Path ApplicationDirectory. Constant for the release notes path. Defaults to./docs/release. notesBUILD_URL_TIMEOUT— URL Timeout PositiveInteger. Timeout in seconds for fetching URLs inurlFetchnotesBUILD_VERSION_NO_OPEN— Build Version No Open Flag Boolean. Constant for whether to open release notes when a version notesBUILD_VERSION_SUFFIX— Build Version Suffix String. Default suffix used ingitTagVersionnotesIP_URL— IP Lookup URL URL. URL to look up IP my address remotely notesIP_URL_FILTER— Filter for IP Lookup String. jq filter to parse IP_URL result (assuming JSON) notesXDG_CACHE_HOME— Main Cache Directory Directory. Main Cache Directory notesXDG_CONFIG_DIRS— Configuration Path Directories DirectoryList. Configuration Path Directories notesXDG_CONFIG_HOME— Main Configuration Path Directory. Main Configuration Path notesXDG_DATA_DIRS— Data Path Directories DirectoryList. Data Path Directories notesXDG_DATA_HOME— Data Home Directory Directory. Data Home Directory notesXDG_STATE_HOME— State Home Directory Directory. State Home Directory notes
Continuous Integration
BITBUCKET_CLONE_DIR— Bitbucket Clone Directory Directory. Defined in BITBUCKET Pipelines notesBITBUCKET_REPO_SLUG— Bitbucket Repository Slug String. Defined in BITBUCKET Pipelines, represents the project code name. notesBITBUCKET_WORKSPACE— Bitbucket Workspace String. Defined in BITBUCKET Pipelines. represents the project workspace. notesCI— Continuous Integration String. If this value is non-blank, then consolestatusMessages are just notes
Continuous Integration: BitBucket
BUILD_DOCKER_BITBUCKET_IMAGE— Docker Image for Bitbucket Containers String. undocumentedBUILD_DOCKER_BITBUCKET_PATH— Docker Path for Bitbucket Containers RemoteDirectory. undocumented
Decoration
BUILD_COLORS— Build Colors Flag Boolean. If true then colors are shown, blank means guess the notesBUILD_PAIR_WIDTH— Pair Width PositiveInteger. Width for pairs. Defaults to40. notesBUILD_PROMPT_COLORS— Prompt Color List ColonDelimitedList. Colon-separated list of colors for the prompt notesBUILD_TEXT_BINARY— Text Executable Callable. Binary used to generatedecorate bignotesBUILD_URL_BINARY— URL Executable Callable. Binary used in __urlOpen notesCOLORFGBG— Terminal Foreground and Background String. Standard way to express the foreground and background colors notes
Deployment
APPLICATION_BUILD_DATE— Application Build Date String. Time when a build was initiated, set upon first invocation notesAPPLICATION_ID— Application ID String. This is the unique hash which represents the source code notesAPPLICATION_REMOTE_HOME— Application Remote Home Directory RemoteDirectory. Path on the remote server where the application is served notesAPPLICATION_TAG— Application Tag String. This is the full version number including debugging or release notesAPPLICATION_VERSION— Application Version String. This is the version number which can be displayed notesBUILD_TARGET— Build Application Target File Name String. The file to generate when generating builds notesBUILD_TIMESTAMP— Build Timestamp UnsignedInteger. Time when a build was initiated, set upon first invocation notesDEPLOYMENT— Deployment Code String. Target deployment for this code notesDEPLOY_REMOTE_HOME— Remote directory for deployment RemoteDirectory. Path on the remote server where the application deployment home notesDEPLOY_USER_HOSTS— Host list for deployment String. A list of one ore more user@host for installation of notes
Deployment: GitHub
GITHUB_REPOSITORY_OWNER— GitHub Repository Owner String. Repository owner for release notes
Development
BUILD_DEVELOPMENT_HOME— Home for Zesk Build development String. Directory where Zesk Build is being developed in the file notesGITHUB_ACCESS_TOKEN— GitHub Access Token Secret. Access token used for release notesGITHUB_ACCESS_TOKEN_EXPIRE— GitHub Access Token Expiration Date Date. GitHub Access token expiration date. Invalid AFTER this date. notesGITHUB_REPOSITORY_NAME— GitHub Repository Name String. Repository name for release notesGIT_BRANCH_FORMAT— Git Branch Format String String. undocumentedGIT_OPEN_LINKS— Git Open Links Flag Boolean. Open links from git remotes ingitCommitnotesGIT_REMOTE— GitHub Remote Name String. undocumented
Docker
BUILD_DOCKER_IMAGE— Docker Image String. Default docker image to use when launchingdockerLocalContainernotesBUILD_DOCKER_PATH— Docker Mapped Path RemoteDirectory. Default path for the shell to map the current directory notesBUILD_DOCKER_PLATFORM— Docker Platform String. The platform fordockerLocalContainernotes
Documentation
BUILD_DOCUMENTATION_SOURCE_LINK_PATTERN— Build documentation URL Pattern String. Links in documentation notes
Installation
BUILD_COMPOSER_VERSION— Composer Version String. Version of composer to use for building vendor directory notesBUILD_NPM_VERSION— npm Version String. Version of npm to install using nativenpmbinary. notesBUILD_PACKAGE_MANAGER— Package Manager Binary Executable. The default package manager on systems which have more than notes
Internal
__BUILD_HAS_TTY— TTY Cached Result Boolean. Cached value of the availability of/dev/tty. notes
PHP
XDEBUG_ENABLED— xDebug Enabled Flag Boolean. Is xdebug enabled? The application can honor this environment variable notes
Testing
BUILD_TEST_FLAGS— Test Flags String. Test flags affect controls and how tests are run. notesTEST_TRACK_ASSERTIONS— Track Assertions Flag Boolean. Assertion tracking testing optimization notes
Vendor
APACHE_HOME— Apache Home Directory Directory. Constant for the Apache configuration home directory. notesBUILD_YARN_VERSION— Yarn Version String. Version of yarn to install usingcorepacknotesDAEMONTOOLS_HOME— Daemontools Home Directory. Constant for the directory where services are monitored by daemontools notesMARIADB_BINARY_CONNECT— mariadb Connect Executable Executable. MariaDB binary for database connections notesMARIADB_BINARY_DUMP— mariadb Dump Executable Executable. MariaDB binary for dump notesNODE_PACKAGE_MANAGER— node Package Manager Executable. The package manager used for node operations. Usuallyyarnor notes
Additional Details on Environment Variables
APACHE_HOME
Apache Home Directory — Constant for the Apache configuration home directory.
Type: Directory • Category: Vendor
Constant for the Apache configuration home directory.
APPLICATION_BUILD_DATE
Application Build Date — Time when a build was initiated, set upon first invocation
Type: String • Category: Deployment
Time when a build was initiated, set upon first invocation if not already.
APPLICATION_CODE
Application Code Name — This is the unique code name of the application. Use
Type: String • Category: Application
This is the unique code name of the application. Use a domain name suffix to ensure global uniqueness.
APPLICATION_CODE_EXTENSIONS
Application Code File Extension List — List of extensions for code in the application. Required.
Type: ColonDelimitedList • Category: Application
List of extensions for code in the application. Required.
APPLICATION_CODE_IGNORE
Application Code Ignore Paths — List of path names to ignore for application code. (e.g.
Type: ColonDelimitedList • Category: Application
List of path names to ignore for application code. (e.g. /vendor/, /node_modules/, etc.)
APPLICATION_ID
Application ID — This is the unique hash which represents the source code
Type: String • Category: Deployment
This is the unique hash which represents the source code state (typically a git hash)
APPLICATION_JSON
Application JSON File — Path to the application configuration JSON
Type: ApplicationFile • Category: Application
Path to the application configuration JSON
APPLICATION_JSON_PREFIX
Application JSON Prefix — Prefix to place we can store things in the JSON
Type: String • Category: Application
Prefix to place we can store things in the JSON file (e.g. to set the fingerprint)
APPLICATION_NAME
Application Name — This is the display name of the application
Type: String • Category: Application
This is the display name of the application
APPLICATION_OWNER
Application Legal Owner — The entity which owns or manages the application. Typically the
Type: String • Category: Application
The entity which owns or manages the application. Typically the owning company name. This is used in Copyright notices in code and other locations.
APPLICATION_REMOTE_HOME
Application Remote Home Directory — Path on the remote server where the application is served
Type: RemoteDirectory • Category: Deployment
Path on the remote server where the application is served
APPLICATION_TAG
Application Tag — This is the full version number including debugging or release
Type: String • Category: Deployment
This is the full version number including debugging or release identifiers
APPLICATION_VERSION
Application Version — This is the version number which can be displayed
Type: String • Category: Deployment
This is the version number which can be displayed
AWS_ACCESS_KEY_DATE
AWS Access Key Issue Date — Date of key expiration which can be checked in pipelines.
Type: Date • Category: Amazon Web Services
Date of key expiration which can be checked in pipelines. Not part of the Amazon specification but a good idea to track expiration of keys.
AWS_ACCESS_KEY_ID
AWS Access Key — Amazon Web Services IAM Identity
Type: String • Category: Amazon Web Services
Amazon Web Services IAM Identity
AWS_PROFILE
AWS Profile — Default profile for Amazon Web Services
Type: String • Category: Amazon Web Services
Default profile for Amazon Web Services
AWS_REGION
AWS Region — Region for Amazon Web Services
Type: String • Category: Amazon Web Services
Region for Amazon Web Services
See Also
- awsIPAccess - Grant access to AWS security group for this IP only using Amazon IAM credentials (source)
AWS_SECRET_ACCESS_KEY
AWS Secret Access Key — Private Secret Password for AWS
Type: Secret • Category: Amazon Web Services
Private Secret Password for AWS
BITBUCKET_CLONE_DIR
Bitbucket Clone Directory — Defined in BITBUCKET Pipelines
Type: Directory • Category: Continuous Integration
Defined in BITBUCKET Pipelines Typically should match BUILD_HOME
BITBUCKET_REPO_SLUG
Bitbucket Repository Slug — Defined in BITBUCKET Pipelines, represents the project code name.
Type: String • Category: Continuous Integration
Defined in BITBUCKET Pipelines, represents the project code name.
BITBUCKET_WORKSPACE
Bitbucket Workspace — Defined in BITBUCKET Pipelines. represents the project workspace.
Type: String • Category: Continuous Integration
Defined in BITBUCKET Pipelines. represents the project workspace.
BUILD_CACHE_HOME
Build Cache Directory — Location for the build system cache files. Defaults to
$HOME/.buildType: Directory • Category: Build Configuration
Location for the build system cache files. Defaults to $HOME/.build and if $HOME is not a directory then $(buildHome)/.build
Cache MAY be deleted at any time. If you need your files to be preserved, store them elsewhere.
BUILD_COLORS
Build Colors Flag — If true then colors are shown, blank means guess the
Type: Boolean • Category: Decoration
If true then colors are shown, blank means guess the value, false means no colors
See Also
BUILD_COMPANY
Company Name — Legal copyright holder for this codebase
Type: String • Category: Application
Legal copyright holder for this codebase
BUILD_COMPANY_LINK
Company URL — Legal copyright holder website for this codebase
Type: URL • Category: Application
Legal copyright holder website for this codebase
BUILD_COMPOSER_VERSION
Composer Version — Version of composer to use for building vendor directory
Type: String • Category: Installation
Version of composer to use for building vendor directory
See Also
- phpComposer - Run Composer commands on code (source)
BUILD_DEBUG
Debugging Flag — Constant for turning debugging on during build to find errors
Type: CommaDelimitedList • Category: Build Configuration
Constant for turning debugging on during build to find errors in the build scripts.
Enable debugging globally in the build scripts. Set to a comma (,) delimited list string to enable specific debugging, or true for ALL debugging, false (or blank) for NO debugging.
BUILD_DEBUG_LINES
Debugging output lines — Number of lines of debugging output to send to stderr
Type: PositiveInteger • Category: Build Configuration
Number of lines of debugging output to send to stderr before stopping
BUILD_DEVELOPMENT_HOME
Home for Zesk Build development — Directory where Zesk Build is being developed in the file
Type: String • Category: Development
Directory where Zesk Build is being developed in the file system (for other projects to test against a changed version)
See Also
- buildDevelopmentLink - Add a development link to the local version of Zesk (source)
BUILD_DOCKER_IMAGE
Docker Image — Default docker image to use when launching
dockerLocalContainerType: String • Category: Docker
Default docker image to use when launching dockerLocalContainer
See Also
- dockerLocalContainer - Run a build container using given docker image. (source)
BUILD_DOCKER_PATH
Docker Mapped Path — Default path for the shell to map the current directory
Type: RemoteDirectory • Category: Docker
Default path for the shell to map the current directory to when launching dockerLocalContainer
See Also
- dockerLocalContainer - Run a build container using given docker image. (source)
BUILD_DOCKER_PLATFORM
Docker Platform — The platform for
dockerLocalContainerType: String • Category: Docker
The platform for dockerLocalContainer
Contacts of this can be found via docker buildx ls
Valid values are:
linux/arm64linux/amd64linux/amd64/v2linux/riscv64linux/ppc64lelinux/s390xlinux/386linux/mips64lelinux/mips64linux/arm/v7linux/arm/v6
If not specified, uses the default for the current platform.
See Also
- dockerLocalContainer - Run a build container using given docker image. (source)- dockerPlatformDefault - Fetch the default platform for docker (source)
BUILD_DOCUMENTATION_PATH
Build Documentation Path List — Search path for documentation settings file.
Type: DirectoryList • Category: Bash
Search path for documentation settings file.
A colon : separated list of paths to search for function documentation settings file for __bashDocumentationCached
See Also
- {SEE:__bashDocumentationCached}
BUILD_DOCUMENTATION_SOURCE_LINK_PATTERN
Build documentation URL Pattern — Links in documentation
Type: String • Category: Documentation
Links in documentation
BUILD_ENVIRONMENT_DIRS
Build Environment Directory List — Search directory for environment definition files.
:separated.Type: DirectoryList • Category: Build Configuration
Search directory for environment definition files. : separated.
Note these should be in addition to the default environment variables ALWAYS located at ./bin/build/env
THe default is $(buildHome)/bin/env. Make sure to append to this as a :-list.
BUILD_HOME
Build Home Directory —
BUILD_HOMEis.when this code is installed - atType: Directory • Category: Build Configuration
BUILD_HOME is . when this code is installed - at ./bin/build. Usually an absolute path and does NOT end with a trailing slash.
This is computed from the current source file using ${BASH_SOURCE[0]}.
BUILD_HOOK_DIRS
Build Hook Directory List — List of directories to search for hooks. Defaults to
bin/hooks:bin/build/hooks.Type: ApplicationDirectoryList • Category: Build Configuration
List of directories to search for hooks. Defaults to bin/hooks:bin/build/hooks.
Colon (:) separated list.
BUILD_HOOK_EXTENSIONS
Build Hook Extension List — List of extensions to run when looking for hooks
Type: ColonDelimitedList • Category: Application
List of extensions to run when looking for hooks
BUILD_INSTALL_URL
Build Installation URL —
BUILD_INSTALL_URLforinstallInstallBuild- source URL for a raw installer.Type: URL • Category: Build Configuration
BUILD_INSTALL_URL for installInstallBuild - source URL for a raw installer.
BUILD_MAINTENANCE_CREATED_FILE
Maintenance Created Flag — When true, means the
.env.localfile was created by theType: Boolean • Category: Application
When true, means the .env.local file was created by the maintenance hook and should be deleted when maintenance is
no longer enabled.
BUILD_MAINTENANCE_MESSAGE_VARIABLE
Maintenance Variable Message Name — Name of the environment variable (if any) which reflects the
Type: EnvironmentVariable • Category: Application
Name of the environment variable (if any) which reflects the current maintenance message.
Default is MAINTENANCE_MESSAGE and this is typically added to the .env.local to a live
application. Your application should monitor these files for changes if they are cached and reload as needed to ensure
these messages are displayed immediately.
BUILD_MAINTENANCE_VARIABLE
Maintenance Variable Name — The maintenance variable name which enables (or disabled) maintenance mode.
Type: EnvironmentVariable • Category: Application
The maintenance variable name which enables (or disabled) maintenance mode.
Default is MAINTENANCE.
This value is set to true or false
BUILD_MAXIMUM_TAGS_PER_VERSION
Maximum Git Tags per Version — Number of versions tags (d0, d1, d2, etc.) to look
Type: PositiveInteger • Category: Build Configuration
Number of versions tags (d0, d1, d2, etc.) to look for before giving up in gitTagVersion
See Also
- gitTagVersion - Generates a git tag for a build version, so `v1.0d1`, (source)
BUILD_NOTIFY_SOUND
Notification Sound — Sound for notifications. Set to
-for no sound. DefaultsType: String • Category: Build Configuration
Sound for notifications. Set to - for no sound. Defaults to zesk-build-notification.
See Also
- darwinNotification - Display a notification for the user (source)
BUILD_NPM_VERSION
npm Version — Version of npm to install using native
npmbinary.Type: String • Category: Installation
Version of npm to install using native npm binary.
See Also
- npmInstall - Install NPM in the build environment (source)
BUILD_PACKAGE_MANAGER
Package Manager Binary — The default package manager on systems which have more than
Type: Executable • Category: Installation
The default package manager on systems which have more than one package manager available.
BUILD_PAIR_WIDTH
Pair Width — Width for pairs. Defaults to
40.Type: PositiveInteger • Category: Decoration
Width for pairs. Defaults to 40.
See Also
- {SEE:__decorateExtensionPair}
BUILD_PRECOMMIT_EXTENSIONS
Pre-Commit Extension List — List of extensions for which build hooks may be written
Type: List • Category: Build Configuration
List of extensions for which build hooks may be written and run.
Presence in this list simply means it may run, not that it is written or runs; add your own
bin/hooks/pre-commit-XXX.sh to handle a specific file type in your application.
Currently:
sh- BashPHP- PHPjs- JavaScriptjson- JSONmd- Markdownyml- Yet Another Markup Languagetxt- Text filespy- Pythongo- Golangrs- Rustcss- CSSless,sass,scss- Compiled stylesheets
BUILD_PROJECT_DEACTIVATE
Project Deactivation Function — Set this to a function which cleans up the project
Type: Function • Category: Application
Set this to a function which cleans up the project context and
will be run on project-deactivate hook which is sourced.
BUILD_PROMPT_COLORS
Prompt Color List — Colon-separated list of colors for the prompt
Type: ColonDelimitedList • Category: Decoration
Colon-separated list of colors for the prompt
Colors are escape codes. Last entry is a reset simply to make environment output less messy.
- Success color
- Failure color
- User
- Host
- Path
See Also
- bashPrompt - Bash prompt toolkit (source)
BUILD_RELEASE_NOTES
Release Notes Application Path — Constant for the release notes path. Defaults to
./docs/release.Type: ApplicationDirectory • Category: Build Configuration
Constant for the release notes path. Defaults to ./docs/release.
BUILD_TARGET
Build Application Target File Name — The file to generate when generating builds
Type: String • Category: Deployment
The file to generate when generating builds
BUILD_TERM_COLORS_STATE
Terminal Color State — State to store state of current terminal color state
Type: String • Category: Application
State to store state of current terminal color state
See Also
- bashPromptModule_TermColors - Terminal colors to match projects (source)
BUILD_TEST_FLAGS
Test Flags — Test flags affect controls and how tests are run.
Type: String • Category: Testing
Test flags affect controls and how tests are run.
BUILD_TEXT_BINARY
Text Executable — Binary used to generate
decorate bigType: Callable • Category: Decoration
Binary used to generate decorate big
See Also
- decorate - Singular decoration function (source){SEE:big}
- {SEE:__aptStandardPackages}
- {SEE:__apkStandardPackages}
- {SEE:__brewStandardPackages}
BUILD_TIMESTAMP
Build Timestamp — Time when a build was initiated, set upon first invocation
Type: UnsignedInteger • Category: Deployment
Time when a build was initiated, set upon first invocation if not already
BUILD_URL_BINARY
URL Executable — Binary used in __urlOpen
Type: Callable • Category: Decoration
Binary used in __urlOpen
See Also
BUILD_URL_TIMEOUT
URL Timeout — Timeout in seconds for fetching URLs in
urlFetchType: PositiveInteger • Category: Build Configuration
Timeout in seconds for fetching URLs in urlFetch
See Also
BUILD_VERSION_NO_OPEN
Build Version No Open Flag — Constant for whether to open release notes when a version
Type: Boolean • Category: Build Configuration
Constant for whether to open release notes when a version is requested (see version-already)
BUILD_VERSION_SUFFIX
Build Version Suffix — Default suffix used in
gitTagVersionType: String • Category: Build Configuration
Default suffix used in gitTagVersion
See Also
- gitTagVersion - Generates a git tag for a build version, so `v1.0d1`, (source)
BUILD_YARN_VERSION
Yarn Version — Version of yarn to install using
corepackType: String • Category: Vendor
Version of yarn to install using corepack
See Also
- yarnInstall - Install yarn (source)
CI
Continuous Integration — If this value is non-blank, then console
statusMessages are justType: String • Category: Continuous Integration
If this value is non-blank, then console statusMessages are just output normally.
Continuous Integration - this is set to a non-blank value in:
- Bitbucket pipelines
See Also
- statusMessage - Output a status message and display correctly on consoles with animation and in log files (source)- consoleHasAnimation - Does the console support animation? (source)
COLORFGBG
Terminal Foreground and Background — Standard way to express the foreground and background colors
Type: String • Category: Decoration
Standard way to express the foreground and background colors
foregroundColor- UnsignedInteger. 0 to 16backgroundColor- UnsignedInteger. 0 to 16
Not referenced in this product; referenced via rxvt and may be honored at some point.
DAEMONTOOLS_HOME
Daemontools Home — Constant for the directory where services are monitored by daemontools
Type: Directory • Category: Vendor
Constant for the directory where services are monitored by daemontools
DEPLOYMENT
Deployment Code — Target deployment for this code
Type: String • Category: Deployment
Target deployment for this code
DEPLOY_REMOTE_HOME
Remote directory for deployment — Path on the remote server where the application deployment home
Type: RemoteDirectory • Category: Deployment
Path on the remote server where the application deployment home is (per application)
DEPLOY_USER_HOSTS
Host list for deployment — A list of one ore more user@host for installation of
Type: String • Category: Deployment
A list of one ore more user@host for installation of the application
See Also
- deployApplication - Deploy an application from a deployment repository (source)
DISPLAY
X Display — Environment variable for X windows display.
Type: String • Category: Bash
Environment variable for X windows display.
From the user's perspective, every X server has a display name of the form: hostname:displaynumber.screennumber
EDITOR
Editor Command — Binary for editing files
Type: Callable • Category: Bash
Binary for editing files
GITHUB_ACCESS_TOKEN
GitHub Access Token — Access token used for release
Type: Secret • Category: Development
Access token used for release
See Also
- githubRelease - Generate a release on GitHub using API (source)
GITHUB_ACCESS_TOKEN_EXPIRE
GitHub Access Token Expiration Date — GitHub Access token expiration date. Invalid AFTER this date.
Type: Date • Category: Development
GitHub Access token expiration date. Invalid AFTER this date.
See Also
- githubRelease - Generate a release on GitHub using API (source)
GITHUB_REPOSITORY_NAME
GitHub Repository Name — Repository name for release
Type: String • Category: Development
Repository name for release
See Also
- githubRelease - Generate a release on GitHub using API (source)
GITHUB_REPOSITORY_OWNER
GitHub Repository Owner — Repository owner for release
Type: String • Category: Deployment: GitHub
Repository owner for release
See Also
- githubRelease - Generate a release on GitHub using API (source)
GIT_OPEN_LINKS
Git Open Links Flag — Open links from git remotes in
gitCommitType: Boolean • Category: Development
Open links from git remotes in gitCommit
See Also
- gitCommit - Commits all files added to git and also update release (source)- gitCommit - Commits all files added to git and also update release (source)
HOME
User Home — Current user's home directory.
Type: Directory • Category: Bash
Current user's home directory.
IP_URL
IP Lookup URL — URL to look up IP my address remotely
Type: URL • Category: Build Configuration
URL to look up IP my address remotely
See Also
- networkIPLookup - Get the current IP address of a host (source)
IP_URL_FILTER
Filter for IP Lookup — jq filter to parse IP_URL result (assuming JSON)
Type: String • Category: Build Configuration
jq filter to parse IP_URL result (assuming JSON) if blank, no filter is used and raw result is returned
See Also
- networkIPLookup - Get the current IP address of a host (source)
LC_TERMINAL
Terminal Application — LC_TERMINAL typically identifies the terminal application
Type: String • Category: Bash
LC_TERMINAL typically identifies the terminal application
MANPATH
Manual Pages Path — A colon
:separated list of paths to search forType: DirectoryList • Category: Bash
A colon : separated list of paths to search for manual pages.
See manPathConfigure
See Also
- manPathConfigure - Modify the MANPATH environment variable to add a path. (source)
MARIADB_BINARY_CONNECT
mariadb Connect Executable — MariaDB binary for database connections
Type: Executable • Category: Vendor
MariaDB binary for database connections
MARIADB_BINARY_DUMP
mariadb Dump Executable — MariaDB binary for dump
Type: Executable • Category: Vendor
MariaDB binary for dump
NODE_PACKAGE_MANAGER
node Package Manager — The package manager used for node operations. Usually
yarnorType: Executable • Category: Vendor
The package manager used for node operations. Usually yarn or npm.
Default is yarn.
PATH
Executable Search Path — A colon
:separated list of paths to search forType: DirectoryList • Category: Bash
A colon : separated list of paths to search for executables in bash.
See pathConfigure
See Also
- pathConfigure - Modify the PATH environment variable to add a path. (source)
PRODUCTION
Production Flag — Is this a production system? e.g. remove unnecessary runtime checks.
Type: Boolean • Category: Bash
Is this a production system? e.g. remove unnecessary runtime checks.
PROMPT_COMMAND
Prompt function — Command is run before displaying the prompt, receives exit status
Type: Callable • Category: Bash
Command is run before displaying the prompt, receives exit status from the prior command.
See Also
- bashPrompt - Bash prompt toolkit (source)
PS1
Bash Command Prompt — Bash Prompt for terminals
Type: String • Category: Bash
Bash Prompt for terminals
See Also
- bashPrompt - Bash prompt toolkit (source)
SHFMT_ARGUMENTS
Shell Formatting Arguments — Arguments passed to shfmt when running as a pre-commit hook
Type: Array • Category: Bash
Arguments passed to shfmt when running as a pre-commit hook
See Also
- {SEE:pre-commit-sh.sh}
TERM
Terminal Type — The current terminal type.
Type: String • Category: Bash
The current terminal type.
TEST_TRACK_ASSERTIONS
Track Assertions Flag — Assertion tracking testing optimization
Type: Boolean • Category: Testing
Assertion tracking testing optimization
Turn on or off tracking of function assertions within the testing core.
If blank, the default behavior is to track; disable it with setting the value to false.
VISUAL
File Preview — Binary for viewing files
Type: Executable • Category: Bash
Binary for viewing files
XDEBUG_ENABLED
xDebug Enabled Flag — Is xdebug enabled? The application can honor this environment variable
Type: Boolean • Category: PHP
Is xdebug enabled? The application can honor this environment variable to automatically connect to the debugger.
See Also
XDG_CACHE_HOME
Main Cache Directory — Main Cache Directory
Type: Directory • Category: Build Configuration
Base directory for user-specific cache data to be stored See basedir-spec for explanation of this and other related environment variables.
XDG_CONFIG_DIRS
Configuration Path Directories — Configuration Path Directories
Type: DirectoryList • Category: Build Configuration
Search directory for user-specific configuration files to be stored. : separated.
See basedir-spec for explanation of this and other related environment variables.
XDG_CONFIG_HOME
Main Configuration Path — Main Configuration Path
Type: Directory • Category: Build Configuration
Location for configuration files See basedir-spec for explanation of this and other related environment variables.
XDG_DATA_DIRS
Data Path Directories — Data Path Directories
Type: DirectoryList • Category: Build Configuration
Search directory for user-specific data files to be stored. : separated.
See basedir-spec for explanation of this and other related environment variables.
XDG_DATA_HOME
Data Home Directory — Data Home Directory
Type: Directory • Category: Build Configuration
Base directory for user-specific data to be stored. See basedir-spec for explanation of this and other related environment variables.
XDG_STATE_HOME
State Home Directory — State Home Directory
Type: Directory • Category: Build Configuration
Base directory for user-specific state files to be stored See basedir-spec for explanation of this and other related environment variables.
__BASH_PROMPT_MARKERS
Prompt marker list — Bash Prompt escape codes for prompt reporting
Type: Array:EmptyString • Category: Bash Prompt
List of markers to identify to the terminal location of the prompt. Used by iTerm2 and, hopefully, other terminal applications.
See Also
- iTerm2Init - Add iTerm2 support to console (source)- bashPrompt - Bash prompt toolkit (source)
__BASH_PROMPT_MODULES
Prompt module list — List of functions to run each prompt command
Type: Array:Callable • Category: Bash Prompt
List of modules to run each prompt command.
Manage with bashPrompt functionName to add, bashPrompt --remove functionName to remove.
Make your functions really fast otherwise the shell becomes sluggish. Also try:
BUILD_DEBUG=bashPrompt
To report on each command and timing.
An automatic reporting occurs when commands exceed 0.3s.
See Also
- bashPrompt - Bash prompt toolkit (source)
__BASH_PROMPT_PREVIOUS
Prompt command previous result — Previous result code
Type: Array • Category: Bash Prompt
Previous result code
See Also
- bashPrompt - Bash prompt toolkit (source)
__BASH_PROMPT_SLOW
Prompt command slow threshold — Bash Prompt slow timer
Type: PositiveInteger • Category: Bash Prompt
Number of milliseconds after which a bashPrompt command is considered slow.
See Also
- bashPrompt - Bash prompt toolkit (source)
__BUILD_HAS_TTY
TTY Cached Result — Cached value of the availability of
/dev/tty.Type: Boolean • Category: Internal
Cached value of the availability of /dev/tty.
Possible values are true or false or blank.
true-/dev/ttyappears to be operating without errorsfalse-/dev/ttyappears to be disconnected and can not be used
This value is set automatically by isTTYAvailable and caches the value using this environment variable to avoid testing again.
See also: