• 6 Posts
  • 1.16K Comments
Joined 2 years ago
cake
Cake day: July 1st, 2023

help-circle


  • I don’t think there’s any reason to use rmdir unless you write (Ba)sh scripts, and you want to make sure that the directory is indeed empty. Just use rm -r.

    Also note that you can use rmdir -p this/is/some/path to remove all nested directories including the parent (this here). But this will only work if there’s exactly one directory per parent directory, and the last directory doesn’t have any files (including directories). This might be helpful for some scripts.

    rmdir -r isn’t a thing, because that would invalidate the reason this command exists.



  • CTRL+L and clear command do two different things (at least when using Bash on Debian):

    • CTRL+L scrolls the terminal output one screen so you don’t see your previous output, unless you scroll up;
    • clear does indeed clear terminal output completely, and your previous command history is available only through the history command.

    If you want CTRL+L to clear your screen completely you can add following to the .bashrc (or other file that is sourced when starting Bash, e.g. .bash_bindings):

    bind -x '"\C-l":clear'

    Note that it might not work if you use Vi mode inside Bash, but who does that.









  • Well, I am from Poland, and I don’t know any friend who is overly obsessed about women breasts. But if you look into American media, especially from few decades ago when it was normal to oversexualize women, it’s all about that.

    I haven’t been to Germany yet, so I don’t know what’s normal there. But I might just have overgeneralized my observation, yeah.