mirror of
https://github.com/tauri-apps/tauri.git
synced 2024-11-28 03:47:37 +03:00
This commit is contained in:
parent
0d2efd9ff4
commit
5ec74456b9
5
.changes/maintainer-fallback.md
Normal file
5
.changes/maintainer-fallback.md
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
"tauri-bundler": patch:enhance
|
||||
---
|
||||
|
||||
The debian `Maintainer` field now defaults to the Cargo.toml authors, but fallbacks to the `publisher` config value and the second part of the bundle identifier.
|
2
Cargo.lock
generated
2
Cargo.lock
generated
@ -7019,7 +7019,7 @@ checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1"
|
||||
|
||||
[[package]]
|
||||
name = "tauri"
|
||||
version = "2.0.0-rc.7"
|
||||
version = "2.0.0-rc.8"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"bytes",
|
||||
|
@ -163,7 +163,17 @@ fn generate_control_file(
|
||||
writeln!(file, "Architecture: {arch}")?;
|
||||
// Installed-Size must be divided by 1024, see https://www.debian.org/doc/debian-policy/ch-controlfields.html#installed-size
|
||||
writeln!(file, "Installed-Size: {}", total_dir_size(data_dir)? / 1024)?;
|
||||
let authors = settings.authors_comma_separated().unwrap_or_default();
|
||||
let authors = settings
|
||||
.authors_comma_separated()
|
||||
.or_else(|| settings.publisher().map(ToString::to_string))
|
||||
.unwrap_or_else(|| {
|
||||
settings
|
||||
.bundle_identifier()
|
||||
.split('.')
|
||||
.nth(1)
|
||||
.unwrap_or(settings.bundle_identifier())
|
||||
.to_string()
|
||||
});
|
||||
|
||||
writeln!(file, "Maintainer: {authors}")?;
|
||||
if let Some(section) = &settings.deb().section {
|
||||
|
@ -539,7 +539,9 @@ pub struct BundleSettings {
|
||||
/// the app's identifier.
|
||||
pub identifier: Option<String>,
|
||||
/// The app's publisher. Defaults to the second element in the identifier string.
|
||||
/// Currently maps to the Manufacturer property of the Windows Installer.
|
||||
///
|
||||
/// Currently maps to the Manufacturer property of the Windows Installer
|
||||
/// and the Maintainer field of debian packages if the Cargo.toml does not have the authors field.
|
||||
pub publisher: Option<String>,
|
||||
/// A url to the home page of your application. If None, will
|
||||
/// fallback to [PackageSettings::homepage].
|
||||
|
@ -1546,7 +1546,7 @@
|
||||
]
|
||||
},
|
||||
"publisher": {
|
||||
"description": "The application's publisher. Defaults to the second element in the identifier string.\n Currently maps to the Manufacturer property of the Windows Installer.",
|
||||
"description": "The application's publisher. Defaults to the second element in the identifier string.\n\n Currently maps to the Manufacturer property of the Windows Installer\n and the Maintainer field of debian packages if the Cargo.toml does not have the authors field.",
|
||||
"type": [
|
||||
"string",
|
||||
"null"
|
||||
|
@ -1546,7 +1546,7 @@
|
||||
]
|
||||
},
|
||||
"publisher": {
|
||||
"description": "The application's publisher. Defaults to the second element in the identifier string.\n Currently maps to the Manufacturer property of the Windows Installer.",
|
||||
"description": "The application's publisher. Defaults to the second element in the identifier string.\n\n Currently maps to the Manufacturer property of the Windows Installer\n and the Maintainer field of debian packages if the Cargo.toml does not have the authors field.",
|
||||
"type": [
|
||||
"string",
|
||||
"null"
|
||||
|
@ -1142,7 +1142,9 @@ pub struct BundleConfig {
|
||||
/// Produce updaters and their signatures or not
|
||||
pub create_updater_artifacts: Updater,
|
||||
/// The application's publisher. Defaults to the second element in the identifier string.
|
||||
/// Currently maps to the Manufacturer property of the Windows Installer.
|
||||
///
|
||||
/// Currently maps to the Manufacturer property of the Windows Installer
|
||||
/// and the Maintainer field of debian packages if the Cargo.toml does not have the authors field.
|
||||
pub publisher: Option<String>,
|
||||
/// A url to the home page of your application. If unset, will
|
||||
/// fallback to `homepage` defined in `Cargo.toml`.
|
||||
|
Loading…
Reference in New Issue
Block a user