LukeSmithxyz / lb

Blog & RSS system in less than 100 lines of shell script
GNU General Public License v3.0
280 stars 81 forks source link

Locales break the RSS feed. #21

Closed pixelcmtd closed 5 years ago

pixelcmtd commented 5 years ago

I have my LANG always set to en_US, but some of my LCs are usually de_DE, so date +%a and date +%b output German abbreviations, which completely broke my RSS feed.

In fact, RSS uses RFC 2822, which can be accomplished by just using date -R, otherwise you could always set LC_TIME=C.

pixelcmtd commented 5 years ago

One update on date -R: It seems like only the GNU and BSD coreutils implement this option (at least it's not in the macOS manpage), so I'd just LC_TIME=en_US.