Does pip have autocomplete?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
2
down vote

favorite
1












Pip has a long list of commands. Is there any way to use auto-complete by Tab in console (Bash)?







share|improve this question






















  • nice! i it work for me like charm
    – Yurij
    Apr 19 at 15:06










  • @Melebius that counts as an answer. Please answer, ping me and I'll come back to upvote!
    – Fabby
    Apr 19 at 15:11










  • yes, this comment is a right answer for me.
    – Yurij
    Apr 19 at 15:54















up vote
2
down vote

favorite
1












Pip has a long list of commands. Is there any way to use auto-complete by Tab in console (Bash)?







share|improve this question






















  • nice! i it work for me like charm
    – Yurij
    Apr 19 at 15:06










  • @Melebius that counts as an answer. Please answer, ping me and I'll come back to upvote!
    – Fabby
    Apr 19 at 15:11










  • yes, this comment is a right answer for me.
    – Yurij
    Apr 19 at 15:54













up vote
2
down vote

favorite
1









up vote
2
down vote

favorite
1






1





Pip has a long list of commands. Is there any way to use auto-complete by Tab in console (Bash)?







share|improve this question














Pip has a long list of commands. Is there any way to use auto-complete by Tab in console (Bash)?









share|improve this question













share|improve this question




share|improve this question








edited Apr 19 at 15:45









anonymous2

3,14541746




3,14541746










asked Apr 19 at 8:46









Yurij

678




678











  • nice! i it work for me like charm
    – Yurij
    Apr 19 at 15:06










  • @Melebius that counts as an answer. Please answer, ping me and I'll come back to upvote!
    – Fabby
    Apr 19 at 15:11










  • yes, this comment is a right answer for me.
    – Yurij
    Apr 19 at 15:54

















  • nice! i it work for me like charm
    – Yurij
    Apr 19 at 15:06










  • @Melebius that counts as an answer. Please answer, ping me and I'll come back to upvote!
    – Fabby
    Apr 19 at 15:11










  • yes, this comment is a right answer for me.
    – Yurij
    Apr 19 at 15:54
















nice! i it work for me like charm
– Yurij
Apr 19 at 15:06




nice! i it work for me like charm
– Yurij
Apr 19 at 15:06












@Melebius that counts as an answer. Please answer, ping me and I'll come back to upvote!
– Fabby
Apr 19 at 15:11




@Melebius that counts as an answer. Please answer, ping me and I'll come back to upvote!
– Fabby
Apr 19 at 15:11












yes, this comment is a right answer for me.
– Yurij
Apr 19 at 15:54





yes, this comment is a right answer for me.
– Yurij
Apr 19 at 15:54











2 Answers
2






active

oldest

votes

















up vote
2
down vote



accepted










A pip autocompletion plugin for Bash can be found at https://github.com/ekalinin/pip-bash-completion.



You can download it as a ZIP or simply install using Git:



git clone https://github.com/ekalinin/pip-bash-completion.git
sudo cp ./pip-bash-completion/pip /etc/bash_completion.d/
. /etc/bash_completion.d/pip # to enable in the current shell, next time should load automatically





share|improve this answer



























    up vote
    3
    down vote













    A reasonably current pip comes with built-in functionality to create completion helpers for bash, zsh or fish:



    $ pip help completion

    Usage: pip completion [options]

    Description:
    A helper command to be used for command completion.

    Completion Options:
    -b, --bash Emit completion code for bash
    -z, --zsh Emit completion code for zsh
    -f, --fish Emit completion code for fish


    You can use it like so:



    pip completion --bash >> ~/.bashrc


    And then start a new shell or source ~/.bashrc to have it take effect.






    share|improve this answer




















    • For the moment the problem is solved with help of @Melebius. I would try your solution too, thanks.
      – Yurij
      Apr 20 at 15:58










    • Funny that the completion does not install automatically together with pip if the code is contained in it…
      – Melebius
      Apr 21 at 7:18










    • @Melebius there's no good way for it to do so - packages can't touch files in the user home directories, and installing globally to /etc/bash.bashrc is tricky to do automatically
      – muru
      Apr 21 at 11:08










    • @muru As you can see in my answer and the linked page, there is also the directory /etc/bash_completion.d/ where it could be placed more easily.
      – Melebius
      Apr 21 at 15:37






    • 1




      @Melebius which is from the bash-completion package, and those are two rather independent packages. This built-in completion code doesn't depend at all on bash-completion, so why would it use that directory?
      – muru
      Apr 21 at 15:39










    Your Answer







    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "89"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    convertImagesToLinks: true,
    noModals: false,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













     

    draft saved


    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1026332%2fdoes-pip-have-autocomplete%23new-answer', 'question_page');

    );

    Post as a guest






























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    2
    down vote



    accepted










    A pip autocompletion plugin for Bash can be found at https://github.com/ekalinin/pip-bash-completion.



    You can download it as a ZIP or simply install using Git:



    git clone https://github.com/ekalinin/pip-bash-completion.git
    sudo cp ./pip-bash-completion/pip /etc/bash_completion.d/
    . /etc/bash_completion.d/pip # to enable in the current shell, next time should load automatically





    share|improve this answer
























      up vote
      2
      down vote



      accepted










      A pip autocompletion plugin for Bash can be found at https://github.com/ekalinin/pip-bash-completion.



      You can download it as a ZIP or simply install using Git:



      git clone https://github.com/ekalinin/pip-bash-completion.git
      sudo cp ./pip-bash-completion/pip /etc/bash_completion.d/
      . /etc/bash_completion.d/pip # to enable in the current shell, next time should load automatically





      share|improve this answer






















        up vote
        2
        down vote



        accepted







        up vote
        2
        down vote



        accepted






        A pip autocompletion plugin for Bash can be found at https://github.com/ekalinin/pip-bash-completion.



        You can download it as a ZIP or simply install using Git:



        git clone https://github.com/ekalinin/pip-bash-completion.git
        sudo cp ./pip-bash-completion/pip /etc/bash_completion.d/
        . /etc/bash_completion.d/pip # to enable in the current shell, next time should load automatically





        share|improve this answer












        A pip autocompletion plugin for Bash can be found at https://github.com/ekalinin/pip-bash-completion.



        You can download it as a ZIP or simply install using Git:



        git clone https://github.com/ekalinin/pip-bash-completion.git
        sudo cp ./pip-bash-completion/pip /etc/bash_completion.d/
        . /etc/bash_completion.d/pip # to enable in the current shell, next time should load automatically






        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Apr 20 at 5:33









        Melebius

        3,75841636




        3,75841636






















            up vote
            3
            down vote













            A reasonably current pip comes with built-in functionality to create completion helpers for bash, zsh or fish:



            $ pip help completion

            Usage: pip completion [options]

            Description:
            A helper command to be used for command completion.

            Completion Options:
            -b, --bash Emit completion code for bash
            -z, --zsh Emit completion code for zsh
            -f, --fish Emit completion code for fish


            You can use it like so:



            pip completion --bash >> ~/.bashrc


            And then start a new shell or source ~/.bashrc to have it take effect.






            share|improve this answer




















            • For the moment the problem is solved with help of @Melebius. I would try your solution too, thanks.
              – Yurij
              Apr 20 at 15:58










            • Funny that the completion does not install automatically together with pip if the code is contained in it…
              – Melebius
              Apr 21 at 7:18










            • @Melebius there's no good way for it to do so - packages can't touch files in the user home directories, and installing globally to /etc/bash.bashrc is tricky to do automatically
              – muru
              Apr 21 at 11:08










            • @muru As you can see in my answer and the linked page, there is also the directory /etc/bash_completion.d/ where it could be placed more easily.
              – Melebius
              Apr 21 at 15:37






            • 1




              @Melebius which is from the bash-completion package, and those are two rather independent packages. This built-in completion code doesn't depend at all on bash-completion, so why would it use that directory?
              – muru
              Apr 21 at 15:39














            up vote
            3
            down vote













            A reasonably current pip comes with built-in functionality to create completion helpers for bash, zsh or fish:



            $ pip help completion

            Usage: pip completion [options]

            Description:
            A helper command to be used for command completion.

            Completion Options:
            -b, --bash Emit completion code for bash
            -z, --zsh Emit completion code for zsh
            -f, --fish Emit completion code for fish


            You can use it like so:



            pip completion --bash >> ~/.bashrc


            And then start a new shell or source ~/.bashrc to have it take effect.






            share|improve this answer




















            • For the moment the problem is solved with help of @Melebius. I would try your solution too, thanks.
              – Yurij
              Apr 20 at 15:58










            • Funny that the completion does not install automatically together with pip if the code is contained in it…
              – Melebius
              Apr 21 at 7:18










            • @Melebius there's no good way for it to do so - packages can't touch files in the user home directories, and installing globally to /etc/bash.bashrc is tricky to do automatically
              – muru
              Apr 21 at 11:08










            • @muru As you can see in my answer and the linked page, there is also the directory /etc/bash_completion.d/ where it could be placed more easily.
              – Melebius
              Apr 21 at 15:37






            • 1




              @Melebius which is from the bash-completion package, and those are two rather independent packages. This built-in completion code doesn't depend at all on bash-completion, so why would it use that directory?
              – muru
              Apr 21 at 15:39












            up vote
            3
            down vote










            up vote
            3
            down vote









            A reasonably current pip comes with built-in functionality to create completion helpers for bash, zsh or fish:



            $ pip help completion

            Usage: pip completion [options]

            Description:
            A helper command to be used for command completion.

            Completion Options:
            -b, --bash Emit completion code for bash
            -z, --zsh Emit completion code for zsh
            -f, --fish Emit completion code for fish


            You can use it like so:



            pip completion --bash >> ~/.bashrc


            And then start a new shell or source ~/.bashrc to have it take effect.






            share|improve this answer












            A reasonably current pip comes with built-in functionality to create completion helpers for bash, zsh or fish:



            $ pip help completion

            Usage: pip completion [options]

            Description:
            A helper command to be used for command completion.

            Completion Options:
            -b, --bash Emit completion code for bash
            -z, --zsh Emit completion code for zsh
            -f, --fish Emit completion code for fish


            You can use it like so:



            pip completion --bash >> ~/.bashrc


            And then start a new shell or source ~/.bashrc to have it take effect.







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered Apr 20 at 5:40









            muru

            129k19272462




            129k19272462











            • For the moment the problem is solved with help of @Melebius. I would try your solution too, thanks.
              – Yurij
              Apr 20 at 15:58










            • Funny that the completion does not install automatically together with pip if the code is contained in it…
              – Melebius
              Apr 21 at 7:18










            • @Melebius there's no good way for it to do so - packages can't touch files in the user home directories, and installing globally to /etc/bash.bashrc is tricky to do automatically
              – muru
              Apr 21 at 11:08










            • @muru As you can see in my answer and the linked page, there is also the directory /etc/bash_completion.d/ where it could be placed more easily.
              – Melebius
              Apr 21 at 15:37






            • 1




              @Melebius which is from the bash-completion package, and those are two rather independent packages. This built-in completion code doesn't depend at all on bash-completion, so why would it use that directory?
              – muru
              Apr 21 at 15:39
















            • For the moment the problem is solved with help of @Melebius. I would try your solution too, thanks.
              – Yurij
              Apr 20 at 15:58










            • Funny that the completion does not install automatically together with pip if the code is contained in it…
              – Melebius
              Apr 21 at 7:18










            • @Melebius there's no good way for it to do so - packages can't touch files in the user home directories, and installing globally to /etc/bash.bashrc is tricky to do automatically
              – muru
              Apr 21 at 11:08










            • @muru As you can see in my answer and the linked page, there is also the directory /etc/bash_completion.d/ where it could be placed more easily.
              – Melebius
              Apr 21 at 15:37






            • 1




              @Melebius which is from the bash-completion package, and those are two rather independent packages. This built-in completion code doesn't depend at all on bash-completion, so why would it use that directory?
              – muru
              Apr 21 at 15:39















            For the moment the problem is solved with help of @Melebius. I would try your solution too, thanks.
            – Yurij
            Apr 20 at 15:58




            For the moment the problem is solved with help of @Melebius. I would try your solution too, thanks.
            – Yurij
            Apr 20 at 15:58












            Funny that the completion does not install automatically together with pip if the code is contained in it…
            – Melebius
            Apr 21 at 7:18




            Funny that the completion does not install automatically together with pip if the code is contained in it…
            – Melebius
            Apr 21 at 7:18












            @Melebius there's no good way for it to do so - packages can't touch files in the user home directories, and installing globally to /etc/bash.bashrc is tricky to do automatically
            – muru
            Apr 21 at 11:08




            @Melebius there's no good way for it to do so - packages can't touch files in the user home directories, and installing globally to /etc/bash.bashrc is tricky to do automatically
            – muru
            Apr 21 at 11:08












            @muru As you can see in my answer and the linked page, there is also the directory /etc/bash_completion.d/ where it could be placed more easily.
            – Melebius
            Apr 21 at 15:37




            @muru As you can see in my answer and the linked page, there is also the directory /etc/bash_completion.d/ where it could be placed more easily.
            – Melebius
            Apr 21 at 15:37




            1




            1




            @Melebius which is from the bash-completion package, and those are two rather independent packages. This built-in completion code doesn't depend at all on bash-completion, so why would it use that directory?
            – muru
            Apr 21 at 15:39




            @Melebius which is from the bash-completion package, and those are two rather independent packages. This built-in completion code doesn't depend at all on bash-completion, so why would it use that directory?
            – muru
            Apr 21 at 15:39

















             

            draft saved


            draft discarded















































             


            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1026332%2fdoes-pip-have-autocomplete%23new-answer', 'question_page');

            );

            Post as a guest













































































            Popular posts from this blog

            Which professions warranted travel in Medieval times?

            How do so many people here on Academia.SE, and in general, afford lavish higher education programs?

            Trouble downloading packages list due to a “Hash sum mismatch” error