Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Use nodejs in bash script for string manipulation
$ echo "FOO_BAR" | node -p 'require("fs").readFileSync(process.stdin.fd, "utf-8").replace("_", "..")'
FOO..BAR
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.