Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] Tauri unwantedly converts PascalCase package product name to kebab-case #8349

Closed
ninjadev64 opened this issue Dec 6, 2023 · 6 comments · Fixed by #9375
Closed

[bug] Tauri unwantedly converts PascalCase package product name to kebab-case #8349

ninjadev64 opened this issue Dec 6, 2023 · 6 comments · Fixed by #9375
Labels
status: needs triage This issue needs to triage, applied to new issues type: bug

Comments

@ninjadev64
Copy link

ninjadev64 commented Dec 6, 2023

Describe the bug

The string configured as package.productName in tauri.conf.json in my project is "OpenDeck". This is the string I would like to be shown in start menus, docks, app launchers, software stores (e.g. GNOME Software), etc.

However, Tauri unwantedly converts this string to "open-deck" for the output artifact names (resulting in open-deck_2.0.0_amd64.deb and so forth) and for the executable name (meaning that it's open-deck to run it from a shell). I would like these both to be opendeck. However, the docs don't appear to mention any property that can be changed to override this behaviour.

Expected behavior

I should be able to specify an alternative string to use for these properties in my tauri.conf.json instead of having to deal with an inaccurate case conversion.

Platform and versions

[✔] Environment
    - OS: Ubuntu 22.04 X64
    ✔ webkit2gtk-4.0: 2.42.2
    ✔ rsvg2: 2.52.5
    ✔ rustc: 1.73.0 (cc66ad468 2023-10-03)
    ✔ cargo: 1.73.0 (9c4383fb5 2023-08-26)
    ✔ rustup: 1.26.0 (5af9b9484 2023-04-05)
    ✔ Rust toolchain: stable-x86_64-unknown-linux-gnu (environment override by RUSTUP_TOOLCHAIN)
    - node: 18.18.0
    - yarn: 1.22.21
    - npm: 10.2.4

[-] Packages
    - tauri [RUST]: 1.5.2
    - tauri-build [RUST]: 1.5.0
    - wry [RUST]: 0.24.4
    - tao [RUST]: 0.16.5
    - tauri-cli [RUST]: 1.5.6
    - @tauri-apps/api [NPM]: 1.5.1
    - @tauri-apps/cli [NPM]: 1.5.6 (outdated, latest: 1.5.7)

[-] App
    - build-type: bundle
    - CSP: default-src 'self';
    - distDir: ../build
    - devPath: http://localhost:5173/
    - framework: Svelte
    - bundler: Vite
@ninjadev64 ninjadev64 added status: needs triage This issue needs to triage, applied to new issues type: bug labels Dec 6, 2023
@FabianLars
Copy link
Member

FabianLars commented Dec 7, 2023

I think #8109 covers this right? You could set opendeck as the packageName and OpenDeck as displayName then.

@ninjadev64
Copy link
Author

Yep, but it's a shame it doesn't exist ;)

@ninjadev64
Copy link
Author

@FabianLars Any update?

@ninjadev64
Copy link
Author

@FabianLars I'm planning to start distributing stable builds of my application soon. I would like the package name to be in order beforehand, so that users don't end up with two versions installed later down the line when the package name gets changed. Do you know of any way to resolve this?

@mariotaku
Copy link
Contributor

@ninjadev64 I have created a PR to support this kind of use case. Would you mind try and let me if it works for you?

@ninjadev64
Copy link
Author

@ninjadev64 I have created a PR to support this kind of use case. Would you mind try and let me if it works for you?

While I'd love to try your changes, I'm currently using Tauri v1. I'll be moving to v2 as soon as it's stable, though, so thanks for the PR!

amrbashir added a commit that referenced this issue Apr 4, 2024
lucasfernog added a commit that referenced this issue May 28, 2024
…rgo name (#9375)

* refactor(cli&bundler): avoid renaming main executable and reserve cargo name

closes #8109
closes #8349

* fix bundler

* fix test

* Discard changes to core/tauri-build/Cargo.toml

* revert Cargo.toml changes

* Discard changes to Cargo.lock

* Discard changes to tooling/cli/Cargo.lock

* lock file

* use product name for installers

* only warn for sign on windows

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.app>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: needs triage This issue needs to triage, applied to new issues type: bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants