Commit Graph

4838 Commits

Author SHA1 Message Date
LiesAuer
30c7685eb8
feat: add Builder::append_invoke_initialization_script (#10295)
* Allow to append a custom initialization script

* docs: add doc for `Builder::append_invoke_initialization_script`

* Update core/tauri/src/app.rs

* Update core/tauri/src/app.rs

* add change file

* fix signature

* fix doc test

* doc fmt

---------

Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.app>
2024-08-19 16:41:28 -03:00
Lucas Fernandes Nogueira
ed04cc3d36
feat(core): enhance IPC permission error message (#10664)
* feat(core): enhance IPC permission error message

- include more information about current URL and allowed origins
- enhance formatting of the error message

* plugin not found & command not found

* lint
2024-08-19 16:41:09 -03:00
Lucas Fernandes Nogueira
7796a8fc64
fix(cli): adapt Package.swift to work on older Swift versions (#10687)
I noticed the plugin build fails on older Swift (tested on macOS 12) because the default minimum required macOS version (10.10 in my case) is older than `v10_13` which is set by the Tauri iOS package (and also swift-rs).
So the plugins must explicitly define a minimum macOS version too.
2024-08-19 16:29:16 -03:00
anatawa12
8d148a9e25
feat: Custom sign command with object notation (#10634)
* feat!: Custom sign command with object notation

* implement JsonSchema if schema feature is enabled

* feat: support old string-based custom signing command config

* format: Run cargo fmt inside tooling/bundler folder

* chore: update json schema

* format: cargo fmt again

* small cleanup

* fix change file

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2024-08-19 15:55:58 -03:00
Sebastian Neubauer
5c335ae9ad
fix(android): avoid rebuilds if nothing changed (#10648)
* fix(android): avoid rebuilds if nothing changed

Unconditionally overwriting files where the build reruns if they changed
leads to rebuilds every time.
Only overwrite a file if its content is different to not rebuild in such
a case.

* use write_if_changed utils

* use existing function

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2024-08-19 13:33:39 -03:00
Masahiko Sakakibara
8ae52a615a
fix(cli): change "register_ios_plugin" params to snake case (#10676)
* fix(cli): change "register_ios_plugin" params to snake case

* Create change-pr-10676.md

* Update .changes/change-pr-10676.md

* Update .changes/change-pr-10676.md

---------

Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.app>
2024-08-19 13:29:01 -03:00
Norbiros
77844529f3
fix: Correctly export DefaultPermissionsRule (#10678)
* fix: Correctly export `DefaultPermissionsRule`

* Update fix-export-default-permissions.md

* fix: Lint

---------

Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
2024-08-19 13:10:05 -03:00
Guillaume M
9b99ebab17
fix(cli): do not force architecture when building and archiving iOS app (#10431)
* feat(ios): add a new cli option to dev to use project archs

Add a new option to instruct cargo-mobile2 to use architectures configured in the project for building

* update cargo-mobile2, add change file

* fix change file [skip ci]

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2024-08-19 12:36:48 -03:00
github-actions[bot]
b25545c53f
apply version updates (#10683)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2024-08-19 09:48:54 -03:00
Lucas Fernandes Nogueira
c689521a76
fix(api): tslib path (#10681) 2024-08-19 09:27:45 -03:00
martin frances
6b63c75504
For linting and testing auto update the node version to "lts/*" (#10323) 2024-08-18 07:55:38 -03:00
Jacob Bolda
52fdcaaf28
skip prepublish on api (#10658) 2024-08-18 07:55:19 -03:00
Jacob Bolda
ee0b53fbe2
skip pack in publish, use check fetch (#10657)
* skip pack in publish, use check fetch

* remove script

* remove apt, exists in main pipeline

* CLI doesn't need separate check

* no assets for tauri-cli
2024-08-18 07:54:59 -03:00
Lucas Fernandes Nogueira
23a912bb84
fix(ci): @tauri-apps/cli publish workflow (#10659)
* fix(ci): pnpm install

* fix setup-node

* node16 setup fails somehow

* remove unnecessary install deps step

* run nodejs directly

* fix permissions

* fix metadata
2024-08-17 08:21:27 -03:00
Lucas Nogueira
dcc62e6fc4
fix(macos-sign): add kv feature to the log crate 2024-08-17 00:58:34 -03:00
Lucas Nogueira
167a0feb31
fix(ci): missing id-token write permission for provenance 2024-08-17 00:38:09 -03:00
Lucas Nogueira
1142289670
fix(tauri-runtime-wry): docs.rs build 2024-08-17 00:16:07 -03:00
Lucas Nogueira
85c2d6302e
fix(ci): set NPM_CONFIG_PROVENANCE to true 2024-08-17 00:15:00 -03:00
Lucas Nogueira
07a5f505d9
fix(ci): run pnpm publish with --no-git-checks 2024-08-17 00:12:24 -03:00
Lucas Nogueira
30667714c0
fix(ci): wrong prepublish scripts for @tauri-apps/api 2024-08-16 23:54:55 -03:00
github-actions[bot]
3522fbd78e
Apply Version Updates From Current Changes (#10561)
* apply version updates

* fix versions

---------

Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2024-08-16 23:39:49 -03:00
Lucas Nogueira
dd5b081eeb
fix(ci): install pnpm on integration tests 2024-08-16 23:13:35 -03:00
Amr Bashir
01f6aa3405
build: migrate repo to use pnpm as the package manager (#10607)
* build: migrate repo to use `pnpm` as the pacakge manager

* corepack enable

* update lock file

* format files

* format .github

* fix audit js

* wrap in quotes

* --frozen-lockfile

* simplify packageManager field

* lockfile

* remove cache from audit workflow
2024-08-16 23:04:08 -03:00
Amr Bashir
9e891933d8
fix(utils): fix resources map becomes directory (#10293)
* fix(utils): fix resources map becomes directory

closes #10187

Fixes the behavior of mapped resources generating extra directory, for example:
`"../resources/user.json": "resources/user.json"` generates this resource `resources/user.json/user.json`
where it should generate `resources/user.json`

This PR includes a refactor of the Iterator implementation which splits it into more scoped functions and relis on recursing instead of a loop which makes the code a lot more readable and easier to maintain.

* clippy

* cover more cases

* clippy

* fix glob into directory, not resolving target correctly

* return error when resource origin path doesn't exist

* fix resources example build

* Update .changes/resources-map-becoming-dirs.md

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2024-08-16 23:03:14 -03:00
Lucas Fernandes Nogueira
8deb1966ac
feat(bundler): infer signing identity from certificate to import (#10652) 2024-08-16 20:30:49 -03:00
Lucas Fernandes Nogueira
d39c392b7c
chore(deps): update tao and wry to latest (#10655) 2024-08-16 20:30:34 -03:00
Amr Bashir
6d7ac65676
chore: use 0.1.0 as version in templates (#10644)
closes #10474
2024-08-16 20:19:04 -03:00
Lucas Fernandes Nogueira
1b0c447fcb
fix(macos-sign): missing stdout/stderr in Node.js context (#10654) 2024-08-16 20:16:00 -03:00
Lucas Fernandes Nogueira
10fb027b75
fix(cli): migrate v1 plugin dependencies, prevent dup, closes #10650 (#10656) 2024-08-16 19:58:20 -03:00
Lucas Fernandes Nogueira
255d64e3dc
fix(cli): actually check if there are multiple android devices connected (#10642) 2024-08-16 04:12:34 +03:00
Lucas Fernandes Nogueira
d0510f52eb
refactor(core): serialize response once, closes #5641 (#10641)
* refactor(core): serialize response once closes #5641

This change impacts both the custom protocol and the postMessage based IPC implementations. Basically it changes the whole IPC mechanism to work on raw JSON strings so we do not need to serialize a serde_json::Value after serializing to it from a user-provided type.

i benchmarked this with a 150MB file response (returning Vec<u8> instead of tauri::ipc::Response since the latter does not serialize at all) and it went from 29s to 23s (custom protocol) and from 54s to 48s (post message) on macOS.

* fix mobile & lint

* clippy
2024-08-15 16:15:11 -03:00
renovate[bot]
d1ee3f4b55
chore(deps) Update Tauri CLI (dev) (#10610)
* chore(deps) Update Tauri CLI

* html5ever 0.28

* update windows-sys

* cast

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.app>
2024-08-15 15:39:21 -03:00
Lucas Fernandes Nogueira
f712f31d1d
fix(cli): add notarize error (#10639)
* fix: add notarize error

* add change file
2024-08-15 14:12:03 -03:00
renovate[bot]
8902dd8137
chore(deps) Update Tauri API Definitions (#10614)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-08-15 11:14:36 -03:00
renovate[bot]
b5c948f68e
chore(deps) Update Tauri Codegen (#10613)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-08-15 10:52:11 -03:00
renovate[bot]
360330136f
chore(deps) Update dependency @types/eslint to v9 (#10620)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-08-15 10:51:46 -03:00
renovate[bot]
659c7d2f5d
chore(deps) Update Rust crate syn to v2.0.74 (#10609)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-08-15 10:50:39 -03:00
Lucas Fernandes Nogueira
9089d97637
fix(cli): properly resolve merge config on mobile build closes #9970 (#10605)
just applying the change from #10600 to xcode to fix the linked issue :)
2024-08-15 10:50:19 -03:00
Lucas Fernandes Nogueira
b6dca99fff
refactor(api)!: change window label getters to be async ref #5380 (#10630) 2024-08-15 09:12:40 -03:00
Lucas Fernandes Nogueira
b160f9359d
fix(cli): only validate iOS lib on debug builds (#10638) 2024-08-15 09:12:21 -03:00
Broken_Deer
521d1d5cdb
fix(bundler): armv7 appimage bundler uses invalid download links [closes #6579] (#10619)
* Update appimage.rs

* Update appimage.rs

* Create change-pr-10619.md

* Update change-pr-10619.md

---------

Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
2024-08-14 17:39:36 +02:00
Lucas Fernandes Nogueira
9f75d06228
fix(cli): adb port forward error handling, add logs, closes #9509 (#10604) 2024-08-13 22:07:02 -03:00
Amr Bashir
39bf0a1635
refactor: rename TAURI_SIGNTOOL_PATH -> TAURI_WINDOWS_SIGNTOOL_PATH (#10595)
immediately after merging #10588 I noticed that the variable name might be a bit ambigious and could cause confusion on other pl atforms other than Windows
2024-08-13 21:48:12 -03:00
Amr Bashir
78e22bedca
feat(cli): support AndroidTV by default (#10602)
closes #10534
2024-08-13 21:47:41 -03:00
Lucas Fernandes Nogueira
f4cd68f040
fix(cli): builtin dev server should also be forwarded for Android (#10600) 2024-08-13 21:11:01 -03:00
Lucas Fernandes Nogueira
f35bcda289
feat(cli): handle known target specific plugins on permission add #10596 (#10598)
Closes #10596
2024-08-13 14:01:10 -03:00
Lucas Fernandes Nogueira
712f1049fa
fix(cli): ios dev and ios build support for bun (#10569) 2024-08-13 09:00:41 -03:00
Lucas Fernandes Nogueira
41c7a6646b
fix(cli): properly exit with code 0 on panic when running with bun (#10572) 2024-08-13 08:53:04 -03:00
anatawa12
f8d658ea1b
feat: TAURI_SIGNTOOL_PATH environment variable for specifying the path to signtool.exe. (#10588) 2024-08-13 14:49:28 +03:00
Lucas Fernandes Nogueira
fedf93eb7e
refactor(core): return 200 on any IPC call, closes #10286 (#10585)
* refactor(core): return 200 on any IPC call, closes #10286

By default the webview prints a `Failed to load resource: the server responded with a status of 400 (Bad Request) ipc://localhost` error message when a command returns an error, which is confusing to users.

This changes the IPC to return status 200 on any call, with a header to indicate whether the result was ok or not. This removes the console error, which would only log the actual error result if it isn't caught by the user.

* add change file

* apply code review changes
2024-08-13 08:39:20 -03:00