summaryrefslogtreecommitdiff
path: root/lisp/vc/vc.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/vc/vc.el')
-rw-r--r--lisp/vc/vc.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el
index c982b0220e3..20056dec7f9 100644
--- a/lisp/vc/vc.el
+++ b/lisp/vc/vc.el
@@ -2913,11 +2913,12 @@ current buffer's file name if it's under version control."
(when (file-exists-p new)
(error "New file already exists"))
(let ((state (vc-state old)))
- (unless (memq state '(up-to-date edited))
+ (unless (memq state '(up-to-date edited added))
(error "Please %s files before moving them"
(if (stringp state) "check in" "update"))))
(vc-call rename-file old new)
(vc-file-clearprops old)
+ (vc-file-clearprops new)
;; Move the actual file (unless the backend did it already)
(when (file-exists-p old) (rename-file old new))
;; ?? Renaming a file might change its contents due to keyword expansion.