+ entry
+ 'no-record))
+ (revised-name (multishell-name-from-entry revised))
+ buffer)
+ (when (not (string= revised entry))
+ (multishell-replace-entry entry revised)
+ (when (and (not (string= name revised-name))
+ (setq buffer (get-buffer (multishell-bracket name))))
+ (with-current-buffer buffer
+ (rename-buffer (multishell-bracket revised-name)))))
+ (when arg
+ (multishell-list-dispatch-selected revised-name t))
+ (with-current-buffer list-buffer
+ (revert-buffer)
+ (multishell-list-goto-item-by-entry revised))))
+
+(defun multishell-list-clone-entry (&optional arg)
+ "Create a new list entry, edited from the current one, ready to launch.
+
+If you provide an optional `universal-argument', the new entry
+will be launched when it's created.
+
+The already existing original entry is left untouched."
+ (interactive "P")
+ (let* ((prototype (tabulated-list-get-id))
+ (name (multishell-name-from-entry prototype))
+ (new (multishell-read-unbracketed-entry
+ (format "Clone new shell spec from %s: " name)
+ prototype
+ 'no-record))
+ (new-name (multishell-name-from-entry new))
+ (new-path (cadr (multishell-split-entry new))))
+ (when (not (string= new prototype))
+ (multishell-register-name-to-path new-name new-path)