fork(1) download
  1. #!/bin/bash
  2. xml='<url><loc>http://w...content-available-to-author-only...e.com/</loc><changefreq>daily</changefreq></url>
  3. <url><loc>http://w...content-available-to-author-only...e.com/en/rWGpqHtU/</loc><changefreq>daily</changefreq></url>
  4. <url><loc>http://w...content-available-to-author-only...e.com/de/hVHaViPm/</loc><changefreq>daily</changefreq></url>
  5. <url><loc>http://w...content-available-to-author-only...e.com/uk/ysbqqLRj/</loc><changefreq>daily</changefreq></url>
  6. <url><loc>http://w...content-available-to-author-only...e.com/jp/EUvnikfR/</loc><changefreq>daily</changefreq></url>
  7. <url><loc>http://w...content-available-to-author-only...e.com/hk/UqGauZTv/</loc><changefreq>daily</changefreq></url>
  8. <url><loc>http://w...content-available-to-author-only...e.com/en/rWGpqHtU/xxx/</loc><changefreq>daily</changefreq></url>
  9. <url><loc>http://w...content-available-to-author-only...e.com/de/hVHaViPm/xxx/</loc><changefreq>daily</changefreq></url>
  10. <url><loc>http://w...content-available-to-author-only...e.com/uk/ysbqqLRj/xxx/</loc><changefreq>daily</changefreq></url>
  11. <url><loc>http://w...content-available-to-author-only...e.com/jp/EUvnikfR/xxx/</loc><changefreq>daily</changefreq></url>
  12. <url><loc>http://w...content-available-to-author-only...e.com/hk/UqGauZTv/xxx/</loc><changefreq>daily</changefreq></url>'
  13. grep -Eo "https?://www\.example\.com/[uh]k/[^/]+/[^/]+?" <<< "$xml"
Success #stdin #stdout 0s 4356KB
stdin
Standard input is empty
stdout
http://w...content-available-to-author-only...e.com/uk/ysbqqLRj/<
http://w...content-available-to-author-only...e.com/hk/UqGauZTv/<
http://w...content-available-to-author-only...e.com/uk/ysbqqLRj/xxx
http://w...content-available-to-author-only...e.com/hk/UqGauZTv/xxx