From ee503a225cb95d40516221dce0b3ef03162ad13f Mon Sep 17 00:00:00 2001 From: LyAhn Date: Sun, 26 Jul 2026 06:47:21 +0100 Subject: [PATCH] feat(profiles): add `up` to .zshrc --- profiles/zsh/.zshrc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/profiles/zsh/.zshrc b/profiles/zsh/.zshrc index f21618e..dba7a42 100644 --- a/profiles/zsh/.zshrc +++ b/profiles/zsh/.zshrc @@ -117,6 +117,13 @@ phok() { # ---------- misc helpers ---------- mkcd(){ mkdir -p "$1" && cd "$1"; } +up(){ + local n="${1:-1}" + [[ "$n" =~ ^[0-9]+$ ]] || { echo "up: expects a number"; return 1; } + local path="" + for ((i=0; i