Follow-up Comment #3, patch #7963 (project weechat):
Ah, I didn't know _ wasn't considered word boundary. You don't need the {1}
though:
([^0-9A-Z]|^)([0-9A-F]{8})([^0-9A-Z]|$)
"foobar_0BADF00D_".match(/([^0-9A-Z]|^)([0-9A-F]{8})([^0-9A-Z]|$)/)[2] =>
"0BADF00D"
Though I'm not sure if we need to special-case ^ and $, but it should be cheap
either way. If someone sends a file which is named their CRC32 only, it would
still work. So there may be a single user who has that.
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/patch/?7963>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
_______________________________________________
Weechat-dev mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/weechat-dev