• forbiddencherry@lemmy.today
    link
    fedilink
    arrow-up
    17
    ·
    edit-2
    10 hours ago

    For recursive behavior, tell me if each of these requires -r or -R (or either) without looking it up (man page, --help, web, etc):

    • chown
    • cp
    • ls
    • rsync
    • scp
    • zip
    • MoffKalast@lemmy.world
      link
      fedilink
      arrow-up
      3
      ·
      edit-2
      3 hours ago

      Also whoever decided what the tar flags will be needs to be hit with a brick, repeatedly if possible.

    • dadarobot@lemmy.ml
      link
      fedilink
      arrow-up
      2
      ·
      6 hours ago

      without looking it up:

      chown -R

      cp -r

      ls -r

      rsync. (idk, i always google this one)

      scp -r

      zip -r

      but why not look it up? you either use a tool and arguments often enough to memorize it, or you don’t.

      • forbiddencherry@lemmy.today
        link
        fedilink
        arrow-up
        2
        ·
        edit-2
        6 hours ago

        It’s not about looking it up or not, it’s a challenge to the boasting of the commenter above me in the context of the OP’s post.

        • dadarobot@lemmy.ml
          link
          fedilink
          arrow-up
          1
          ·
          6 hours ago

          ah yeah that’s fair. but also i kinda agree with that person’s response. getting frustrated with linux doesnt mean linux sucks, it means you are learning. ive been using linux for over 20 years, and i still find plenty of things that take me out of my element. and that’s a good thing.

    • prole@lemmy.blahaj.zone
      link
      fedilink
      arrow-up
      4
      ·
      edit-2
      9 hours ago

      without looking it up (man page, --help, web, etc):

      But why? Why would you need to do this when we have access to these tools?

      Pointless test.

    • PlexSheep@infosec.pub
      link
      fedilink
      arrow-up
      2
      ·
      edit-2
      8 hours ago

      -R -r -R -r -r -r I think

      I don’t know if this is true, but if yes, then -R is a GNU weirdness No wait that doesn’t make sense. ls is also GNU.

    • craftrabbit@lemmy.zip
      link
      fedilink
      arrow-up
      3
      ·
      10 hours ago

      Oh god oh damn my kde doesn’t tell me that…

      Okay I’ll give it a whirl:

      • chown: yes, I think
      • cp: no, pretty sure
      • ls: what? Like for a tree? For folder size? Idk I say yes because there’s nothing recursive to me about standard ls
      • rsync: literally no clue have never used it but I’d guess no
      • scp: yes pretty confident
      • zip: yes also pretty confident

      The actual reason I barely ever find Linux annoying is because my Fedora KDE just does all I need it to pretty much all the time.

      • forbiddencherry@lemmy.today
        link
        fedilink
        arrow-up
        3
        ·
        10 hours ago

        With ls you can list the contents of directories recursively. Or you can list the contents in reverse order. One of them requires a lowercase “r”, one requires uppercase, but which is which? It’s not such a big deal that different commands have inconsistent syntax, but even having run Linux as my primary OS since 2004, and before that Unix since 1993, I still have to look these up sometimes.

      • craftrabbit@lemmy.zip
        link
        fedilink
        arrow-up
        2
        ·
        10 hours ago

        Aight I got cp wrong, which is kinda silly since I knew it for scp but I’m happy with that nonetheless

    • forbiddencherry@lemmy.today
      link
      fedilink
      arrow-up
      2
      ·
      10 hours ago

      A couple more challenges:

      • As an unprivileged user, append multiple lines to a file owned by root, using sudo and a here document.
      • Redirect both stdout and stderr to a file using Bourne shell syntax (not bash!)
    • tyler@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      10 hours ago

      Every damn time.

      I think rsync is lowercase, and maybe zip. The rest I think are uppercase. Complete guess though.

    • Eager Eagle@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      edit-2
      9 hours ago

      funny I never had this specific issue with recursive behavior. I find it obvious that only rsync and zip are recursive by default, but I’m not sure why.

      edit: ah you mean which ones are lowercase or uppercase, that makes more sense.