diff --git a/CMakeLists.txt b/CMakeLists.txt index 59e403f79..9d30eb5e7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -705,6 +705,7 @@ IF(SC_INSTALL) "${CMAKE_CURRENT_SOURCE_DIR}/lib" "Makefile" ".deps" + ".gitignore" COMMENT "Copying needed files" VERBATIM ) diff --git a/lib/user/archive/.gitignore b/lib/user/archive/.gitignore new file mode 100644 index 000000000..a1841eeee --- /dev/null +++ b/lib/user/archive/.gitignore @@ -0,0 +1,8 @@ +# This directory is used for randart files and borg dumps if running the +# game from where it was built and using the Windows front end (main-win.c) +# or a front end that uses main.c but was compiled without PRIVATE_USER_PATH +# set. Front ends using main.c would create this directory if needed, but +# main-win.c does not. +# For git, ignore everything here except for this file. +* +!.gitignore diff --git a/src/main-win.c b/src/main-win.c index da2490b25..1d8e3d24d 100644 --- a/src/main-win.c +++ b/src/main-win.c @@ -5110,6 +5110,7 @@ static void init_stuff(void) validate_dir(ANGBAND_DIR_SAVE); validate_dir(ANGBAND_DIR_PANIC); validate_dir(ANGBAND_DIR_SCORES); + validate_dir(ANGBAND_DIR_ARCHIVE); /* Build the filename */ path_build(path, sizeof(path), ANGBAND_DIR_SCREENS, "news.txt");