39

I accidentally discovered that both "cd ..." and "..." work, and moreover, I can add more dots to go back further! I'm using zsh on iTerm2 on macOS. I'm pretty sure this isn't a cd feature. Is this specific to zsh or iTerm2? Are there other cool features I just never knew existed??

I'm so excited about an extra dot right now.

you are viewing a single comment's thread
view the rest of the comments
[-] originalfrozenbanana@lemm.ee 8 points 1 year ago* (last edited 1 year ago)

Each instance of . is a relative level to your current directory. ‘cd .’ changes your directory to your current directory. ‘cd ..’ (edit: on mobile this keeps changing to three periods but it should just be two) changes it to the directory above, ‘cd ….’ would change it to three directories above. This is standard in *nix (Unix and Linux) operating systems

Edit 2: this is very wrong

[-] HumbleFlamingo@beehaw.org 41 points 1 year ago

This is standard in *nix (Unix and Linux) operating systems

No, it very much isn't.

[-] originalfrozenbanana@lemm.ee 7 points 1 year ago

Yeah you’re right. I wrote this before sleep and after sleep it’s hilariously wrong lol. Oh well I’ll leave it as a cautionary tale

load more comments (10 replies)
this post was submitted on 03 Nov 2023
39 points (100.0% liked)

Programming

13405 readers
1 users here now

All things programming and coding related. Subcommunity of Technology.


This community's icon was made by Aaron Schneider, under the CC-BY-NC-SA 4.0 license.

founded 2 years ago
MODERATORS