Created
July 30, 2021 14:37
-
-
Save slash-cyberpunk/5b9d41a916cc1ee9f4da231af32873b7 to your computer and use it in GitHub Desktop.
Bash multiline from file to one line
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tr '\n' ',' < requirements.txt | sed 's/,$/\n/' | |
or | |
paste -sd ',' requirements.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment