Skip to content

Conversation

@ryan-crabbe
Copy link

Summary

  • Change -o/--outfile to accept multiple values via action="append", so users can write multiple output formats in one invocation
  • Each outfile infers its renderer from the file extension (unless -r is explicitly set, which applies to all)
  • No -o or single -o behavior is unchanged
  • Adds tests for multiple outfiles, single outfile, explicit renderer with multiple outfiles, and unrecognized extension error

Closes #422

Allow users to specify -o multiple times to generate multiple output
formats in one run, e.g.:

    pyinstrument -o output.txt -o output.html script.py

Each outfile infers its renderer from the file extension unless -r is
explicitly set. Single -o and no -o behavior is unchanged.

Closes joerick#422
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support multiple -o/--outfile flags in a single invocation

1 participant