I'm trying to search within all settings.ini files and determine which of them contain a specific multiline string.
My directory structures look like this
/
|-- folder
|---- settings.ini
|-- folder
|---- settings.ini
|-- folder
|---- settings.ini
|-- folder
|---- settings.ini
.
.
.
The string I am trying to find looks like this
[NeatFeature]
Enabled=1
The files themselves will contain either Enabled=1 or Enabled=0
I'm able to get a single line search working like this
find . -maxdepth 2 -name 'settings.ini' -exec grep '\[TransactionalMessageSearch\]' {} +
The problem is I can't figure out how to also include the Enabled=1 portion. I can't just search for that on it's own as that patter occurs multiple times throughout the files under different headings.
Any ideas?