Hello bash completion team. Forwarding my changes to the team now that I discovered there is a mailling list for this.
Please consider applying the attached git commits for bash-completion for make. attachments: commit-aef2ee - converts make completion to use more metadata for better results commit-6d1b6d9 - simplifies regex, adds more exclusions commit-d05dbbc - scalability and speed + incremental completions. The commits against http://anonscm.debian.org/gitweb/?p=bash-completion/bash-completion.git improve bash completion for make by replacing the processing command for the output of make -np This lists all explicit targets, no intermediates, and no source files. For an automake project like gcc there is almost no difference in output completions. For gcc's generated makefile a couple of completions are not proposed in this version which are proposed by the existing version and these are not buildable targets in that project's make system. Performance even for small makefiles like gcc's is improved. For makefiles with .INTERMEDIATE targets properly marked up then generated deps rules, targets of those deps and intermediate files do not get listed thus the patch avoids suggesting most of the targets a user doesn't want. For the linux kernel makefiles, completion time is reduced to one quarter of the time to process the makefiles, nearly halving the latency while returning most useful targets (taking the list from 88 to four digits) and keeping the number of suggestions small (taking the first round of suggestions up to the first slash from 88 to 100 or so because it supports incremental completion where targets are in subdirectories.). For a makefile such as the example at http://codeshot.blogspot.co.uk/2012/08/this-is-program-that-lists-targets-in.html the improvement is dramatic. When I create 4 empty files named test/a.cc test/b.cc test/c.cc test/d.cc in a subfolder "test" below that Makefile this version of make target completion generates 14 useful user targets and no source files vs 2 useful targets and 5 source files for the existing bash completion awk expression. -- Regards, Tristan Wibberley
commit-d05dbbc
Description: Binary data
commit-aef2eee
Description: Binary data
commit-6d1b6d9
Description: Binary data
_______________________________________________ Bash-completion-devel mailing list Bash-completion-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/bash-completion-devel