Description
Is your feature request related to a problem? Please describe.
When running a script over some input that is neither part of the sources, nor the resources, I would like for --watch
mode to be configurable, so it can react to file events from files/folders of my choosing.
Examples:
- Static site generator which reacts to both markdown changes, and build script changes
- Any script with file inputs
Describe the solution you'd like
scala-cli run --watch --watching folder/**/*.md
Or a more appropriate name
Describe alternatives you've considered
Manually invoking the command every time I change my markdown files. Like a caveman.
Additional context
Ammonite has it as part of the interp
api: https://github.com/com-lihaoyi/Ammonite/blob/main/amm/interp/api/src/main/scala/ammonite/interp/api/InterpAPI.scala#L18 which is strictly more powerful, but I feel like with scala-cli focus on command line args and directives, the simpler solution would be sufficient for many workflows.