Commit Graph

5413 Commits

Author SHA1 Message Date
github-actions[bot]
b154826881 apply version updates (#13060)
Co-authored-by: lucasfernog <20051258+lucasfernog@users.noreply.github.com>
@tauri-apps/cli-v2.4.1 tauri-cli-v2.4.1 tauri-bundler-v2.3.1 tauri-plugin-v2.1.1 tauri-build-v2.1.1 tauri-runtime-v2.5.1 tauri-v2.4.1 @tauri-apps/api-v2.4.1 tauri-utils-v2.3.1 tauri-runtime-wry-v2.5.1 tauri-macros-v2.1.1 tauri-codegen-v2.1.1
2025-04-01 13:52:38 -03:00
Lucas Nogueira
dade232592 chore: change bumps to patches 2025-04-01 13:14:28 -03:00
Tony
aa6b4d4edf fix(cli): preserve null when merging patches (#13120)
* fix(cli): preserve null when merging patches

* add test

* remove commented out code

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-04-01 13:09:50 -03:00
Tony
794af778e4 fix(cli): merge config based on the first one (#13117)
* fix(cli): merge config based on the first one

* Add change file
2025-04-01 17:18:13 +08:00
dependabot[bot]
4e22ae29d3 chore(deps-dev): bump vite from 6.2.3 to 6.2.4 (#13111)
* chore(deps-dev): bump vite from 6.2.3 to 6.2.4

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 6.2.3 to 6.2.4.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.2.4/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.2.4/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update esbuild

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tony <legendmastertony@gmail.com>
2025-04-01 09:05:10 +08:00
Tony
4ae14bf2f2 fix: suppress deprecated warning in tray icon codegen (#13093) 2025-03-31 09:54:07 +08:00
Pietagorh
f805061d11 feat(cli): allow for toml and json5 files in --config arg (#13079) 2025-03-30 18:11:47 +02:00
Tony
30beb6fee7 fix(cli): tauri info can't find the latest version for rust crates (#13096)
* fix(cli): `tauri info` can't find the latest version for rust crates

* Forget to remove dbg!

* Use strip_suffix

* Add change file
2025-03-29 23:45:38 +08:00
renovate[bot]
22c7a877e3 chore(deps): update dependency rollup to v4.38.0 (#13094)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-03-29 17:32:15 +08:00
Tony
2138bbc212 fix(nsis): in wrong language if SpanishInternational is included (#13087) 2025-03-28 03:45:13 -07:00
dependabot[bot]
5c2b3b8b65 chore(deps-dev): bump vite from 6.2.0 to 6.2.3 (#13072)
* chore(deps-dev): bump vite from 6.2.0 to 6.2.3

Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 6.2.0 to 6.2.3.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v6.2.3/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v6.2.3/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>

* Update esbuilds to the same version

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tony <legendmastertony@gmail.com>
2025-03-26 15:10:34 +08:00
阿豪
dd13728334 enhance(api): add generic parameter to emit and emitTo functions (#13066)
closes #13059
2025-03-25 05:34:20 +02:00
renovate[bot]
f235ec0113 chore(deps): update dependency rollup to v4.37.0 (#13062)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-03-24 21:14:02 +08:00
Matthew Richardson
f182b0bb93 docs: Update general setup in contributing guide (#13065) 2025-03-24 05:51:09 -07:00
Tony
a851b6597f enhance: include permission group permissions in the generated schema (#13057)
* enhance: include permissions in default permission description

* Only include in schema

* Remove 'which includes` to tauri's build script

* Also bump utils

* Clippy
My local clippy didn't report this, weird

* Use `which enables all commands`
for default permissions that enables everything

* Extract description into a variable

* Generate permissions with or without description

* Tweak the docs and generate 'which includes'

* Simplify to just `includes`

* Docs change change file

* Put the change in minor

* Update .changes/include-permissions-in-schema.md

Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>

* Remove unused change file

---------

Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
2025-03-23 21:35:45 +08:00
WofWca
be31675fbc docs: improve Builder::run docs (#13058)
Otherwise people might use it and not realize
that `App::run` also takes the callback argument,
which could be useful for some.
2025-03-23 15:07:33 +02:00
Lőrik Levente
dea8bbf6cd docs: Improve BaseDirectory documentation (#13043)
* add notes

* Add links

* fix fmt
2025-03-21 13:57:34 +02:00
github-actions[bot]
be3a79c864 apply version updates (#12856)
Co-authored-by: lucasfernog <20051258+lucasfernog@users.noreply.github.com>
tauri-v2.4.0 tauri-bundler-v2.3.0 tauri-plugin-v2.1.0 @tauri-apps/cli-v2.4.0 tauri-runtime-wry-v2.5.0 tauri-runtime-v2.5.0 tauri-codegen-v2.1.0 tauri-cli-v2.4.0 @tauri-apps/api-v2.4.0 tauri-build-v2.1.0 tauri-utils-v2.3.0 tauri-macros-v2.1.0
2025-03-20 15:34:59 -03:00
Lucas Nogueira
ba42a1f553 chore: pin tao and wry to latest patch versions
they include necessary bug fixes for the 2.4 release
2025-03-20 14:52:38 -03:00
Tony
1cd8f55eed fix: don't ship global api bundle if withGlobalTauri is false (#13033)
* fix: don't ship global api bundle if withGlobalTauri is false

* Comment and prettier
2025-03-20 12:37:31 -03:00
Tony
8603e42a6b fix: channel no longer being always allowed (#13032)
* fix: channel no longer being always allowed

* Prettier

* Don't change the plugin name just yet

* Handle TAURI_CHANNEL as a special case in macro

* remove commented out code

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-20 12:19:55 -03:00
Akshanabha Chakraborty
c32bd722d3 prettify: Remove beta tag and alert users that tauri for android currently doesn't work on android 7 (#12646) 2025-03-18 08:33:47 -03:00
Lucas Fernandes Nogueira
bcdd510254 feat(core): resolve file names from Android content URIs (#13012)
* feat(core): resolve file names from Android content URIs

This PR adds a new Android path plugin function to resolve file names from content URIs. `PathResolver::file_name` was added to expose this API on Rust, and the existing `@tauri-apps/api/path` basename and extname function now leverages it on Android.

Closes https://github.com/tauri-apps/plugins-workspace/issues/1775

Tauri core port from https://github.com/tauri-apps/plugins-workspace/pull/2421

Co-authored-by: VulnX

* update change file [skip ci]

Co-authored-by: VulnX <62636727+VulnX@users.noreply.github.com>

---------

Co-authored-by: VulnX <62636727+VulnX@users.noreply.github.com>
2025-03-18 08:29:07 -03:00
WofWca
71cb1e26d7 docs: update .disable_javascript() docs (#13013)
The initial version of the MR that introduced this to Wry
(https://github.com/tauri-apps/wry/pull/1496)
had no Android implementation, but it has been added
in a later version of the MR, so the comment is no longer valid.
2025-03-18 09:47:27 +02:00
WofWca
b459f1d405 docs: improve Capability docs: mention webviews (#13015) 2025-03-18 09:46:48 +02:00
dependabot[bot]
8cc0067165 chore(deps): bump zip from 2.2.2 to 2.3.0 (#13016)
Bumps [zip](https://github.com/zip-rs/zip2) from 2.2.2 to 2.3.0.
- [Release notes](https://github.com/zip-rs/zip2/releases)
- [Changelog](https://github.com/zip-rs/zip2/blob/master/CHANGELOG.md)
- [Commits](https://github.com/zip-rs/zip2/compare/v2.2.2...v2.3.0)

---
updated-dependencies:
- dependency-name: zip
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-18 11:35:36 +08:00
Lucas Fernandes Nogueira
f2c94aaca0 feat(core): add startIntentSenderForResult Android API for plugins (#12682) 2025-03-17 11:52:11 -03:00
WofWca
cefefa930b docs: improve tauri_build::build & try_build (#13001)
* docs: remove outdated `tauri_build::build` docs

The docstring has been unchanged ever since
40ac52971e (2021).
The `build()` function has grown massivly since then,
now it's not only about Windows.

* docs: `tauri_build::build`: see `try_build` for more config

`try_build` is not only about not panicing, but it also takes the
`attributes: Attributes` argument,
which is very important for controlling command permissions.

* Update crates/tauri-build/src/lib.rs

Co-authored-by: Amr Bashir <github@amrbashir.me>

* update docs

---------

Co-authored-by: Amr Bashir <github@amrbashir.me>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-17 09:28:09 -03:00
renovate[bot]
4a01299e31 chore(deps): update dependency rollup to v4.36.0 (#13010)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-03-17 19:36:29 +08:00
WofWca
5a23146566 docs: clarify Capability::windows/webviews OR nature (#13000)
* docs: clarify Capability::windows/webviews OR nature

It is intuitive to expect that for the capability to be enabled,
_both_ the window label and the webview label have to match.
However, this is not the case: the capability is enabled
if _either_ the window label matches a pattern
in `Capability::windows` _or_ the webview label matches a pattern
in `Capability::webviews`.

This commit should somewhat clarify this oddity
and protect developers from adding excessive permissions.

For reference, `Capability::webviews` was added in
0cb0a15ce2
(https://github.com/tauri-apps/tauri/pull/8789).

* Apply suggestions from code review

Co-authored-by: Amr Bashir <github@amrbashir.me>

* update schemas

---------

Co-authored-by: Amr Bashir <github@amrbashir.me>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-17 08:29:58 -03:00
Tony
4062e49914 fix: always delete auto start registry entry (#13006) 2025-03-17 08:21:14 -03:00
Nano
a483ba7c27 enhance: align log like Cargo (#13002) 2025-03-17 02:39:36 +02:00
Levi Zim
f981a5ee8b feat: basic support for linux riscv64 (#12602) 2025-03-16 16:33:17 -03:00
animesh chaudhri
2b960dfd9f feat(uninstaller): remove autostart entry during uninstallation (#12643)
* feat(uninstaller): remove autostart entry during uninstallation

Signed-off-by: animeshchaudri <animeshchaudhri3@gmail.com>

* add change file

* check when not updating

* delete registry value only if install mode is "currentUser"

---------

Signed-off-by: animeshchaudri <animeshchaudhri3@gmail.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-16 16:28:10 -03:00
Xuan
eec08a18b6 fix: use bun.lock to identify bun's lockfile (fix #12914) (#12998)
* fix: use bun.lock to identify bun's lockfile

* fix: also check bun.lockb

* doc: add changes doc
2025-03-16 18:00:04 +01:00
Tony
35018eed02 chore: fix missing .md on request-restart.md (#12996) 2025-03-16 21:20:25 +08:00
Tony
de7f34bff4 feat: introduce request_restart (#12874)
* Introduce request_restart

* Migrate `restart`

* Add change file

* Save restart_on_exit and add docs

* Tweak docs to include `restart`

* clear restart flow

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-16 08:42:29 -03:00
Tony
72df2e4a04 refactor: remove permission description from runtime (#12994)
* Remove description from runtime

* Just use none instead

* global_scope_schema and add comments about it

* Tweak wording

* remove comments [skip ci]

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-16 07:33:41 -03:00
Fabian-Lars
0d1446857c fix: Don't minify api dist files (#12989) 2025-03-16 07:11:42 -03:00
Thomas Eizinger
658e5f5d1d feat: introduce App::run_return (#12668)
* Introduce `run_return`

* Fix compile error

* Clone web_context

* Refactor to Result API

* Fix clippy

* Impl mock runtime

* Make it desktop-only

* Add changelog entry

* Fix compile error

* Make it semver compatible

* Extend changelog entry

* Undo semver-hack

* Reduce diff

* Remove unnecessary mut

* Make it take `self` by value

* Reduce diff

* Undo diff hack

* Make everything cfg(desktop)

* Rename vars to reduce diff

* Fix clippy

* Extract make_event_handler

* Reduce diff

* Deprecate `App::run_return`

* Update changelog

* Fix compile errors

* Accept reference

* Create event handler first

* Update example

* Update manifest

* Fix example

* Fix example docs

* Call `setup` only upon Ready

* Update changelog entry

* Update docs

* Update changelog

* Add platform-specific note

* update docs

* run_return on mobile

* Apply suggestions from code review

* remove change file

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-16 07:04:22 -03:00
WofWca
7930dde85c chore: examples: fix & simplify helloworld (#12995)
Remove the cookies code from it.
Firtly, they are not necessary: "Hello, world!" should be simple.
Secondly, it's broken on Windows: `.cookies()` hangs.

The cookies stuff was introduced recently,
in cedb24d494
(https://github.com/tauri-apps/tauri/pull/12665).
This commit reverts the changes to the example.

This supersedes https://github.com/tauri-apps/tauri/pull/12992.
2025-03-16 11:50:06 +02:00
anatawa12
b05f82d35b fix: ensure RunEvent::Exit is triggered on restart (#12313)
* fix: AppHandle::restart() may not send RunEvent::Exit event

* docs: add changelog: `AppHandle::restart()` may not send `RunEvent::Exit` event before exiting the application.

* style: cargo fmt

* avoid deadlock on main thread

* do not let the restart be prevented

leads to a deadlock currently

* Apply suggestions from code review

* lint

* do not emit RunEvent on main thread

* re-export RESTART_EXIT_CODE

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-15 15:49:42 -03:00
Tony
51bcafe323 refactor: use a single closure for filtering in emit_to (#12907)
* Use a single closure for filtering

* clippy

* Update crates/tauri/src/manager/mod.rs

---------

Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.app>
2025-03-15 13:46:51 -03:00
Tony
013f8f6523 feat: add a new option to remove unused commands (#12890)
* Add a new option to remove unused commands

* Fix compile

* Add markers to all core plugins

* Clippy

* Add allow unused when running with this

* Use build script to generate allowed-commands.json

* Clean up and add proper reruns

* Wrong path

* Revert to #[cfg_attr(not(debug_assertions), allow(unused))]

* Add change files

* Some more docs

* Add version requirement note

* Avoid rerun if no capabilities folder

* Remove unused box

* small cleanup

* fix channel

* implement for app handler too

* rely on core:default for channel perms

* Move this feature to config

* Docs change

* Forget one last remove_unused_commands

* Remove removeUnusedCommands from helloworld

* tell handler that the app ACL manifest exists

* update change file

* update doc

* update change file

* Use a struct to pass the data instead of env var

* Clippy

* Fix can't exclude inlined plugins on Windows
due to UNC paths...

* Apply suggestion from code review

* Remove remove on empty to tauri-build

* Revert "Remove remove on empty to tauri-build"

This reverts commit b727dd621e.

* Centralize remove_file(allowed_commands_file_path)

* Escape glob pattern

* update change file

* remove unused commands for dev too

* Update crates/tauri-utils/src/config.rs

Co-authored-by: Fabian-Lars <github@fabianlars.de>

* regen schema

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
Co-authored-by: Fabian-Lars <github@fabianlars.de>
2025-03-15 13:46:08 -03:00
Tobias Assarsson
5591a4f0b4 feature(linux) add mousewheel bindings for zoom functions (#12912)
* add mousewheel bindings commonly used for zooming

* add change file

* update docs

* fmt

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-15 13:29:13 -03:00
Fabian-Lars
2fa33d5c44 chore: Fix example readme instructions. Add pnpm build:debug. (#12983)
* chore: Fix example readme instructions. Add `pnpm build:debug`.

* keep terser on bundle.global.js build to avoid file modifications

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-15 12:51:40 -03:00
Adam Charron
cedb24d494 feat: add Webview::cookies and Webview::cookies_for_url() (#12665)
* Add support for fetching cookies by url

* Add support for fetching all cookies

* add missing getters, update change file

* update docs for windows deadlock

* fix mobile build

* Update crates/tauri-runtime/Cargo.toml

* add docs for stability [skip ci]

---------

Co-authored-by: Adam Charron <acharron@higherlogic.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-15 12:34:41 -03:00
Fabian-Lars
30f5a1553d feat: traffic light position (#12366)
* moving to macbook

* that was so weird to implement

* rm patch

* Discard changes to Cargo.lock

* Create change-pr-12366.md

* add missing builder fn

* remove test

* split change files

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2025-03-15 12:18:11 -03:00
Lucas Fernandes Nogueira
08de8a172b chore: remove 2.0.0-rc references (#12987) 2025-03-15 12:03:09 -03:00
Sean Wang
c108024257 feat(tauri): derive Clone for tauri::ExitRequestApi (#12710) 2025-03-15 10:26:22 -03:00