<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>78439</bug_id>
          
          <creation_ts>2005-01-17 16:01 0000</creation_ts>
          <short_desc>bash-completion does not complete correctly for &quot;cvs commit&quot;</short_desc>
          <delta_ts>2005-01-20 03:49:32 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Applications</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>remy.blank@pobox.com</reporter>
          <assigned_to>shell-tools@gentoo.org</assigned_to>
          

      

      
          <long_desc isprivate="0">
            <who>remy.blank@pobox.com</who>
            <bug_when>2005-01-17 16:01:37 0000</bug_when>
            <thetext>The current version of bash-completion (20041017-r3) is not very practical for the command &quot;cvs commit&quot;. When I am in the root directory of a project, and I would like to commit the file documentation/myproject.html, I would like to type &quot;cvs ci doc&lt;TAB&gt;my&lt;TAB&gt;&quot; and have it completed to &quot;cvs ci documentation/myproject.html&quot;. However, after the first TAB, I get &quot;cvs ci documentation &quot; (note the trailing space) so that I have to go back, add the slash, and continue completion.

This behaviour is pretty annoying. Strangely enough, completion works correctly for &quot;cvs diff&quot;.

Reproducible: Always
Steps to Reproduce:
1. Go into the root of a project managed with cvs and having files in subdirectories.
2. Try to auto-complete a &quot;cvs commit&quot; for a file in a subdirectory.

Actual Results:  
The name of the directory is added to the command line, with a trailing space.

Expected Results:  
The name of the directory, with a trailing slash and *no* space, should have
been added to the command line.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>remy.blank@pobox.com</who>
            <bug_when>2005-01-17 16:06:19 0000</bug_when>
            <thetext>Created an attachment (id=48795)
A possible fix to /etc/bash_completion

This patch to /etc/bash_completion seems to fix the behaviour of &quot;cvs commit&quot;.
However, I&apos;m not yet sure if it breaks someting else for cvs auto-completion.
I&apos;ll report back after a few days of use.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>ka0ttic@gentoo.org</who>
            <bug_when>2005-01-17 16:43:28 0000</bug_when>
            <thetext>Please try the latest version (I&apos;ve just committed 20050112-r1).  It has much improved cvs commit completion code.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>remy.blank@pobox.com</who>
            <bug_when>2005-01-18 00:51:23 0000</bug_when>
            <thetext>I&apos;m afraid the symptoms with &quot;cvs commit&quot; are still exactly the same (using app-shells/bash-completion-20050112-r1). The patch still seems to work, too.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>ka0ttic@gentoo.org</who>
            <bug_when>2005-01-20 03:26:02 0000</bug_when>
            <thetext>Ok, this is what I am going to do for the solution.  Since your &quot;actual results&quot; and &quot;expected results&quot; are both valid CVS commands, I really don&apos;t want to choose one or the other.

Instead, I will be fixing it so that no space is appended to the directory name.  This way, if you wanted to commit the dir as a whole (cvs ci dir) you can just hit enter.  If you want to commit something *in* dir, then you can manually append the &apos;/&apos; and finish completing.

20050120 was just released today, so my fix will be included in the version bump.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>ka0ttic@gentoo.org</who>
            <bug_when>2005-01-20 03:49:32 0000</bug_when>
            <thetext>Bah, scratch that as I found a better solution ;)
20050120 is in cvs.  Thanks for the report.</thetext>
          </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>48795</attachid>
            <date>2005-01-17 16:06 0000</date>
            <desc>A possible fix to /etc/bash_completion</desc>
            <filename>bash-completion</filename>
            <type>text/plain</type>
            <data encoding="base64">LS0tIGJhc2hfY29tcGxldGlvbi5vcmlnCTIwMDUtMDEtMTggMDE6MDI6NTcuMDc3NDQ0MjY2ICsw
MTAwCisrKyBiYXNoX2NvbXBsZXRpb24JMjAwNS0wMS0xOCAwMDo0MToxMC45OTUxNzg0MDQgKzAx
MDAKQEAgLTE1MjMsNyArMTUyMyw3IEBACiAJCiAJcmV0dXJuIDAKIH0KLWNvbXBsZXRlIC1GIF9j
dnMgJGRlZmF1bHQgY3ZzCitjb21wbGV0ZSAtRiBfY3ZzICRkZWZhdWx0ICRmaWxlbmFtZXMgY3Zz
CiB9CiAKIGhhdmUgcnBtICYmIHsK
</data>        

          </attachment>
    </bug>

</bugzilla>