Pages
Home
Info
HowTo
Code
Publications
Music
Finance
Links
Legal
21/09/2019
[bash] Store content of file in a variable
In bash, it is possible to store the content of a file in a variable simply with:
file=/path/to/somefile.something
content="`cat $file`"
Note the special quotes used
No comments:
Post a Comment
With great power comes great responsibility
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
With great power comes great responsibility