feat: versions_check print_age
This commit is contained in:
parent
36f98c8685
commit
8a9934383d
@ -20,6 +20,30 @@ fi
|
|||||||
cd $(dirname $0)
|
cd $(dirname $0)
|
||||||
eval $(asdf exec direnv export zsh)
|
eval $(asdf exec direnv export zsh)
|
||||||
|
|
||||||
|
# Print Age
|
||||||
|
#
|
||||||
|
function print_age
|
||||||
|
{
|
||||||
|
program=$1
|
||||||
|
|
||||||
|
echo "\n${bg[red]}${fg[black]}>>>> ${program} ${reset_color}"
|
||||||
|
|
||||||
|
# Already installed
|
||||||
|
#
|
||||||
|
if (( ${+commands[$program]} )); then
|
||||||
|
echo "\n${bg[cyan]} Installed ${reset_color}"
|
||||||
|
|
||||||
|
prog_out=$(${program} -V)
|
||||||
|
|
||||||
|
# Extract version from program's output
|
||||||
|
current_version=$(lastversion format "${prog_out}")
|
||||||
|
|
||||||
|
# Highlight program's version
|
||||||
|
echo ${prog_out} | grep --colour=always -F "${current_version}"
|
||||||
|
lsd -lh --date=relative =${program}
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
# Debian Package
|
# Debian Package
|
||||||
#
|
#
|
||||||
function debian
|
function debian
|
||||||
@ -149,6 +173,8 @@ filter=Linux_x86_64
|
|||||||
archive lazygit https://github.com/jesseduffield/lazygit
|
archive lazygit https://github.com/jesseduffield/lazygit
|
||||||
archive nvim https://github.com/neovim/neovim
|
archive nvim https://github.com/neovim/neovim
|
||||||
|
|
||||||
|
print_age nnn
|
||||||
|
|
||||||
# Fonts
|
# Fonts
|
||||||
setopt nullglob
|
setopt nullglob
|
||||||
fonts=( $(echo /opt/fonts/**/*NerdFont* $HOME/.fonts/**/*NerdFont*) )
|
fonts=( $(echo /opt/fonts/**/*NerdFont* $HOME/.fonts/**/*NerdFont*) )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user