diff options
Diffstat (limited to 'dot-oh-my-zsh/custom/themes/spaceship-prompt/sections/php.zsh')
| m--------- | dot-oh-my-zsh | 0 | ||||
| -rw-r--r-- | dot-oh-my-zsh/custom/themes/spaceship-prompt/sections/php.zsh | 37 |
2 files changed, 0 insertions, 37 deletions
diff --git a/dot-oh-my-zsh b/dot-oh-my-zsh new file mode 160000 +Subproject 6fe84bf5c82da7b1f6d7c5ec3e5c447721ac8ce diff --git a/dot-oh-my-zsh/custom/themes/spaceship-prompt/sections/php.zsh b/dot-oh-my-zsh/custom/themes/spaceship-prompt/sections/php.zsh deleted file mode 100644 index 4eb2e818..00000000 --- a/dot-oh-my-zsh/custom/themes/spaceship-prompt/sections/php.zsh +++ /dev/null @@ -1,37 +0,0 @@ -# -# PHP -# -# PHP is a server-side scripting language designed primarily for web development. -# Link: http://www.php.net/ - -# ------------------------------------------------------------------------------ -# Configuration -# ------------------------------------------------------------------------------ - -SPACESHIP_PHP_SHOW="${SPACESHIP_PHP_SHOW=true}" -SPACESHIP_PHP_PREFIX="${SPACESHIP_PHP_PREFIX="$SPACESHIP_PROMPT_DEFAULT_PREFIX"}" -SPACESHIP_PHP_SUFFIX="${SPACESHIP_PHP_SUFFIX="$SPACESHIP_PROMPT_DEFAULT_SUFFIX"}" -SPACESHIP_PHP_SYMBOL="${SPACESHIP_PHP_SYMBOL="🐘 "}" -SPACESHIP_PHP_COLOR="${SPACESHIP_PHP_COLOR="blue"}" - -# ------------------------------------------------------------------------------ -# Section -# ------------------------------------------------------------------------------ - -# Show current version of PHP -spaceship_php() { - [[ $SPACESHIP_PHP_SHOW == false ]] && return - - # Show only if php files or composer.json exist in current directory - [[ -n *.php(#qN^/) || -f composer.json ]] || return - - spaceship::exists php || return - - local php_version=$(php -v 2>&1 | \grep --color=never -oe "^PHP\s*[0-9.]\+" | awk '{print $2}') - - spaceship::section \ - "$SPACESHIP_PHP_COLOR" \ - "$SPACESHIP_PHP_PREFIX" \ - "${SPACESHIP_PHP_SYMBOL}v${php_version}" \ - "${SPACESHIP_PHP_SUFFIX}" -} |
