@@ -336,20 +336,26 @@ a list of operations that would allow a full update."
336336 (error " Package %s is nowhere to be found in el-get status file. "
337337 package ))))
338338
339- (defun el-get-merge-properties-into-status (package
340- operation
341- &rest keys )
339+ (el-get-define-pkg-op-button-type 'el-get-merge-properties-into-status
340+ " force cached recipe update of" )
341+
342+ (defun el-get-merge-properties-into-status (package operation &rest keys )
342343 " Merge updatable properties for package into status file.
343344
344345PACKAGE is either a package source or name, in which case the
345346source will be read using `el-get-package-def' . The named
346347package must already be installed.
347348
348- Warn about any non-whitelisted properties differing from the
349- cached values."
349+ Warn about any non-whitelisted for OPERATION properties differing
350+ from the cached values.
351+
352+ Interactively, OPERATION is `update' with prefix arg, `reinstall'
353+ with double prefix arg, or `init' otherwise."
350354 (interactive
351355 (list (el-get-read-package-with-status " Update cached recipe" " installed" )
352- 'init ))
356+ (cond ((equal '(16 ) current-prefix-arg) 'reinstall )
357+ (current-prefix-arg 'update )
358+ (t 'init ))))
353359 (let* ((source (el-get-package-or-source package ))
354360 (package (plist-get source :name ))
355361 (cached (el-get-read-cached-recipe package source )))
@@ -362,8 +368,18 @@ cached values."
362368 (lwarn '(el-get recipe-cache) :warning
363369 (concat " Must %s `%s' to modify its cached recipe\n "
364370 " adding: %s"
365- " removing: %s" )
366- (mapconcat #'symbol-name required-ops " or " ) package
371+ " removing: %s"
372+ (el-get-fmt-button
373+ " Or %s if you know these changes are safe.\n "
374+ " force update the cached recipe"
375+ :type 'el-get-merge-properties-into-status
376+ 'el-get-package package 'el-get-pkg-extra-args '(reinstall)))
377+ (mapconcat (lambda (op )
378+ (el-get-fmt-button
379+ " %s" op :type (intern (concat " el-get-" op))
380+ 'el-get-package package ))
381+ (mapcar #'symbol-name required-ops) " or " )
382+ package
367383 (if no-add (pp-to-string no-add) " ()\n " )
368384 (if no-rem (pp-to-string no-rem) " ()\n " ))))))
369385
0 commit comments