Linux Command Line (45) xargs

Поделиться
HTML-код
  • Опубликовано: 12 сен 2024

Комментарии • 15

  • @batchrocketproject4720
    @batchrocketproject4720 2 месяца назад

    I've never been confident using xargs and often get unintended results. Many of the videos I've watched on it have somewhat added to my confusion and the examples relied on tend to be lazy. This video has helped, in part because you voice the meaning of each part of the command as you type it. I do the same but now find some of my assumptions were not correct because I was voicing the wrong words. It'll take me a while to confidently use xargs but this one has set me on the right road. The -t flag will be very useful to me too. Thanks.

  • @biswanathdutta4219
    @biswanathdutta4219 3 года назад +3

    I used to struggle with xargs. Wish I had this video back then.
    You are doing great service sir.

  • @janekmachnicki2593
    @janekmachnicki2593 Месяц назад

    You are a great teatcher .Thanks !!

  • @zhenyutan7618
    @zhenyutan7618 3 года назад +4

    I feel this is not said enough- love these videos!

  • @noam65
    @noam65 Месяц назад

    That's an excellent treatment.

  • @mohammedalbatati5529
    @mohammedalbatati5529 3 года назад +1

    Many thanks, I learned a lot from your channel.

  • @habibk9538
    @habibk9538 2 года назад

    AWESOME session on xargs.....

  • @rsmith31416
    @rsmith31416 3 года назад +2

    There is an issue with your command at 5:09. Even though you added the -0 flag, `ls` doesn't know about that and directories/files with single or double quotation marks won't be parsed correctly. (e.g. mkdir -p '12" records'; ls | xargs -0 -I {} rmdir {} -> rmdir: failed to remove '12" records'$'
    ': No such file or directory). As an alternative to `ls`, use find . -print0 | xargs -0 or populate an array and loop over its values `arr=(*); for file in "${arr[@]}"; ... ` . As a third option, xargs -d '
    ' will split your input correctly, but it will break with potentially malicious filenames as those can include newlines.

  • @bobbysue517
    @bobbysue517 3 года назад

    Very much appreciate you and your videos.

  • @GooogleGoglee
    @GooogleGoglee 3 года назад

    Thank you sir! Love your videos!

  • @michaelruth5775
    @michaelruth5775 3 года назад

    Great....as always.

  • @runrin_
    @runrin_ 3 года назад

    I've never used xargs for any of these particular use cases. I've always used a combination of for, sed, awk, etc.

    • @rodricbr
      @rodricbr 3 года назад +1

      same, this is going to help me a lot

  • @safeermn3134
    @safeermn3134 3 года назад

    love your videos sir. can you teach me software engineering.

  • @bendokis4989
    @bendokis4989 6 месяцев назад

    5:46 - $ ls | xargs -n1 -I {} echo is a directory: {} 1>/dev/null
    xargs: warning: options --max-args and --replace/-I/-i are mutually exclusive, ignoring previous --max-args value