$ cat /var/log/logfile | grep -n section_start which gives me required line numbers. and then:
$ nano +lineno /var/log/logfile
and for configs, of course.
$ cat /var/log/logfile | grep -n section_start which gives me required line numbers. and then:
$ nano +lineno /var/log/logfile
and for configs, of course.
It is absolutely a learning curve, but the power of vim is insane. "dd" deletes lines, "A" appends to the end, "I" inserts at the beginning, "<lineno>G" jumps to a line number, all little tweaks that I use nearly every day in editing files quickly. It's especially nice when editing known_hosts where it tells you the line of the offending key, just "<line#>Gdd:wq" and it's done.
Nano seems to be far slower than vim for opening large files.
Just quickly testing on a 200M 500k row text file on a SSD:
Vim opens practically instantly.
nano takes over 10 seconds to display text, but works well after that.