mirror of
https://github.com/jimeh/dotfiles.git
synced 2026-02-19 01:46:43 +00:00
Install ctop with Zinit when docker CLI tool is available
This commit is contained in:
@@ -6,14 +6,11 @@ alias d="docker"
|
||||
alias dc="docker-compose"
|
||||
alias co="docker-compose"
|
||||
|
||||
if ! (( $+commands[ctop] )); then
|
||||
ctop() {
|
||||
docker run --rm -ti --name=ctop-$RANDOM \
|
||||
--volume /var/run/docker.sock:/var/run/docker.sock:ro \
|
||||
quay.io/vektorlab/ctop:latest
|
||||
}
|
||||
fi
|
||||
|
||||
docker_remove_exited () {
|
||||
docker rm "$(docker ps -f='status=exited' -q)"
|
||||
}
|
||||
|
||||
if (( $+commands[docker] )); then
|
||||
zinit ice from'gh-r' as'program' mv'ctop-* -> ctop'
|
||||
zinit light bcicen/ctop
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user