[Bug 1330173] Re: bash-completion of Makefile: invalid option name

Aapo Rantalainen 1330173 at bugs.launchpad.net
Tue Jun 24 12:01:35 UTC 2014


I created new user and bug didn't triggered. Then I copied .bashrc and
bug triggered. With bisecting I found one row which destroys bash-
completion for make.

.bashrc
-alias grep='grep --color=always'
+alias grep='grep --color=auto'

------
And after that, proper patch wasn't difficult.

/usr/share/bash-completion/completions/make

--- make_orig      2014-06-24 14:54:46.256847066 +0300
+++ make        2014-06-24 14:56:55.240851566 +0300
@@ -141,7 +141,7 @@
             mode=-d # display-only mode
         fi
 
-        local reset=$( set +o | grep -F posix ); set +o posix # for <(...)
+        local reset=$( set +o | grep -F --color=never posix ); set +o posix # for <(...)
         COMPREPLY=( $( LC_ALL=C \
             make -npq "${makef[@]}" "${makef_dir[@]}" .DEFAULT 2>/dev/null | \
             sed -nrf <(_make_target_extract_script $mode "$cur") ) )


----
'grep grep /usr/share/bash-completion/completions/*' gives so many hits that it is possible that "grep is aliased to 'grep --color=always' " is bad idea.


** Package changed: bash (Ubuntu) => bash-completion (Ubuntu)

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1330173

Title:
  bash-completion of Makefile: invalid option name

Status in “bash-completion” package in Ubuntu:
  New

Bug description:
  Happened with two computers when upgraded from 13.10 to 14.04.
  DISTRIB_DESCRIPTION="Ubuntu 14.04 LTS"
  GNU bash, versio 4.3.11(1)-release (x86_64-pc-linux-gnu)

  Steps: 
  Create very simple Makefile
  echo -e "foo: \n\nbar:" > Makefile

  make [TAB]
  Gives error "bash: set: posix: invalid option name"

  
  make[TAB][TAB] 
  gives
  bash: set: posix: invalid option name
  bash: set: posix: invalid option name

  bar  foo

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash-completion/+bug/1330173/+subscriptions



More information about the foundations-bugs mailing list