on Windows the Webview2 environment options must match when created webviews sharing the same data directory (unless specified, all webviews share the same data directory). This PR validates the options, warning if they do not match, and forces the webview to be created with the same previous environment to prevent a crash.
discovered as part of #14089
currently we only install Rust targets for mobile when initializing the projects.
Users can commit the Android/iOS projects, so running the init command is not a requirement to develop mobile apps. This change ensures the Rust targets are installed before trying to compile them.
* fix(tauri-runtime-wry): ignore about:blank initial URL
fixes a macOS warning when a navigation handler is registered and you choose to create a new window on the on_new_window hook - in this case we shouldn't perform the initial navigation since the URL is provided by the webview configuration from the hook
* change tag
* bump min wry
- Replace `unwrap` and `expect` with `anyhow::Result` for safer error handling
- Add contextual error messages using `anyhow::Context`
- Fix `home_path` on Windows by using `USERPROFILE` instead of `HOMEPATH`
- Ensure process helpers (`run_collect`, `run`) return `Result` instead of panicking
- Improve parsing logic in `parse_max_mem` and `parse_strace_output`
- Add documentation comments for all public functions
- Add best-effort cleanup and resilience against malformed input
* Fix Tauri iOS build not having a PATH variable to access unzip to extract binaryTargets and also not including Frameworks when linking
* Add covector change
* fmt
* Update crates/tauri-utils/src/build.rs
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.app>
---------
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.app>
* feat(cli): check plugin versions for incompatibilities
check core plugin versions for incompatibilities between Cargo and NPM releases
a plugin NPM/cargo version is considered "incompatible" if their major or minor versions are not equal
on dev we show an warning
on build we error out (with a `--ignore-incompatible-plugins` flag to prevent that)
this is an idea from @oscartbeaumont
we've seen several plugin changes that require updates for both the cargo and the NPM releases of a plugin, and if they are not in sync, the functionality does not work
e.g. https://github.com/tauri-apps/plugins-workspace/pull/2573 where the change actually breaks the app updater if you miss the NPM update
* Use list to get multiple package versions at once
* Fix for older rust versions
* Clippy
* Support yarn classic
* Support yarn berry
* Use `.cmd` only for `npm`, `yarn`, `pnpm`
* Use yarn list without --pattern
* rename
* Extract function `check_incompatible_packages`
* Check `tauri` <-> `@tauri-apps/api`
* incompatible -> mismatched
* run build check in parallel
* rename struct
* Switch back to use sync check and add todo
* Extract to function `cargo_manifest_and_lock`
---------
Co-authored-by: Tony <legendmastertony@gmail.com>
* fix: a few regressions from previous PRs
* rename with_window_features to window_features
* Clippy
* clippy
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* Adds the ability to set the focused property from tauri.conf.json -- windows
* add set_focusable, pin tao
* fmt
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* add "new window" and "document title changed" webview handler
* take document title changed handler
* update example, add missing api, change files
* allow creating tauri window for the window.open call
* set size and position, fix linux, example
* enhance document title change
* fix windows deadlock
* wry 0.53
* update wry
---------
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
* feat: add `--root-certificate-path` option for mobile dev
lets you use a HTTPS development server
example usage:
```
cargo install tauri-cli --git https://github.com/tauri-apps/tauri --branch feat/mobile-dev-cert
cargo tauri android dev --open --root-certificate-path "/Users/lucas/Library/Application Support/mkcert/rootCA.pem" --features tauri/rustls-tls
```
* Apply suggestions from code review
Co-authored-by: Fabian-Lars <github@fabianlars.de>
---------
Co-authored-by: Fabian-Lars <github@fabianlars.de>