Search code examples
linuxbash-completionphabricatorarcanist

How to add in bash for auto completion of arcanist commands


I am new to linux.

I am trying to set up arcanist.

I am done with git clone and adding the path in environment variable, however I am confused on how to set up the tab completion for arcanist commands.

In the arcanist user guide it says that you need to add source /path/to/arcanist/resources/shell/bash-completion to your .bashrc, .profile files.

What are these files and how can I edit them to work with arcanist with the tab completion.


Solution

  • After lot of googling and asking people, I finally did it.

    First of all I had to export the path where my arcanist code from the github has been cloned in the ~/.bashsrc file(in bold below)

    export PATH="$PATH:$HOME/.rvm/bin:$HOME/arcanist/bin/"

    After this command, I copied the function which was present in the /arcanist/resources/shell/bash-completion into the bashrc file

    And then I closed and open the terminal and bingo I was able to get arc and it's command as auto completion on striking tab.

    Thanks ap0 for the comments.