Using sed to append something after search pattern.
sed -i '/PATTERN/a\APPENDED' <file>
For example, this will add "sample": "sample x", after "flows": .*, to test_inactive.json
sed -i '/"flows": .*,/a\\ "sample": "sample x",' test.json
Using sed to append something after search pattern.
sed -i '/PATTERN/a\APPENDED' <file>
For example, this will add "sample": "sample x", after "flows": .*, to test_inactive.json
sed -i '/"flows": .*,/a\\ "sample": "sample x",' test.json