Victoria's Neofeed
  • 2020-08-22 16:29:10 +0000 UTC
    Victoria Drake

    Victoria Drake

    Aug 22, 2020

    Use shell parameter expansion to replace all the newlines in a text file with %0A URL encoding of a newline:

    OUTPUT=$(cat output.txt)
    FORMATTED=${OUTPUT//$'\n'/%0A}
    
    2020-08-22 16:29:10 +0000 UTC 1450 days ago
    webmention this