git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] Add exclude file support to cg-status

From
MPMatt Porter <mporter@kernel.crashing.org>
Date
May 3, 2005, 00:10 UTC
Message-ID
<20050502171042.A24299@cox.net>

Adds a trivial per-repository exclude file implementation for cg-status on top of the new git-ls-files option.

Signed-off-by: Matt Porter <mporter@kernel.crashing.org>

--- 002c6f1e4924965e2101d2e6447855f10c55df41/cg-status (mode:100755 sha1:9e7f0e59284a3d15cda35bbd5579c44d8eda05d5) +++ 1b8c5395679e5c04734b1c86445a6355124ada7e/cg-status (mode:100755 sha1:6669e36f5ff5d5964882b58ba43a5dcab4fd7fc6)

@@ -7,8 +7,14 @@
 
 . cg-Xlib
 
+EXCLUDEFILE=.git/exclude
+EXCLUDE=
+if [ -f $EXCLUDEFILE ]; then
+	EXCLUDE="--exclude-from=$EXCLUDEFILE"
+fi
+
 {
-	git-ls-files -z -t --others --deleted --unmerged
+	git-ls-files -z -t --others --deleted --unmerged $EXCLUDE
 } | sort -z -k 2 | xargs -0 sh -c '
 while [ "$1" ]; do
 	tag=${1% *};
Next: Junio C Hamano
Message 1 of 9 in “Add exclude file support to cg-status”
  1. Add exclude file support to cg-statusMatt Porter, May 3, 2005
  2. Junio C HamanoMay 3, 2005
  3. Matt PorterMay 3, 2005
  4. Junio C HamanoMay 3, 2005
  5. Matt PorterMay 3, 2005
  6. Matt PorterMay 3, 2005
  7. Petr BaudisMay 8, 2005
  8. Junio C HamanoMay 8, 2005
  9. Petr BaudisMay 8, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.