Show pageOld revisionsBacklinksExport to PDFBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== .bashrc up ====== To cd up a certain number of times, add this to your .bashrc file <code bash> up() { local d="" local limit="$1" if [ -z "$limit" ] || [ "$limit" -le 0 ]; then limit=1 fi for ((i=1;i<=limit;i++)); do d="../$d" done if ! cd "$d"; then echo "Path shallower than $limit"; fi } </code> linux/shell_commands/up.txt Last modified: 2022/02/18 07:41by 127.0.0.1