901
That is the way (sub.wetshaving.social)
top 50 comments
sorted by: hot top controversial new old
[-] bappity@lemmy.world 192 points 2 months ago* (last edited 2 months ago)
$ cd ..
$ ls
$ cd ..
$ ls

"hmm yes.. everything seems to be in order"

[-] LiveLM@lemmy.zip 41 points 2 months ago* (last edited 2 months ago)

I need a shell/plugin/tool/whatever that always shows me the content of the current dir in a little popup or something.

Anything I do in the shell is like cd this, ls, cd there, ls *, I feel like a have the navigational awareness of a amnesiac goldfish

[-] fushuan@lemm.ee 21 points 2 months ago

Put this in bashrc or whatever flavour of shells's bashrc you use:

function cs () { cd "$@" && ls }

I didnt remember the function sintax of bash so I just copied it from SO.

[-] Artyom@lemm.ee 20 points 2 months ago
cs () {
    cd $1;
    ls ${@:2}
}

You (probably) only want to pass the first argument to cd, this'll send the rest to ls.

[-] ka1ikasan@lemmy.zip 5 points 2 months ago

Did that years ago, just called it cds. I also have an "up" command which is an alias to "cds ..". Oh, and I have a "setup server_name" they copy all my aliases to a server and create an alias that allow me to "ssh -A server_name" using only server_name.

[-] Eyedust@lemmy.dbzer0.com 10 points 2 months ago

Alternatively, you could use a TUI file manager. Once you get the navigation down you can manage things pretty quickly. Especially with ones that have options for dual directory layouts, like Midnight Commander or vifm.

[-] Prime@lemmy.sdf.org 6 points 2 months ago

It is called windows 2000 explorer and it's great for file operations :) In Linux i have yet to find a really good replacement ;(

[-] Lifter@discuss.tchncs.de 13 points 2 months ago

Try Dolphin. Press F4 to open the terminal view. It stays in dync with the gui so if you use cd in the terminal, the contents of the new folder will be shown.

load more comments (1 replies)
load more comments (1 replies)
load more comments (3 replies)
[-] Zachariah@lemmy.world 4 points 2 months ago

pwd seems more appropriate than ls

load more comments (4 replies)
[-] Zachariah@lemmy.world 52 points 2 months ago* (last edited 2 months ago)

cd ..
⭡ ⏎
⭡ ⏎
⭡ ⏎

[-] maxprime@lemmy.ml 10 points 2 months ago
[-] protogen420 7 points 2 months ago
[-] lemmyhavesome@lemmy.world 52 points 2 months ago* (last edited 2 months ago)
In your rc:
alias ..='cd ..'
alias ...='cd ../..'
alias ....='cd ../../..'

Usage:
1/2/3 $ ...
1 $
load more comments (2 replies)
[-] wpb@lemmy.world 43 points 2 months ago* (last edited 2 months ago)
[-] karmiclychee@sh.itjust.works 34 points 2 months ago

Excuse me what? I've been multi cd'ing for years like a chump?

[-] beeng@discuss.tchncs.de 9 points 2 months ago

Exactly. The fucking what now?

load more comments (2 replies)
[-] Drekaridill@feddit.is 29 points 2 months ago

cd .. ls cd .. ls cd .. ls cd .. ls

[-] OpenStars@discuss.online 28 points 2 months ago

Depending on where you are, maybe just "cd".

[-] wreckedcarzz@lemmy.world 12 points 2 months ago

Smh when are you going to upgrade to dvd

[-] Naich@lemmings.world 23 points 2 months ago

for i in { 1..4 }; do cd ..; done

[-] zqwzzle@lemmy.ca 23 points 2 months ago
[-] Maxxie 10 points 2 months ago

Installing zoxide led me to installing fzf, which has improved my terminal experience by about 35%, I already installed it in all the machines I'm managing

Got any more tools? :)

[-] Eyedust@lemmy.dbzer0.com 5 points 2 months ago* (last edited 2 months ago)

Check out Atuin. Its another must have for me. When you push up arrow, it shows your command history in a very pleasing list. You can even generate account keys to migrate your history between PCs, but I've never bothered with it. You can also search past commands on the history menu.

You don't need an account for it. That's only for the migration keys.

[-] zqwzzle@lemmy.ca 4 points 2 months ago

I don't think there's anything too unusual but here's my nix packages

{ pkgs }:

with pkgs; [
  # General packages for development
  copier      # Project scaffolding and templating
  fastlane
  jujutsu
  just        # Project specific command runner
  mise        # Tool version manager
  ngrok       # Public tunnel ngrok.com
  sqlite
  pre-commit
  trufflehog  # Scan for secrets in code repositories

  # Encryption and security tools
  age
  age-plugin-yubikey
  gnupg
  libfido2

  # Container tools and SDKs
  colima
  podman
  podman-compose

  # Media-related packages
  dejavu_fonts
  ffmpeg
  hack-font
  noto-fonts
  noto-fonts-emoji
  meslo-lgs-nf
  yt-dlp

  # Text and terminal utilities
  bat
  btop        # resource monitor
  #chezmoi    # manage dotfiles; to try
  coreutils   # GNU system tools
  curl
  delta
  exiftool
  f3          # flash drive verification tool
  fd          # alternate find command
  fzf
  htop
  iftop
  jq          # command line JSON tool
  # openssh
  ripgrep
  s3cmd
  shellcheck  # static analysis for shell scripts
  tree
  tmux
  unison
  unrar
  unzip
  wget
  zip
  zoxide

  # fish specific
  fishPlugins.foreign-env
  fishPlugins.forgit
  fishPlugins.fzf-fish
  fishPlugins.tide
  fishPlugins.z

  # Python packages
  python3
  virtualenv
]
load more comments (5 replies)
[-] Danitos@reddthat.com 4 points 2 months ago

zoxide, btop and lazygit are a must for me in any computer.

load more comments (1 replies)
[-] funkajunk@lemm.ee 23 points 2 months ago

I alias .. to cd ..

Works for me 🤷🏻

[-] Bonsoir@lemmy.ca 18 points 2 months ago

I do that too!
I also alias ... to cd ../... I'll be honest, I often forget to do it, but in theory it can speed things up.

[-] beerclue@lemmy.world 17 points 2 months ago

I use a lot cd - (go to previous) or just cd to go home.

[-] quantenzitrone@lemmings.world 16 points 2 months ago

i use fish shell with https://github.com/nickeb96/puffer-fish

basically when i type ... it expands to ../.. and adds another /.. for every additional dot i type

its similar to what the zsh users in the comment section are doing

load more comments (2 replies)
[-] billwashere@lemmy.world 16 points 2 months ago* (last edited 2 months ago)

Or the alias I have set up

…..

[-] confusedpuppy@lemmy.dbzer0.com 9 points 2 months ago

I kept saying "cd up" in my mind so I just made an alias for cdu, became a reflex within the next day

load more comments (3 replies)
[-] _thebrain_@sh.itjust.works 15 points 2 months ago* (last edited 2 months ago)
load more comments (2 replies)
[-] lambda@programming.dev 14 points 2 months ago
[-] jia_tan 4 points 2 months ago

Whaaaaaaaaaaaaaaat

load more comments (2 replies)
[-] axEl7fB5@lemmy.cafe 11 points 2 months ago
cd ..
!!
!!
!!
[-] some_guy@lemmy.sdf.org 8 points 2 months ago
alias ..='cd ..' #: up one directory
alias ...='cd ../..' #: up two directories
load more comments (1 replies)
[-] Ganbat@lemmy.dbzer0.com 8 points 2 months ago

Tbf it is less key presses since you can generally just recall the last command.

[-] MoogleMaestro@lemmy.zip 8 points 2 months ago
load more comments (3 replies)
[-] hperrin@lemmy.ca 8 points 2 months ago
load more comments (1 replies)
[-] SchwertImStein@lemmy.dbzer0.com 7 points 2 months ago
[-] kibiz0r@midwest.social 6 points 2 months ago
load more comments (2 replies)
[-] technotony@sh.itjust.works 6 points 2 months ago

Easiest solution, use fish instead of bash! Default fish keybindings will allow you to just type . . or name a directory similar to how you could do with Zoxide.

Also, wait until you find about pushd and popd ;)

load more comments (1 replies)
[-] h4x0r@lemmy.dbzer0.com 6 points 2 months ago* (last edited 2 months ago)
~$ mkdir -p 1/2/3/4
~$ pushd 1
~/1 ~
1$ pushd 2/3/4
~/1/2/3/4 ~/1 ~
4$ popd
~/1 ~
1$
[-] 6nk06@sh.itjust.works 5 points 2 months ago

The history of the CTO at a previous job was filled with dc and sl because he was a fucking moron. Yes I'm still bitter that he earned way more money than me who had to fix all his mess.

[-] toynbee@lemmy.world 7 points 2 months ago

You could have gifted him some silly fun with the sl package.

[-] unsubtle@sh.itjust.works 5 points 2 months ago

Wait until we tell them about autojump

[-] demunted@lemmy.ml 5 points 2 months ago
[-] Forester@pawb.social 4 points 2 months ago* (last edited 2 months ago)

Why no cd /////// speceficterm if you know how deep it is

Those are supposed to be stars. I'm not fixing this on a phone

load more comments
view more: next ›
this post was submitted on 25 May 2025
901 points (100.0% liked)

linuxmemes

26544 readers
1455 users here now

Hint: :q!


Sister communities:


Community rules (click to expand)

1. Follow the site-wide rules

2. Be civil
  • Understand the difference between a joke and an insult.
  • Do not harrass or attack users for any reason. This includes using blanket terms, like "every user of thing".
  • Don't get baited into back-and-forth insults. We are not animals.
  • Leave remarks of "peasantry" to the PCMR community. If you dislike an OS/service/application, attack the thing you dislike, not the individuals who use it. Some people may not have a choice.
  • Bigotry will not be tolerated.
  • 3. Post Linux-related content
  • Including Unix and BSD.
  • Non-Linux content is acceptable as long as it makes a reference to Linux. For example, the poorly made mockery of sudo in Windows.
  • No porn, no politics, no trolling or ragebaiting.
  • 4. No recent reposts
  • Everybody uses Arch btw, can't quit Vim, <loves/tolerates/hates> systemd, and wants to interject for a moment. You can stop now.
  • 5. 🇬🇧 Language/язык/Sprache
  • This is primarily an English-speaking community. 🇬🇧🇦🇺🇺🇸
  • Comments written in other languages are allowed.
  • The substance of a post should be comprehensible for people who only speak English.
  • Titles and post bodies written in other languages will be allowed, but only as long as the above rule is observed.
  • 6. (NEW!) Regarding public figuresWe all have our opinions, and certain public figures can be divisive. Keep in mind that this is a community for memes and light-hearted fun, not for airing grievances or leveling accusations.
  • Keep discussions polite and free of disparagement.
  • We are never in possession of all of the facts. Defamatory comments will not be tolerated.
  • Discussions that get too heated will be locked and offending comments removed.
  •  

    Please report posts and comments that break these rules!


    Important: never execute code or follow advice that you don't understand or can't verify, especially here. The word of the day is credibility. This is a meme community -- even the most helpful comments might just be shitposts that can damage your system. Be aware, be smart, don't remove France.

    founded 2 years ago
    MODERATORS