From 55892d23981917aefdb387ad7d0429f90cbd446a Mon Sep 17 00:00:00 2001 From: Alexander Potashev Date: Sun, 11 Jan 2009 15:19:12 +0300 Subject: Allow cloning to an existing empty directory The die() message updated accordingly. The previous behaviour was to only allow cloning when the destination directory doesn't exist. [jc: added trivial tests] Signed-off-by: Alexander Potashev Signed-off-by: Junio C Hamano --- dir.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'dir.h') diff --git a/dir.h b/dir.h index 02875ec58..bdc2d4744 100644 --- a/dir.h +++ b/dir.h @@ -84,6 +84,8 @@ static inline int is_dot_or_dotdot(const char *name) (name[1] == '.' && name[2] == '\0'))); } +extern int is_empty_dir(const char *dir); + extern void setup_standard_excludes(struct dir_struct *dir); extern int remove_dir_recursively(struct strbuf *path, int only_empty); -- cgit v1.2.1