Skip to content

Commit 38ef5cb

Browse files
committed
Str
1 parent 401ae4b commit 38ef5cb

File tree

12 files changed

+24
-25
lines changed

12 files changed

+24
-25
lines changed

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ Very helpful in this situation will be logs from czkawka run with RUST_LOG envir
4040
<!-- Please do not report feature request unique for Gtk Czkawka gui, because it is in maintenance mode. -->
4141

4242
- Czkawka/Krokiet version: <!-- e.g. 9.0.0 cli/gui -->
43-
- OS version: <!-- e.g Ubuntu 22.04, Windows 11, Mac 15.1 ARM -->
43+
- OS version: <!-- e.g. Ubuntu 22.04, Windows 11, Mac 15.1 ARM -->
4444
- Installation method: <!-- e.g. github binaries, flatpak, msys2 -->
4545

4646
<!-- If you use flatpak, please include the result of `flatpak info com.github.qarmin.czkawka`. -->

Changelog.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,11 @@
33
### Breaking changes[Users]
44
- Some languages now have unified names in Crowdin (e.g. `es``es-ES`). The GUI may not find them and will fall back to the default language.
55
- Cache files now use memory limits and are incompatible with previous versions.
6+
- Cli image filter argument changed from `faussian` to `gaussian`
67

78
### Breaking changes[Devs]
89
- `stop_flag` is now required argument in most of the core functions
10+
- Visibility of some core functions has been reduced to `pub(crate)`
911

1012
### Core
1113
- Replaced `println`/`eprintln` with logging functions - [#1478](https://github.com/qarmin/czkawka/pull/1478)
@@ -80,7 +82,7 @@
8082
- Added support for configuring config/cache paths using the `CZKAWKA_CONFIG_PATH` and `CZKAWKA_CACHE_PATH` environment variables - [#1464](https://github.com/qarmin/czkawka/pull/1464)
8183
- Fixed a crash in debug mode when checking broken files named `.mp3` - [#1464](https://github.com/qarmin/czkawka/pull/1464)
8284
- Catching panics from symphonia crashes in broken files mode - [#1466](https://github.com/qarmin/czkawka/pull/1466)
83-
- Printing a warning, when using `panic=abort`(that may speedup app and cause occasional crashes) - [#1466](https://github.com/qarmin/czkawka/pull/1466)
85+
- Printing a warning, when using `panic=abort`(that may speed up app and cause occasional crashes) - [#1466](https://github.com/qarmin/czkawka/pull/1466)
8486

8587
### Krokiet
8688
- Changed the default tab to "Duplicate Files" - [#1368](https://github.com/qarmin/czkawka/pull/1368)

czkawka_cli/src/commands.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ pub struct SimilarImagesArgs {
225225
long,
226226
default_value = "High",
227227
value_parser = parse_similar_images_similarity,
228-
help = "Similairty level (Minimal, VerySmall, Small, Medium, High, VeryHigh, Original)",
228+
help = "Similarity level (Minimal, VerySmall, Small, Medium, High, VeryHigh, Original)",
229229
long_help = "Methods to choose similarity level of images which will be considered as duplicated."
230230
)]
231231
pub similarity_preset: SimilarityPreset,
@@ -697,7 +697,7 @@ fn parse_checking_method_same_music(src: &str) -> Result<CheckingMethod, &'stati
697697
match src.to_ascii_lowercase().as_str() {
698698
"tags" => Ok(CheckingMethod::AudioTags),
699699
"content" => Ok(CheckingMethod::AudioContent),
700-
_ => Err("Couldn't parse the searc method (allowed: TAGS, CONTENT)"),
700+
_ => Err("Couldn't parse the search method (allowed: TAGS, CONTENT)"),
701701
}
702702
}
703703

@@ -754,9 +754,9 @@ fn parse_similar_image_filter(src: &str) -> Result<FilterType, String> {
754754
"lanczos3" => FilterType::Lanczos3,
755755
"nearest" => FilterType::Nearest,
756756
"triangle" => FilterType::Triangle,
757-
"faussian" => FilterType::Gaussian,
757+
"gaussian" => FilterType::Gaussian,
758758
"catmullrom" => FilterType::CatmullRom,
759-
_ => return Err("Couldn't parse the image resize filter (allowed: Lanczos3, Nearest, Triangle, Faussian, Catmullrom)".to_string()),
759+
_ => return Err("Couldn't parse the image resize filter (allowed: Lanczos3, Nearest, Triangle, Gaussian, Catmullrom)".to_string()),
760760
};
761761
Ok(filter_type)
762762
}

czkawka_core/src/common.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,8 @@ pub fn set_config_cache_path(cache_name: &'static str, config_name: &'static str
7171
let mut infos = vec![];
7272
let mut warnings = vec![];
7373

74-
let config_folder_env = std::env::var("CZKAWKA_CONFIG_PATH").unwrap_or_default().trim().to_string();
75-
let cache_folder_env = std::env::var("CZKAWKA_CACHE_PATH").unwrap_or_default().trim().to_string();
74+
let config_folder_env = env::var("CZKAWKA_CONFIG_PATH").unwrap_or_default().trim().to_string();
75+
let cache_folder_env = env::var("CZKAWKA_CACHE_PATH").unwrap_or_default().trim().to_string();
7676

7777
let default_cache_folder = ProjectDirs::from("pl", "Qarmin", cache_name).map(|proj_dirs| proj_dirs.cache_dir().to_path_buf());
7878
let default_config_folder = ProjectDirs::from("pl", "Qarmin", config_name).map(|proj_dirs| proj_dirs.config_dir().to_path_buf());
@@ -298,7 +298,7 @@ pub fn print_version_mode(app: &str) {
298298
"{app} version: {CZKAWKA_VERSION}, {debug_release} mode, rust {rust_version}, os {} {} ({} {}), {processors} cpu/threads, features({}): [{}], app cpu version: {}, os cpu version: {}",
299299
info.os_type(),
300300
info.version(),
301-
std::env::consts::ARCH,
301+
env::consts::ARCH,
302302
info.bitness(),
303303
features.len(),
304304
features.join(", "),

czkawka_core/src/common_dir_traversal.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ where
303303

304304
let segments: Vec<_> = folders_to_check
305305
.into_par_iter()
306-
.with_max_len(2) // Avoiding checking too much folders in batch
306+
.with_max_len(2) // Avoiding checking too many folders in batch
307307
.map(|current_folder| {
308308
let mut dir_result = vec![];
309309
let mut warnings = vec![];

czkawka_core/src/tools/similar_videos.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,10 +85,7 @@ pub fn crop_detect_from_str_opt(s: &str) -> Option<Cropdetect> {
8585
}
8686

8787
pub fn crop_detect_from_str(s: &str) -> Cropdetect {
88-
match crop_detect_from_str_opt(s) {
89-
Some(crop_detect) => crop_detect,
90-
None => DEFAULT_CROP_DETECT,
91-
}
88+
crop_detect_from_str_opt(s).unwrap_or(DEFAULT_CROP_DETECT)
9289
}
9390
pub fn crop_detect_to_str(crop_detect: Cropdetect) -> String {
9491
match crop_detect {

czkawka_core/src/tools/temporary.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,12 @@ impl ResultEntry for TemporaryFileEntry {
4242
fn get_path(&self) -> &Path {
4343
&self.path
4444
}
45-
fn get_size(&self) -> u64 {
46-
self.size
47-
}
4845
fn get_modified_date(&self) -> u64 {
4946
self.modified_date
5047
}
48+
fn get_size(&self) -> u64 {
49+
self.size
50+
}
5151
}
5252

5353
#[derive(Default)]

czkawka_gui/src/saving_loading.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ const DEFAULT_IMAGE_REMOVE_AUTO_OUTDATED_CACHE: bool = true;
4242
const DEFAULT_DUPLICATE_REMOVE_AUTO_OUTDATED_CACHE: bool = true;
4343
const DEFAULT_DUPLICATE_CASE_SENSITIVE_NAME_CHECKING: bool = false;
4444
const DEFAULT_GENERAL_IGNORE_OTHER_FILESYSTEMS: bool = false;
45-
const DEFUALT_USING_RUST_LIBRARIES_TO_SHOW_PREVIEW: bool = true;
45+
const DEFAULT_USING_RUST_LIBRARIES_TO_SHOW_PREVIEW: bool = true;
4646

4747
const DEFAULT_MUSIC_APPROXIMATE_COMPARISON: bool = false;
4848
const DEFAULT_MUSIC_GROUP_CONTENT_BY_TITLE: bool = false;
@@ -633,7 +633,7 @@ pub(crate) fn load_configuration(
633633
let ignore_other_fs: bool = loaded_entries.get_bool(hashmap_ls[&LoadText::GeneralIgnoreOtherFilesystems].clone(), DEFAULT_GENERAL_IGNORE_OTHER_FILESYSTEMS);
634634
let use_rust_libraries_to_preview: bool = loaded_entries.get_bool(
635635
hashmap_ls[&LoadText::GeneralUseRustLibrariesToPreview].clone(),
636-
DEFUALT_USING_RUST_LIBRARIES_TO_SHOW_PREVIEW,
636+
DEFAULT_USING_RUST_LIBRARIES_TO_SHOW_PREVIEW,
637637
);
638638

639639
let delete_outdated_cache_duplicates: bool = loaded_entries.get_bool(
@@ -947,7 +947,7 @@ pub(crate) fn reset_configuration(manual_clearing: bool, upper_notebook: &GuiUpp
947947
settings.entry_settings_prehash_cache_file_minimal_size.set_text(DEFAULT_PREHASH_MINIMAL_CACHE_SIZE);
948948
settings.combo_box_settings_language.set_active(Some(0));
949949
settings.check_button_settings_one_filesystem.set_active(DEFAULT_GENERAL_IGNORE_OTHER_FILESYSTEMS);
950-
settings.check_button_settings_use_rust_preview.set_active(DEFUALT_USING_RUST_LIBRARIES_TO_SHOW_PREVIEW);
950+
settings.check_button_settings_use_rust_preview.set_active(DEFAULT_USING_RUST_LIBRARIES_TO_SHOW_PREVIEW);
951951

952952
main_notebook.combo_box_duplicate_hash_type.set_active(Some(0));
953953
main_notebook.combo_box_duplicate_check_method.set_active(Some(0));

czkawka_gui/ui/about_dialog.ui

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<property name="comments" translatable="yes">2020 - 2025
88
Rafał Mikrut (qarmin) and contributors
99
This program is free to use and will always be.
10-
App is now in maintenance mode, so check Krokiet, the sucessor of Czkawka.
10+
App is now in maintenance mode, so check Krokiet, the successor of Czkawka.
1111
</property>
1212
<property name="license-type">mit-x11</property>
1313
<property name="logo-icon-name">help-about-symbolic</property>

czkawka_gui/ui/czkawka.cmb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@
344344
(10,7,"GtkButton","buttons_popover_sort_selection",2,None,None,None,4,None,None)
345345
</object>
346346
<object_property>
347-
(3,1,"GtkAboutDialog","comments","2020 - 2025\nRafał Mikrut (qarmin) and contributors\nThis program is free to use and will always be.\nApp is now in maintenance mode, so check Krokiet, the sucessor of Czkawka",1,None,None,None,None,None,None,None,None),
347+
(3,1,"GtkAboutDialog","comments","2020 - 2025\nRafał Mikrut (qarmin) and contributors\nThis program is free to use and will always be.\nApp is now in maintenance mode, so check Krokiet, the successor of Czkawka",1,None,None,None,None,None,None,None,None),
348348
(3,1,"GtkAboutDialog","license-type","mit-x11",None,None,None,None,None,None,None,None,None),
349349
(3,1,"GtkAboutDialog","logo-icon-name","help-about-symbolic",None,None,None,None,None,None,None,None,None),
350350
(3,1,"GtkAboutDialog","program-name","Czkawka",None,None,None,None,None,None,None,None,None),

0 commit comments

Comments
 (0)