Merged from trunk 8123:8140
authorFabian Groffen <grobian@gentoo.org>
Sun, 21 Oct 2007 10:34:42 +0000 (10:34 -0000)
committerFabian Groffen <grobian@gentoo.org>
Sun, 21 Oct 2007 10:34:42 +0000 (10:34 -0000)
   | 8124    | Add a note to clarify os.walk() behavior with respect to     |
   | zmedico | symlinks to directories.                                     |

   | 8125    | Sort the modes in the repoman --help output.                 |
   | zmedico |                                                              |

   | 8126    | Document the "manifest" mode.                                |
   | zmedico |                                                              |

   | 8128    | remove unused tmpfs variable                                 |
   | genone  |                                                              |

   | 8129    | Bug #195949 - Use a different diff_command sanity check when |
   | zmedico | using_editor is true.                                        |

   | 8130    | Bug #195949 - Add one more using_editor conditional for      |
   | zmedico | diff_command.                                                |

   | 8136    | Update NOTE_2 to document proper use of the using_editor     |
   | zmedico | config option.                                               |

   | 8138    | Update emacs and vim docs to reference NOTE_2.               |
   | zmedico |                                                              |

   | 8140    | Fix --help summary so that "commit" mode shows.              |
   | zmedico |                                                              |

svn path=/main/branches/prefix/; revision=8203

bin/etc-update
bin/repoman
cnf/etc-update.conf
cnf/make.conf
man/repoman.1
pym/portage/dbapi/porttree.py
pym/portage/dbapi/vartree.py

index 8121ddbc3a54536edadb432896d698016cd488ba..f0e544d7bf83df7039a6f0069ddb72668dfe09ed 100755 (executable)
@@ -412,8 +412,16 @@ Please select from the menu above (-1 to exit, losing this merge): "
                                   rm ${rm_opts} "${file}"
                                   return 255
                                   ;;
-                               2) ( echo "Showing differences between ${ofile} and ${mfile}"
-                                        diff_command "${ofile}" "${mfile}" ) | ${pager}
+                               2)      if [ "${using_editor}" == 0 ]; then
+                                               (
+                                                       echo "Showing differences between ${ofile} and ${mfile}"
+                                                       diff_command "${ofile}" "${mfile}"
+                                               ) | ${pager}
+                                       else
+                                               echo "Beginning of differences between ${ofile} and ${mfile}"
+                                               diff_command "${ofile}" "${mfile}"
+                                               echo "End of differences between ${ofile} and ${mfile}"
+                                       fi
                                   continue
                                   ;;
                                3) break
@@ -520,13 +528,20 @@ declare -i mode=$(get_config mode)
 [[ -z ${mode} ]] && mode=0
 [[ -z ${pager} ]] && pager="cat"
 
-# Sanity check to make sure diff exists and works
-echo > "${TMP}"/.diff-test-1
-echo > "${TMP}"/.diff-test-2
-
-if ! diff_command "${TMP}"/.diff-test-1 "${TMP}"/.diff-test-2 &> /dev/null ; then
-       echo "ERROR: '${diff_command}' does not seem to work, aborting"
-       exit 1
+if [ "${using_editor}" == 0 ]; then
+       # Sanity check to make sure diff exists and works
+       echo > "${TMP}"/.diff-test-1
+       echo > "${TMP}"/.diff-test-2
+       
+       if ! diff_command "${TMP}"/.diff-test-1 "${TMP}"/.diff-test-2 ; then
+               echo "ERROR: '${diff_command}' does not seem to work, aborting"
+               exit 1
+       fi
+else
+       if ! type ${diff_command%% *} >/dev/null; then
+               echo "ERROR: '${diff_command}' does not seem to work, aborting"
+               exit 1
+       fi
 fi
 
 #echo "rm_opts: $rm_opts, mv_opts: $mv_opts, cp_opts: $cp_opts"
index fa7749c12b64096fde209f30ecd5e1a779d8b3e8..1b27172ebc4e48663ea1f00bd4992047f275c439 100755 (executable)
@@ -121,6 +121,7 @@ modeshelp={
 "lfull"  : "Remember report from last run (full listing)"
 }
 modes=modeshelp.keys()
+modes.sort()
 repoman_options={
 "--commitmsg"      : "Adds a commit message via the command line",
 "--commitmsgfile"  : "Adds a commit message from the specified file",
@@ -287,7 +288,9 @@ def help(exitstatus=1,helpfulness=1):
        print bold(" Usage:"),turquoise(exename),"[",green("options"),"] [",green("mode"),"]"
        if helpfulness:
                print bold(" Modes:"),turquoise("scan (default)"),
-               for x in modes[1:]:
+               for x in modes:
+                       if x == "scan":
+                               continue
                        print "|",turquoise(x),
                print
        print
index 12396b3b4bf6b42116ab4193baccd582109438bc..fcb4f582b05ea90b0baca2274a278b8a925d685d 100644 (file)
@@ -17,15 +17,15 @@ mv_opts="-i"
 # arguments used whenever cp is called
 cp_opts="-i"
 
-# pager for use with diff commands (see NOTE_2)
+# pager for use with diff commands
 pager="less"
 #pager=""
 
-# For emacs-users
+# For emacs-users (see NOTE_2)
 # diff_command="eval emacs -nw --eval=\'\(ediff\ \"%file1\"\ \"%file2\"\)\'"
 #using_editor=1
 
-# vim-users: you CAN use vimdiff for diff_command. (see NOTE_1)
+# vim-users: you CAN use vimdiff for diff_command. (see NOTE_1 and NOTE_2)
 #diff_command="vim -d %file1 %file2"
 #using_editor=1
 
@@ -72,4 +72,5 @@ merge_command="sdiff -s -o %merged %orig %new"
 # because it is not known what filenames the produced files have (the user can
 # choose while using those programs)
 
-# NOTE_2: Make sure pager is set to "" when using an editor as diff_command!
+# NOTE_2: Make sure using_editor is set to "1" when using an editor as
+# diff_command!
index abe42f587ed4f19cd8aed73fce1ef6ec889d7959..1077d28ea31a423306e2493bd0f0097efc4aa9d6 100644 (file)
 #              packages.  Do not use it unless absolutely necessary!
 #AUTOCLEAN="yes"
 #
-# PORTAGE_TMPFS is a location where portage may create temporary files.
-#     If specified, portage will use this directory whenever possible
-#     for all rapid operations such as lockfiles and transient data.
-#     It is _highly_ recommended that this be a tmpfs or ramdisk. Do not
-#     set this to anything that does not give a significant performance
-#     enhancement and proper FS compliance for locks and read/write.
-#     /dev/shm is a glibc mandated tmpfs, and should be a reasonable
-#     setting for all linux kernel+glibc based systems.
-#PORTAGE_TMPFS="/dev/shm"
-#
 # FEATURES are settings that affect the functionality of portage. Most of
 #     these settings are for developer use, but some are available to non-
 #     developers as well.
index 81d9e6a0884b94c34733d009fbed0f728d464e0e..5fc789c8258b023b56ec219c73d268ee0649d7da 100644 (file)
@@ -68,6 +68,9 @@ Fix simple QA issues (stray digests, missing digests)
 .B lfull
 Remember report from last run (full listing)
 .TP
+.B manifest
+Generate a Manifest (fetches files if necessary)
+.TP
 .B commit
 Scan directory tree for QA issues; if OK, commit via cvs
 .SH QA KEYWORDS
index 6a8e441ca7ca68d246eabeb058ba20959e16d955..05fe2a767e44c37dfa46c467b24e3e1b5a51bf48 100644 (file)
@@ -65,14 +65,6 @@ class portdbapi(dbapi):
 
                self.depcachedir = self.mysettings.depcachedir[:]
 
-               self.tmpfs = self.mysettings["PORTAGE_TMPFS"]
-               if self.tmpfs and not os.path.exists(self.tmpfs):
-                       self.tmpfs = None
-               if self.tmpfs and not os.access(self.tmpfs, os.W_OK):
-                       self.tmpfs = None
-               if self.tmpfs and not os.access(self.tmpfs, os.R_OK):
-                       self.tmpfs = None
-
                self.eclassdb = eclass_cache.cache(self.porttree_root,
                        overlays=self.mysettings["PORTDIR_OVERLAY"].split())
 
index 26badff201f7c95321175e17fb39c15357d9e5b5..a298f48b38b893f7430eefb560b9a4f88342aeb9 100644 (file)
@@ -1731,6 +1731,9 @@ class dblink(object):
                                if stat.S_ISREG(file_mode):
                                        myfilelist.append(file_path[len(srcroot):])
                                elif stat.S_ISLNK(file_mode):
+                                       # Note: os.walk puts symlinks to directories in the "dirs"
+                                       # list and it does not traverse them since that could lead
+                                       # to an infinite recursion loop.
                                        mylinklist.append(file_path[len(srcroot):])
 
                # Preserve old libs if they are still in use