wip
This commit is contained in:
parent
059da9ee0e
commit
7bfea6a9d8
2 changed files with 3 additions and 16 deletions
|
@ -20,7 +20,7 @@ _help() {
|
|||
}
|
||||
|
||||
_install_func() {
|
||||
curl -fsSL "https://git.k4li.de/scripts/installs/raw/branch/main/${1}.sh" | sh
|
||||
curl -fsSL "https://git.k4li.de/scripts/installs/raw/branch/main/${1}.sh" | { bash || sh }
|
||||
}
|
||||
|
||||
_check() {
|
||||
|
|
17
.zshrc
17
.zshrc
|
@ -640,7 +640,7 @@ __alias__() {
|
|||
if command_exists zellij; then
|
||||
za() {
|
||||
# local zsession='zellij list-sessions | tail -1 | grep -q EXITED'
|
||||
if ! zellij list-sessions; then
|
||||
if ! zellij list-sessions >/dev/null 2>&1; then
|
||||
echo "-- Zellij session active! | Connecting to existing session --"
|
||||
sleep 0.3
|
||||
zellij attach
|
||||
|
@ -649,7 +649,7 @@ __alias__() {
|
|||
sleep 0.3
|
||||
zellij attach
|
||||
else
|
||||
echo "-- No Zellij session found! | Creating one --"
|
||||
echo "-- No Zellij session active! | Creating one --"
|
||||
sleep 0.3
|
||||
zellij
|
||||
fi
|
||||
|
@ -666,30 +666,17 @@ _coding_() {
|
|||
alias h='hugo'
|
||||
alias hs='hugo server -D --noHTTPCache --disableFastRender' # --bind "$(get_ip)"'
|
||||
fi
|
||||
# ─< c stands for bin/cake >──────────────────────────────────────────────────────────────
|
||||
# alias cake='bin/cake'
|
||||
# alias c='cake'
|
||||
# alias cs='c server -p 1313'
|
||||
# ─< VSCodium >─────────────────────────────────────────────────────────────────────────────
|
||||
if command_exists codium; then
|
||||
alias code="codium"
|
||||
export EDITOR="codium"
|
||||
fi
|
||||
|
||||
cursor_exe="/mnt/c/Users/piecka/AppData/Local/Programs/cursor/Cursor.exe"
|
||||
if [ -e "$cursor_exe" ]; then
|
||||
alias code="$cursor_exe"
|
||||
fi
|
||||
|
||||
# Function to get the IP address
|
||||
get_ip() {
|
||||
ip a | grep 'inet ' | grep -v '127.0.0.1' | awk '{print $2}' | cut -d/ -f1 | head -n 1
|
||||
}
|
||||
|
||||
if command_exists composer; then
|
||||
alias laravel_new="composer create-project laravel/laravel"
|
||||
fi
|
||||
|
||||
# Check if php is available, then create the alias
|
||||
if command_exists php; then
|
||||
alias phprun="php artisan serve --host=$(get_ip) --port=8000"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue