Pages
Home
Legal
Info
HowTos
Code
Publications
Music
Finance
Links
Comics
Donate
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
View mobile version
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
With great power comes great responsibility