regex to export all dotfiles or wordpress resized images to new list

awk '/\/\./ { print }' all.txt > dotfiles.sh

  1. call awk and open command with single quote
  2. open pattern with slash
  3. pattern is
    1. escaped slash
    2. escaped dot
  4. close pattern with slash
  5. call print and close command with a single quote
  6. input file name
  7. redirect results to
  8. output file name

awk '/.+[0-9]{2,4}x[0-9]{2,4}\.[a-z]{3,4}/ { print }' all.txt > wpresizes.sh

  1. call awk and open command with single quote
  2. open pattern with slash
  3. pattern is
    1. at least one character
    2. from 2 to 4 numerals
    3. an ex
    4. from 2 to 4 numerals
    5. a dot
    6. 3 or 4 lowercase letters (file name extension
  4. close pattern with slash
  5. call print and close command with a single quote
  6. input file name
  7. redirect results to
  8. output file name