Changes
Jump to navigation
Jump to search
← Older edit
Linux command: awk
(view source)
Revision as of 09:05, 16 November 2018
277 bytes added
,
09:05, 16 November 2018
→Print columns as lines
Line 34:
Line 34:
| |--------> run the loop as long as there is a field number x
| |--------> run the loop as long as there is a field number x
|------------> initialize x to 1</nowiki>
|------------> initialize x to 1</nowiki>
+
== Print from line x to line y ==
+
<nowiki>I suggest the sed solution, but for the sake of completeness,
+
awk 'NR >= 57890000 && NR <= 57890010' /path/to/file
+
To cut out after the last line:
+
+
awk 'NR < 57890000 { next } { print } NR == 57890010 { exit }' /path/to/file</nowiki>
== Cheatsheet ==
== Cheatsheet ==
Rafahsolis
Bureaucrats
,
Administrators
2,306
edits
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
Page
Discussion
Variants
Views
Read
View source
View history
More
Search
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Tools
Special pages
Printable version