This commit is contained in:
2025-04-09 12:25:15 +08:00
commit c5fe3160fe
9 changed files with 148 additions and 0 deletions

7
aliases/container.sh Normal file
View File

@@ -0,0 +1,7 @@
alias c=podman
alias crt="c run -it --rm" # container run temporarily
alias ce="c exec -it" # container exec
#alias nginx="c exec nginx nginx"
# alias lzd="DOCKER_HOST=unix:///run/podman/podman.sock lazydocker"
alias lzd="DOCKER_HOST=unix:///run/user/1000/podman/podman.sock lazydocker"

21
aliases/main.sh Normal file
View File

@@ -0,0 +1,21 @@
# List file
alias l="ls -a"
alias la="ls -a"
alias ll="ls -lh"
alias lla="ls -alh"
# Directory and File
alias mkdir="mkdir -pv"
alias rm="rm -rv"
alias mv="mv -v"
alias cp="cp -rv"
# Human Readable
alias free="free -h"
alias du="du -h"
alias df="df -hT" # T: show filesystem type
alias dfo="df | grep -v tmpfs"
# Systemctl
alias sctl="systemctl"
alias ssctl="sudo systemctl"

6
aliases/proxy.sh Normal file
View File

@@ -0,0 +1,6 @@
alias setproxy="export http_proxy=http://127.0.0.1:7890 https_proxy=http://127.0.0.1:7890 all_proxy=socks5://127.0.0.1:7890"
alias unsetproxy="set -e http_proxy https_proxy all_proxy"
# The following alias is for bash or zsh
[ -n "$BASH_VERSION" -o -n "$ZSH_VERSION" ] && \
alias unsetproxy="unset http_proxy https_proxy all_proxy"

7
aliases/python.sh Normal file
View File

@@ -0,0 +1,7 @@
# Python venv
alias newvenv="python -m venv .venv"
alias actvenv=". .venv/bin/activate.fish"
# The following alias is for bash or zsh
[ -n "$BASH_VERSION" -o -n "$ZSH_VERSION" ] && \
alias actvenv=". .venv/bin/activate"