generated from Templates/Baseline
add lazygit (#116)
### 📖 Summary - adds lazygit installation - update shell completion script - updade readme ### 📑 Test Plan ✅ CI pipeline tests (Default) ### 💬 Details _No response_ ### 📚 Additional Notes _No response_ Reviewed-on: #116
This commit is contained in:
parent
d9b03cadb4
commit
fa17e1d5e8
@ -204,6 +204,7 @@ This helps reducing the image size.
|
||||
nodejs Installs latest NodeJs LTS version using Volta.
|
||||
volta Installs Volta as NodeJS version manager.
|
||||
powershell Installs latest PowerShell LTS version.
|
||||
lazygit Installs latest Lazygit binary.
|
||||
|
||||
Example 1: arkanum git setup "my-name" "my-email"
|
||||
Example 2: arkanum install golang
|
||||
|
16
arkanum
16
arkanum
@ -35,6 +35,7 @@ function showHelp() {
|
||||
nodejs Installs latest NodeJs LTS version using Volta.
|
||||
volta Installs Volta as NodeJS version manager.
|
||||
powershell Installs latest PowerShell LTS version.
|
||||
lazygit Installs latest Lazygit binary.
|
||||
|
||||
Example 1: arkanum git setup "my-name" "my-email"
|
||||
Example 2: arkanum install golang
|
||||
@ -210,6 +211,19 @@ function instGiteaTools() {
|
||||
say "done." "Gitea"
|
||||
}
|
||||
|
||||
function installLazyGit() {
|
||||
say "Installing latest lazygit version..." "Lazygit"
|
||||
LAZYGIT_VERSION=$(curl -s "https://api.github.com/repos/jesseduffield/lazygit/releases/latest" | grep -Po '"tag_name": "v\K[^"]*')
|
||||
sudo -E curl -#fSL "https://github.com/jesseduffield/lazygit/releases/latest/download/lazygit_${LAZYGIT_VERSION}_Linux_x86_64.tar.gz" -o /tmp/lazygit.tar.gz
|
||||
#mkdir -p /tmp/lazygit
|
||||
cd /tmp
|
||||
tar xf /tmp/lazygit.tar.gz lazygit
|
||||
say "Installing Lazygit binary" "Lazygit"
|
||||
sudo install /tmp/lazygit /usr/local/bin
|
||||
say "Removing lazygit cache files..." "Lazygit"
|
||||
sudo rm -f /tmp/lazygit.tar.gz
|
||||
rm -rf /tmp/lazygit
|
||||
}
|
||||
function instCodeExtension() {
|
||||
say "Installing default extensions...." "Extension"
|
||||
# Gitlens
|
||||
@ -330,6 +344,8 @@ function main() {
|
||||
instPwsh
|
||||
elif [[ "$2" == "gitea" ]]; then
|
||||
instGiteaTools
|
||||
elif [[ "$2" == "lazygit" ]]; then
|
||||
installLazyGit
|
||||
fi
|
||||
else
|
||||
sayE "Unknown parameter value given!($1)."
|
||||
|
@ -24,7 +24,7 @@ function _command_completions() {
|
||||
;;
|
||||
install)
|
||||
# shellcheck disable=2207,SC2086
|
||||
COMPREPLY=($(compgen -W "docker-cli dotnet golang bun nodejs volta powershell gitea" -- ${cur}))
|
||||
COMPREPLY=($(compgen -W "docker-cli dotnet golang bun nodejs volta powershell gitea lazygit" -- ${cur}))
|
||||
;;
|
||||
help)
|
||||
;;
|
||||
|
Loading…
x
Reference in New Issue
Block a user