Dre4m Shell
Server IP : 85.214.239.14  /  Your IP : 3.145.2.87
Web Server : Apache/2.4.62 (Debian)
System : Linux h2886529.stratoserver.net 4.9.0 #1 SMP Tue Jan 9 19:45:01 MSK 2024 x86_64
User : www-data ( 33)
PHP Version : 7.4.18
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
MySQL : OFF  |  cURL : OFF  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : OFF
Directory :  /proc/self/root/proc/2/root/bin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /proc/self/root/proc/2/root/bin/register-python-argcomplete
#!/usr/bin/python3
# PYTHON_ARGCOMPLETE_OK

# Copyright 2012-2021, Andrey Kislyuk and argcomplete contributors.
# Licensed under the Apache License. See https://github.com/kislyuk/argcomplete for more info.

'''
Register a Python executable for use with the argcomplete module.

To perform the registration, source the output of this script in your bash shell
(quote the output to avoid interpolation).

Example:

    $ eval "$(register-python-argcomplete my-favorite-script.py)"

For Tcsh

    $ eval `register-python-argcomplete --shell tcsh my-favorite-script.py`

For Fish

    $ register-python-argcomplete --shell fish my-favourite-script.py > ~/.config/fish/my-favourite-script.py.fish
'''

import sys
import argparse
import argcomplete


parser = argparse.ArgumentParser(
    description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter)

parser.add_argument(
    '--no-defaults',
    dest='use_defaults', action='store_false', default=True,
    help='When no matches are generated, do not fallback to readline\'s default completion')
parser.add_argument(
    '--complete-arguments',
    nargs=argparse.REMAINDER,
    help='arguments to call complete with; use of this option discards default options')
parser.add_argument(
    '-s', '--shell',
    choices=('bash', 'tcsh', 'fish'), default='bash',
    help='output code for the specified shell')
parser.add_argument(
    '-e', '--external-argcomplete-script',
    help='external argcomplete script for auto completion of the executable')

parser.add_argument(
    'executable',
    nargs='+',
    help='executable to completed (when invoked by exactly this name)')

argcomplete.autocomplete(parser)

if len(sys.argv) == 1:
    parser.print_help()
    sys.exit(1)

args = parser.parse_args()


sys.stdout.write(argcomplete.shellcode(
    args.executable, args.use_defaults, args.shell, args.complete_arguments, args.external_argcomplete_script))

Anon7 - 2022
AnonSec Team