Timeline for Get contents of a file from first instance to last instance of some arbitrary string
Current License: CC BY-SA 4.0
15 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Oct 29, 2019 at 19:11 | answer | added | Jeff Schaller♦ | timeline score: 1 | |
| Oct 29, 2019 at 18:53 | history | edited | Captain Man | CC BY-SA 4.0 |
Clarify the file's format
|
| Oct 29, 2019 at 18:35 | answer | added | izzy | timeline score: 0 | |
| Aug 17, 2016 at 14:10 | history | edited | Captain Man | CC BY-SA 3.0 |
Update example on old question
|
| Mar 17, 2016 at 23:23 | history | edited | Gilles 'SO- stop being evil' |
edited tags
|
|
| Mar 17, 2016 at 16:36 | vote | accept | Captain Man | ||
| Mar 17, 2016 at 16:19 | answer | added | mik | timeline score: 4 | |
| Mar 17, 2016 at 15:37 | comment | added | phk | Ok, then it might be related to: stackoverflow.com/questions/20096639/… | |
| Mar 17, 2016 at 15:33 | comment | added | Captain Man | @phk no, that's not what I meant, I've updated with an example. | |
| Mar 17, 2016 at 15:32 | comment | added | don_crissti |
This has been asked before more than once - here's just an example: How can I “grep” patterns across multiple lines? so in your case pcregrep -M 'foo.*(\n|.)*foo' infile
|
|
| Mar 17, 2016 at 15:31 | comment | added | Captain Man |
@Jeff I don't mind at all, I just tagged with grep and sed because they seemed like the tools that would be able to do this.
|
|
| Mar 17, 2016 at 15:30 | history | edited | Captain Man | CC BY-SA 3.0 |
added 180 characters in body
|
| Mar 17, 2016 at 15:28 | comment | added | phk |
So you want an interactive grep, one where you only get shown one result at a time and you can switch between them?
|
|
| Mar 17, 2016 at 15:23 | comment | added | Jeff Schaller♦ |
you say "don't want to grep" but you tagged sed and grep; are you opposed to calling sed before less?
|
|
| Mar 17, 2016 at 15:01 | history | asked | Captain Man | CC BY-SA 3.0 |