diff options
| author | Eli Zaretskii | 2013-05-16 12:58:56 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2013-05-16 12:58:56 +0300 |
| commit | a9519e2685d19b13ce4e3e1ba13f97569013627e (patch) | |
| tree | 6a9e0e35514c400749f23c891e9a95577fb9bfc1 /admin | |
| parent | 3946d31b7bcf2a7dceacb86598823360f457cd19 (diff) | |
| parent | 2d4bf34b5b83b3728b2fb18a72536f3e14afcf34 (diff) | |
| download | emacs-a9519e2685d19b13ce4e3e1ba13f97569013627e.tar.gz emacs-a9519e2685d19b13ce4e3e1ba13f97569013627e.zip | |
Merge from trunk.
Diffstat (limited to 'admin')
| -rw-r--r-- | admin/ChangeLog | 10 | ||||
| -rw-r--r-- | admin/cus-test.el | 57 | ||||
| -rwxr-xr-x | admin/quick-install-emacs | 8 |
3 files changed, 55 insertions, 20 deletions
diff --git a/admin/ChangeLog b/admin/ChangeLog index 5ae948ad192..221d5c0586c 100644 --- a/admin/ChangeLog +++ b/admin/ChangeLog | |||
| @@ -1,3 +1,13 @@ | |||
| 1 | 2013-05-16 Glenn Morris <rgm@gnu.org> | ||
| 2 | |||
| 3 | * cus-test.el (cus-test-cus-load-groups): New function. | ||
| 4 | (cus-test-get-options): Add option to return groups. | ||
| 5 | (cus-test-noloads): Also check custom groups. | ||
| 6 | |||
| 7 | 2013-05-15 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 8 | |||
| 9 | * quick-install-emacs: Don't prune DOC-* files a any more. | ||
| 10 | |||
| 1 | 2013-05-14 Glenn Morris <rgm@gnu.org> | 11 | 2013-05-14 Glenn Morris <rgm@gnu.org> |
| 2 | 12 | ||
| 3 | * cus-test.el (cus-test-get-lisp-files): Ignore obsolete/. | 13 | * cus-test.el (cus-test-get-lisp-files): Ignore obsolete/. |
diff --git a/admin/cus-test.el b/admin/cus-test.el index e68ee7744e7..6b8ec9abe02 100644 --- a/admin/cus-test.el +++ b/admin/cus-test.el | |||
| @@ -232,17 +232,38 @@ The detected problematic options are stored in `cus-test-errors'." | |||
| 232 | (length cus-test-tested-variables)) | 232 | (length cus-test-tested-variables)) |
| 233 | (cus-test-errors-display)) | 233 | (cus-test-errors-display)) |
| 234 | 234 | ||
| 235 | (defun cus-test-get-options (regexp) | 235 | (defun cus-test-cus-load-groups (&optional cus-load) |
| 236 | "Return a list of custom options matching REGEXP." | 236 | "Return a list of current custom groups. |
| 237 | (let (found) | 237 | If CUS-LOAD is non-nil, include groups from cus-load.el." |
| 238 | (append (mapcar 'cdr custom-current-group-alist) | ||
| 239 | (if cus-load | ||
| 240 | (with-temp-buffer | ||
| 241 | (insert-file-contents (locate-library "cus-load.el")) | ||
| 242 | (search-forward "(put '") | ||
| 243 | (beginning-of-line) | ||
| 244 | (let (res) | ||
| 245 | (while (and (looking-at "^(put '\\(\\S-+\\)") | ||
| 246 | (zerop (forward-line 1))) | ||
| 247 | (push (intern (match-string 1)) res)) | ||
| 248 | res))))) | ||
| 249 | |||
| 250 | (defun cus-test-get-options (regexp &optional group) | ||
| 251 | "Return a list of custom options matching REGEXP. | ||
| 252 | If GROUP is non-nil, return groups rather than options. | ||
| 253 | If GROUP is `cus-load', include groups listed in cus-loads as well as | ||
| 254 | currently defined groups." | ||
| 255 | (let ((groups (if group (cus-test-cus-load-groups (eq group 'cus-load)))) | ||
| 256 | found) | ||
| 238 | (mapatoms | 257 | (mapatoms |
| 239 | (lambda (symbol) | 258 | (lambda (symbol) |
| 240 | (and | 259 | (and |
| 241 | (or | 260 | (if group |
| 242 | ;; (user-variable-p symbol) | 261 | (memq symbol groups) |
| 243 | (get symbol 'standard-value) | 262 | (or |
| 244 | ;; (get symbol 'saved-value) | 263 | ;; (user-variable-p symbol) |
| 245 | (get symbol 'custom-type)) | 264 | (get symbol 'standard-value) |
| 265 | ;; (get symbol 'saved-value) | ||
| 266 | (get symbol 'custom-type))) | ||
| 246 | (string-match regexp (symbol-name symbol)) | 267 | (string-match regexp (symbol-name symbol)) |
| 247 | (not (member symbol cus-test-skip-list)) | 268 | (not (member symbol cus-test-skip-list)) |
| 248 | (push symbol found)))) | 269 | (push symbol found)))) |
| @@ -492,17 +513,17 @@ It is suitable for batch mode. E.g., invoke | |||
| 492 | 513 | ||
| 493 | in the Emacs source directory." | 514 | in the Emacs source directory." |
| 494 | (interactive) | 515 | (interactive) |
| 495 | (let (cus-loaded) | 516 | (let ((groups-loaded (cus-test-get-options "" 'cus-load)) |
| 517 | cus-loaded groups-not-loaded) | ||
| 496 | 518 | ||
| 497 | (message "Running %s" 'cus-test-load-custom-loads) | 519 | (message "Running %s" 'cus-test-load-custom-loads) |
| 498 | (cus-test-load-custom-loads) | 520 | (cus-test-load-custom-loads) |
| 499 | (setq cus-loaded | 521 | (setq cus-loaded (cus-test-get-options "")) |
| 500 | (cus-test-get-options "")) | ||
| 501 | 522 | ||
| 502 | (message "Running %s" 'cus-test-load-libs) | 523 | (message "Running %s" 'cus-test-load-libs) |
| 503 | (cus-test-load-libs "all") | 524 | (cus-test-load-libs "all") |
| 504 | (setq cus-test-vars-not-cus-loaded | 525 | (setq cus-test-vars-not-cus-loaded (cus-test-get-options "") |
| 505 | (cus-test-get-options "")) | 526 | groups-not-loaded (cus-test-get-options "" t)) |
| 506 | 527 | ||
| 507 | (dolist (o cus-loaded) | 528 | (dolist (o cus-loaded) |
| 508 | (setq cus-test-vars-not-cus-loaded | 529 | (setq cus-test-vars-not-cus-loaded |
| @@ -512,7 +533,15 @@ in the Emacs source directory." | |||
| 512 | (message "No options not loaded by custom-load-symbol found") | 533 | (message "No options not loaded by custom-load-symbol found") |
| 513 | (message "The following options were not loaded by custom-load-symbol:") | 534 | (message "The following options were not loaded by custom-load-symbol:") |
| 514 | (cus-test-message | 535 | (cus-test-message |
| 515 | (sort cus-test-vars-not-cus-loaded 'string<))))) | 536 | (sort cus-test-vars-not-cus-loaded 'string<))) |
| 537 | |||
| 538 | (dolist (o groups-loaded) | ||
| 539 | (setq groups-not-loaded (delete o groups-not-loaded))) | ||
| 540 | |||
| 541 | (if (not groups-not-loaded) | ||
| 542 | (message "No groups not in cus-load.el found") | ||
| 543 | (message "The following groups are not in cus-load.el:") | ||
| 544 | (cus-test-message (sort groups-not-loaded 'string<))))) | ||
| 516 | 545 | ||
| 517 | (provide 'cus-test) | 546 | (provide 'cus-test) |
| 518 | 547 | ||
diff --git a/admin/quick-install-emacs b/admin/quick-install-emacs index e74a2a5af49..98bd61f839d 100755 --- a/admin/quick-install-emacs +++ b/admin/quick-install-emacs | |||
| @@ -105,8 +105,8 @@ and build directories reside. | |||
| 105 | 105 | ||
| 106 | Optionally, $me can also remove old versions of | 106 | Optionally, $me can also remove old versions of |
| 107 | automatically generated files that are version-specific (such as the | 107 | automatically generated files that are version-specific (such as the |
| 108 | versioned emacs executables in the \`src' directory, and the DOC-* files | 108 | versioned emacs executables in the \`src' directory). |
| 109 | in the \`etc' directory). The latter action is called \`pruning,' and | 109 | The latter action is called \`pruning,' and |
| 110 | can be enabled using the \`-p' or \`--prune' options. | 110 | can be enabled using the \`-p' or \`--prune' options. |
| 111 | EOF | 111 | EOF |
| 112 | exit 0 | 112 | exit 0 |
| @@ -209,10 +209,6 @@ maybe_mkdir "$DST_INFO" | |||
| 209 | 209 | ||
| 210 | PRUNED="" | 210 | PRUNED="" |
| 211 | if test x"$PRUNE" != xno; then | 211 | if test x"$PRUNE" != xno; then |
| 212 | for D in `ls -1t $BUILD/etc/DOC-* | sed 1d`; do | ||
| 213 | echo $REMOVE_CMD $D | ||
| 214 | PRUNED="$PRUNED $D" | ||
| 215 | done | ||
| 216 | for D in `ls -1t $BUILD/src/emacs-$VERSION.* | sed 1d`; do | 212 | for D in `ls -1t $BUILD/src/emacs-$VERSION.* | sed 1d`; do |
| 217 | echo $REMOVE_CMD $D | 213 | echo $REMOVE_CMD $D |
| 218 | PRUNED="$PRUNED $D" | 214 | PRUNED="$PRUNED $D" |