INF(1)

NAME
inf - instant feedback for your compile and run loop

SYNOPSIS

inf [options] [compile_cmd...]

DESCRIPTION

inf monitors files and executes the given commands whenever they change. It provides convenience flags for common development workflows.

OPTIONS

-r, --run run_cmd
    Execute run_cmd after compile_cmd finishes successfully.

-i, --input input_file
    Pipe input_file to run_cmd on standard input. Requires -r.

-m, --monitor file[,file...]
    Append file(s) to the list of paths to monitor.

-n, --noparse
    Skip search for *.* files in compile_cmd.

-x, --refresh
    Recompile immediately whenever any monitored file changes.

-p, --postpone
    Wait for a change in a monitored file before the first compilation.

-q, --quiet
    Suppress compiler output.

-w, --waitkey
    Wait for a key press before each recompilation.

-z, --zen
    Disable meta-headers output.

-v, --verbose
    Always print compiler output (overrides -q, --quiet).

-d, --debug
    Print the parsed arguments and exit.

-V, --version
    Display version information and exit.

-h, --help
    Show usage information.

EXAMPLES

Rebuild and run when main.c changes:

    $ inf --run ./main gcc -o main main.c

Pipe input into the binary when either main.c or input.txt changes:

    $ inf --input input.txt --run ./main gcc -o main main.c

For build systems, list every source file that should trigger a rebuild. Here the shell expands the globs and pipes them into inf (inf monitors all *.c and *.h files in src/):

    $ echo src/*.c src/*.h | inf --run "make test" make -j4

Run a static type checker in zen mode (no meta-headers), whenever any Python file in src/ or its subdirectories changes:

    $ inf -z mypy src/**/*.py

AUTHOR

Nikolai Oplachko