Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python Module Commandline Arguments #74

Open
rickhg12hs opened this issue Dec 24, 2017 · 2 comments
Open

Python Module Commandline Arguments #74

rickhg12hs opened this issue Dec 24, 2017 · 2 comments

Comments

@rickhg12hs
Copy link

rickhg12hs commented Dec 24, 2017

How can Python Module commandline arguments be defined and used?

I see in README.md...

NOTE: ./python_example.py claims that it has additional parameters -f and -q. However, these parameters have no effect. They are listed just for a demonstration of the optparse.OptionParser class that can be used in python Nemea modules for unified help output.

... but looking at the source, there is no mention of the additional parameters.

Are additional parameters possible?

@rickhg12hs
Copy link
Author

... Ah, OK. Looks like I need to do my own argparse before calling TrapCtx.init with the remaining commandline args.

@rickhg12hs
Copy link
Author

... Although....

What is your recommended method to include Python module commandline arguments? TrapCtx has it's own argument parsing and help. How should more parameters be integrated?

@rickhg12hs rickhg12hs reopened this Dec 24, 2017
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

No branches or pull requests

1 participant