From a043e0a81460a94e0732672afc3831689984caf8 Mon Sep 17 00:00:00 2001 From: xmusjackson Date: Sun, 14 May 2023 20:57:35 -0500 Subject: Add "Extract to subdirectory" option This commit adds an "Extract to subdirectory" option to the extract dialog which allows the user to extract the contents of the archive to a directory with the name of the archive (without the extension.) The user will be prompted if the directory must be created. file-utils.c: Improve remove_extension_from_path Rework this function so that it correctly parses and truncates files with multiple extensions like .tar.gz file-utils.c: Improve get_file_extension Improve this function to correctly identify and return supported compressed tar file extensions --- src/preferences.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/preferences.h') diff --git a/src/preferences.h b/src/preferences.h index 575ffb3..330845e 100644 --- a/src/preferences.h +++ b/src/preferences.h @@ -63,6 +63,7 @@ #define PREF_EXTRACT_SKIP_NEWER "skip-newer" #define PREF_EXTRACT_CLOSE_DIALOG "close-dialog" #define PREF_EXTRACT_RECREATE_FOLDERS "recreate-folders" +#define PREF_EXTRACT_CREATE_SUBDIR "create-subdirectory" #define PREF_ADD_CURRENT_FOLDER "current-folder" #define PREF_ADD_FILENAME "filename" -- cgit v1.2.1