Tuesday, January 2, 2024
How to store command output in bash variable
x="$(head -15 testfile.txt)"
This would store the first 15 lines of testfile.txt in variable x.
No comments:
Post a Comment
Newer Post
Older Post
Home
View mobile version
Subscribe to:
Post Comments (Atom)
Popular Posts
Sexionnaire
The other day, while browsing Wikipedia, I wondered how hard it must be to have weird fetishes without being able to share them with someone...
How To Make Portable Applications
Don't read this article. I've written a much better one which you can find here . The purpose of this (late-night) post is to sho...
Aperito v1.6.1
Version 1.6.1 of Aperito fixes some typos in some error messages and makes Aperito recognize non-existing types of "keep" and...
No comments:
Post a Comment