mirror of
https://github.com/r4sas/PBinCLI
synced 2025-03-13 05:41:08 +00:00
Add CLI autocompletion using argcomplete
This commit is contained in:
parent
3f30828e1a
commit
b40f48295a
@ -1,7 +1,10 @@
|
||||
#!/usr/bin/env python
|
||||
# PYTHON_ARGCOMPLETE_OK
|
||||
import os, sys, argparse
|
||||
from distutils.util import strtobool
|
||||
|
||||
import argcomplete
|
||||
|
||||
import pbincli.actions
|
||||
from pbincli.api import PrivateBin
|
||||
from pbincli.utils import PBinCLIException, PBinCLIError, validate_url_ending
|
||||
@ -124,6 +127,9 @@ def main():
|
||||
delete_parser.add_argument("-d", "--debug", default=False, action="store_true", help="Enable debug output")
|
||||
delete_parser.set_defaults(func=pbincli.actions.delete)
|
||||
|
||||
# Add argcomplete trigger
|
||||
argcomplete.autocomplete(parser)
|
||||
|
||||
# parse arguments
|
||||
args = parser.parse_args()
|
||||
|
||||
|
@ -2,3 +2,4 @@ pycryptodome
|
||||
sjcl
|
||||
base58
|
||||
requests
|
||||
argcomplete
|
||||
|
Loading…
x
Reference in New Issue
Block a user