Skip to content

Allow regex parsing of files #70

@koseduhemak

Description

@koseduhemak

Hi,

I got an idea for a new feature: Regex parsing which contents of a file should be extracted.
As files tend to change, it would be very helpful to enhance the parser to allow something like:
my-file.json#R:/"scripts".*\]/imgs
which should match the following contents of my-file.json:

... other content here...
"scripts": [
    "scripts/general-env-variables.sh",
    "scripts/ca-certificates.sh",
    "scripts/apt-install.sh",
    "scripts/timezone-fix.sh",
    "scripts/python-pip-repository.sh",
    "scripts/cloudfoundry-cli.sh",
]
... other content here...

See here for example: https://regex101.com/r/URfVWn/1

This way we can extract in a more flexible / reliable way and do not need to adjust start and end of line if source files are changing...

What do you think?

Best wishes,
koseduhemak

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions