double colon autocomplete

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





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;







up vote
-1
down vote

favorite












I have a couple of bash function librarys that follow the double colon name convention ie



function lib::my_func() 
echo "$1"



All is well with the functions but the bash autocomplete in ubuntu turnslib::my_func into lib::my_func" whilst this still works it horrid to look at. And if I type lib::[TAB] it completely resets auto-completion.



I've searched around and found mention of how to fix this with a config.d file. This is what I tested but no joy:



_lib()

local cur
_get_comp_words_by_ref -n : cur
__ltrim_colon_completions "$cur"

complete -F _lib lib


I placed this in /etc/bach_completion.d/lib







share|improve this question



























    up vote
    -1
    down vote

    favorite












    I have a couple of bash function librarys that follow the double colon name convention ie



    function lib::my_func() 
    echo "$1"



    All is well with the functions but the bash autocomplete in ubuntu turnslib::my_func into lib::my_func" whilst this still works it horrid to look at. And if I type lib::[TAB] it completely resets auto-completion.



    I've searched around and found mention of how to fix this with a config.d file. This is what I tested but no joy:



    _lib()

    local cur
    _get_comp_words_by_ref -n : cur
    __ltrim_colon_completions "$cur"

    complete -F _lib lib


    I placed this in /etc/bach_completion.d/lib







    share|improve this question























      up vote
      -1
      down vote

      favorite









      up vote
      -1
      down vote

      favorite











      I have a couple of bash function librarys that follow the double colon name convention ie



      function lib::my_func() 
      echo "$1"



      All is well with the functions but the bash autocomplete in ubuntu turnslib::my_func into lib::my_func" whilst this still works it horrid to look at. And if I type lib::[TAB] it completely resets auto-completion.



      I've searched around and found mention of how to fix this with a config.d file. This is what I tested but no joy:



      _lib()

      local cur
      _get_comp_words_by_ref -n : cur
      __ltrim_colon_completions "$cur"

      complete -F _lib lib


      I placed this in /etc/bach_completion.d/lib







      share|improve this question













      I have a couple of bash function librarys that follow the double colon name convention ie



      function lib::my_func() 
      echo "$1"



      All is well with the functions but the bash autocomplete in ubuntu turnslib::my_func into lib::my_func" whilst this still works it horrid to look at. And if I type lib::[TAB] it completely resets auto-completion.



      I've searched around and found mention of how to fix this with a config.d file. This is what I tested but no joy:



      _lib()

      local cur
      _get_comp_words_by_ref -n : cur
      __ltrim_colon_completions "$cur"

      complete -F _lib lib


      I placed this in /etc/bach_completion.d/lib









      share|improve this question












      share|improve this question




      share|improve this question








      edited Jul 30 at 5:58









      SivaPrasath

      3,46311535




      3,46311535









      asked Jul 30 at 5:33









      user141533

      99




      99

























          active

          oldest

          votes











          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "106"
          ;
          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: false,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          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%2funix.stackexchange.com%2fquestions%2f459253%2fdouble-colon-autocomplete%23new-answer', 'question_page');

          );

          Post as a guest



































          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes










           

          draft saved


          draft discarded


























           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f459253%2fdouble-colon-autocomplete%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          Peggy Mitchell

          Palaiologos

          The Forum (Inglewood, California)