diff --git a/.changes/fix-tauri-build-filedescription.md b/.changes/fix-tauri-build-filedescription.md new file mode 100644 index 000000000..02ddec1ec --- /dev/null +++ b/.changes/fix-tauri-build-filedescription.md @@ -0,0 +1,6 @@ +--- +tauri-build: 'patch:bug' +tauri-bundler: 'patch:bug' +--- + +The executable and NSIS installer on Windows will now use the `productName` config for the `FileDescription` property instead of `shortDescription`. diff --git a/Cargo.lock b/Cargo.lock index 9e0825f8d..c573557e5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7120,6 +7120,7 @@ dependencies = [ "thiserror", "time", "ureq", + "url", "uuid", "walkdir", "windows-registry", diff --git a/crates/tauri-build/src/lib.rs b/crates/tauri-build/src/lib.rs index e47d9e89b..7baecdb2e 100644 --- a/crates/tauri-build/src/lib.rs +++ b/crates/tauri-build/src/lib.rs @@ -673,9 +673,12 @@ pub fn try_build(attributes: Attributes) -> Result<()> { res.set("ProductName", product_name); } - if let Some(short_description) = &config.bundle.short_description { - res.set("FileDescription", short_description); - } + let file_description = config + .product_name + .or_else(|| manifest.package.as_ref().map(|p| p.name.clone())) + .or_else(|| std::env::var("CARGO_PKG_NAME").ok()); + + res.set("FileDescription", &file_description.unwrap()); if let Some(copyright) = &config.bundle.copyright { res.set("LegalCopyright", copyright); diff --git a/crates/tauri-bundler/src/bundle/windows/templates/installer.nsi b/crates/tauri-bundler/src/bundle/windows/templates/installer.nsi index c6e728c66..864a275ad 100644 --- a/crates/tauri-bundler/src/bundle/windows/templates/installer.nsi +++ b/crates/tauri-bundler/src/bundle/windows/templates/installer.nsi @@ -35,7 +35,6 @@ ${StrLoc} !define PRODUCTNAME "{{product_name}}" !define VERSION "{{version}}" !define VERSIONWITHBUILD "{{version_with_build}}" -!define SHORTDESCRIPTION "{{short_description}}" !define HOMEPAGE "{{homepage}}" !define INSTALLMODE "{{install_mode}}" !define LICENSE "{{license}}" @@ -78,7 +77,7 @@ InstallDir "${PLACEHOLDER_INSTALL_DIR}" VIProductVersion "${VERSIONWITHBUILD}" VIAddVersionKey "ProductName" "${PRODUCTNAME}" -VIAddVersionKey "FileDescription" "${SHORTDESCRIPTION}" +VIAddVersionKey "FileDescription" "${PRODUCTNAME}" VIAddVersionKey "LegalCopyright" "${COPYRIGHT}" VIAddVersionKey "FileVersion" "${VERSION}" VIAddVersionKey "ProductVersion" "${VERSION}" diff --git a/crates/tauri-cli/config.schema.json b/crates/tauri-cli/config.schema.json index e268edf28..4cc3b65b1 100644 --- a/crates/tauri-cli/config.schema.json +++ b/crates/tauri-cli/config.schema.json @@ -2675,7 +2675,7 @@ } }, "obsoletes": { - "description": "The list of RPM dependencies your application supersedes - if this package is installed,\n packages listed as “obsoletes” will be automatically removed (if they are present).", + "description": "The list of RPM dependencies your application supersedes - if this package is installed,\n packages listed as \"obsoletes\" will be automatically removed (if they are present).", "type": [ "array", "null" diff --git a/crates/tauri-schema-generator/schemas/config.schema.json b/crates/tauri-schema-generator/schemas/config.schema.json index e268edf28..4cc3b65b1 100644 --- a/crates/tauri-schema-generator/schemas/config.schema.json +++ b/crates/tauri-schema-generator/schemas/config.schema.json @@ -2675,7 +2675,7 @@ } }, "obsoletes": { - "description": "The list of RPM dependencies your application supersedes - if this package is installed,\n packages listed as “obsoletes” will be automatically removed (if they are present).", + "description": "The list of RPM dependencies your application supersedes - if this package is installed,\n packages listed as \"obsoletes\" will be automatically removed (if they are present).", "type": [ "array", "null" diff --git a/crates/tauri-utils/src/config.rs b/crates/tauri-utils/src/config.rs index 441d3f183..75b25c7b3 100644 --- a/crates/tauri-utils/src/config.rs +++ b/crates/tauri-utils/src/config.rs @@ -404,7 +404,7 @@ pub struct RpmConfig { /// in order for the package to be installed. pub conflicts: Option>, /// The list of RPM dependencies your application supersedes - if this package is installed, - /// packages listed as “obsoletes” will be automatically removed (if they are present). + /// packages listed as "obsoletes" will be automatically removed (if they are present). pub obsoletes: Option>, /// The RPM release tag. #[serde(default = "default_release")]