Compare commits

...

498 Commits

Author SHA1 Message Date
Lucas Nogueira
83a9e6c572 Merge remote-tracking branch 'origin/dev' into feat/command-tests 2023-01-04 19:00:48 -03:00
matthme
72aa17f79a added additional information to AllowlistConfid documentation (#5985)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2023-01-04 18:21:26 -03:00
Lucas Nogueira
f7e86798c2 lint 2023-01-04 18:19:15 -03:00
renovate[bot]
7ae67dde69 chore(deps) Update dependency eslint-config-standard-with-typescript to v26 (#5981)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2023-01-04 13:05:00 -03:00
dependabot[bot]
2809171fb4 chore(deps): bump json5 from 1.0.1 to 1.0.2 in /tooling/api (#5973)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-04 10:11:46 -03:00
renovate[bot]
4b9a5af3cf chore(deps) Update dependency @napi-rs/cli to v2.14.1 (#5977)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-04 10:10:51 -03:00
renovate[bot]
d2df2e831b chore(deps) Update Tauri API Definitions (#5978)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-04 10:10:10 -03:00
Amr Bashir
c94e1326a7 feat(bundler): add nsis, closes #4450, closes #2319 (#4674)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2023-01-03 14:29:20 -03:00
Jason
4892637f83 fix: Resizing glitch on custom titlebar click (closes #2549) (#5966)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
closes https://github.com/tauri-apps/tauri/issues/2549
2023-01-03 14:14:37 -03:00
Lucas Nogueira
936d46a41a struct arg test 2023-01-02 15:43:37 -03:00
Lucas Nogueira
a115f91c52 add future test 2023-01-02 15:21:49 -03:00
alesharik
ce76d95ab1 feat(tauri-cli): add dylib support to tauri.bundle.macOS.frameworks, closes #4615 (#5732)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-31 13:53:35 -03:00
luofei
2265e09718 feat(windows): implement with_tooltip (#5938)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-31 13:24:39 -03:00
dependabot[bot]
6d5dc9489c chore(deps): bump json5 from 2.2.0 to 2.2.2 in /tooling/cli/node (#5949)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-31 12:55:52 -03:00
renovate[bot]
d703c7f459 chore(deps) Update Rust crate cargo_toml to 0.14 (#5928)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-31 12:55:19 -03:00
renovate[bot]
281714e567 chore(deps) Update dependency @napi-rs/cli to v2.14.0 (#5930)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-31 12:48:50 -03:00
renovate[bot]
c1d84e8127 chore(deps) Update Tauri API Definitions (#5927)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-31 12:47:45 -03:00
renovate[bot]
04ddee91e8 chore(deps) Update Rust crate ico to 0.3 (#5929)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-31 12:47:25 -03:00
Lucas Nogueira
864dfe4de5 fix(examples): use new MessageDialogButtons variant name 2022-12-30 20:15:45 -03:00
Amr Bashir
077605f58b refactor: use windows manifest already present in tauri-build crate (#5936)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-30 08:44:31 -03:00
Bo
00e1efaa9b feat: customize button texts of message dialog (#4383)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-27 18:15:53 -03:00
Amr Bashir
7a8d570db7 fix: sync webview theme with window theme on Windows, closes #5802 (#5874)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-27 14:57:02 -03:00
Amr Bashir
0d5835d133 chore: update plugin example based on CTA (#5213)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-27 14:32:29 -03:00
renovate[bot]
488a7562bb chore(deps) Update dependency eslint-config-standard-with-typescript to v24 (#5832)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-27 13:15:58 -03:00
Darin Morrison
3f35b45263 Expose wry navigation_handler via WindowBuilder closes #4080 (#5686)
Co-authored-by: silvanshade <silvanshade@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-27 12:54:57 -03:00
Amr Bashir
146a794cb6 fix(core): sync windows metadata across all windows, closes #5571 (#5615)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-27 12:19:07 -03:00
TomatoCake
ff99a9bf74 docs(api): Add missing APIs to dialog allowlist (#5858) 2022-12-27 10:40:28 -03:00
renovate[bot]
bf550f94cc chore(deps) Update Tauri JS CLI (#5882)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-27 10:39:55 -03:00
renovate[bot]
f439122622 chore(deps) Update Tauri API Definitions (#5883)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-27 10:39:46 -03:00
khuongduy354
9d2144128f feat(cli): add option to make custom icon sizes, closes #5121 (#5246)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-27 10:34:20 -03:00
tweidinger
f5305de251 Added GitHub disclosure process (#5905) 2022-12-26 19:01:45 -03:00
Lucas Fernandes Nogueira
d17027e1a0 feat: expose url method (#5914)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
Co-authored-by: Jonas Kruckenberg <iterpre@protonmail.com>
2022-12-26 15:31:40 -03:00
Amr Bashir
72621892fe fix(cli): use unicode feature for heck crate, closes #5860 (#5872) 2022-12-26 11:38:13 -03:00
Amr Bashir
89602cdce3 feat(bundler): check Launch app by default for WiX, closes #5859 (#5871) 2022-12-26 11:36:43 -03:00
Amr Bashir
c2608423b6 fix(cli): don't panic when a crate version couldn't be parsed (#5873)
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-12-26 11:35:04 -03:00
Lucas Nogueira
1956a3aeda fix(core): window allowlist error message for internal APIs 2022-12-23 22:28:04 -03:00
Lucas Nogueira
14d567f7ec chore: update tauri changelog 2022-12-22 11:35:29 -03:00
Amr Bashir
72389b00d7 Merge pull request from GHSA-6mv3-wm7j-h4w5
* fix(core): use `require_literal_separator` when matching paths

* document the need for `require_literal_separator`

* use `require_literal_leading_dot`
2022-12-22 15:53:46 +02:00
Lucas Nogueira
4f2fd4dcf7 chore: run cargo fmt 2022-12-15 18:40:57 -03:00
Lucas Nogueira
cf0986491c chore(cli): fix clippy warnings 2022-12-15 18:30:32 -03:00
Lucas Nogueira
d7ffa7f95e chore: addition to previous commit 2022-12-15 18:28:44 -03:00
Lucas Nogueira
015020760a chore: fix clippy warnings 2022-12-15 18:03:28 -03:00
renovate[bot]
a02c6c4c81 chore(deps) Update Rust crate toml to 0.5.10 (#5836)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-15 12:35:58 -03:00
Fabian-Lars
cd8c074ae6 feat(cli): add support for Cargo's workspace inheritance for the package version, closes #5070 (#5775)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-14 13:39:05 -03:00
Robin van Boven
f7a080a121 fix(bench): Result interpretation problems (#5798)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-14 12:44:05 -03:00
Amr Bashir
bca09f7f5f feat(tauri-build): add option to specify Windows manifest, closes #5584 (#5730)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-14 12:18:46 -03:00
Lucas Nogueira
2bf9c27375 fix(ci): use client-payload input to trigger cli.js publish workflow 2022-12-14 12:17:43 -03:00
Noam Zaks
3dc38b150e feat(core): expose additional_browser_args to window config (fix: #5757) (#5799)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-14 11:46:24 -03:00
renovate[bot]
28133c5155 chore(deps) Update dependency @napi-rs/cli to v2.13.2 (#5827)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 09:01:29 -03:00
renovate[bot]
1efe861d3c chore(deps) Update Rust crate json-patch to 0.3 (#5828)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 09:01:20 -03:00
renovate[bot]
0eddb812c6 chore(deps) Update Tauri API Definitions (#5829)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 09:00:53 -03:00
renovate[bot]
19ec53fae4 chore(deps) Update Tauri Codegen (#5830)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 09:00:36 -03:00
filip
73fd60eef2 expose set_device_event_filter in tauri (#5562)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
Closes https://github.com/tauri-apps/tauri/issues/5496
2022-12-13 13:57:32 -03:00
Amr Bashir
5fd4d20e3b chore: remove duplicate field (#5824) 2022-12-13 12:56:58 -03:00
Amr Bashir
4ab5545b7a feat: add content protection api, closes #5132 (#5513)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-13 01:04:22 -03:00
Amr Bashir
233e43b0c3 feat: add title getter on window, closes #5023 (#5515)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-13 00:59:09 -03:00
Lucas Fernandes Nogueira
d0d873e39a feat(core): add support to mailto: and tel: links, closes #5521 (#5544) 2022-12-13 00:57:39 -03:00
Lucas Nogueira
9db9e6c037 feat(ci): also run check-generated-files on pull request 2022-12-12 10:36:25 -03:00
crpz1
62144ef3be feat: add is_minimized (fix #3878) (#5618)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
fixes https://github.com/tauri-apps/tauri/issues/3878
2022-12-12 10:34:19 -03:00
Lucas Nogueira
2624af9c24 add rename_all test 2022-12-09 09:02:06 -03:00
Lucas Nogueira
b0485d0187 add async command tests, command with arg 2022-12-08 17:02:58 -03:00
Lucas Nogueira
a2724b3e1c basic setup for command tests 2022-12-08 14:15:20 -03:00
Lucas Fernandes Nogueira
eaf0d71779 fix(ci): do not test cli.js on node v12 (#5784) 2022-12-08 13:23:50 -03:00
github-actions[bot]
75a0c79dea Apply Version Updates From Current Changes (#5710)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-12-08 11:57:21 -03:00
Orvar Segerström
c14b1df372 fix(core): Invoke event listener in windows safely to avoid causing uncaught errors in windows that have loaded external urls (#5563)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-12-08 11:32:52 -03:00
Lucas Fernandes Nogueira
41a471b23a feat(covector): improve published version check (#5783) 2022-12-08 09:49:55 -03:00
Avaab Razzaq
9e7ce0a8ee feat(cli): detect SolidJS and SolidStart (#5758) 2022-12-08 09:47:32 -03:00
Lucas Nogueira
b293da35dd fix(changes): change enable_macos_default_menu bump to patch
This is a regression so we can publish it as a patch.
2022-12-08 09:32:59 -03:00
Lucas Nogueira
fdcd77338c chore(deps): update wry to 0.23 2022-12-08 09:01:12 -03:00
Lucas Fernandes Nogueira
9093ef3314 fix(bundler): blank taskbar icon on WiX update, closes #5631 (#5779) 2022-12-08 08:49:54 -03:00
Lucas Nogueira
ffe21e0225 chore(cli): rerun build on template changes 2022-12-07 16:30:35 -03:00
Lucas Nogueira
4f087cfd92 chore(deps): pin wry to 0.22.6 2022-12-07 16:28:40 -03:00
renovate[bot]
7225501c13 chore(deps) Update dependency prettier to v2.8.1 (#5777)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-07 16:27:02 -03:00
renovate[bot]
9c632ee35d chore(deps) Update dependency prettier to v2.8.1 (#5776)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-07 16:26:52 -03:00
renovate[bot]
b5059d77e9 chore(deps) Update Tauri API Definitions (#5772)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-07 16:06:27 -03:00
Lucas Nogueira
f81c3f2922 fix(ci): install libfuse2 to run integration tests 2022-12-07 16:06:06 -03:00
Amr Bashir
8866ecac3c feat(core): add tauri::Builder::enable_macos_default_menu (#5756) 2022-12-07 11:01:53 +08:00
Amr Bashir
0f26960891 fix(core/api): cleanup before exit (#5765) 2022-12-07 11:01:13 +08:00
Antoine Meloche
c7bffb01be DOCS: incorrect descriptions in AboutMetadata fields (#5744) 2022-12-03 10:22:17 -03:00
Lucas Fernandes Nogueira
9d872ab872 feat(cli): detect SvelteKit and Vite (#5742) 2022-12-02 08:18:28 -03:00
renovate[bot]
b6027b2dd2 chore(deps) Update Tauri API Definitions (#5729)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-30 11:31:11 -03:00
renovate[bot]
2a0b2cea03 chore(deps) Update dependency fs-extra to v11 (#5727)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-30 11:30:53 -03:00
renovate[bot]
873840a204 chore(deps) Update Rust crate image to 0.24.5 (#5675)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-30 11:25:53 -03:00
renovate[bot]
445a8b6062 chore(deps) Update Tauri API Definitions (#5676)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-30 11:11:07 -03:00
renovate[bot]
677db85877 chore(deps) Update Tauri JS CLI (#5678)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-30 11:10:54 -03:00
Amr Bashir
c0989848b9 feat(cli/dev): add --no-dev-server, ref #5708 (#5722) 2022-11-30 10:34:51 -03:00
Fabian-Lars
04681a6b13 fix(docs): cross-link to correct PathResolver method in path module docs. (#5714) 2022-11-29 11:26:13 +08:00
Fabian-Lars
2d545eff58 fix(cli): corrupted icons in bundled macOS icons (#5698)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-11-28 08:57:32 -03:00
Vilian Gerdzhikov
0e8d3a6f16 wording & version corrections (#5696) 2022-11-28 08:57:11 -03:00
Fabian-Lars
b490308c88 fix(core): compilation error on older Linux versions, fixes #5684 (#5697) 2022-11-28 08:39:19 -03:00
github-actions[bot]
527bd9feea Apply Version Updates From Current Changes (#5644)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-11-24 12:52:54 -03:00
Lucas Fernandes Nogueira
d710946064 refactor: move Linux custom protocol headers support behind feature flag (#5683) 2022-11-24 09:38:19 -03:00
Eric Veilleux
15ebeb1851 Update ico package (#5577) 2022-11-22 11:15:54 -03:00
Lucas Nogueira
50fbd49273 chore(examples): simplify streaming example code, closes #5670 2022-11-22 10:47:03 -03:00
LucasJavaudin
677838ccfa fix double serialize on invoke (#5639)
Co-authored-by: LucasJavaudin <lucas.javaudin@cyu.fr>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-11-20 10:20:09 -03:00
renovate[bot]
168c3d0148 chore(deps) Update Tauri API Definitions (#5590)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-20 09:38:42 -03:00
renovate[bot]
2eec3e13fb chore(deps) Update Tauri Codegen (#5593)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-20 09:38:31 -03:00
renovate[bot]
a883c31088 chore(deps) Update dependency jest to v29.3.1 (#5594)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-20 09:37:57 -03:00
renovate[bot]
f2d7405df4 chore(deps) Update Rust crate attohttpc to 0.24 (#5591)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-20 09:37:49 -03:00
Lucas Nogueira
1ecaeb29aa fix(cli): inject config feature flags when features arg is not provided 2022-11-18 13:12:50 -03:00
Lucas Nogueira
7e3d672b9b chore(examples): ignore mobile artifacts on api example 2022-11-18 13:11:18 -03:00
Amr Bashir
bb2510876d fix(core): extend allowlist with app's allowlist, closes #5650 (#5652) 2022-11-18 12:27:38 -03:00
Oscar Beaumont
ed43ff3243 fix(tauri): add missing generics on AppHandle and App (#5642)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-11-17 18:54:47 -03:00
Fabian-Lars
5fe68b1cec docs: Various docs improvements (#5643) 2022-11-17 18:47:54 -03:00
看彩虹的人
3d37ed38c7 fix(examples): fix command args case (#5635) 2022-11-17 15:04:10 +02:00
Justin Syme
830ae97955 docs(api.js): update app.show docs (#5633)
Grammar correction.
2022-11-16 12:39:22 +02:00
Lucas Nogueira
67f14b4ce8 chore(tauri): update CHANGELOG.md 2022-11-11 12:09:27 -03:00
Lucas Fernandes Nogueira
6e879742f0 feat(ci): improve cache, add test-core features matrix (#5604) 2022-11-10 17:30:10 -03:00
Orhun Parmaksız
a836373328 chore: fix a typo in changelog (#5580) 2022-11-08 23:23:25 +02:00
Lucas Nogueira
2e1bd04775 fix(cli.js): set version to 1.2.0 2022-11-08 10:33:33 -03:00
github-actions[bot]
45a5cd569b Apply Version Updates From Current Changes (#5295)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-11-08 09:24:09 -03:00
Lucas Fernandes Nogueira
3afccfce17 chore(deps): update wry to 0.22 (#5573) 2022-11-08 08:47:29 -03:00
Lucas Fernandes Nogueira
1aba1780de feat(ci): define workspace for rust-cache, improving cache key (#5559) 2022-11-06 16:27:29 -03:00
Ben Wishovich
878421beb7 fix: Add WASM files to Vite Allow List and change devPath to localhost to fix Web Example (#5560)
Co-authored-by: Ben Wishovich <ben@benw.is>
2022-11-06 16:26:27 -03:00
Lucas Nogueira
777c086590 feat(ci): improve cache usage 2022-11-05 13:14:56 -03:00
Lucas Nogueira
60e08605d5 chore(ci): do not cache artifacts-updater on failure 2022-11-05 09:33:00 -03:00
Lucas Nogueira
d8b996c00a chore(changes): adjust config-schema build scripts 2022-11-05 09:32:23 -03:00
Lucas Fernandes Nogueira
7aaf27ce5f fix(bundler): load WiX DLLs on Github Actions (#5552) 2022-11-04 21:00:02 -03:00
Lucas Fernandes Nogueira
014aeca11f fix(ci): use python 3.10 on bench workflow (#5550) 2022-11-04 19:25:55 -03:00
renovate[bot]
e7078a3030 chore(deps) Update dependency jest to v29 (#5542)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 18:29:15 -03:00
Lucas Fernandes Nogueira
b41447b811 feat(ci): use Swatinem/rust-cache@v2 (#5547) 2022-11-04 18:26:30 -03:00
Lucas Fernandes Nogueira
aa119f2836 feat(api): add FormData support on Body.form, closes #5545 (#5546) 2022-11-04 15:18:28 -03:00
Amr Bashir
99fe1c562f fix(core): resolve base dir in shell scope, closes #5480 (#5508) 2022-11-04 12:38:06 -03:00
Lucas Fernandes Nogueira
9b1a6a1c02 fix(core): set correct mimetype for asset protocol streams, #5203 (#5536) 2022-11-04 12:35:45 -03:00
Lucas Fernandes Nogueira
c6321a610c fix(cli): remove unused dependencies, closes #5522 (#5543) 2022-11-04 12:35:21 -03:00
Dotan J. Nahum
e055c69c23 small typo fix (#5541) 2022-11-04 08:59:57 -03:00
Lucas Fernandes Nogueira
582c25a0f0 refactor(cli): disable api-all on templates (#5538) 2022-11-03 18:57:32 -03:00
renovate[bot]
dc9269bc8d chore(deps) Update Tauri API Definitions (#5523)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 18:31:27 -03:00
Lucas Fernandes Nogueira
6c13840cee feat(examples): add desktop/web application example (#5537) 2022-11-03 18:01:47 -03:00
Amr Bashir
2d9c2b4724 Revert "fix(core): set correct mimetype for asset protocol streams, closes #5203 (#5210)"
This reverts commit 39443b4350.
2022-11-03 10:00:49 -03:00
Lucas Nogueira
23859f7502 fix(prettier): ignore core/config-schema/schema.json 2022-11-03 09:39:03 -03:00
Lucas Nogueira
ab29908aba chore(cli): remove unneeded create_dir_all call 2022-11-03 09:37:18 -03:00
Lucas Nogueira
873b9aee90 chore: run yarn format 2022-11-03 09:27:43 -03:00
Webber Takken
35264b4c18 docs: fix missing object to read from for listen example (#5505) 2022-10-29 08:56:14 -03:00
Amr Bashir
a178f95d68 feat: config schema generator (#5193)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-28 10:44:37 -03:00
Amr Bashir
cc186c7a0e fix(cli): keep dev watcher alive if config is incorrect, closes #5173 (#5495)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-27 19:47:50 -03:00
Lucas Fernandes Nogueira
79dd6e16a7 fix(core): properly emit events with object payload, closes #5482 (#5492) 2022-10-27 19:01:37 -03:00
Amr Bashir
9417ce401c fix(cli): apply .taurignore rules to workspace members, closes #5355 (#5460)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-27 19:01:28 -03:00
Amr Bashir
7a231cd1c9 fix(cli): detect deno (#5475)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-27 19:00:56 -03:00
renovate[bot]
6ca8a056e8 chore(deps) Update Rust crate serde_json to 1.0.87 (#5483)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-26 11:25:11 -03:00
renovate[bot]
e599d92681 chore(deps) Update Tauri API Definitions (#5484)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-26 11:25:00 -03:00
Amr Bashir
a3a70218f3 fix(cli): pass --no-default-features to runner instead of app, closes #5415 (#5474) 2022-10-25 10:26:30 -03:00
Webber Takken
cb6ee77e69 fix(docs): remove parameter from example that's not in the api [skip ci] (#5471)
* Remove parameter from example that's not in the API

* Update filter extensions

Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
2022-10-23 21:46:40 +02:00
Jonas Kruckenberg
5b1e99f264 Fix/hook env vars (#5452)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-22 10:33:15 -03:00
Lucas Fernandes Nogueira
e00b1e5f94 fix(core): update metadata before window-created listeners, closes #5191 (#5458) 2022-10-22 10:04:56 -03:00
renovate[bot]
161d5be49a chore(deps) Update dependency eslint-plugin-promise to v6.1.1 (#5444)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-20 10:54:24 -03:00
Lucas Fernandes Nogueira
e7ccbd8573 feat(cli): detect JSON5 and TOML configuration files in the dev watcher (#5439) 2022-10-19 15:37:54 -03:00
Tnze
9076d5d2e7 feat(cli): add prompt information when file changing detected, closes #5417 (#5428)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-19 10:24:56 -03:00
renovate[bot]
ef41c5bfd4 chore(deps) Update Tauri API Definitions (#5438)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-19 10:07:23 -03:00
renovate[bot]
0b43033c5c chore(deps) Update dependency eslint-config-standard-with-typescript to v23 (#5187)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-19 10:06:48 -03:00
renovate[bot]
a65b5fea3d chore(deps) Update Rust crate clap to v4 (#5353)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-19 10:04:13 -03:00
renovate[bot]
87ebf4e084 chore(deps) Update Tauri JS CLI (#5351)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-19 09:43:15 -03:00
Lucas Nogueira
e37b7677cd chore: update schema.json 2022-10-19 09:40:34 -03:00
renovate[bot]
fc2bac959b chore(deps) Update Tauri API Definitions (#5350)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-19 09:26:46 -03:00
Lucas Fernandes Nogueira
9d8b377481 feat(tauri-runtime-wry): drop the WebContext on WebView drop (#5240) 2022-10-19 09:23:10 -03:00
Caesar Schinas
4137ab44a8 feat(macos): add tabbing_identifier option, closes #2804, #3912 (#5399)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-19 09:20:17 -03:00
renovate[bot]
bddf59e5d0 chore(deps) Update Rust crate cargo_toml to 0.13 (#5434)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-19 09:19:14 -03:00
Lucas Nogueira
b713aed21b chore(cli): update Cargo.lock 2022-10-18 09:39:52 -03:00
Lucas Fernandes Nogueira
d23d6f60e8 feat(ci): check if generated files match source (#5422) 2022-10-17 12:09:23 -03:00
Lucas Fernandes Nogueira
357480f4ae feat(core): custom protocol headers on Linux, closes #4496 (#5421) 2022-10-17 12:08:59 -03:00
Lucas Fernandes Nogueira
95f467add5 feat(core): add window accept_first_mouse option, closes #5347 (#5374) 2022-10-17 11:07:45 -03:00
renovate[bot]
b8bf8e0fac chore(deps) Update Rust crate attohttpc to 0.23 (#5392)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-17 11:06:56 -03:00
я котик пур-пур
60bf067913 chore(examples): remove the legacy X-UA-Compatible meta (#5394) 2022-10-17 11:05:31 -03:00
Pedro Luiz Cabral Salomon Prado
49f06ca4b9 fix: deepfreeze check by prop (#5407)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-17 10:59:06 -03:00
Lucas Fernandes Nogueira
4036e15f5a feat(core): reimplement window initial focus flag, closes #5120 (#5338) 2022-10-08 16:37:12 -03:00
Kasper
8357ce5b2e Fix dialog.save return type (#5373)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
2022-10-08 15:59:13 -03:00
Lucas Nogueira
ecf6a8ad10 chore(deps): set wry to git dev branch 2022-10-08 15:53:38 -03:00
Amr Bashir
208ce34f1e feat: update to wry 0.22 (#5306) 2022-10-08 15:52:25 -03:00
Amr Bashir
4cbdf0fb1c fix(core): escape glob characters in drop/dialogs , closes #5234 (#5237)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-04 19:50:29 -03:00
Amr Bashir
f756cd5e7e fix(core): wait for tray cleanup before exiting app, closes #5244 (#5245) 2022-10-04 17:02:54 -03:00
Amr Bashir
a5861d8294 chore: add covector readme (#5255) 2022-10-04 17:02:30 -03:00
Amr Bashir
1129f4f575 refactor: simplify api.js bundling (#4277)
Co-authored-by: Jonas Kruckenberg <iterpre@protonmail.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-04 16:56:35 -03:00
Amr Bashir
d4cac20292 fix(bundler): fix japanese lang code, closes #5342 (#5346) 2022-10-04 13:25:58 -03:00
Amr Bashir
095b18620b fix(cli.js): fix invoking cli from a node shim, closes #5343 (#5345) 2022-10-04 13:25:02 -03:00
Amr Bashir
a4aec9f0a8 feat(cli): expose TAURI_TARGET_TRIPLE to before*Commands, closes #5091 (#5101)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-03 16:11:06 -03:00
Kasper
39bf895b73 feat(macOS): Add application show and hide methods (#3689)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-03 14:49:59 -03:00
Lucas Fernandes Nogueira
7c0fa1f3f9 fix(bundler): clear env before calling wix, closes #4791 (#4819) 2022-10-03 14:43:34 -03:00
Eric Hagman
a6c94119d8 feat(core): expose user_agent to window config (#5317)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-10-02 10:37:53 -03:00
Kasper
321f3fed19 feat(macos): title_bar_style and hidden_title window options, closes #2663 (#3965)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-30 17:15:45 -03:00
Amr Bashir
39443b4350 fix(core): set correct mimetype for asset protocol streams, closes #5203 (#5210)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-30 15:38:20 -03:00
Amr Bashir
6f41a27124 fix(api.js): fix Monitor initialization, closes #4672 (#5314)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-30 14:39:51 -03:00
Lucas Nogueira
1377f8e13b perf(ci): do not run Rust jobs when the tauri script changes 2022-09-30 14:34:20 -03:00
Tomáš Vojtášek
8f1ace7795 feat: expose set_title for MacOS tray (#5182)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-30 14:08:11 -03:00
Amr Bashir
63011ca84e fix(macos): fix regression in with_menu_on_left_click, closes #5220 (#5235)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
2022-09-30 13:16:33 -03:00
Amr Bashir
73d9cd51b2 chore: cleanup readme (#5312) 2022-09-30 13:06:24 -03:00
Lucas Fernandes Nogueira
a06dc69931 fix(core): canonicalize resource dir to fix scope check, closes #5196 (#5218) 2022-09-29 16:33:48 -03:00
Rafael Keramidas
ca3cd8b3d1 fix(api): fs/exists return type previously set to void when it should be boolean (#5252) 2022-09-29 15:55:45 -03:00
Lucas Nogueira
0d3a97ec7b chore(cli): update to tokio 1.21.2 2022-09-29 10:35:44 -03:00
renovate[bot]
04201d43b1 chore(deps) Update Rust crate notify to v5, clap to v4 (#5109)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-29 10:34:50 -03:00
renovate[bot]
d9d430e5a5 chore(deps) Update Tauri API Definitions (#5299)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-29 09:28:29 -03:00
Caesar Schinas
5d89905e39 feat(api): add app-specific directory APIs, closes #5263 (#5272)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-28 19:34:09 -03:00
jabza
eedfa5e618 feat(core): Expose "ignore_cursor_events" to Tauri and API (#5032)
Co-authored-by: Thomas Kilsby <>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-28 16:55:35 -03:00
Lucas Fernandes Nogueira
7d9aa3987e feat: bump MSRV to 1.59 (#5296) 2022-09-28 14:33:35 -03:00
Lucas Fernandes Nogueira
1dd722c4a7 feat(command): add rename_all attribute, closes #4898 (#4903) 2022-09-28 13:52:18 -03:00
renovate[bot]
f98e1b128c chore(deps) Update Tauri API Definitions (#5249)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-28 13:48:06 -03:00
renovate[bot]
82e915c487 chore(deps) Update Rust crate env_logger to 0.9.1 (#5248)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-28 13:47:50 -03:00
Amr Bashir
628285c1cf feat(bundler): add publisher field, closes #5273 (#5283)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-28 13:42:26 -03:00
Amr Bashir
54c337e06f feat(cli): hotreload support for frontend static files, closes #2173 (#5256)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-28 13:16:58 -03:00
renovate[bot]
e8e2853830 chore(deps) Update Rust crate cargo_toml to 0.12 (#5290)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-28 11:44:40 -03:00
Amr Bashir
b9316a64ea fix(cli): validate productName in config, closes #5233 (#5262) 2022-09-28 11:44:14 -03:00
Amr Bashir
ae65951bc4 fix(core): fix deadlock in on_menu_event, closes #5254 (#5257) 2022-09-28 11:36:58 -03:00
Caesar Schinas
08a44490d7 docs: correct path for desktop_dir, closes #5267 (#5268) 2022-09-28 11:36:15 -03:00
renovate[bot]
3baa6ac9b8 chore(deps) Update Rust crate image to 0.24.4 (#5289)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-28 11:11:44 -03:00
Lucas Fernandes Nogueira
aec5537de0 fix(codegen): serialize template tags, closes #4410 (#5247) 2022-09-28 11:10:56 -03:00
Caesar Schinas
4c5a30370c fix(examples): use a less common port in API example, closes #5276 (#5277) 2022-09-28 11:10:12 -03:00
Lucas Nogueira
013fb354d9 docs(path): fix log directory documentation 2022-09-23 20:06:52 -03:00
Amr Bashir
adba73a9ff ci: migrate to the org-level token 2022-09-23 18:00:13 +02:00
Amr Bashir
1d7171a1ec chore: add prettierignore and fmt the repo (#5192)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-18 09:16:35 -03:00
renovate[bot]
ecb489a77c chore(deps) Update Tauri API Definitions (#5184)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-18 09:16:19 -03:00
renovate[bot]
0563fe3d46 chore(deps) Update Tauri Core (#5186)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-18 09:15:33 -03:00
Lucas Fernandes Nogueira
18b17a954c chore(cli): remove unused dependencies (#5219) 2022-09-18 09:07:06 -03:00
Fabian-Lars
60c15750c1 ci: Don't trigger docs update when no packages were published (#5221) 2022-09-18 09:06:50 -03:00
Lucas Nogueira
ee9706d8ae chore: update tauri CHANGELOG.md to include 1.0.6 2022-09-16 18:08:58 -03:00
Lucas Fernandes Nogueira
7950fcb9a8 fix(ci): add inputs to publish-cli-js (#5217) 2022-09-16 16:16:29 -03:00
github-actions[bot]
e4292ce7be apply version updates (#5216) 2022-09-16 14:30:18 -03:00
Amr Bashir
db26aaf2b4 fix: fix wrong cli metadata (#5214)
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-09-16 13:54:09 -03:00
Lucas Nogueira
c8445a69ca chore: add cursor allowlist checks in to_features function 2022-09-16 13:33:46 -03:00
Fabian-Lars
c764408da7 fix: Add missing allowlist config for cursor apis, closes #5207 (#5211) 2022-09-16 13:26:27 -03:00
Lucas Nogueira
2954f6d252 fix(cli): wrong metadata 2022-09-15 14:51:42 -03:00
Lucas Nogueira
0967da262e fix(cli.js): revert jest update 2022-09-15 14:36:31 -03:00
Lucas Nogueira
e939e6d9e4 fix(ci): adjust publish-cli-js workflow to only install prod deps 2022-09-15 14:14:59 -03:00
Lucas Nogueira
3ceed62686 chore: add exists function to the changelog 2022-09-15 12:35:05 -03:00
github-actions[bot]
83a6dab7b2 Revert "Apply Version Updates From Current Changes (#5198)"
This reverts commit 9190206387.
2022-09-15 12:34:10 -03:00
github-actions[bot]
9190206387 Apply Version Updates From Current Changes (#5198)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-09-15 12:32:51 -03:00
github-actions[bot]
fbdd0a7ca9 Apply Version Updates From Current Changes (#4753)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-09-15 12:03:45 -03:00
Fabian-Lars
3c62dbc902 feat(api): Add exists function to the fs module. (#5060)
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-09-15 11:28:52 -03:00
Amr Bashir
255ebcb7ef refactor: upload schema to tauri-build release instead of cli (#5197) 2022-09-15 11:27:38 -03:00
Lucas Fernandes Nogueira
447370fa50 chore(deps): update to wry 0.21 (#5181) 2022-09-13 10:56:54 -03:00
Yuyi Wang
9b793eeb68 Remove futures & futures-lite and use futures-util directily. (#5172) 2022-09-12 19:24:57 -03:00
Amr Bashir
5e74aefd4a chore(api.js): add @since tag where appropriate (#5169) 2022-09-12 16:45:57 -03:00
Lucas Nogueira
6b737315b0 fix(api): revert broken @rollup/plugin-node-resolve 2022-09-12 16:41:33 -03:00
renovate[bot]
1c98751da4 chore(deps) Update Rust crate url to 2.3 (#5157)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-10 09:45:32 -03:00
Fabian-Lars
b779e52ba7 docs: Add link to usage example to State docs (#5165) 2022-09-08 15:27:31 -03:00
Fabian-Lars
3fdd287704 fix(cli): fix wrong filename for 256px png icon (#5164) 2022-09-08 15:14:22 -03:00
Amr Bashir
f4121c128e fix(endpoints/fs/readDir): don't read symlinks that are not allowed b… (#5123) 2022-09-08 10:59:05 -03:00
renovate[bot]
5b0b8ef83f chore(deps) Update dependency @rollup/plugin-node-resolve to v14 (#5156)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 12:05:19 -03:00
Lucas Fernandes Nogueira
e9412fb983 chore(deps): use less specific version for tokio and once_cell (#5158) 2022-09-07 11:55:21 -03:00
renovate[bot]
83eefccefd chore(deps) Update Rust crate once_cell to 1.14 (#5152)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 10:46:15 -03:00
renovate[bot]
cdb5c8e068 chore(deps) Update dependency jest to v29.0.2 (#5151)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 10:45:23 -03:00
renovate[bot]
824aec9e40 chore(deps) Update Tauri API Definitions (#5153)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 10:45:04 -03:00
renovate[bot]
1d55a5fe1f chore(deps) Update Tauri Core (#5154)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 10:44:54 -03:00
Lucas Nogueira
bf5a9ab9e6 chore(cli): update lockfile 2022-09-04 13:49:13 -03:00
Fabian-Lars
12e9d811e6 feat(cli): Add icon command (tauricon) (#4992)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-03 14:37:41 -03:00
Fabian-Lars
0837454b00 fix(api): Remove unused @ts-expect-error (#5131) 2022-09-03 11:56:15 -03:00
Amr Bashir
e6d9b670b0 refactor: remove unneeded focus code (#5065)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-03 11:07:18 -03:00
renovate[bot]
8183153a86 chore(deps) Update dependency eslint-config-standard-with-typescript to v22 (#4603)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-03 09:38:47 -03:00
Lucas Nogueira
5790218fb6 chore: update core/tauri/scripts/bundle.js 2022-09-03 01:05:48 -03:00
Rafael Keramidas
a9381f3b40 refactor(core/api): use constants for events in core, add new enum for core events in api (#5100) 2022-09-03 01:04:55 -03:00
Josh Soref
8fd79b8fc0 Spelling (#4880)
Co-authored-by: Lorenzo Lewis <lorenzo_lewis@icloud.com>
Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
2022-09-03 01:03:02 -03:00
Akirami
14f337d8ad docs(updater): fix configure missing required key (#5058)
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-09-03 00:47:33 -03:00
renovate[bot]
4cd8507ea0 chore(deps) Update dependency jest to v29 (#5110)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-09-02 20:57:46 -03:00
dependabot[bot]
89af335156 chore(deps-dev): bump vite from 2.9.12 to 2.9.13 in /examples/api (#5103)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-09-02 20:57:37 -03:00
renovate[bot]
bca796be2f chore(deps) Update Tauri API Definitions (#5108)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-02 20:57:17 -03:00
Lucas Nogueira
0668dd4220 fix(tauri-runtime-wry): ignore events on unknown windows 2022-08-29 14:23:11 -03:00
Lucas Fernandes Nogueira
b9fb53ed73 docs(cli): clarify passing arguments to the application on tauri dev closes #5079 (#5086) 2022-08-29 09:31:21 -03:00
Lucas Nogueira
ef8ca7b363 fix(ci): actually use MSRV toolchain 2022-08-28 23:04:19 -03:00
Lucas Nogueira
d88de30076 fix(ci): checkout repo in udeps.yml 2022-08-28 17:52:40 -03:00
Lucas Nogueira
1629c5ad27 fix(ci): set target on test-core.yml 2022-08-28 17:50:05 -03:00
Lucas Fernandes Nogueira
8a380fc4e3 feat(ci): test core on MSRV (#5077) 2022-08-28 16:26:32 -03:00
Lucas Fernandes Nogueira
2901145c49 chore: update license headers (#5067) 2022-08-28 15:13:21 -03:00
Olivier Lemasle
38449bc57d chore: update links from tauri.studio to tauri.app (#5069) 2022-08-27 16:18:16 -03:00
Lucas Fernandes Nogueira
8f6ab87fb4 feat(cli): package license files (#5066) 2022-08-27 10:10:05 -03:00
renovate[bot]
cf6f0c511b chore(deps) Update Tauri API Definitions to v5.35.1 (#5034)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-26 09:24:34 -03:00
Akirami
bd51cddd6f docs(updater): fix server missing required key (#5050) 2022-08-26 09:23:59 -03:00
Jonas Kruckenberg
4fa968dc0e fix(api): add async mockIPC() handler signature (#5056) 2022-08-26 13:12:24 +02:00
Amr Bashir
e9f1e627f8 feat: upload tauri config schema to cli github release (#5038) 2022-08-25 10:09:46 -03:00
renovate[bot]
ab5a307bc1 chore(deps) Update Tauri API Definitions (#5018)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-24 12:40:50 -03:00
renovate[bot]
238fdc9563 chore(deps) Update Tauri JS CLI (#5019)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-24 12:40:40 -03:00
Mateo Gallardo
d35cc77831 docs(clipboard): Added allowlist section to the Clipboard module (#5014) 2022-08-23 13:54:32 -03:00
Amr Bashir
169682219a covector: reduce cargo audit/publish noise in release notes (#5011) 2022-08-23 12:04:28 -03:00
Lucas Nogueira
4ac8006efd feat(tauri-build): rerun-if-changed Info.plist 2022-08-23 10:47:41 -03:00
Dave Lage
02a2ec52f1 fix: Grammar in signer generate (#5004) 2022-08-22 18:12:41 -03:00
Lucas Nogueira
28a1ec34a4 fix(tauri-runtime-wry): only emit global tray event if tray was found 2022-08-21 17:53:09 -03:00
Lucas Fernandes Nogueira
436f3d8d66 feat(cli): load Cargo configuration to check default build target (#4990) 2022-08-21 17:48:28 -03:00
Lucas Nogueira
fa44c44379 fix(tauri-runtime-wry): trigger global tray event listeners 2022-08-21 17:44:13 -03:00
Fabian-Lars
fea70effad refactor(cli): Use cargo metadata to detect the workspace root and target directory, closes #4632, #4928. (#4932) 2022-08-21 10:42:26 -03:00
renovate[bot]
e16b366174 chore(deps) Update Tauri API Definitions (#4960)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-20 10:25:34 -03:00
dependabot[bot]
9ac6135c2a chore(deps): bump undici from 5.8.0 to 5.9.1 in /examples/api (#4976)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-20 10:25:07 -03:00
renovate[bot]
8bf0f66c06 chore(deps) Update dependency @napi-rs/cli to v2.11.4 (#4961)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-20 10:24:36 -03:00
Angelo Huang
9bbc30590b chore: add missing closing tag in a comment (#4958) 2022-08-17 00:22:24 +02:00
Lucas Fernandes Nogueira
c53d9ea1b3 refactor(cli): prepare for mobile implementation (#4952) 2022-08-16 10:13:14 -03:00
Lucas Nogueira
e4d5022077 perf(ci): adjust test-core.yml paths 2022-08-16 10:06:01 -03:00
Amr Bashir
725236cea0 refactor: enhance api demo app mobile experience (#4929)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-08-14 18:39:35 -03:00
Lucas Nogueira
d2572050be chore(examples): remove mobile code from API example 2022-08-14 17:54:26 -03:00
Amr Bashir
20a7036ba5 Revert "fix(core): avoid conflict with user-defined cmd arg in invoke, closes #4875 (#4892)" (#4924)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-08-12 20:34:17 -03:00
Lucas Fernandes Nogueira
6ba99689aa feat(codegen): use TARGET environment variable if set (#4921) 2022-08-12 19:11:33 -03:00
Amr Bashir
8958e9fdb5 docs: fix bullet point alignment in js api (#4922) 2022-08-12 19:08:18 -03:00
Lucas Nogueira
6119f4582e chore(examples): update API dist 2022-08-11 09:55:49 -03:00
Lucas Fernandes Nogueira
ff8fd7619a fix(tauri-build): rerun if assets or icons change (#4910) 2022-08-10 16:32:52 -03:00
Lucas Nogueira
0e925fd8f0 feat(examples): prepare API example for mobile 2022-08-10 16:30:07 -03:00
Lucas Fernandes Nogueira
64546cb9cc refactor: use RefCell instead of Mutex for windows map, closes #4870 (#4909) 2022-08-10 15:36:01 -03:00
Lucas Nogueira
96885b6e5a chore(cli): remove unused encode_unicode dependency 2022-08-10 08:46:01 -03:00
renovate[bot]
9e48da502f chore(deps) Update Rust crate attohttpc to 0.22 (#4906)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-10 08:39:11 -03:00
renovate[bot]
3951aac930 chore(deps) Update Tauri JS CLI (#4905)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-10 08:38:55 -03:00
renovate[bot]
e86c9df9f0 chore(deps) Update Tauri API Definitions to v22.0.2 (#4904)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-10 08:38:39 -03:00
Lucas Fernandes Nogueira
4d063ae9ee feat(core): create system tray at runtime, closes #2278 (#4862) 2022-08-09 14:43:51 -03:00
Lucas Nogueira
fd992c547e fix(core): before_bundle_command kebab-case alias 2022-08-09 14:17:11 -03:00
Lucas Nogueira
e602432ef6 chore(ci): run udeps on push to dev 2022-08-09 14:00:57 -03:00
Lucas Fernandes Nogueira
698a31aa79 feat(ci): improve udeps check performance (#4900) 2022-08-09 14:00:12 -03:00
Amr Bashir
57ab9847eb feat(cli): add beforeBundleCommand, closes #4879 (#4893)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-08-09 12:54:44 -03:00
Lorenzo Lewis
4c24d10ff3 Update path.ts (#4895) 2022-08-09 11:36:50 -03:00
Amr Bashir
5813f08386 ci: publish cli.js *.node modules to the existing cli.js release (#4883) 2022-08-09 11:36:21 -03:00
Lucas Nogueira
08584fc657 fix(codegen): adapt for iOS build 2022-08-09 09:16:39 -03:00
Amr Bashir
4e8b122df6 refactor(cli/core/bundler): use absolute path for msiexec and powershell (#4884) 2022-08-08 18:59:59 -03:00
Lucas Fernandes Nogueira
ed581950ea fix(tauri-build): use ::tauri as root for the CodegenContext (#4894) 2022-08-08 16:33:48 -03:00
Brian Li
f957cbb56c fix(codegen): write output file when contents change (#4889) 2022-08-08 16:07:05 -03:00
Amr Bashir
5109c27501 fix(core): avoid conflict with user-defined cmd arg in invoke, closes #4875 (#4892) 2022-08-08 15:51:56 -03:00
Lucas Fernandes Nogueira
d88b9de7aa feat(core): add fips_compliant wix config option, closes #4541 (#4843) 2022-08-04 14:58:26 -03:00
Lucas Nogueira
1caf485fce perf(ci): do not run artifacts-updater on PRs except on example update 2022-08-04 14:56:02 -03:00
Kilian Gosewisch
3b44b01412 Fix typo (#4854) 2022-08-04 14:05:35 -03:00
renovate[bot]
49f9334e19 chore(deps) Update Tauri API Definitions (#4844)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-04 14:05:17 -03:00
renovate[bot]
3be8c238cc chore(deps) Update Rust crate os_info to 3.5 (#4845)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-04 14:05:01 -03:00
renovate[bot]
e59407f2bd chore(deps) Update Rust crate serde_json to 1.0.83 (#4855)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-04 14:04:46 -03:00
Lucas Fernandes Nogueira
58fc1f2150 fix(updater): blank icon after update on macOS, closes #4613 (#4861) 2022-08-04 14:04:37 -03:00
Paul Soporan
f7d2dfc7a6 chore: add libc field to node packages (#4856) 2022-08-04 01:04:24 -03:00
Lucas Fernandes Nogueira
964926ff85 feat(core): enhance SystemTray::with_icon (#4849) 2022-08-03 11:39:16 -03:00
Lucas Fernandes Nogueira
52f0c8bb83 feat(core): improve tray icon read error messages (#4850) 2022-08-03 11:38:43 -03:00
Lucas Fernandes Nogueira
fa23310f23 fix(cli): set MACOSX_DEPLOYMENT_TARGET env var, closes #4704 (#4842) 2022-08-02 19:54:31 -03:00
Lucas Fernandes Nogueira
dcd506676c fix(core): parse inner CLI subcommands, closes #4688 (#4841) 2022-08-02 19:49:01 -03:00
Lucas Fernandes Nogueira
d6f7d3cfe8 Add cwd option to before commands, add wait option to dev #4740 #3551 (#4834) 2022-08-02 18:54:50 -03:00
Lucas Fernandes Nogueira
90d5929fea feat(cli.rs): add support to cargo-binstall, closes #4651 (#4817) 2022-08-02 18:54:40 -03:00
Lucas Fernandes Nogueira
f21cbecdeb feat(core): implement theme APIs for Linux (#4808) 2022-08-02 18:54:14 -03:00
Lucas Fernandes Nogueira
331f346002 feat(core): add option to use vendored openssl, closes #4470 (#4809) 2022-08-02 18:54:05 -03:00
Lucas Fernandes Nogueira
e6012b88af docs(core): enhance initialization_script documentation, ref #4831 (#4832) 2022-08-02 18:53:55 -03:00
Lucas Fernandes Nogueira
9f1d34c288 feat: implement From<Command> for std::process::Command, closes #4673 (#4836) 2022-08-02 18:53:48 -03:00
Lucas Fernandes Nogueira
5c5c42edb6 feat(build): use modern dialog styles on Windows, closes #4709 (#4840) 2022-08-02 18:53:34 -03:00
Lucas Nogueira
75d3d677ae chore(examples): update window-vibrancy and window-shadows 2022-08-02 18:32:15 -03:00
Lucas Fernandes Nogueira
ae83d008f9 feat: add support to TOML config file Tauri.toml, closes #4806 (#4813) 2022-08-02 14:12:26 -03:00
Lucas Fernandes Nogueira
c04d0340e2 feat(core): prepare build for mobile targets (#4830)
Co-authored-by: Yu-Wei Wu <wusyong9104@gmail.com>
2022-08-02 11:25:28 -03:00
Lucas Fernandes Nogueira
5cc1fd0f7b feat(tauri-build): validate sidecar name, closes #4780 closes #4823 (#4814) 2022-08-02 10:37:16 -03:00
Lucas Fernandes Nogueira
d576e8ae72 feat(core): do not follow redirects if max_redirects is 0 closes #4795 (#4812) 2022-07-31 20:00:48 -03:00
Lucas Fernandes Nogueira
ba5560b2a1 feat(core): implement max_redirections for attohttpc, ref #4795 (#4811) 2022-07-31 19:12:34 -03:00
Amr Bashir
0ad9531d79 chore(deps): update tao to 0.13, wry to 0.20, rfd to 0.10, raw-window-handle to 0.5 (#4804) 2022-07-31 10:41:49 -03:00
Lucas Fernandes Nogueira
0983d7ce7f feat(cli): add --no-watch argument to the dev command, closes #4617 (#4793) 2022-07-29 18:34:43 -03:00
Brian Li
024620529e fix(bundler): cache appimage bundle tools (#4790)
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-07-29 18:34:12 -03:00
Lucas Fernandes Nogueira
596fa08d48 feat(cli): automatically use .taurignore, ref #4617 (#4623) 2022-07-28 18:58:38 -03:00
renovate[bot]
77e48ab7db chore(deps) Update dependency rollup to v2.77.2 (#4781)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-27 18:24:08 -03:00
horochx
d8cf9f9fcd Command support for specified character encoding, closes #4644 (#4772)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-27 18:23:27 -03:00
Lucas Fernandes Nogueira
433dafa01a feat: add docker images for cross (#4702) 2022-07-27 14:58:43 -03:00
renovate[bot]
810b3be080 chore(deps) Update Tauri API Definitions (#4776)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-27 14:54:08 -03:00
renovate[bot]
77f4a7173b chore(deps) Update dependency @napi-rs/cli to v2.10.3 (#4778)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-27 14:53:49 -03:00
@RubenKelevra
08deda5f99 Fix: issue template rendering poorly 'platform and version' response (#4648)
* Issue template change rendering of 'platform and version'

The previously used 'shell' is for shellscript, not for console output with commands. 'console' does render much more nicely text output and commands.

* remove `tauri info` render

Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-26 17:31:45 -03:00
Danil Karpenko
aa9f1243e6 Improved EventEmitter for tauri api shell (#4697)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-25 19:35:35 -03:00
Lucas Nogueira
f7ea867d31 fix(core): clear env args on restart test 2022-07-25 19:17:32 -03:00
Lucas Nogueira
816f474c3e fix(cli): only try to read updater private key if we've bundled it 2022-07-25 14:04:52 -03:00
Lucas Fernandes Nogueira
47fab6809a fix(cli): dev watcher incorrectly killing process on multiple file write (#4684) 2022-07-25 13:51:04 -03:00
renovate[bot]
e903dfe762 chore(deps) Update Tauri API Definitions (#4660)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-25 12:46:50 -03:00
renovate[bot]
b47d8c88c5 chore(deps) Update Rust crate ureq to 2.5 (#4661)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-25 12:46:19 -03:00
renovate[bot]
9b7caab672 chore(deps) Update dependency jest to v28.1.3 (#4666)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-25 12:46:08 -03:00
Lorenzo Lewis
2adef93faf Update readme badges (#4696) 2022-07-25 12:03:18 -03:00
Jonas Kruckenberg
c7fec3e1ff fix typo in state.rs (#4699) 2022-07-25 11:54:10 -03:00
renovate[bot]
fd4c851ee9 chore(deps) Update Rust crate image to 0.24.3 (#4716)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-25 11:05:45 -03:00
renovate[bot]
d2b6351157 chore(deps) Update Rust crate serde_with to v2 (#4719)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-25 11:01:20 -03:00
dependabot[bot]
c2c1e6f081 chore(deps): bump terser from 5.7.0 to 5.14.2 in /tooling/api (#4718)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-25 11:00:43 -03:00
dependabot[bot]
38604a111e chore(deps): bump undici from 5.5.1 to 5.8.0 in /examples/api (#4731)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-25 11:00:02 -03:00
dependabot[bot]
5785aeb806 chore(deps-dev): bump svelte from 3.48.0 to 3.49.0 in /examples/api (#4686)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-25 10:59:54 -03:00
Lucas Fernandes Nogueira
6218c31e17 fix(core): retain command line arguments on restart, closes #4760 (#4763) 2022-07-25 10:59:24 -03:00
Amr Bashir
6d4945c9f0 feat(cli): prompt for before*Command, closes #4691 (#4721)
* feat(cli): prompt for before*Command, closes #4691

* fix default command

* add allow_empty argument

Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-25 10:59:08 -03:00
Lucas Fernandes Nogueira
b2a8930b3c feat(cli): validate updater private key when signing (#4754) 2022-07-25 10:58:25 -03:00
Axel Lindeberg
b48962ed15 fix(cli): don't warn on first dev server connection attempt (#4751)
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-07-24 09:41:37 -03:00
shniubobo
accbc5e880 fix(codegen): fix relative paths in version field of tauri.config.json, closes #4723 (#4725) 2022-07-24 09:41:14 -03:00
github-actions[bot]
679abc6a9a Apply Version Updates From Current Changes (#4701)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-07-22 12:08:38 -03:00
Lucas Fernandes Nogueira
9a8f8fc815 Revert "feat(updater): use full path to msiexec" (#4739) 2022-07-22 12:07:15 -03:00
Lucas Fernandes Nogueira
f116ee6a12 feat(updater): use full path to msiexec (#4738) 2022-07-22 11:59:57 -03:00
Lucas Fernandes Nogueira
9af43134e1 fix(updater): escape MSI path (#4737) 2022-07-22 11:23:43 -03:00
Lucas Fernandes Nogueira
635f23b88a fix(bundler): correctly set debian architecture for aarch64 (#4700) 2022-07-17 09:19:40 -03:00
github-actions[bot]
b1d53426d1 Apply Version Updates From Current Changes (#4650)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-07-14 18:36:35 -03:00
Lucas Nogueira
89cb252640 fix(bundler): pin linuxdeploy version 2022-07-14 15:12:57 -03:00
Lucas Fernandes Nogueira
597c98203c feat(bundler): use known Id for the sidecar files on WiX, ref #4546 (#4658) 2022-07-12 16:55:37 -03:00
Lucas Fernandes Nogueira
261d1bc9d4 feat(bundler): load WiX extensions used on fragments, closes #4546 (#4656) 2022-07-12 14:08:08 -03:00
Lucas Fernandes Nogueira
ac72800fb6 fix(macros): strip r# from command arguments, closes #4654 (#4657) 2022-07-12 14:07:51 -03:00
Lucas Fernandes Nogueira
c635a0dad4 refactor(cli): do not capture and force colors of cargo build output (#4627) 2022-07-12 09:49:23 -03:00
Lucas Fernandes Nogueira
3b4ed970e6 feat(codegen): validate __TAURI_ISOLATION_HOOK__ is referenced (#4631) 2022-07-11 16:41:34 -07:00
Lucas Nogueira
d5e6f7fa5c chore(examples): update sidecar deps, closes #4621 2022-07-11 16:21:07 -03:00
Vinícius Miguel
bc370e3268 feat: reduce the amount of heck-related allocations (#4634)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-11 16:07:39 -03:00
Lucas Nogueira
d3e19e3420 fix(macros): items_after_statements Clippy warning, closes #4639 2022-07-11 16:11:15 -03:00
Lorenzo Lewis
47666c4a0b Fix/docs qol improvements (#4641) 2022-07-11 10:14:31 -03:00
Lucas Nogueira
95abf48e21 docs(core): add supported macOS version on devtools APIs, closes #4612 2022-07-07 15:02:38 -03:00
github-actions[bot]
7bbf167c1c Apply Version Updates From Current Changes (#4560)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-07-06 14:32:55 -03:00
renovate[bot]
a30f95f76e chore(deps) Update Tauri JS CLI (#4608)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-06 14:28:37 -03:00
Lucas Nogueira
6fb49fd19b fix(cli.js): add timeout to manifest watcher to prevent deadlock 2022-07-06 12:45:34 -03:00
Lucas Fernandes Nogueira
9170c92070 feat(core): improve config deserialization error messages (#4607) 2022-07-06 10:33:45 -03:00
Lucas Fernandes Nogueira
d5e910ebcc chore(api): remove type-fest (#4605) 2022-07-06 10:07:46 -03:00
Lucas Fernandes Nogueira
fa028ebf3c refactor: do not pass entire config from CLI to core, send patch instead (#4598) 2022-07-06 09:29:26 -03:00
Lucas Fernandes Nogueira
2e61abaa9a feat(cli): allow dynamic link vcruntime, closes #4565 (#4601) 2022-07-06 09:29:03 -03:00
renovate[bot]
038c2cc8b1 chore(deps) Update Tauri API Definitions (#4599)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-06 09:24:31 -03:00
renovate[bot]
326f87df26 chore(deps) Update Rust crate regex to 1.6.0 (#4600)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-06 09:24:14 -03:00
renovate[bot]
adea3f1e81 chore(deps) Update Tauri CLI (#4602)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-07-06 09:23:59 -03:00
Lucas Fernandes Nogueira
8e3e7fc646 feat(cli): improve bundle identifier validation, closes #4589 (#4596) 2022-07-05 19:57:31 -03:00
Lucas Fernandes Nogueira
92aca55a6f feat(api): add support to ArrayBuffer (#4579) 2022-07-05 17:40:36 -03:00
Lucas Fernandes Nogueira
b02fc90f45 feat(api): add abstractions to updater and window event listeners (#4569) 2022-07-05 16:57:53 -03:00
Lucas Fernandes Nogueira
e29fff2566 fix(updater): do not run in dialog mode on .deb, closes #4573 (#4577) 2022-07-05 10:22:47 -03:00
Lucas Fernandes Nogueira
64416100c6 refactor(cli): reuse Rust build logic for dev and build commands (#4578) 2022-07-05 10:21:20 -03:00
Lucas Fernandes Nogueira
f8a3becb28 feat(core): add option to disable tray menu on left click, closes #4584 (#4587)
* feat(core): add option to disable tray menu on left click, closes #4584

* Update .changes/menu-on-left-click.md [skip ci]

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

Co-authored-by: Amr Bashir <amr.bashir2015@gmail.com>
2022-07-05 09:05:01 -03:00
Lucas Fernandes Nogueira
f7c59ecfc8 fix(bundler): support macOS 10.13.6+ on notarization, closes #4549 (#4593) 2022-07-05 09:04:40 -03:00
Lucas Fernandes Nogueira
b8cd2a7993 feat(api): call toString() on dialog title and message, closes #4583 (#4588) 2022-07-04 22:30:06 -03:00
Amr Bashir
a1d569bbc9 fix(core): disable tao's drag-n-drop based on fileDropEnabled, closes #4580 (#4592)
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-07-04 22:29:54 -03:00
Jonas Kruckenberg
c02337be29 chore: auto assign needs triage label (#4586) 2022-07-04 10:28:34 -03:00
Lucas Nogueira
f65eb4f84d fix(cli.js): revert run command to be nonblocking 2022-07-04 09:09:00 -03:00
Amr Bashir
3fbaee454d refactor(examples/api): new look (#4465)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-03 22:15:23 -03:00
Lucas Fernandes Nogueira
7e3ac8475c fix(core): command stack overflow on Windows, closes #4548 (#4562) 2022-07-03 21:37:49 -03:00
Lucas Fernandes Nogueira
23d3d847d1 fix(bundler): ensure RequestUUID and Status parser adds a \n, closes #4549 (#4559) 2022-07-03 21:36:33 -03:00
Didrik Nordström
34879f7344 fix: allow graceful shutdown of sidecar commands on exit (#4561)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-03 21:33:08 -03:00
Lucas Fernandes Nogueira
e046e04c63 chore(ci): adjust issue labels (#4564) 2022-07-03 20:50:37 -03:00
Amr Bashir
9105588373 feat: add implicit default menu for macOS only, closes #4551 (#4570)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-03 20:26:32 -03:00
Lucas Fernandes Nogueira
0fa745344e feat(updater): relaunch on Windows, closes #4220 (#4568) 2022-07-03 19:48:23 -03:00
Lucas Fernandes Nogueira
dbb8c87b96 feat(cli): watch Cargo workspaces in the dev command, closes #4222 (#4572) 2022-07-03 19:48:05 -03:00
Lucas Nogueira
edb9ab2069 docs(core): fix link to webview2 controller, closes #4576 2022-07-03 18:28:42 -03:00
Robin van Boven
8dd03e69b0 fix(bundler): Build AppImages inside the target folder (#4521)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-07-03 18:24:03 -03:00
Lucas Fernandes Nogueira
573b4c0b3c refactor(cli): move watch and manifest logic to the Rust impl (#4571) 2022-07-02 15:05:18 -03:00
Lucas Fernandes Nogueira
d4cdf80781 feat(macros): hide command macro from docs, closes #4550 (#4556) 2022-07-01 18:07:01 -03:00
github-actions[bot]
35b53784ee Apply Version Updates From Current Changes (#4545)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-06-30 18:45:58 -03:00
Lucas Nogueira
60adaf4a97 Revert "feat(ci): readd integration tests on Windows"
This reverts commit 1316602346.
2022-06-30 18:12:03 -03:00
Lucas Fernandes Nogueira
3df6c8c645 feat(bundler): enable TLS 1.2 before downloading webview2 bootstrapper (#4543) 2022-06-30 18:07:11 -03:00
renovate[bot]
9217d88f94 chore(deps) Update Tauri API Definitions (#4523)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-30 17:52:43 -03:00
Lucas Nogueira
d0758e5fca chore(tauri-runtime-wry): remove commented out code 2022-06-30 10:49:10 -03:00
Lucas Fernandes Nogueira
63841c1060 fix(tauri-runtime-wry): do not send theme twice on macOS, closes #4532 (#4540) 2022-06-30 10:39:25 -03:00
Lucas Fernandes Nogueira
185b0e314e fix(tauri-runtime-wry): deadlock when window focus change, closes #4533 (#4539) 2022-06-30 10:39:10 -03:00
Jonas Kruckenberg
8e808fece9 fix(cli.rs): conflicts_with arg doesn't exist closes (#4538)
* fix: conflicts_with path doesn't exist

* add change file

Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-30 10:38:57 -03:00
Lucas Fernandes Nogueira
2e74d20e83 fix(core): check whether external url is local, ref #4449 (#4536) 2022-06-30 10:38:46 -03:00
Lucas Fernandes Nogueira
23a48007c0 fix(tauri-runtime-wry): deadlock on file drop, closes #4527 (#4535) 2022-06-30 10:38:21 -03:00
Lucas Fernandes Nogueira
bf764e83e0 feat(utils): expose windows_version function (#4534) 2022-06-30 10:38:01 -03:00
renovate[bot]
3125a5a383 chore(deps) Update Rust crate serde_json to 1.0.82 (#4522)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-30 08:48:58 -03:00
Lucas Nogueira
1b581747c5 docs(api): revert typedoc update 2022-06-29 16:53:41 -03:00
Lucas Nogueira
1316602346 feat(ci): readd integration tests on Windows 2022-06-29 16:29:08 -03:00
Lucas Nogueira
28c8171f47 Revert "chore(ci): disable integration tests temporarily"
This reverts commit 1a9b13330f.
2022-06-29 16:28:54 -03:00
Lucas Nogueira
1a9b13330f chore(ci): disable integration tests temporarily 2022-06-29 15:22:39 -03:00
github-actions[bot]
df5fd52a4c Apply Version Updates From Current Changes (#4382)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-06-29 14:34:20 -03:00
Lucas Fernandes Nogueira
5105b428c4 feat(cli): change app template to only set default menu on macOS (#4518) 2022-06-29 14:03:42 -03:00
Fabian-Lars
de645a32e9 fix(cli): Typo in beforeBuildCommand error message (#4516) 2022-06-29 09:38:03 -03:00
renovate[bot]
49e49f5bba chore(deps) Update dependency jest to v28.1.2 (#4515)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-29 09:07:21 -03:00
Lucas Nogueira
0257004be1 chore(deps): update lockfiles 2022-06-29 01:06:16 -03:00
renovate[bot]
be4831fdfb chore(deps) Update Tauri API Definitions (#4512)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-29 00:58:07 -03:00
Lucas Nogueira
3cf178654c fix(renovate): only enable cargo manager for tooling/cli
This disables updates for the templates - should be handled by the app/plugin instead
2022-06-29 00:11:53 -03:00
Lucas Nogueira
445e05d9bd chore(config): add link to doc page 2022-06-29 00:01:31 -03:00
Lucas Nogueira
eac56c32fe chore(cli): update lockfile 2022-06-28 23:52:18 -03:00
Robin van Boven
bf45ca1df6 fix(cli,bundler): prefer AppImage libraries with ABI version (#4505) 2022-06-28 23:45:36 -03:00
Robin van Boven
0e6edeb14f fix(cli): Don't add pkg-config to deb (#4508) 2022-06-28 23:44:14 -03:00
MentalGear
94e581b8d0 docs: fixed readdir example code (#4510) 2022-06-28 17:56:44 -03:00
Lucas Fernandes Nogueira
fd125f76d7 fix(updater): fallback if tmp is on different mount point, closes #4500 (#4504) 2022-06-28 12:20:59 -03:00
Lucas Fernandes Nogueira
f6edc6df29 chore(deps): update tao to 0.12, wry to 0.19, closes #3220 (#4502) 2022-06-28 10:05:09 -03:00
Lucas Fernandes Nogueira
57039fb216 fix(core): add windows 7 notification support (#4491) 2022-06-28 09:59:13 -03:00
Lucas Nogueira
1949aa89be chore: remove println 2022-06-28 09:50:47 -03:00
Lucas Fernandes Nogueira
643ae846d8 fix: fire window-specific event on Window emit_to/emit_all, closes #4493 (#4498) 2022-06-28 09:34:09 -03:00
Lucas Fernandes Nogueira
b857a00679 perf(ci): run CLI tests only when template changes and on dev push (#4487) 2022-06-27 12:46:49 -03:00
dswd
b0133083dd Fix appimage creation in container when host has appimagelauncher enabled (#4457)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-27 10:36:37 -03:00
Lucas Fernandes Nogueira
46196fe922 refactor(tauri-runtime-wry): move window and menu listeners to window (#4485) 2022-06-27 10:36:28 -03:00
Lucas Fernandes Nogueira
66ed165773 chore(ci): remove sync-prerelease script (#4486) 2022-06-27 10:36:14 -03:00
Lucas Fernandes Nogueira
e39e2999e0 refactor(tauri-runtime-wry): enhance plugin interface (#4476) 2022-06-27 09:57:00 -03:00
Lucas Fernandes Nogueira
094b3eb352 fix(cli): file name instead of path on updater sig comment, closes #4467 (#4484) 2022-06-27 09:56:37 -03:00
Fabian-Lars
68a09b3588 fix(docs): Fix typos in js path api docs. Extend rust path api docs. (#4482) 2022-06-27 08:41:00 -03:00
Lucas Fernandes Nogueira
956af4f30f feat(bundler): validate wix toolset files, ref #4474 (#4475) 2022-06-26 18:00:33 -03:00
Lucas Fernandes Nogueira
2ca762d207 feat(bundler): extend webview2 installation options, closes #2882 #2452 (#4466)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
2022-06-26 15:45:31 -03:00
Amr Bashir
3efbc67f74 feat: implement raw_window_handle on Linux (#4469)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-26 11:56:12 -03:00
Fabian-Lars
82eb6e79e8 fix(bundler): Fix appimage bundler crashing if path has spaces (#4471)
* fix(bundler): Fix appimage bundler crashing if path has spaces

* add changefile
2022-06-26 09:28:29 -03:00
Lucas Nogueira
23a049c593 chore: fix clippy warnings, remove license template
The license template has been removed from rustfmt nightly :(
2022-06-24 22:01:13 -03:00
Lucas Fernandes Nogueira
9d33d09341 fix(core): deadlock on plugin webview ready hook (#4462) 2022-06-24 15:34:07 -03:00
Lucas Fernandes Nogueira
13b8a2403d feat(cli): validate target argument (#4458) 2022-06-24 13:16:19 -03:00
Jiwon Choi
08a73acde8 fix(bundler): fix language code. closes #4437 (#4444)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-24 00:19:31 -03:00
Lucas Fernandes Nogueira
be4bb391a9 feat: add AppHandle::remove_plugin and plugin on_drop, closes #4361 (#4443) 2022-06-24 00:15:44 -03:00
renovate[bot]
4b5291d9d9 chore(deps) Update dependency prettier to v2.7.1 (#4436)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-24 00:10:40 -03:00
Lucas Fernandes Nogueira
b025b9f581 refactor(cli): set binary name on dev (#4447) 2022-06-23 22:09:37 -03:00
Lorenzo Lewis
d277881d7f fix: add supported OSs to readme, update status badges to stable (#4432)
Co-authored-by: Fabian-Lars <fabianlars@fabianlars.de>
2022-06-23 15:31:11 -03:00
Lucas Nogueira
95e77e591d docs(api): enhance theme api doc 2022-06-23 15:31:12 -03:00
renovate[bot]
d38e66aca2 chore(deps) Update Tauri API Definitions (#4442)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-06-22 09:49:01 -03:00
Lucas Fernandes Nogueira
6650e5d672 fix(cli): preserve Cargo manifest formatting when possible (#4431) 2022-06-22 00:14:46 -03:00
Lucas Fernandes Nogueira
672174b822 feat(bundler): validate version before bundling with WiX (#4429) 2022-06-22 00:14:39 -03:00
Lucas Fernandes Nogueira
e0e5f77243 feat(cli): improve cargo not found error message, closes #4428 (#4430) 2022-06-22 00:14:27 -03:00
Lucas Nogueira
38f5db6e6a feat(codegen): fill app metadata in development Info.plist 2022-06-21 20:36:49 -03:00
Lucas Fernandes Nogueira
2616ede410 perf(ci): optimize cargo package step, closes #3823 (#4427) 2022-06-21 15:21:47 -03:00
Lucas Fernandes Nogueira
77ef1cd849 docs(api): fix dialog filters usage, closes #4367 (#4424) 2022-06-21 14:37:53 -03:00
Cyandev
45981851e3 chore(lint): unused variable warnings for release builds (#4411)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-21 13:19:57 -03:00
Lucas Fernandes Nogueira
12f65219ea fix(cli): read lockfile from workspace on the info command, closes #4232 (#4423) 2022-06-21 13:19:36 -03:00
Brian Li
35dd51db68 fix(cli): add shebang for kill-children.sh, closes #4262 (#4416)
Co-authored-by: Lucas Fernandes Nogueira <lucas@tauri.studio>
2022-06-21 13:16:16 -03:00
Lucas Fernandes Nogueira
31c15cd2bd docs(config): enhance documentation for bundle targets, closes #3251 (#4418) 2022-06-21 13:13:56 -03:00
Lucas Nogueira
384dc8c9cf chore(cli): adjust default release tag in the plugin templates 2022-06-21 12:46:50 -03:00
Ngo Iok Ui (Wu Yu Wei)
538d35f462 Update CODEOWNERS (#4420) 2022-06-21 12:19:35 -03:00
Robin van Boven
aa0336d6c5 fix(bundler): ensure AppImage usr/lib is a dir (#4419)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-21 12:16:46 -03:00
Lucas Fernandes Nogueira
45076b3ede refactor(bundler): use the plist crate to create and merge Info.plist (#4412) 2022-06-21 10:00:12 -03:00
Lucas Fernandes Nogueira
079b1cc06e fix(core): properly get external URL origin, closes #4414 (#4417) 2022-06-21 09:29:03 -03:00
Lucas Nogueira
f1d998243a fix(core): regression on Size and Position serde 2022-06-21 09:19:15 -03:00
Lucas Nogueira
11ca206b2d docs(core): update MenuItem entries supported platforms, closes #3882 2022-06-20 20:13:45 -03:00
fehnomenal
83186dd897 Read extra ignore file for dev watcher, closes #4406 (#4409)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-20 09:49:19 -03:00
Lucas Nogueira
32f35196a3 docs(api): add example for tauri://close-requested event usage 2022-06-19 22:38:44 -03:00
Lucas Nogueira
09241f9aca chore(cli): remove unused template GH action 2022-06-19 20:40:01 -03:00
Lucas Nogueira
b8a64d01ba fix(cli): add prepublish scripts to the plugin templates 2022-06-19 15:54:55 -03:00
Lucas Nogueira
07f9079532 chore(cli): update plugin template tauri-apps/create-pull-request 2022-06-19 15:17:39 -03:00
Lucas Fernandes Nogueira
307c2ebfb6 feat(core): set macOS app icon in development (#4385) 2022-06-19 13:02:02 -03:00
Lucas Fernandes Nogueira
c7d13a1c60 feat(core): add missing methods to the dpi module (#4393)
* feat(core): add missing methods to the dpi module

* cleanup impl
2022-06-19 13:01:53 -03:00
Lucas Fernandes Nogueira
123f6e69f6 fix(tauri-runtime-wry): release windows lock immediately, closes #4390 (#4392) 2022-06-19 13:00:21 -03:00
Lucas Fernandes Nogueira
010530459e chore(cli): use unix path separator on $schema (#4384) 2022-06-19 12:48:48 -03:00
Lorenzo Lewis
1a2e141bad Update documentation link (#4405) 2022-06-19 12:35:33 -03:00
yutotnh
cbceb7d6cf fix: some typos (#4403)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-19 10:23:35 -03:00
Lucas Fernandes Nogueira
6d94ce4235 feat(core): theme is now implemented on macOS (#4380) 2022-06-17 14:08:35 -03:00
Lucas Fernandes Nogueira
7be997b974 feat(core): set macOS app bundle name in development (#4381) 2022-06-17 13:54:31 -03:00
Imad Bouziani
0674a80129 fix: assert config.bundle.identifier to be only alphanumeric, hyphens or dots. closes #4359 (#4363)
Co-authored-by: Lucas Nogueira <lucas@tauri.studio>
2022-06-17 11:26:14 -03:00
github-actions[bot]
8457cccab0 Apply Version Updates From Current Changes (#4369)
Co-authored-by: lucasfernog <lucasfernog@users.noreply.github.com>
2022-06-16 12:26:04 -03:00
Lucas Fernandes Nogueira
ea43cf52db fix(api): writeBinaryFile sends an empty contents with only one arg (#4368) 2022-06-16 11:56:13 -03:00
663 changed files with 38363 additions and 15016 deletions

2
.cargo/config Normal file
View File

@@ -0,0 +1,2 @@
[env]
__TAURI_WORKSPACE__ = "true"

View File

@@ -0,0 +1,5 @@
---
"tauri-bundler": patch
---
Add dylib support to `tauri.bundle.macOS.frameworks`.

View File

@@ -0,0 +1,5 @@
---
"api": minor
---
Added the `additionalBrowserArgs` option when creating a window.

View File

@@ -0,0 +1,5 @@
---
"tauri-utils": minor
---
Added the `additional_browser_args` option to the window configuration.

View File

@@ -0,0 +1,7 @@
---
"tauri": minor
"tauri-runtime-wry": minor
"tauri-runtime": minor
---
Added the `additional_browser_args` option when creating a window.

6
.changes/cli-info.md Normal file
View File

@@ -0,0 +1,6 @@
---
"cli.rs": "patch"
---
Fix `tauri info` panicking when parsing crates version on a newly created project without a `Cargo.lock` file.

View File

@@ -5,10 +5,10 @@
"rust": {
"errorOnVersionRange": "^2.0.0-0",
"version": true,
"getPublishedVersion": "cargo search ${ pkgFile.pkg.package.name } --limit 1 | sed -nE \"s/^[^\\\"]*\\\"//; s/\\\".*//1p\"",
"getPublishedVersion": "node ../../.scripts/covector/package-latest-version.js cargo ${ pkgFile.pkg.package.name } ${ pkgFile.pkg.package.version }",
"prepublish": [
"sudo apt-get update",
"sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf",
"sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev",
"cargo install cargo-audit --features=fix",
{
"command": "cargo generate-lockfile",
@@ -17,12 +17,7 @@
"pipe": true
},
{
"command": "echo \"# Cargo Audit\"",
"dryRunCommand": true,
"pipe": true
},
{
"command": "echo '```'",
"command": "echo '<details>\n<summary><em><h4>Cargo Audit</h4></em></summary>\n\n```'",
"dryRunCommand": true,
"pipe": true
},
@@ -33,7 +28,7 @@
"pipe": true
},
{
"command": "echo '```'",
"command": "echo '```\n\n</details>\n'",
"dryRunCommand": true,
"pipe": true
}
@@ -41,26 +36,21 @@
"publish": [
"sleep 15s",
{
"command": "cargo package --allow-dirty --no-verify",
"command": "cargo package --no-verify",
"dryRunCommand": true
},
{
"command": "echo \"# Cargo Publish\"",
"command": "echo '<details>\n<summary><em><h4>Cargo Publish</h4></em></summary>\n\n```'",
"dryRunCommand": true,
"pipe": true
},
{
"command": "echo '```'",
"dryRunCommand": true,
"command": "cargo publish",
"dryRunCommand": "cargo publish --dry-run",
"pipe": true
},
{
"command": "cargo publish --no-verify",
"dryRunCommand": "cargo publish --no-verify --dry-run --allow-dirty",
"pipe": true
},
{
"command": "echo '```'",
"command": "echo '```\n\n</details>\n'",
"dryRunCommand": true,
"pipe": true
}
@@ -80,19 +70,14 @@
"javascript": {
"errorOnVersionRange": "^2.0.0-0",
"version": true,
"getPublishedVersion": "npm view ${ pkgFile.pkg.name } version",
"getPublishedVersion": "node ../../.scripts/covector/package-latest-version.js npm ${ pkgFile.pkg.name } ${ pkgFile.pkg.version }",
"prepublish": [
{
"command": "yarn",
"dryRunCommand": true
},
{
"command": "echo \"# Yarn Audit\n\"",
"dryRunCommand": true,
"pipe": true
},
{
"command": "echo '<details>\n<summary>click to view</summary>\n\n```'",
"command": "echo '<details>\n<summary><em><h4>Yarn Audit</h4></em></summary>\n\n```'",
"dryRunCommand": true,
"pipe": true
},
@@ -115,12 +100,7 @@
"publish": [
"sleep 15s",
{
"command": "echo \"# Yarn Package Publish\"",
"dryRunCommand": true,
"pipe": true
},
{
"command": "echo '```'",
"command": "echo '<details>\n<summary><em><h4>Yarn Publish</h4></em></summary>\n\n```'",
"dryRunCommand": true,
"pipe": true
},
@@ -130,7 +110,7 @@
"pipe": true
},
{
"command": "echo '```'",
"command": "echo '```\n\n</details>\n'",
"dryRunCommand": true,
"pipe": true
}
@@ -158,12 +138,7 @@
"dryRunCommand": true
},
{
"command": "echo \"# Yarn Audit\n\"",
"dryRunCommand": true,
"pipe": true
},
{
"command": "echo '<details>\n<summary>click to view</summary>\n\n```'",
"command": "echo '<details>\n<summary><em><h4>Yarn Audit</h4></em></summary>\n\n```'",
"dryRunCommand": true,
"pipe": true
},
@@ -185,12 +160,7 @@
],
"publish": [
{
"command": "echo \"# Yarn Package Publish\"",
"dryRunCommand": true,
"pipe": true
},
{
"command": "echo '```'",
"command": "echo '<details>\n<summary><em><h4>Yarn Publish</h4></em></summary>\n\n```'",
"dryRunCommand": true,
"pipe": true
},
@@ -200,7 +170,7 @@
"pipe": true
},
{
"command": "echo '```'",
"command": "echo '```\n\n</details>\n'",
"dryRunCommand": true,
"pipe": true
}
@@ -218,14 +188,12 @@
"tauri-runtime": {
"path": "./core/tauri-runtime",
"manager": "rust",
"dependencies": ["tauri-utils"],
"postversion": "node ../../.scripts/covector/sync-prerelease.js ${ pkg.pkg } ${ release.type }"
"dependencies": ["tauri-utils"]
},
"tauri-runtime-wry": {
"path": "./core/tauri-runtime-wry",
"manager": "rust",
"dependencies": ["tauri-utils", "tauri-runtime"],
"postversion": "node ../../.scripts/covector/sync-prerelease.js ${ pkg.pkg } ${ release.type }"
"dependencies": ["tauri-utils", "tauri-runtime"]
},
"tauri-codegen": {
"path": "./core/tauri-codegen",
@@ -241,7 +209,16 @@
"path": "./core/tauri-build",
"manager": "rust",
"dependencies": ["tauri-codegen", "tauri-utils"],
"postversion": "node ../../.scripts/covector/sync-cli-metadata.js ${ pkg.pkg } ${ release.type }"
"postversion": [
"node ../../.scripts/covector/sync-cli-metadata.js ${ pkg.pkg } ${ release.type }",
"cargo build --manifest-path ../config-schema/Cargo.toml"
],
"assets": [
{
"path": "./tooling/cli/schema.json",
"name": "schema.json"
}
]
},
"tauri": {
"path": "./core/tauri",
@@ -257,8 +234,12 @@
"cli.js": {
"path": "./tooling/cli/node",
"manager": "javascript",
"getPublishedVersion": "node ../../../.scripts/covector/package-latest-version.js npm ${ pkgFile.pkg.name } ${ pkgFile.pkg.version }",
"dependencies": ["cli.rs"],
"postversion": "node ../../../.scripts/covector/sync-cli-metadata.js ${ pkg.pkg } ${ release.type }",
"postversion": [
"node ../../../.scripts/covector/sync-cli-metadata.js ${ pkg.pkg } ${ release.type }",
"cargo build --manifest-path ../../../core/config-schema/Cargo.toml"
],
"prepublish": [],
"publish": [],
"postpublish": []
@@ -267,7 +248,10 @@
"path": "./tooling/cli",
"manager": "rust",
"dependencies": ["tauri-bundler", "tauri-utils"],
"postversion": "cargo check",
"postversion": [
"cargo check",
"cargo build --manifest-path ../../core/config-schema/Cargo.toml"
],
"assets": [
{
"path": "${ pkg.path }/target/package/tauri-cli-${ pkgFile.version }.crate",
@@ -277,8 +261,7 @@
},
"tauri-driver": {
"path": "./tooling/webdriver",
"manager": "rust",
"postversion": "node ../../.scripts/covector/sync-prerelease.js ${ pkg.pkg } ${ release.type }"
"manager": "rust"
}
}
}

View File

@@ -0,0 +1,5 @@
---
"api": "minor"
---
Added the `WindowOptions::contentProtected` option and `WebviewWindow#setContentProtected` to change it at runtime.

View File

@@ -0,0 +1,5 @@
---
"tauri-utils": "patch"
---
Added the `content_protected` option to the window configuration.

View File

@@ -0,0 +1,7 @@
---
"tauri": "minor"
"tauri-runtime": "minor"
"tauri-runtime-wry": "minor"
---
Added the `content_protected` option when creating a window and `Window::set_content_protected` to change it at runtime.

View File

@@ -0,0 +1,5 @@
---
"tauri": minor
---
Added `Window::on_navigation`.

View File

@@ -0,0 +1,5 @@
---
"tauri": "patch"
---
Sync `__TAURI_METADATA__.__windows` across all windows.

View File

@@ -0,0 +1,5 @@
---
"api": minor
---
Allow setting the text of the dialog buttons.

View File

@@ -0,0 +1,5 @@
---
"tauri": minor
---
Added `OkWithLabel` and `OkCancelWithLabels` variants to the `api::dialog::MessageDialogButtons` enum to set the text of the dialog buttons.

6
.changes/custom-icon.md Normal file
View File

@@ -0,0 +1,6 @@
---
"cli.rs": minor
"cli.js": minor
---
Add `--png` option for the `icon` command to generate custom icon sizes.

View File

@@ -0,0 +1,7 @@
---
"tauri-runtime-wry": minor
"tauri-runtime": minor
"tauri": minor
---
Added `Builder::device_event_filter` and `App::set_device_event_filter` methods.

5
.changes/fix-2549.md Normal file
View File

@@ -0,0 +1,5 @@
---
"tauri": "patch"
---
Fix resize glitch when double clicking a custom titlebar in the top resize area.

View File

@@ -0,0 +1,5 @@
---
"tauri": "patch"
---
Fix the filesystem scope allowing sub-directories of the directory picked by the dialog when `recursive` option was `false`.

5
.changes/heck-unicode.md Normal file
View File

@@ -0,0 +1,5 @@
---
"cli.rs": "patch"
---
Fix building apps with unicode characters in their `productName`.

8
.changes/is-minimized.md Normal file
View File

@@ -0,0 +1,8 @@
---
"tauri": minor
"tauri-runtime": minor
"tauri-runtime-wry": minor
"api": minor
---
Add `is_minimized()` window method.

8
.changes/nsis.md Normal file
View File

@@ -0,0 +1,8 @@
---
"tauri-bundler": minor
"tauri-utils": minor
"cli.rs": minor
"cli.js": minor
---
Add `nsis` bundle target

View File

@@ -0,0 +1,5 @@
---
"tauri": minor
---
Added support to `mailto:` and `tel:` links on the shell API.

31
.changes/readme.md Normal file
View File

@@ -0,0 +1,31 @@
# Changes
##### via https://github.com/jbolda/covector
As you create PRs and make changes that require a version bump, please add a new markdown file in this folder. You do not note the version _number_, but rather the type of bump that you expect: major, minor, or patch. The filename is not important, as long as it is a `.md`, but we recommend that it represents the overall change for organizational purposes.
When you select the version bump required, you do _not_ need to consider dependencies. Only note the package with the actual change, and any packages that depend on that package will be bumped automatically in the process.
Use the following format:
```md
---
"package-a": patch
"package-b": patch
---
Change summary goes here
```
Summaries do not have a specific character limit, but are text only. These summaries are used within the (future implementation of) changelogs. They will give context to the change and also point back to the original PR if more details and context are needed.
Changes will be designated as a `major`, `minor` or `patch` as further described in [semver](https://semver.org/).
Given a version number MAJOR.MINOR.PATCH, increment the:
- MAJOR version when you make incompatible API changes,
- MINOR version when you add functionality in a backwards compatible manner, and
- PATCH version when you make backwards compatible bug fixes.
Additional labels for pre-release and build metadata are available as extensions to the MAJOR.MINOR.PATCH format, but will be discussed prior to usage (as extra steps will be necessary in consideration of merging and publishing).

View File

@@ -0,0 +1,5 @@
---
"tauri-runtime": minor
---
Added `navigation_handler` field on `PendingWindow`.

View File

@@ -0,0 +1,5 @@
---
"tauri-build": "minor"
---
Add `WindowsAttributes::app_manifest` to specify the application manifest on Windows.

8
.changes/title-getter.md Normal file
View File

@@ -0,0 +1,8 @@
---
"tauri": "minor"
"api": "minor"
"tauri-runtime": "minor"
"tauri-runtime-wry": "minor"
---
Add `title` getter on window.

View File

@@ -0,0 +1,6 @@
---
"tauri-runtime": minor
"tauri-runtime-wry": minor
---
Added `TrayHandle::set_tooltip` and `SystemTray::with_tooltip`.

5
.changes/tray-tooltip.md Normal file
View File

@@ -0,0 +1,5 @@
---
"tauri": patch
---
Implement `SystemTray::with_tooltip` and `SystemTrayHandle::set_tooltip` for Windows and macOS.

7
.changes/url-getter.md Normal file
View File

@@ -0,0 +1,7 @@
---
"tauri-runtime": minor
"tauri-runtime-wry": minor
"tauri": minor
---
Added window's `url()` getter.

View File

@@ -0,0 +1,5 @@
---
'cli.rs': 'minor'
---
Add support for Cargo's workspace inheritance for the package version.

View File

@@ -0,0 +1,7 @@
---
"tauri": "patch"
"tauri-runtime": "patch"
"tauri-runtime-wry": "patch"
---
On Windows, change webview theme based on Window theme for more accurate `prefers-color-scheme` support.

View File

@@ -0,0 +1,6 @@
---
"tauri-bundler": "patch"
---
On Windows, the `msi` installer's `Launch App` checkbox will be checked by default.

View File

@@ -0,0 +1,5 @@
---
"tauri-runtime-wry": minor
---
Implement the webview navigation handler.

View File

@@ -5,7 +5,7 @@ FROM mcr.microsoft.com/vscode/devcontainers/base:0-${VARIANT}
# Derived from Tauri contribution and setup guides:
# See: https://github.com/tauri-apps/tauri/blob/dev/.github/CONTRIBUTING.md#development-guide
# See: https://tauri.studio/v1/guides/getting-started/prerequisites/#setting-up-linux
# See: https://tauri.app/v1/guides/getting-started/prerequisites/#setting-up-linux
ARG TAURI_BUILD_DEPS="build-essential curl libappindicator3-dev libgtk-3-dev librsvg2-dev libssl-dev libwebkit2gtk-4.0-dev wget"
RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \

View File

@@ -24,7 +24,7 @@ Prerequisites are mainly derived from VS Code's instructions for usage of develo
### A note on filesystem performance
Due to limititations in how Docker shares files between the Docker host and a container, it's also recommended that developers [clone Tauri source code into a container volume](https://code.visualstudio.com/remote/advancedcontainers/improve-performance#_use-clone-repository-in-container-volume). This is optional, but highly advised as many filesystem/IO heavy opearations (`cargo build`, `yarn install`, etc) will be very slow if they operate on directories shared with a Docker container from the Docker host.
Due to limitations in how Docker shares files between the Docker host and a container, it's also recommended that developers [clone Tauri source code into a container volume](https://code.visualstudio.com/remote/advancedcontainers/improve-performance#_use-clone-repository-in-container-volume). This is optional, but highly advised as many filesystem/IO heavy operations (`cargo build`, `yarn install`, etc) will be very slow if they operate on directories shared with a Docker container from the Docker host.
To do this, open your project with VS Code and run **Remote-Containers: Clone Repository in Container Volume...** from the Command Palette (<kbd>F1</kbd>).

View File

@@ -0,0 +1,44 @@
FROM ubuntu:18.04
ARG DEBIAN_FRONTEND=noninteractive
COPY common.sh lib.sh /
RUN /common.sh
COPY cmake.sh /
RUN /cmake.sh
COPY xargo.sh /
RUN /xargo.sh
RUN apt-get update && apt-get install --assume-yes --no-install-recommends \
g++-aarch64-linux-gnu \
libc6-dev-arm64-cross
COPY deny-debian-packages.sh /
RUN TARGET_ARCH=arm64 /deny-debian-packages.sh \
binutils \
binutils-aarch64-linux-gnu
COPY qemu.sh /
RUN /qemu.sh aarch64 softmmu
COPY dropbear.sh /
RUN /dropbear.sh
COPY linux-image.sh /
RUN /linux-image.sh aarch64
COPY linux-runner /
ENV CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=aarch64-linux-gnu-gcc \
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_RUNNER="/linux-runner aarch64" \
CC_aarch64_unknown_linux_gnu=aarch64-linux-gnu-gcc \
CXX_aarch64_unknown_linux_gnu=aarch64-linux-gnu-g++ \
BINDGEN_EXTRA_CLANG_ARGS_aarch64_unknown_linux_gnu="--sysroot=/usr/aarch64-linux-gnu" \
QEMU_LD_PREFIX=/usr/aarch64-linux-gnu \
RUST_TEST_THREADS=1 \
PKG_CONFIG_PATH="/usr/lib/aarch64-linux-gnu/pkgconfig/:${PKG_CONFIG_PATH}"
RUN dpkg --add-architecture arm64
RUN apt-get update
RUN apt-get install --assume-yes --no-install-recommends libssl-dev:arm64 libdbus-1-dev:arm64 libsoup2.4-dev:arm64 libssl-dev:arm64 libgtk-3-dev:arm64 webkit2gtk-4.0-dev:arm64 libappindicator3-1:arm64 librsvg2-dev:arm64 patchelf:arm64

31
.docker/cross/cmake.sh Executable file
View File

@@ -0,0 +1,31 @@
#!/usr/bin/env bash
set -x
set -euo pipefail
# shellcheck disable=SC1091
. lib.sh
main() {
local version=3.23.1
install_packages curl
local td
td="$(mktemp -d)"
pushd "${td}"
curl --retry 3 -sSfL "https://github.com/Kitware/CMake/releases/download/v${version}/cmake-${version}-linux-x86_64.sh" -o cmake.sh
sh cmake.sh --skip-license --prefix=/usr/local
popd
purge_packages
rm -rf "${td}"
rm -rf /var/lib/apt/lists/*
rm "${0}"
}
main "${@}"

40
.docker/cross/common.sh Executable file
View File

@@ -0,0 +1,40 @@
#!/usr/bin/env bash
set -x
set -euo pipefail
# shellcheck disable=SC1091
. lib.sh
# For architectures except amd64 and i386, look for packages on ports.ubuntu.com instead.
# This is important if you enable additional architectures so you can install libraries to cross-compile against.
# Look for 'dpkg --add-architecture' in the README for more details.
if grep -i ubuntu /etc/os-release >/dev/null; then
sed 's/http:\/\/\(.*\).ubuntu.com\/ubuntu\//[arch-=amd64,i386] http:\/\/ports.ubuntu.com\/ubuntu-ports\//g' /etc/apt/sources.list > /etc/apt/sources.list.d/ports.list
sed -i 's/http:\/\/\(.*\).ubuntu.com\/ubuntu\//[arch=amd64,i386] http:\/\/\1.archive.ubuntu.com\/ubuntu\//g' /etc/apt/sources.list
fi
install_packages \
autoconf \
automake \
binutils \
ca-certificates \
curl \
file \
gcc \
git \
libtool \
m4 \
make
if_centos install_packages \
clang-devel \
gcc-c++ \
glibc-devel \
pkgconfig
if_ubuntu install_packages \
g++ \
libc6-dev \
libclang-dev \
pkg-config

View File

@@ -0,0 +1,19 @@
#!/usr/bin/env bash
set -x
set -euo pipefail
main() {
local package
for package in "${@}"; do
echo "Package: ${package}:${TARGET_ARCH}
Pin: release *
Pin-Priority: -1" > "/etc/apt/preferences.d/${package}"
echo "${package}"
done
rm "${0}"
}
main "${@}"

56
.docker/cross/dropbear.sh Executable file
View File

@@ -0,0 +1,56 @@
#!/usr/bin/env bash
set -x
set -euo pipefail
# shellcheck disable=SC1091
. lib.sh
main() {
local version=2022.82
install_packages \
autoconf \
automake \
bzip2 \
curl \
make
if_centos install_packages zlib-devel
if_ubuntu install_packages zlib1g-dev
local td
td="$(mktemp -d)"
pushd "${td}"
curl --retry 3 -sSfL "https://matt.ucc.asn.au/dropbear/releases/dropbear-${version}.tar.bz2" -O
tar --strip-components=1 -xjf "dropbear-${version}.tar.bz2"
# Remove some unwanted message
sed -i '/skipping hostkey/d' cli-kex.c
sed -i '/failed to identify current user/d' cli-runopts.c
./configure \
--disable-syslog \
--disable-shadow \
--disable-lastlog \
--disable-utmp \
--disable-utmpx \
--disable-wtmp \
--disable-wtmpx \
--disable-pututline \
--disable-pututxline
make "-j$(nproc)" PROGRAMS=dbclient
cp dbclient /usr/local/bin/
purge_packages
popd
rm -rf "${td}"
rm "${0}"
}
main "${@}"

45
.docker/cross/lib.sh Normal file
View File

@@ -0,0 +1,45 @@
purge_list=()
install_packages() {
if grep -i ubuntu /etc/os-release; then
apt-get update
for pkg in "${@}"; do
if ! dpkg -L "${pkg}" >/dev/null 2>/dev/null; then
apt-get install --assume-yes --no-install-recommends "${pkg}"
purge_list+=( "${pkg}" )
fi
done
else
for pkg in "${@}"; do
if ! yum list installed "${pkg}" >/dev/null 2>/dev/null; then
yum install -y "${pkg}"
purge_list+=( "${pkg}" )
fi
done
fi
}
purge_packages() {
if (( ${#purge_list[@]} )); then
if grep -i ubuntu /etc/os-release; then
apt-get purge --assume-yes --auto-remove "${purge_list[@]}"
else
yum remove -y "${purge_list[@]}"
fi
fi
}
if_centos() {
if grep -q -i centos /etc/os-release; then
eval "${@}"
fi
}
if_ubuntu() {
if grep -q -i ubuntu /etc/os-release; then
eval "${@}"
fi
}

274
.docker/cross/linux-image.sh Executable file
View File

@@ -0,0 +1,274 @@
#!/usr/bin/env bash
set -x
set -euo pipefail
# shellcheck disable=SC1091
. lib.sh
main() {
# arch in the rust target
local arch="${1}" \
kversion=4.19.0-20
local debsource="deb http://http.debian.net/debian/ buster main"
debsource="${debsource}\ndeb http://security.debian.org/ buster/updates main"
local dropbear="dropbear-bin"
local -a deps
local kernel=
local libgcc="libgcc1"
# select debian arch and kernel version
case "${arch}" in
aarch64)
arch=arm64
kernel="${kversion}-arm64"
;;
armv7)
arch=armhf
kernel="${kversion}-armmp"
;;
i686)
arch=i386
kernel="${kversion}-686"
;;
mips|mipsel)
kernel="${kversion}-4kc-malta"
;;
mips64el)
kernel="${kversion}-5kc-malta"
;;
powerpc)
# there is no buster powerpc port, so we use jessie
# use a more recent kernel from backports
kversion='4.9.0-0.bpo.6'
kernel="${kversion}-powerpc"
debsource="deb http://archive.debian.org/debian jessie main"
debsource="${debsource}\ndeb http://archive.debian.org/debian jessie-backports main"
debsource="${debsource}\ndeb http://ftp.ports.debian.org/debian-ports unstable main"
debsource="${debsource}\ndeb http://ftp.ports.debian.org/debian-ports unreleased main"
# archive.debian.org Release files are expired.
echo "Acquire::Check-Valid-Until false;" | tee -a /etc/apt/apt.conf.d/10-nocheckvalid
echo "APT::Get::AllowUnauthenticated true;" | tee -a /etc/apt/apt.conf.d/10-nocheckvalid
dropbear="dropbear"
deps=(libcrypt1:"${arch}")
;;
powerpc64)
# there is no stable port
arch=ppc64
# https://packages.debian.org/en/sid/linux-image-powerpc64
kversion='5.*'
kernel="${kversion}-powerpc64"
libgcc="libgcc-s1"
debsource="deb http://ftp.ports.debian.org/debian-ports unstable main"
debsource="${debsource}\ndeb http://ftp.ports.debian.org/debian-ports unreleased main"
# sid version of dropbear requires these dependencies
deps=(libcrypt1:"${arch}")
;;
powerpc64le)
arch=ppc64el
kernel="${kversion}-powerpc64le"
;;
s390x)
arch=s390x
kernel="${kversion}-s390x"
;;
sparc64)
# there is no stable port
# https://packages.debian.org/en/sid/linux-image-sparc64
kernel='*-sparc64'
libgcc="libgcc-s1"
debsource="deb http://ftp.ports.debian.org/debian-ports unstable main"
debsource="${debsource}\ndeb http://ftp.ports.debian.org/debian-ports unreleased main"
# sid version of dropbear requires these dependencies
deps=(libcrypt1:"${arch}")
;;
x86_64)
arch=amd64
kernel="${kversion}-amd64"
;;
*)
echo "Invalid arch: ${arch}"
exit 1
;;
esac
install_packages ca-certificates \
curl \
cpio \
sharutils \
gnupg
# Download packages
mv /etc/apt/sources.list /etc/apt/sources.list.bak
echo -e "${debsource}" > /etc/apt/sources.list
# Old ubuntu does not support --add-architecture, so we directly change multiarch file
if [ -f /etc/dpkg/dpkg.cfg.d/multiarch ]; then
cp /etc/dpkg/dpkg.cfg.d/multiarch /etc/dpkg/dpkg.cfg.d/multiarch.bak
fi
dpkg --add-architecture "${arch}" || echo "foreign-architecture ${arch}" > /etc/dpkg/dpkg.cfg.d/multiarch
# Add Debian keys.
curl --retry 3 -sSfL 'https://ftp-master.debian.org/keys/archive-key-{7.0,8,9,10}.asc' -O
curl --retry 3 -sSfL 'https://ftp-master.debian.org/keys/archive-key-{8,9,10}-security.asc' -O
curl --retry 3 -sSfL 'https://ftp-master.debian.org/keys/release-{7,8,9,10}.asc' -O
curl --retry 3 -sSfL 'https://www.ports.debian.org/archive_{2020,2021,2022}.key' -O
for key in *.asc *.key; do
apt-key add "${key}"
rm "${key}"
done
# allow apt-get to retry downloads
echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries
apt-get update
mkdir -p "/qemu/${arch}"
chmod 777 /qemu "/qemu/${arch}"
cd "/qemu/${arch}"
apt-get -d --no-install-recommends download \
${deps[@]+"${deps[@]}"} \
"busybox:${arch}" \
"${dropbear}:${arch}" \
"libtommath1:${arch}" \
"libtomcrypt1:${arch}" \
"libgmp10:${arch}" \
"libc6:${arch}" \
"${libgcc}:${arch}" \
"libstdc++6:${arch}" \
"linux-image-${kernel}:${arch}" \
ncurses-base \
"zlib1g:${arch}"
cd /qemu
# Install packages
root="root-${arch}"
mkdir -p "${root}"/{bin,etc/dropbear,root,sys,dev,proc,sbin,tmp,usr/{bin,sbin},var/log}
for deb in "${arch}"/*deb; do
dpkg -x "${deb}" "${root}"/
done
cp "${root}/boot/vmlinu"* kernel
# initrd
mkdir -p "${root}/modules"
cp -v \
"${root}/lib/modules"/*/kernel/drivers/net/net_failover.ko \
"${root}/lib/modules"/*/kernel/drivers/net/virtio_net.ko \
"${root}/lib/modules"/*/kernel/drivers/virtio/* \
"${root}/lib/modules"/*/kernel/fs/netfs/netfs.ko \
"${root}/lib/modules"/*/kernel/fs/9p/9p.ko \
"${root}/lib/modules"/*/kernel/fs/fscache/fscache.ko \
"${root}/lib/modules"/*/kernel/net/9p/9pnet.ko \
"${root}/lib/modules"/*/kernel/net/9p/9pnet_virtio.ko \
"${root}/lib/modules"/*/kernel/net/core/failover.ko \
"${root}/modules" || true # some file may not exist
rm -rf "${root:?}/boot"
rm -rf "${root:?}/lib/modules"
cat << 'EOF' > "${root}/etc/hosts"
127.0.0.1 localhost qemu
EOF
cat << 'EOF' > $root/etc/hostname
qemu
EOF
cat << 'EOF' > $root/etc/passwd
root::0:0:root:/root:/bin/sh
EOF
cat << 'EOF' | uudecode -o $root/etc/dropbear/dropbear_rsa_host_key
begin 600 dropbear_rsa_host_key
M````!W-S:"UR<V$````#`0`!```!`0"N!-<%K,3Z.!Z,OEMB2.N\O.$IWQ*F
M#5%(_;(^2YKY_J_.RQW/7U@_MK&J#!Z0_\;EH#98ZW*E1\.<FF%P/*Y.W56-
M31.'EJE`TN@=T5EC(8"Y%3'ZBYH)^WIVJ]S*G/_;#RH\_?S"U^1L_<<.F`O+
MZVI?*]\KTDOT&QV0#B-M;"%_7:\>+3[X=QMH,B<HM$+0E[\B6*^!XKLR@V,K
M)<V80HHK:_#;D]26XKN&CB./EZAC%4)78R!G""4HT@UK<5I4B^$/""`,?*\T
M>*4$RYULV,V3X6]K:7@Q?80"#WXGGQZNFN6CZ7LTDX(F6J[\]F5<0`HEOF:Z
MX;^53`L'4I/A```!``$L:$Z*#6<^3@+O%.[-#/5H+.C'3\#QQZN[1;J>L`8I
MZ_&T'!"J'/Y+?R?55G:M^=]R*-&I3TOJYZA8@&H51ZOAF59'1_>>Z@?E4#)$
MQU)X/RWH51ZB5KSDWJS:D'7GD(!?NAY`C'7\)I:_4)J")QBV/P"RJQGHG'%B
M1BT2LE6676>`1K,0\NIMZTKQNB(IC+88<7#8%_-=P<&6<"9LH>60TSS?3?-C
MN`T36YB/3^<(Q;`N1NT>I9EZS`BAC^-?.:,R\7EL"<4>7E=]^1]B\K9])AQU
MBM\]M;4V(S(6KH-I.4[6>9E+@\UEM.J6:[2LUEEJDG:G:+:/EVF^Y75@(S$`
M``"!`.O+KW=&*CBCHL"11&SVO4/K]$R-]7MV7,3RR)Q[X'0;6.?4JHW!3VR6
M*FGBY--37ZD-+UV.8_+"$<?B"#&K$.[V)F7V2\UY!7(0FZ@A2`0ADDY*J-_B
M4AU&.*GP#F/!I([:?E],.>6PH9)(/E.\G19#G0K`LRM?JWS!58&;D0C1````
M@0"\[@NYWSTW(?Q@:_A*1Y3/AKYO5?S=0"<2>#V-AH6W-NCSDTSRP=2D79FS
M"D?[;.)V>8'#9&I3"MU@+:2\Z%$0-MG0+J'(0>T1_C6?*C=4U0I$DI<=@D]1
H_&DE8Y(OT%%EPG]!$H&5HX*),_D1A2\P=R.7G'`0L%YM-79Y"T">$0``
`
end
EOF
# dropbear complains when this file is missing
touch "${root}/var/log/lastlog"
cat << 'EOF' > $root/init
#!/bin/busybox sh
set -e
/bin/busybox --install
mount -t devtmpfs devtmpfs /dev
mount -t proc none /proc
mount -t sysfs none /sys
mkdir /dev/pts
mount -t devpts none /dev/pts/
# some archs does not have virtio modules
insmod /modules/failover.ko || true
insmod /modules/net_failover.ko || true
insmod /modules/virtio.ko || true
insmod /modules/virtio_ring.ko || true
insmod /modules/virtio_mmio.ko || true
insmod /modules/virtio_pci_legacy_dev.ko || true
insmod /modules/virtio_pci_modern_dev.ko || true
insmod /modules/virtio_pci.ko || true
insmod /modules/virtio_net.ko || true
insmod /modules/netfs.ko || true
insmod /modules/fscache.ko
insmod /modules/9pnet.ko
insmod /modules/9pnet_virtio.ko || true
insmod /modules/9p.ko
ifconfig lo 127.0.0.1
ifconfig eth0 10.0.2.15
route add default gw 10.0.2.2 eth0
mkdir /target
mount -t 9p -o trans=virtio target /target -oversion=9p2000.u || true
exec dropbear -F -E -B
EOF
chmod +x "${root}/init"
cd "${root}"
find . | cpio --create --format='newc' --quiet | gzip > ../initrd.gz
cd -
# Clean up
rm -rf "/qemu/${root}" "/qemu/${arch}"
mv -f /etc/apt/sources.list.bak /etc/apt/sources.list
if [ -f /etc/dpkg/dpkg.cfg.d/multiarch.bak ]; then
mv /etc/dpkg/dpkg.cfg.d/multiarch.bak /etc/dpkg/dpkg.cfg.d/multiarch
fi
# can fail if arch is used (amd64 and/or i386)
dpkg --remove-architecture "${arch}" || true
apt-get update
purge_packages
ls -lh /qemu
}
main "${@}"

173
.docker/cross/linux-runner Executable file
View File

@@ -0,0 +1,173 @@
#!/usr/bin/env bash
set -e
LOG=/tmp/qemu.log
LOCK=/tmp/qemu.lock
if [ -n "${CROSS_DEBUG}" ]; then
set -x
fi
# arch in the rust target
arch="${1}"
shift
if [ "${CROSS_RUNNER}" = "" ]; then
if [[ "${arch}" == i?86 ]] || [[ "${arch}" == x86_64 ]]; then
CROSS_RUNNER=native
else
CROSS_RUNNER=qemu-user
fi
fi
# select qemu arch
qarch="${arch}"
case "${arch}" in
armv7)
qarch="arm"
;;
i686)
qarch="i386"
;;
powerpc)
qarch="ppc"
;;
powerpc64)
qarch="ppc64"
;;
powerpc64le)
if [ "${CROSS_RUNNER}" = "qemu-user" ]; then
qarch="ppc64le"
else
qarch="ppc64"
fi
;;
esac
case "${CROSS_RUNNER}" in
native)
exec "${@}"
;;
qemu-user)
exec "qemu-${qarch}" "${@}"
;;
qemu-system)
true
;;
*)
echo "Invalid runner: \"${CROSS_RUNNER}\"";
echo "Valid runners are: native, qemu-user and qemu-system"
exit 1
;;
esac
n="$(nproc)"
memory=1G
driver9p="virtio-9p-pci"
drivernet="virtio-net-pci"
# select qemu parameters
case "${arch}" in
aarch64)
# 8 is the max number of cpu supported by qemu-aarch64
n=$(( n > 8 ? 8 : n ))
opt="-machine virt -cpu cortex-a57"
;;
armv7)
opt="-machine virt"
driver9p="virtio-9p-device"
drivernet="virtio-net-device"
;;
i686)
opt="-append console=ttyS0"
;;
mips|mipsel)
# avoid kernel error
# https://blahcat.github.io/2017/07/14/building-a-debian-stretch-qemu-image-for-mipsel/
opt="-append nokaslr"
n=1
;;
mips64el)
# avoid kernel error
# https://blahcat.github.io/2017/07/14/building-a-debian-stretch-qemu-image-for-mipsel/
opt="-append nokaslr -cpu MIPS64R2-generic"
n=1
;;
powerpc)
opt="-append console=ttyPZ0"
n=1
;;
powerpc64|powerpc64le)
opt="-append console=hvc0 --nodefaults -serial stdio"
;;
s390x)
n=1
driver9p="virtio-9p-ccw"
drivernet="virtio-net-ccw"
;;
sparc64)
n=1
driver9p+=",bus=pciB"
drivernet+=",bus=pciB"
;;
x86_64)
opt="-append console=ttyS0"
;;
esac
(
flock -n 200 || exit 0
echo Booting QEMU virtual machine with $n cpus...
QEMU_CMD="qemu-system-${qarch} \
-m ${memory} \
-smp ${n} \
-nographic \
-monitor none \
-netdev user,id=net0,hostfwd=tcp::10022-:22 \
-device ${drivernet},netdev=net0 \
-kernel /qemu/kernel \
-initrd /qemu/initrd.gz \
${opt} \
-fsdev local,id=fs0,path=/target,security_model=mapped \
-device ${driver9p},fsdev=fs0,mount_tag=target"
touch "${LOG}"
if [[ -n "${CROSS_DEBUG}" ]]; then
(${QEMU_CMD} 2>&1 | tee -a "${LOG}") &
else
${QEMU_CMD} >> "${LOG}" 2>&1 &
fi
# wait for dropbear
for _ in $(seq 240); do
if grep -q "Not backgrounding" "${LOG}"; then
READY=1
break
fi
sleep 0.5s
done
if [ -z "${READY}" ]; then
if [ -n "${CROSS_DEBUG}" ]; then
echo "Not ready but continuing because CROSS_DEBUG is set"
else
echo "Qemu is not ready after ${SECONDS} seconds..."
echo "Set the environment variable CROSS_DEBUG=1 to debug"
echo "Last 100 lines of qemu output:"
tail -n 100 "${LOG}"
exit 1
fi
fi
echo "Booted in ${SECONDS} seconds"
) 200>"${LOCK}"
if [[ -t 1 ]] && [[ -t 2 ]]; then
tty_flag='-t'
fi
exec dbclient ${tty_flag} -p 10022 -y -y root@localhost "${@}"

233
.docker/cross/qemu.sh Executable file
View File

@@ -0,0 +1,233 @@
#!/usr/bin/env bash
set -x
set -euo pipefail
# shellcheck disable=SC1091
. lib.sh
build_static_libffi () {
local version=3.0.13
local td
td="$(mktemp -d)"
pushd "${td}"
curl --retry 3 -sSfL "https://github.com/libffi/libffi/archive/refs/tags/v${version}.tar.gz" -O -L
tar --strip-components=1 -xzf "v${version}.tar.gz"
./configure --prefix="$td"/lib --disable-builddir --disable-shared --enable-static
make "-j$(nproc)"
install -m 644 ./.libs/libffi.a /usr/lib64/
popd
rm -rf "${td}"
}
build_static_libmount () {
local version_spec=2.23.2
local version=2.23
local td
td="$(mktemp -d)"
pushd "${td}"
curl --retry 3 -sSfL "https://kernel.org/pub/linux/utils/util-linux/v${version}/util-linux-${version_spec}.tar.xz" -O -L
tar --strip-components=1 -xJf "util-linux-${version_spec}.tar.xz"
./configure --disable-shared --enable-static --without-ncurses
make "-j$(nproc)" mount blkid
install -m 644 ./.libs/*.a /usr/lib64/
popd
rm -rf "${td}"
}
build_static_libattr() {
local version=2.4.46
local td
td="$(mktemp -d)"
pushd "${td}"
yum install -y gettext
curl --retry 3 -sSfL "https://download.savannah.nongnu.org/releases/attr/attr-${version}.src.tar.gz" -O
tar --strip-components=1 -xzf "attr-${version}.src.tar.gz"
cp /usr/share/automake*/config.* .
./configure
make "-j$(nproc)"
install -m 644 ./libattr/.libs/libattr.a /usr/lib64/
yum remove -y gettext
popd
rm -rf "${td}"
}
build_static_libcap() {
local version=2.22
local td
td="$(mktemp -d)"
pushd "${td}"
curl --retry 3 -sSfL "https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-${version}.tar.xz" -O
tar --strip-components=1 -xJf "libcap-${version}.tar.xz"
make "-j$(nproc)"
install -m 644 libcap/libcap.a /usr/lib64/
popd
rm -rf "${td}"
}
build_static_pixman() {
local version=0.34.0
local td
td="$(mktemp -d)"
pushd "${td}"
curl --retry 3 -sSfL "https://www.cairographics.org/releases/pixman-${version}.tar.gz" -O
tar --strip-components=1 -xzf "pixman-${version}.tar.gz"
./configure
make "-j$(nproc)"
install -m 644 ./pixman/.libs/libpixman-1.a /usr/lib64/
popd
rm -rf "${td}"
}
main() {
local version=5.1.0
if_centos version=4.2.1
local arch="${1}" \
softmmu="${2:-}"
install_packages \
autoconf \
automake \
bison \
bzip2 \
curl \
flex \
libtool \
make \
patch \
python3 \
if_centos install_packages \
gcc-c++ \
pkgconfig \
xz \
glib2-devel \
glib2-static \
glibc-static \
libattr-devel \
libcap-devel \
libfdt-devel \
pcre-static \
pixman-devel \
libselinux-devel \
libselinux-static \
libffi \
libuuid-devel \
libblkid-devel \
libmount-devel \
zlib-devel \
zlib-static
if_centos 'curl --retry 3 -sSfL "https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD" -o /usr/share/automake*/config.guess'
if_centos 'curl --retry 3 -sSfL "https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD" -o /usr/share/automake*/config.sub'
# these are not packaged as static libraries in centos; build them manually
if_centos build_static_libffi
if_centos build_static_libmount
if_centos build_static_libattr
if_centos build_static_libcap
if_centos build_static_pixman
if_ubuntu install_packages \
g++ \
pkg-config \
xz-utils \
libattr1-dev \
libcap-ng-dev \
libffi-dev \
libglib2.0-dev \
libpixman-1-dev \
libselinux1-dev \
zlib1g-dev
# if we have python3.6+, we can install qemu 6.1.0, which needs ninja-build
# ubuntu 16.04 only provides python3.5, so remove when we have a newer qemu.
is_ge_python36=$(python3 -c "import sys; print(int(sys.version_info >= (3, 6)))")
if [[ "${is_ge_python36}" == "1" ]]; then
if_ubuntu version=6.1.0
if_ubuntu install_packages ninja-build
fi
local td
td="$(mktemp -d)"
pushd "${td}"
curl --retry 3 -sSfL "https://download.qemu.org/qemu-${version}.tar.xz" -O
tar --strip-components=1 -xJf "qemu-${version}.tar.xz"
local targets="${arch}-linux-user"
local virtfs=""
case "${softmmu}" in
softmmu)
if [ "${arch}" = "ppc64le" ]; then
targets="${targets},ppc64-softmmu"
else
targets="${targets},${arch}-softmmu"
fi
virtfs="--enable-virtfs"
;;
"")
true
;;
*)
echo "Invalid softmmu option: ${softmmu}"
exit 1
;;
esac
./configure \
--disable-kvm \
--disable-vnc \
--disable-guest-agent \
--enable-linux-user \
--static \
${virtfs} \
--target-list="${targets}"
make "-j$(nproc)"
make install
# HACK the binfmt_misc interpreter we'll use expects the QEMU binary to be
# in /usr/bin. Create an appropriate symlink
ln -s "/usr/local/bin/qemu-${arch}" "/usr/bin/qemu-${arch}-static"
purge_packages
popd
rm -rf "${td}"
rm "${0}"
}
main "${@}"

28
.docker/cross/xargo.sh Executable file
View File

@@ -0,0 +1,28 @@
#!/usr/bin/env bash
set -x
set -euo pipefail
# shellcheck disable=SC1091
. lib.sh
main() {
install_packages ca-certificates curl
export RUSTUP_HOME=/tmp/rustup
export CARGO_HOME=/tmp/cargo
curl --retry 3 -sSfL https://sh.rustup.rs -o rustup-init.sh
sh rustup-init.sh -y --no-modify-path --profile minimal
rm rustup-init.sh
PATH="${CARGO_HOME}/bin:${PATH}" cargo install xargo --root /usr/local
rm -r "${RUSTUP_HOME}" "${CARGO_HOME}"
purge_packages
rm "${0}"
}
main "${@}"

24
.github/CODEOWNERS vendored
View File

@@ -1,24 +1,8 @@
# Current WG Code Sub Teams:
# @tauri-apps/admins
# @tauri-apps/bundler
# @tauri-apps/core
# @tauri-apps/js-cli
# @tauri-apps/testing
# @tauri-apps/wg-tauri
# @tauri-apps/wg-devops
# admins default to review
# Order is important; the last matching pattern takes the most precedence.
* @tauri-apps/admins
* @tauri-apps/wg-tauri
.github @tauri-apps/admins @tauri-apps/testing
/examples/ @tauri-apps/testing
/tooling/api/ @tauri-apps/core
/tooling/bundler/ @tauri-apps/bundler
/tooling/cli/ @tauri-apps/core
/tooling/cli/node/ @tauri-apps/js-cli
/core/** @tauri-apps/core
.github @tauri-apps/wg-devops

View File

@@ -61,7 +61,7 @@ representative at an online or offline event.
Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the community leaders responsible for enforcement at
[contact@tauri.studio](mailto:contact@tauri.studio).
[contact@tauri.app](mailto:contact@tauri.app).
All complaints will be reviewed and investigated promptly and fairly.
All community leaders are obligated to respect the privacy and security of the

View File

@@ -48,9 +48,9 @@ Hi! We, the maintainers, are really excited that you are interested in contribut
First, [join our Discord server](https://discord.gg/SpmNs4S) and let us know that you want to contribute. This way we can point you in the right direction and help ensure your contribution will be as helpful as possible.
To set up your machine for development, follow the [Tauri setup guide](https://tauri.studio/guides/getting-started/prerequisites/) to get all the tools you need to develop Tauri apps. The only additional tool you may need is [Yarn](https://yarnpkg.com/), it is only required if you are developing the Node CLI or API packages (`tooling/cli/node` and `tooling/api`). Next, fork and clone this repo. It is structured as a monorepo, which means that all the various Tauri packages are under the same repository. The development process varies depending on what part of Tauri you are contributing to, see the guides below for per-package instructions.
To set up your machine for development, follow the [Tauri setup guide](https://tauri.app/v1/guides/getting-started/prerequisites/) to get all the tools you need to develop Tauri apps. The only additional tool you may need is [Yarn](https://yarnpkg.com/), it is only required if you are developing the Node CLI or API packages (`tooling/cli/node` and `tooling/api`). Next, fork and clone this repo. It is structured as a monorepo, which means that all the various Tauri packages are under the same repository. The development process varies depending on what part of Tauri you are contributing to, see the guides below for per-package instructions.
Some Tauri packages will be automatically built when running one of the examples. Others, however, will need to be built beforehand. To build these automatically, run the `.scripts/setup.sh` (Linux and macOS) or `.scripts/setup.ps1` (Windows) script. This will install the Rust and Node.js CLI and build the JS API. After that, you should be able to run all the examples. Note that the setup script should be executed from the root folder of the respository in order to run correctly.
Some Tauri packages will be automatically built when running one of the examples. Others, however, will need to be built beforehand. To build these automatically, run the `.scripts/setup.sh` (Linux and macOS) or `.scripts/setup.ps1` (Windows) script. This will install the Rust and Node.js CLI and build the JS API. After that, you should be able to run all the examples. Note that the setup script should be executed from the root folder of the repository in order to run correctly.
### Packages Overview
@@ -87,4 +87,4 @@ The JS API provides bindings between the developer's JS in the Webview and the b
## Financial Contribution
Tauri is an MIT-licensed open source project. Its ongoing development can be supported via [Github Sponsors](https://github.com/sponsors/nothingismagick) or [Open Collective](https://opencollective.com/tauri). We prefer Github Sponsors as donations made are doubled through the matching fund program.
Tauri is an MIT-licensed open source project. Its ongoing development can be supported via [GitHub Sponsors](https://github.com/sponsors/nothingismagick) or [Open Collective](https://opencollective.com/tauri). We prefer GitHub Sponsors as donations made are doubled through the matching fund program.

View File

@@ -1,7 +1,7 @@
name: 🐞 Bug Report
title: '[bug] '
description: Report a bug
labels: 'type: bug'
labels: ['type: bug', 'status: needs triage']
body:
- type: markdown
@@ -43,7 +43,6 @@ body:
attributes:
label: Platform and versions
description: "Output of `npm run tauri info` or `cargo tauri info`"
render: shell
validations:
required: true

View File

@@ -1,24 +1,19 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
name: updater test artifacts
on:
push:
branches:
- dev
- next
schedule:
- cron: '0 0 * * *'
pull_request:
paths:
- '.github/workflows/artifacts-updater.yml'
- 'core/tauri/**'
- 'tooling/cli/**'
- 'tooling/bundler/**'
- 'examples/updater/**'
workflow_dispatch:
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
@@ -26,7 +21,7 @@ concurrency:
cancel-in-progress: true
jobs:
build-artifacs:
build-artifacts:
runs-on: ${{ matrix.platform }}
strategy:
@@ -45,61 +40,13 @@ jobs:
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache core cargo target
uses: actions/cache@v2
env:
cache-name: cargo_core
with:
path: target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache CLI cargo target
uses: actions/cache@v2
env:
cache-name: cargo_cli
with:
path: tooling/cli/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
workspaces: |
core -> ../target
tooling/cli
- name: build and install cli.rs
run: cargo install --path tooling/cli --force
@@ -110,13 +57,14 @@ jobs:
run: |
echo "Enable code signing: ${{ env.ENABLE_CODE_SIGNING != '' }}"
echo "::set-output name=enabled::${{ env.ENABLE_CODE_SIGNING != '' }}"
# run only on tauri-apps/tauri repo (require secrets)
- name: build sample artifacts + code signing (updater)
if: steps.enablecodesigning.outputs.enabled == 'true'
working-directory: ./examples/updater
run: |
yarn install
cargo tauri build
cargo tauri build --verbose
env:
# Notarization (disabled)
# FIXME: enable only on `dev` push maybe? as it take some times...
@@ -130,15 +78,17 @@ jobs:
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
# Updater signature is exposed here to make sure it works in PR's
TAURI_PRIVATE_KEY: dW50cnVzdGVkIGNvbW1lbnQ6IHJzaWduIGVuY3J5cHRlZCBzZWNyZXQga2V5ClJXUlRZMEl5YTBGV3JiTy9lRDZVd3NkL0RoQ1htZmExNDd3RmJaNmRMT1ZGVjczWTBKZ0FBQkFBQUFBQUFBQUFBQUlBQUFBQWdMekUzVkE4K0tWQ1hjeGt1Vkx2QnRUR3pzQjVuV0ZpM2czWXNkRm9hVUxrVnB6TUN3K1NheHJMREhQbUVWVFZRK3NIL1VsMDBHNW5ET1EzQno0UStSb21nRW4vZlpTaXIwZFh5ZmRlL1lSN0dKcHdyOUVPclVvdzFhVkxDVnZrbHM2T1o4Tk1NWEU9Cg==
TAURI_KEY_PASSWORD:
# run on PRs and forks
- name: build sample artifacts (updater)
if: steps.enablecodesigning.outputs.enabled != 'true'
working-directory: ./examples/updater
run: |
yarn install
cargo tauri build
cargo tauri build --verbose
env:
TAURI_PRIVATE_KEY: dW50cnVzdGVkIGNvbW1lbnQ6IHJzaWduIGVuY3J5cHRlZCBzZWNyZXQga2V5ClJXUlRZMEl5YTBGV3JiTy9lRDZVd3NkL0RoQ1htZmExNDd3RmJaNmRMT1ZGVjczWTBKZ0FBQkFBQUFBQUFBQUFBQUlBQUFBQWdMekUzVkE4K0tWQ1hjeGt1Vkx2QnRUR3pzQjVuV0ZpM2czWXNkRm9hVUxrVnB6TUN3K1NheHJMREhQbUVWVFZRK3NIL1VsMDBHNW5ET1EzQno0UStSb21nRW4vZlpTaXIwZFh5ZmRlL1lSN0dKcHdyOUVPclVvdzFhVkxDVnZrbHM2T1o4Tk1NWEU9Cg==
TAURI_KEY_PASSWORD:
# upload assets
- uses: actions/upload-artifact@v2
if: matrix.platform == 'ubuntu-latest'

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT

View File

@@ -9,8 +9,8 @@ on:
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
LC_ALL: en_US.UTF-8 # This prevents strace from changing it's number format to use commas.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
@@ -34,72 +34,30 @@ jobs:
with:
toolchain: ${{ matrix.rust }}
override: true
default: true
components: rust-src
target: ${{ matrix.platform.target }}
- name: setup python
uses: actions/setup-python@v2
with:
python-version: '3.x'
python-version: '3.10'
architecture: x64
- name: install depedencies
- name: install dependencies
run: |
python -m pip install --upgrade pip
sudo apt-get update
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf xvfb
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev xvfb
wget https://github.com/sharkdp/hyperfine/releases/download/v1.11.0/hyperfine_1.11.0_amd64.deb
sudo dpkg -i hyperfine_1.11.0_amd64.deb
pip install memory_profiler
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache core cargo target
uses: actions/cache@v2
env:
cache-name: cargo_core
with:
path: target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-${{ matrix.rust }}-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-${{ matrix.rust }}-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}
${{ matrix.platform }}-${{ matrix.rust }}-${{ env.cache-name }}-
${{ matrix.platform }}-${{ matrix.rust }}-
${{ matrix.platform }}-
- name: cache cargo `tooling/bench/tests` target
uses: actions/cache@v2
env:
cache-name: cargo_benches
with:
path: tooling/bench/tests/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-${{ matrix.rust }}-${{ env.cache-name }}-${{ hashFiles('tooling/bench/tests/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-${{ matrix.rust }}-${{ env.cache-name }}-${{ hashFiles('tooling/bench/tests/Cargo.lock') }}
${{ matrix.platform }}-${{ matrix.rust }}-${{ env.cache-name }}-
${{ matrix.platform }}-${{ matrix.rust }}-
${{ matrix.platform }}-
workspaces: |
core -> ../target
tooling/bench/tests
- name: run benchmarks
run: |
@@ -126,7 +84,7 @@ jobs:
git commit --message "Update Tauri benchmarks"
git push origin gh-pages
- name: Worker info
- name: Print worker info
run: |
cat /proc/cpuinfo
cat /proc/meminfo

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT

View File

@@ -0,0 +1,91 @@
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
name: Check generated files
on:
pull_request:
paths:
- '.github/workflows/check-generated-files.yml'
- 'tooling/api/src/**'
- 'core/tauri/scripts/bundle.global.js'
- 'core/tauri-utils/src/config.rs'
- 'tooling/cli/schema.json'
- 'core/config-schema/schema.json'
push:
paths:
- '.github/workflows/check-generated-files.yml'
- 'tooling/api/src/**'
- 'core/tauri/scripts/bundle.global.js'
- 'core/tauri-utils/src/config.rs'
- 'tooling/cli/schema.json'
- 'core/config-schema/schema.json'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
changes:
runs-on: ubuntu-latest
outputs:
bundle: ${{ steps.filter.outputs.bundle }}
schema: ${{ steps.filter.outputs.schema }}
steps:
- uses: actions/checkout@v2
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
bundle:
- 'tooling/api/src/**'
- 'core/tauri/scripts/bundle.global.js'
schema:
- 'core/tauri-utils/src/config.rs'
- 'tooling/cli/schema.json'
- 'core/config-schema/schema.json'
check-bundle:
runs-on: ubuntu-latest
needs: changes
if: needs.changes.outputs.bundle == 'true'
steps:
- uses: actions/checkout@v2
- name: generate bundle
working-directory: tooling/api
run: yarn && yarn build
- name: check bundle
run: ./.scripts/ci/has-diff.sh
check-schema:
runs-on: ubuntu-latest
needs: changes
if: needs.changes.outputs.schema == 'true'
steps:
- uses: actions/checkout@v2
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: install Linux dependencies
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- uses: Swatinem/rust-cache@v2
with:
workspaces: core -> ../target
- name: generate schema.json
uses: actions-rs/cargo@v1
with:
command: build
args: --manifest-path ./core/config-schema/Cargo.toml
- name: check schema
run: ./.scripts/ci/has-diff.sh

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
@@ -16,8 +16,7 @@ jobs:
strategy:
fail-fast: false
matrix:
# platform: [ubuntu-latest, macos-latest, windows-latest]
platform: [ubuntu-latest, macos-latest]
platform: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v2
@@ -31,61 +30,13 @@ jobs:
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev libfuse2
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache core cargo target
uses: actions/cache@v2
env:
cache-name: cargo_core
with:
path: target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache CLI cargo target
uses: actions/cache@v2
env:
cache-name: cargo_cli
with:
path: tooling/cli/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
workspaces: |
core -> ../target
tooling/cli
- name: build CLI
uses: actions-rs/cargo@v1
@@ -96,6 +47,14 @@ jobs:
- name: run integration tests
run: cargo test --test '*' -- --ignored
- name: run CLI tests
timeout-minutes: 30
run: |
cd ./tooling/cli/node
yarn
yarn build
yarn test
version-or-publish:
runs-on: ubuntu-latest
timeout-minutes: 65
@@ -118,7 +77,7 @@ jobs:
cache-dependency-path: tooling/*/yarn.lock
- name: cargo login
run: cargo login ${{ secrets.crate_token }}
run: cargo login ${{ secrets.ORG_CRATES_IO_TOKEN }}
- name: git config
run: |
git config --global user.name "${{ github.event.pusher.name }}"
@@ -128,7 +87,7 @@ jobs:
uses: jbolda/covector/packages/action@covector-v0
id: covector
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.ORG_NPM_TOKEN }}
CARGO_AUDIT_OPTIONS: ${{ secrets.CARGO_AUDIT_OPTIONS }}
with:
token: ${{ secrets.GITHUB_TOKEN }}
@@ -137,7 +96,7 @@ jobs:
- name: Create Pull Request With Versions Bumped
if: steps.covector.outputs.commandRan == 'version'
uses: tauri-apps/create-pull-request@v3.4.1
uses: tauri-apps/create-pull-request@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: release/version-updates
@@ -147,10 +106,12 @@ jobs:
body: ${{ steps.covector.outputs.change }}
- name: Trigger doc update
if: steps.covector.outputs.successfulPublish == 'true'
if: |
steps.covector.outputs.successfulPublish == 'true' &&
steps.covector.outputs.packagesPublished != ''
uses: peter-evans/repository-dispatch@v1
with:
token: ${{ secrets.TAURI_BOT_PAT }}
token: ${{ secrets.ORG_TAURI_BOT_PAT }}
repository: tauri-apps/tauri-docs
event-type: update-docs
@@ -160,6 +121,17 @@ jobs:
contains(steps.covector.outputs.packagesPublished, 'cli.rs')
uses: peter-evans/repository-dispatch@v1
with:
token: ${{ secrets.TAURI_BOT_PAT }}
token: ${{ secrets.ORG_TAURI_BOT_PAT }}
repository: tauri-apps/tauri
event-type: publish-clijs
client-payload: '{"releaseId": "${{ steps.covector.outputs.cli.js-releaseId }}" }'
- name: Trigger cli.rs publishing workflow
if: |
steps.covector.outputs.successfulPublish == 'true' &&
contains(steps.covector.outputs.packagesPublished, 'cli.rs')
uses: peter-evans/repository-dispatch@v1
with:
token: ${{ secrets.ORG_TAURI_BOT_PAT }}
repository: tauri-apps/tauri
event-type: publish-clirs

133
.github/workflows/docker.yml vendored Normal file
View File

@@ -0,0 +1,133 @@
name: docker
on:
workflow_dispatch:
#pull_request:
# paths:
# - '.docker/**'
# - '.github/workflows/docker.yml'
jobs:
setup:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: install Linux dependencies
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- name: install cross
run: cargo install cross --git https://github.com/cross-rs/cross
- name: Upload cross
uses: actions/upload-artifact@v3
with:
name: cross
path: '~/.cargo/bin/cross'
if-no-files-found: error
- name: build CLI
uses: actions-rs/cargo@v1
with:
command: build
args: --manifest-path ./tooling/cli/Cargo.toml
- name: Upload CLI
uses: actions/upload-artifact@v3
with:
name: cargo-tauri
path: tooling/cli/target/debug/cargo-tauri
if-no-files-found: error
docker:
needs: setup
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
target:
- { name: 'aarch64-unknown-linux-gnu', filename: 'aarch64' }
steps:
- name: Checkout
uses: actions/checkout@v3
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
default: true
target: ${{ matrix.target.name }}
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 16
- name: Download cross
uses: actions/download-artifact@v3
with:
name: cross
path: '~/.cargo/bin'
- name: Download CLI
uses: actions/download-artifact@v3
with:
name: cargo-tauri
path: 'examples/api'
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and export to Docker
uses: docker/build-push-action@v3
with:
context: .docker/cross
file: .docker/cross/${{ matrix.target.filename }}.Dockerfile
load: true
tags: ${{ matrix.target.name }}:latest
- name: install dependencies
run: |
sudo apt-get update
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev
- name: Test
run: |
cd tooling/api
yarn && yarn build
cd ../../examples/api
yarn
. .setup-cross.sh
chmod +x cargo-tauri
chmod +x $HOME/.cargo/bin/cross
./cargo-tauri build --runner cross --bundles deb --target ${{ matrix.target.name }} --verbose
- name: Build and push
uses: docker/build-push-action@v3
with:
context: .docker/cross
file: .docker/cross/${{ matrix.target.filename }}.Dockerfile
push: true
tags: ghcr.io/${{ github.repository }}/${{ matrix.target.name }}:latest

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
@@ -16,7 +16,6 @@ on:
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
@@ -33,7 +32,7 @@ jobs:
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
toolchain: stable
override: true
components: rustfmt
@@ -55,44 +54,14 @@ jobs:
override: true
components: clippy
- name: install Linux dependencies
- name: install dependencies
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
ubuntu-latest-stable-${{ env.cache-name }}-
ubuntu-latest-stable-
ubuntu-latest-
- name: Cache CLI cargo target
uses: actions/cache@v2
env:
cache-name: cargo_cli
with:
path: tooling/cli/target
# Add date to the cache to keep it up to date
key: ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}
ubuntu-latest-stable-${{ env.cache-name }}-
ubuntu-latest-stable-
ubuntu-latest-
workspaces: tooling/cli
- uses: actions-rs/clippy-check@v1
with:

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
@@ -13,11 +13,11 @@ on:
paths:
- '.github/workflows/lint-fmt-core.yml'
- 'core/**'
- '!core/tauri/scripts/**'
- 'examples/**'
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
@@ -34,7 +34,7 @@ jobs:
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
toolchain: stable
override: true
components: rustfmt
@@ -50,7 +50,7 @@ jobs:
clippy:
- { args: '', key: 'empty' }
- {
args: '--features compression,wry,isolation,custom-protocol,api-all,cli,updater,system-tray,http-multipart',
args: '--features compression,wry,linux-protocol-headers,isolation,custom-protocol,api-all,cli,updater,system-tray,windows7-compat,http-multipart',
key: 'all'
}
- { args: '--features custom-protocol', key: 'custom-protocol' }
@@ -58,10 +58,11 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: install webkit2gtk
- name: install dependencies
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev
- uses: actions-rs/toolchain@v1
with:
@@ -70,44 +71,10 @@ jobs:
override: true
components: clippy
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
ubuntu-latest-stable-${{ env.cache-name }}-
ubuntu-latest-stable-
ubuntu-latest-
- name: Cache core cargo target
uses: actions/cache@v2
env:
cache-name: cargo_core
with:
path: target
# Add date to the cache to keep it up to date
key: ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
ubuntu-latest-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}
ubuntu-latest-stable-${{ env.cache-name }}-
ubuntu-latest-stable-
ubuntu-latest-
workspaces: core -> ../target
save-if: ${{ matrix.clippy.key == 'all' }}
- uses: actions-rs/clippy-check@v1
with:

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
@@ -22,7 +22,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '12'
node-version: '14'
cache: yarn
cache-dependency-path: tooling/*/yarn.lock
- name: install cli.js deps via yarn

View File

@@ -5,6 +5,10 @@ env:
MACOSX_DEPLOYMENT_TARGET: '10.13'
on:
workflow_dispatch:
inputs:
releaseId:
description: 'ID of the cli.js release'
required: true
repository_dispatch:
types: [publish-clijs]
@@ -194,7 +198,6 @@ jobs:
- host: windows-latest
target: x86_64-pc-windows-msvc
node:
- '12'
- '14'
- '16'
- '18'
@@ -228,7 +231,6 @@ jobs:
fail-fast: false
matrix:
node:
- '12'
- '14'
- '16'
- '18'
@@ -255,7 +257,7 @@ jobs:
- name: install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev
- name: Test bindings
run: yarn test
test-linux-x64-musl-binding:
@@ -266,7 +268,6 @@ jobs:
fail-fast: false
matrix:
node:
- '12'
- '14'
- '16'
- '18'
@@ -294,7 +295,7 @@ jobs:
shell: bash
- name: Install system dependencies
run: |
apk add openssl-dev musl-dev glib-dev cairo-dev pkgconfig gdk-pixbuf-dev webkit2gtk-dev curl libappindicator-dev patchelf librsvg-dev gtk+3.0-dev
apk add openssl-dev musl-dev glib-dev cairo-dev pkgconfig gdk-pixbuf-dev webkit2gtk-dev curl libappindicator-dev gtk+3.0-dev
- name: Setup and run tests
run: |
yarn tauri --help
@@ -314,7 +315,6 @@ jobs:
fail-fast: false
matrix:
node:
- '12'
- '14'
- '16'
- '18'
@@ -351,7 +351,7 @@ jobs:
set -e
export PATH=/usr/local/cargo/bin/:/usr/local/fnm:$PATH
apt-get update
DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get install --no-install-recommends -y unzip libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get install --no-install-recommends -y unzip webkit2gtk-4.0 libayatana-appindicator3-dev
bash
curl https://sh.rustup.rs -sSf | bash -s -- -y
curl -fsSL https://fnm.vercel.app/install | bash -s -- --install-dir "/usr/local/fnm" --skip-shell
@@ -396,4 +396,5 @@ jobs:
npm publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NPM_TOKEN: ${{ secrets.ORG_NPM_TOKEN }}
RELEASE_ID: ${{ github.event.client_payload.releaseId || github.event.inputs.releaseId }}

82
.github/workflows/publish-cli-rs.yml vendored Normal file
View File

@@ -0,0 +1,82 @@
name: publish cli.rs
env:
MACOSX_DEPLOYMENT_TARGET: '10.13'
on:
workflow_dispatch:
repository_dispatch:
types: [publish-clirs]
jobs:
build:
runs-on: ${{ matrix.target.platform }}
strategy:
fail-fast: false
matrix:
target:
- {
name: 'x86_64-unknown-linux-gnu',
platform: 'ubuntu-18.04',
ext: ''
}
- { name: 'x86_64-apple-darwin', platform: 'macos-latest', ext: '' }
- {
name: 'x86_64-pc-windows-msvc',
platform: 'windows-latest',
ext: '.exe'
}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: install Linux dependencies
if: matrix.target.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- name: build CLI
uses: actions-rs/cargo@v1
with:
command: build
args: --manifest-path ./tooling/cli/Cargo.toml --release
- name: Upload CLI
uses: actions/upload-artifact@v3
with:
name: cargo-tauri-${{ matrix.target.name }}${{ matrix.target.ext }}
path: tooling/cli/target/release/cargo-tauri${{ matrix.target.ext }}
if-no-files-found: error
upload:
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download built CLIs
uses: actions/download-artifact@v3
with:
path: outputs
- name: Pack archives
run: ./.scripts/ci/pack-cli.sh
- name: Get CLI version
run: echo "CLI_VERSION=$(cat tooling/cli/metadata.json | jq '."cli.js".version' -r)" >> $GITHUB_ENV
- name: Publish release
uses: softprops/action-gh-release@50195ba7f6f93d1ac97ba8332a178e008ad176aa
with:
tag_name: cli.rs-v${{ env.CLI_VERSION }}
files: |
outputs/cargo-tauri-*.zip
outputs/cargo-tauri-*.tgz

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
@@ -16,7 +16,6 @@ on:
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
@@ -34,49 +33,15 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache bundler cargo target
uses: actions/cache@v2
env:
cache-name: cargo_bundler
with:
path: tooling/bundler/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/bundler/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/bundler/Cargo.lock') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
workspaces: tooling/bundler
- name: test
run: |
@@ -92,7 +57,7 @@ jobs:
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
toolchain: stable
override: true
components: rustfmt
@@ -106,52 +71,19 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: install minimal stable with clippy and rustfmt
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
default: true
components: rustfmt, clippy
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache bundler cargo target
uses: actions/cache@v2
env:
cache-name: cargo_bundler
with:
path: tooling/bundler/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/bundler/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/bundler/Cargo.lock') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
workspaces: tooling/bundler
- name: clippy check
uses: actions-rs/clippy-check@v1

68
.github/workflows/test-cli-js.yml vendored Normal file
View File

@@ -0,0 +1,68 @@
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
name: test cli.js
on:
push:
branches:
- dev
- next
pull_request:
paths:
- '.github/workflows/test-cli-js.yml'
# currently cli.js only tests the template
- 'tooling/cli/templates/app/**'
env:
RUST_BACKTRACE: 1
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test-tauri-js-cli:
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v2
- name: install Rust stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: setup node
uses: actions/setup-node@v2
with:
node-version: 14
cache: yarn
cache-dependency-path: tooling/cli/node/yarn.lock
- name: install Linux dependencies
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev
- uses: Swatinem/rust-cache@v2
with:
workspaces: |
tooling/cli
tooling/cli/node/test/jest/fixtures/empty/src-tauri
- name: test
timeout-minutes: 30
run: |
cd ./tooling/cli/node
yarn
yarn build
yarn test

57
.github/workflows/test-cli-rs.yml vendored Normal file
View File

@@ -0,0 +1,57 @@
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
name: test cli.rs
on:
push:
branches:
- dev
- next
pull_request:
paths:
- '.github/workflows/test-cli-rs.yml'
- 'tooling/cli/**'
env:
RUST_BACKTRACE: 1
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test-tauri-cli:
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v2
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: install Linux dependencies
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- uses: Swatinem/rust-cache@v2
with:
workspaces: tooling/cli
- name: build CLI
uses: actions-rs/cargo@v1
with:
command: build
args: --manifest-path ./tooling/cli/Cargo.toml

View File

@@ -1,182 +0,0 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
name: test CLI
on:
push:
branches:
- dev
- next
pull_request:
paths:
- '.github/workflows/test-cli.yml'
- 'tooling/cli/**'
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test-tauri-cli:
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v2
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: install Linux dependencies
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache CLI cargo target
uses: actions/cache@v2
env:
cache-name: cargo_cli
with:
path: tooling/cli/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: build CLI
uses: actions-rs/cargo@v1
with:
command: build
args: --manifest-path ./tooling/cli/Cargo.toml
test-tauri-js-cli:
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v2
- name: install Rust stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: setup node
uses: actions/setup-node@v2
with:
node-version: 14
cache: yarn
cache-dependency-path: tooling/cli/node/yarn.lock
- name: install Linux dependencies
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache CLI cargo target
uses: actions/cache@v2
env:
cache-name: cargo_cli
with:
path: tooling/cli/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache template cargo target
uses: actions/cache@v2
env:
cache-name: cargo_template
with:
path: tooling/cli/node/test/jest/fixtures/empty/src-tauri/target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/templates/app/**') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('tooling/cli/templates/app/**') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: test
timeout-minutes: 30
run: |
cd ./tooling/cli/node
yarn
yarn build
yarn test

View File

@@ -1,4 +1,4 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
@@ -13,12 +13,10 @@ on:
paths:
- '.github/workflows/test-core.yml'
- 'core/**'
- 'examples/**'
- 'tooling/cli/**'
- '!core/tauri/scripts/**'
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
@@ -27,66 +25,62 @@ concurrency:
jobs:
test-tauri-core:
runs-on: ${{ matrix.platform }}
runs-on: ${{ matrix.platform.os }}
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, macos-latest, windows-latest]
platform:
- {
target: x86_64-pc-windows-msvc,
os: windows-latest,
toolchain: '1.61.0'
}
- {
target: x86_64-unknown-linux-gnu,
os: ubuntu-latest,
toolchain: '1.59.0'
}
- {
target: x86_64-apple-darwin,
os: macos-latest,
toolchain: '1.59.0'
}
features:
- {
args: --no-default-features,
key: no-default
}
- {
args: --features api-all,
key: api-all
}
- {
args: --features compression,wry,linux-protocol-headers,isolation,custom-protocol,api-all,cli,updater,system-tray,windows7-compat,http-multipart,
key: all
}
steps:
- uses: actions/checkout@v2
- name: install stable
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: ${{ matrix.platform.toolchain }}
target: ${{ matrix.platform.target }}
override: true
default: true
- name: install Linux dependencies
if: matrix.platform == 'ubuntu-latest'
if: contains(matrix.platform.target, 'unknown-linux')
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
if: matrix.platform == 'macos-latest' || matrix.platform == 'ubuntu-latest'
- name: Get current date
if: matrix.platform == 'windows-latest'
run: echo "CURRENT_DATE=$(Get-Date -Format "yyyy-MM-dd")" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
- uses: Swatinem/rust-cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
- name: Cache core cargo target
uses: actions/cache@v2
env:
cache-name: cargo_core
with:
path: target
# Add date to the cache to keep it up to date
key: ${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
${{ matrix.platform }}-stable-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}
${{ matrix.platform }}-stable-${{ env.cache-name }}-
${{ matrix.platform }}-stable-
${{ matrix.platform }}-
workspaces: core -> ../target
save-if: ${{ matrix.features.key == 'all' }}
- name: test
run: |
cargo test
cargo test --features api-all
cargo test --features compression,wry,isolation,custom-protocol,api-all,cli,updater,system-tray,http-multipart
run: cargo test --target ${{ matrix.platform.target }} ${{ matrix.features.args }}

View File

@@ -1,20 +1,17 @@
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
name: Udeps
on:
pull_request:
paths:
- '.github/workflows/udeps.yml'
- 'core/**'
- 'tooling/bundler/**'
- 'tooling/cli/**'
push:
branches:
- dev
- next
env:
RUST_BACKTRACE: 1
CARGO_INCREMENTAL: 0 # This is set to 0 by the https://github.com/Swatinem/rust-cache
CARGO_PROFILE_DEV_DEBUG: 0 # This would add unnecessary bloat to the target folder, decreasing cache efficiency.
concurrency:
@@ -22,26 +19,58 @@ concurrency:
cancel-in-progress: true
jobs:
udeps:
changes:
runs-on: ubuntu-latest
strategy:
matrix:
clippy:
- {
path: './core/tauri/Cargo.toml',
args: '--features compression,wry,isolation,custom-protocol,api-all,cli,updater,system-tray,http-multipart'
}
- { path: './core/tauri-build/Cargo.toml', args: '--all-features' }
- { path: './core/tauri-codegen/Cargo.toml', args: '--all-features' }
- { path: './core/tauri-macros/Cargo.toml', args: '--all-features' }
- { path: './core/tauri-runtime/Cargo.toml', args: '--all-features' }
- {
path: './core/tauri-runtime-wry/Cargo.toml',
args: '--features devtools,system-tray,macos-private-api,objc-exception'
}
- { path: './core/tauri-utils/Cargo.toml', args: '--all-features' }
- { path: './tooling/bundler/Cargo.toml', args: '--all-features' }
- { path: './tooling/cli/Cargo.toml', args: '--all-features' }
outputs:
tauri: ${{ steps.filter.outputs.tauri }}
build: ${{ steps.filter.outputs.build }}
codegen: ${{ steps.filter.outputs.codegen }}
macros: ${{ steps.filter.outputs.macros }}
runtime: ${{ steps.filter.outputs.runtime }}
wry: ${{ steps.filter.outputs.wry }}
utils: ${{ steps.filter.outputs.utils }}
bundler: ${{ steps.filter.outputs.bundler }}
cli: ${{ steps.filter.outputs.cli }}
steps:
- uses: actions/checkout@v2
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
tauri:
- 'core/tauri/**'
- '!core/tauri/scripts/**'
build:
- 'core/tauri-build/**'
codegen:
- 'core/tauri-codegen/**'
macros:
- 'core/tauri-macros/**'
runtime:
- 'core/tauri-runtime/**'
wry:
- 'core/tauri-runtime-wry/**'
utils:
- 'core/tauri-utils/**'
bundler:
- 'tooling/bundler/**'
cli:
- 'tooling/cli/**'
setup:
runs-on: ubuntu-latest
needs: changes
if: |
needs.changes.outputs.tauri == 'true' ||
needs.changes.outputs.build == 'true' ||
needs.changes.outputs.codegen == 'true' ||
needs.changes.outputs.macros == 'true' ||
needs.changes.outputs.runtime == 'true' ||
needs.changes.outputs.wry == 'true' ||
needs.changes.outputs.utils == 'true' ||
needs.changes.outputs.bundler == 'true' ||
needs.changes.outputs.cli == 'true'
steps:
- uses: actions/checkout@v2
@@ -51,86 +80,86 @@ jobs:
toolchain: nightly
override: true
- name: install Linux dependencies
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- name: Get current date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- name: Cache cargo state
uses: actions/cache@v2
env:
cache-name: cargo_state
with:
path: |
~/.cargo/registry
~/.cargo/git
~/.cargo/bin
key: ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
restore-keys: |
ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('**/Cargo.toml') }}-
ubuntu-latest-nightly-${{ env.cache-name }}-
ubuntu-latest-nightly-
ubuntu-latest-
- name: Cache core cargo target
uses: actions/cache@v2
env:
cache-name: cargo_core
with:
path: target
# Add date to the cache to keep it up to date
key: ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('core/**/Cargo.toml') }}
ubuntu-latest-nightly-${{ env.cache-name }}-
ubuntu-latest-nightly-
ubuntu-latest-
- name: Cache bundler cargo target
uses: actions/cache@v2
env:
cache-name: cargo_bundler
with:
path: tooling/bundler/target
# Add date to the cache to keep it up to date
key: ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('tooling/bundler/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('tooling/bundler/Cargo.lock') }}
ubuntu-latest-nightly-${{ env.cache-name }}-
ubuntu-latest-nightly-
ubuntu-latest-
- name: Cache CLI cargo target
uses: actions/cache@v2
env:
cache-name: cargo_cli
with:
path: tooling/cli/target
# Add date to the cache to keep it up to date
key: ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}-${{ env.CURRENT_DATE }}
# Restore from outdated cache for speed
restore-keys: |
ubuntu-latest-nightly-${{ env.cache-name }}-${{ hashFiles('tooling/cli/Cargo.lock') }}
ubuntu-latest-nightly-${{ env.cache-name }}-
ubuntu-latest-nightly-
ubuntu-latest-
- uses: actions-rs/cargo@v1
with:
command: install
args: cargo-udeps --locked --force
- name: Upload udeps
uses: actions/upload-artifact@v3
with:
name: udeps
path: '~/.cargo/bin/cargo-udeps'
if-no-files-found: error
- name: Create udeps matrix
id: create-matrix
env:
TAURI: ${{ needs.changes.outputs.tauri == 'true' }}
BUILD: ${{ needs.changes.outputs.build == 'true' }}
CODEGEN: ${{ needs.changes.outputs.codegen == 'true' }}
MACROS: ${{ needs.changes.outputs.macros == 'true' }}
RUNTIME: ${{ needs.changes.outputs.runtime == 'true' }}
WRY: ${{ needs.changes.outputs.wry == 'true' }}
UTILS: ${{ needs.changes.outputs.utils == 'true' }}
BUNDLER: ${{ needs.changes.outputs.bundler == 'true' }}
CLI: ${{ needs.changes.outputs.cli == 'true' }}
run: |
crates=()
if [ "${TAURI}" == "true" ]; then crates[${#crates[@]}]="\"./core/tauri\""; fi
if [ "${BUILD}" == "true" ]; then crates[${#crates[@]}]="\"./core/tauri-build\""; fi
if [ "${CODEGEN}" == "true" ]; then crates[${#crates[@]}]="\"./core/tauri-codegen\""; fi
if [ "${MACROS}" == "true" ]; then crates[${#crates[@]}]="\"./core/tauri-macros\""; fi
if [ "${RUNTIME}" == "true" ]; then crates[${#crates[@]}]="\"./core/tauri-runtime\""; fi
if [ "${WRY}" == "true" ]; then crates[${#crates[@]}]="\"./core/tauri-runtime-wry\""; fi
if [ "${UTILS}" == "true" ]; then crates[${#crates[@]}]="\"./core/tauri-utils\""; fi
if [ "${BUNDLER}" == "true" ]; then crates[${#crates[@]}]="\"./tooling/bundler\""; fi
if [ "${CLI}" == "true" ]; then crates[${#crates[@]}]="\"./tooling/cli\""; fi
echo ::set-output name=matrix::[$crates]
outputs:
matrix: ${{ steps.create-matrix.outputs.matrix }}
udeps:
runs-on: ubuntu-latest
needs: setup
strategy:
matrix:
path: ${{ fromJson(needs.setup.outputs.matrix) }}
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: true
- name: install dependencies
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev
- uses: Swatinem/rust-cache@v2
with:
workspaces: |
core -> ../target
tooling/cli
tooling/bundler
- name: Download udeps
uses: actions/download-artifact@v3
with:
name: udeps
path: '~/.cargo/bin'
- run: chmod +x $HOME/.cargo/bin/cargo-udeps
- name: Install required packages
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libayatana-appindicator3-dev librsvg2-dev patchelf
sudo apt-get install -y webkit2gtk-4.0 libayatana-appindicator3-dev
- uses: actions-rs/cargo@v1
with:
command: udeps
args: --manifest-path ${{ matrix.clippy.path }} --all-targets ${{ matrix.clippy.args }}
args: --manifest-path ${{ matrix.path }}/Cargo.toml --all-targets --all-features

View File

@@ -1,6 +1,6 @@
#!/bin/sh
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT

View File

@@ -1,3 +0,0 @@
// Copyright {20\d{2}(-20\d{2})?} Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT

12
.prettierignore Normal file
View File

@@ -0,0 +1,12 @@
/.github
/.husky
/.vscode
/audits
node_modules
target
dist
/core/tauri/scripts
/tooling/cli/templates
/tooling/cli/node
/tooling/cli/schema.json
/core/config-schema/schema.json

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env sh
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT

9
.scripts/ci/has-diff.sh Executable file
View File

@@ -0,0 +1,9 @@
#!/bin/bash
if git diff --quiet --ignore-submodules HEAD
then
echo "working directory is clean"
else
echo "found diff"
exit 1
fi

18
.scripts/ci/pack-cli.sh Executable file
View File

@@ -0,0 +1,18 @@
#!/bin/bash
set -euxo pipefail
for o in outputs/*; do
pushd "$o"
chmod +x cargo-tauri*
cp ../../tooling/cli/LICENSE* ../../tooling/cli/README.md .
target=$(basename "$o" | cut -d. -f1)
if grep -qE '(apple|windows)' <<< "$target"; then
zip "../${target}.zip" *
else
tar cv * | gzip -9 > "../${target}.tgz"
fi
popd
done

View File

@@ -0,0 +1,54 @@
#!/usr/bin/env node
// Copyright 2019-2022 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
/*
This script is solely intended to be run as part of the `covector publish` step to
check the latest version of a crate, considering the current minor version.
*/
const https = require('https')
const kind = process.argv[2]
const packageName = process.argv[3]
const packageVersion = process.argv[4]
const target = packageVersion.substring(0, packageVersion.lastIndexOf('.'))
let url = null
switch (kind) {
case 'cargo':
url = `https://crates.io/api/v1/crates/${packageName}`
break;
case 'npm':
url = `https://registry.npmjs.org/${packageName}`
break;
default:
throw new Error('unexpected kind ' + kind)
}
const options = {
headers: {
'Content-Type': 'application/json',
'Accept': 'application/json',
'User-Agent': 'tauri (https://github.com/tauri-apps/tauri)'
}
}
https.get(url, options, (response) => {
let chunks = []
response.on('data', function (chunk) {
chunks.push(chunk)
})
response.on('end', function () {
const data = JSON.parse(chunks.join(''))
if (kind === 'cargo') {
const versions = data.versions.filter(v => v.num.startsWith(target))
console.log(versions.length ? versions[0].num : '0.0.0')
} else if (kind === 'npm') {
const versions = Object.keys(data.versions).filter(v => v.startsWith(target))
console.log(versions[versions.length - 1] || '0.0.0')
}
})
})

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env node
// Copyright 2019-2021 Tauri Programme within The Commons Conservancy
// Copyright 2019-2022 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
@@ -10,34 +10,39 @@ we should look to find a more "rusty way" to import / "pin" a version value in o
rust binaries.
*/
const {
readFileSync,
writeFileSync
} = require('fs')
const { readFileSync, writeFileSync } = require('fs')
const packageNickname = process.argv[2]
const filePath = packageNickname === 'cli.js' ? `../../../tooling/cli/metadata.json` : `../../tooling/cli/metadata.json`
const filePath =
packageNickname === 'cli.js'
? `../../../tooling/cli/metadata.json`
: `../../tooling/cli/metadata.json`
const bump = process.argv[3]
let index = null
switch (bump) {
case 'major':
index = 0;
break;
index = 0
break
case 'minor':
index = 1;
break;
index = 1
break
case 'patch':
index = 2;
break;
index = 2
break
default:
throw new Error('unexpected bump ' + bump)
}
const inc = (version) => {
const v = version.split('.')
const n = v[index]
v[index] = String(Number(n) + 1)
for (let i = 0; i < v.length; i++) {
if (i === index) {
v[i] = String(Number(v[i]) + 1)
} else if (i > index) {
v[i] = 0
}
}
return v.join('.')
}

View File

@@ -1,62 +0,0 @@
#!/usr/bin/env node
// Copyright 2019-2021 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
/*
This script is solely intended to be run as part of the `covector version` step to
keep the `tauri-runtime`, `tauri-runtime-wry` and `tauri-driver` crates version without the `beta` or `rc` suffix.
*/
const {
readFileSync,
writeFileSync
} = require('fs')
const packageNickname = process.argv[2]
const bump = process.argv[3]
let manifestPath
let dependencyManifestPaths
let changelogPath
if (packageNickname === 'tauri-runtime') {
manifestPath = '../../core/tauri-runtime/Cargo.toml'
dependencyManifestPaths = [
'../../core/tauri/Cargo.toml',
'../../core/tauri-runtime-wry/Cargo.toml'
]
changelogPath = '../../core/tauri-runtime/CHANGELOG.md'
} else if (packageNickname === 'tauri-runtime-wry') {
manifestPath = '../../core/tauri-runtime-wry/Cargo.toml'
dependencyManifestPaths = ['../../core/tauri/Cargo.toml']
changelogPath = '../../core/tauri-runtime-wry/CHANGELOG.md'
} else if (packageNickname === 'tauri-driver') {
manifestPath = '../../tooling/webdriver/Cargo.toml'
dependencyManifestPaths = []
changelogPath = '../../tooling/webdriver/CHANGELOG.md'
} else {
throw new Error(`Unexpected package ${packageNickname}`)
}
let manifest = readFileSync(manifestPath, 'utf-8')
manifest = manifest.replace(
/version = "(\d+\.\d+\.\d+)-[^0-9\.]+\.0"/,
'version = "$1"'
)
writeFileSync(manifestPath, manifest)
let changelog = readFileSync(changelogPath, 'utf-8')
changelog = changelog.replace(/(\d+\.\d+\.\d+)-[^0-9\.]+\.0/, '$1')
writeFileSync(changelogPath, changelog)
for (const dependencyManifestPath of dependencyManifestPaths) {
let dependencyManifest = readFileSync(dependencyManifestPath, 'utf-8')
dependencyManifest = dependencyManifest.replace(
new RegExp(
packageNickname + ' = { version = "(\\d+\\.\\d+.\\d+)-[^0-9.]+.0"'
),
`${packageNickname} = { version = "$1"`
)
writeFileSync(dependencyManifestPath, dependencyManifest)
}

3
.scripts/docker/build.sh Executable file
View File

@@ -0,0 +1,3 @@
#!/bin/sh
docker build -t aarch64-unknown-linux-gnu:latest --file .docker/cross/aarch64.Dockerfile .docker/cross

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env pwsh
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT

View File

@@ -1,5 +1,5 @@
#!/usr/bin/env bash
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT

View File

@@ -1,9 +1,9 @@
#!/usr/bin/env sh
# Copyright 2019-2021 Tauri Programme within The Commons Conservancy
# Copyright 2019-2022 Tauri Programme within The Commons Conservancy
# SPDX-License-Identifier: Apache-2.0
# SPDX-License-Identifier: MIT
declare -a examples=("api" "sidecar" "updater" "resources" "tauri-dynamic-lib")
declare -a examples=("api" "sidecar" "updater" "resources" "tauri-dynamic-lib" "workspace")
declare -a tooling=("bench" "cli" "webdriver")
for example in "${examples[@]}"

View File

@@ -1,6 +1,6 @@
@ECHO OFF
REM Copyright 2019-2021 Tauri Programme within The Commons Conservancy
REM Copyright 2019-2022 Tauri Programme within The Commons Conservancy
REM SPDX-License-Identifier: Apache-2.0
REM SPDX-License-Identifier: MIT
@@ -59,4 +59,4 @@ IF EXIST %SourceFiles% DEL %SourceFiles%
IF EXIST %Config% DEL %Config%
IF EXIST %Source7ZFile% DEL %Source7ZFile%
ENDLOCAL
ENDLOCAL

View File

@@ -1,5 +1,6 @@
# The Tauri Architecture
https://tauri.studio
https://tauri.app
https://github.com/tauri-apps/tauri
## Introduction
@@ -39,7 +40,7 @@ This is common code that is reused in many places and offers useful utilities li
### Tauri Tooling
#### [api](https://github.com/tauri-apps/tauri/tree/dev/tooling/api) [TS -> JS]
A typescript library that creates `cjs` and `esm` Javascript endpoints for you to import into your Frontend framework so that the Webview can call and listen to backend activity. We also ship the pure typescript, because for some frameworks this is more optimal. It uses the message passing of webviews to their hosts.
A TypeScript library that creates `cjs` and `esm` JavaScript endpoints for you to import into your Frontend framework so that the Webview can call and listen to backend activity. We also ship the pure TypeScript, because for some frameworks this is more optimal. It uses the message passing of webviews to their hosts.
#### [bundler](https://github.com/tauri-apps/tauri/tree/dev/tooling/bundler) [RUST / SHELL]
The bundler is a library that builds a Tauri App for the platform triple it detects / is told. At the moment it currently supports macOS, Windows and Linux - but in the near future will support mobile platforms as well. May be used outside of Tauri projects.
@@ -81,7 +82,7 @@ This plugin allows you to very quickly install tauri in a vue-cli project.
## [tauri-vscode](https://github.com/tauri-apps/tauri-vscode)
This project enhances the VS Code interface with several nice-to-have features.
# Tauri Plugins [documentation](https://tauri.studio/en/docs/guides/plugin)
# Tauri Plugins [documentation](https://tauri.app/v1/guides/features/plugin/)
Generally speaking, plugins are authored by third parties (even though there may be official, supported plugins). A plugin generally does 3 things:
1. It provides rust code to do "something".

View File

@@ -8,7 +8,8 @@ members = [
"core/tauri-utils",
"core/tauri-build",
"core/tauri-codegen",
"core/config-schema",
# integration tests
"core/tests/restart",
"core/tests/app-updater"
@@ -19,12 +20,13 @@ exclude = [
"examples/api/src-tauri",
"examples/updater/src-tauri",
"examples/resources/src-tauri",
"examples/sidecar/src-tauri"
"examples/sidecar/src-tauri",
"examples/web/core",
"examples/workspace"
]
# default to small, optimized workspace release binaries
[profile.release]
strip = true
panic = "abort"
codegen-units = 1
lto = true

View File

@@ -6,7 +6,7 @@ PackageSupplier: Organization: The Tauri Programme in the Commons Conservancy
PackageHomePage: https://tauri.app
PackageLicenseDeclared: Apache-2.0
PackageLicenseDeclared: MIT
PackageCopyrightText: 2019-2021, The Tauri Programme in the Commons Conservancy
PackageCopyrightText: 2019-2022, The Tauri Programme in the Commons Conservancy
PackageSummary: <text>Tauri is a rust project that enables developers to make secure
and small desktop applications using a web frontend.
</text>
@@ -17,4 +17,4 @@ Created: 2019-05-20T09:00:00Z
PackageDownloadLocation: git://github.com/tauri-apps/tauri
PackageDownloadLocation: git+https://github.com/tauri-apps/tauri.git
PackageDownloadLocation: git+ssh://github.com/tauri-apps/tauri.git
Creator: Person: Daniel Thompson-Yvetot
Creator: Person: Daniel Thompson-Yvetot

160
README.md
View File

@@ -1,29 +1,46 @@
<img src=".github/splash.png" alt="Tauri" />
[![status](https://img.shields.io/badge/Status-Beta-green.svg)](https://github.com/tauri-apps/tauri/tree/dev)
[![status](https://img.shields.io/badge/status-stable-blue.svg)](https://github.com/tauri-apps/tauri/tree/dev)
[![License](https://img.shields.io/badge/License-MIT%20or%20Apache%202-green.svg)](https://opencollective.com/tauri)
[![test library](https://img.shields.io/github/workflow/status/tauri-apps/tauri/test%20library?label=test%20library)](https://github.com/tauri-apps/tauri/actions?query=workflow%3A%22test+library%22)
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Ftauri-apps%2Ftauri.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Ftauri-apps%2Ftauri?ref=badge_shield)
[![Chat Server](https://img.shields.io/badge/chat-on%20discord-7289da.svg)](https://discord.gg/SpmNs4S)
[![devto](https://img.shields.io/badge/blog-dev.to-black.svg)](https://dev.to/tauri)
[![devto](https://img.shields.io/badge/documentation-tauri.studio-purple.svg)](https://tauri.studio/guides/getting-started/prerequisites/)
[![Chat Server](https://img.shields.io/badge/chat-discord-7289da.svg)](https://discord.gg/SpmNs4S)
[![website](https://img.shields.io/badge/website-tauri.app-purple.svg)](https://tauri.app)
[![https://good-labs.github.io/greater-good-affirmation/assets/images/badge.svg](https://good-labs.github.io/greater-good-affirmation/assets/images/badge.svg)](https://good-labs.github.io/greater-good-affirmation)
[![support](https://img.shields.io/badge/sponsor-open%20collective-blue.svg)](https://opencollective.com/tauri)
[![support](https://img.shields.io/badge/sponsor-Open%20Collective-blue.svg)](https://opencollective.com/tauri)
## Current Releases
| Component | Description | Version | Lin | Win | Mac |
| ------------------------------------------------------------------------------- | ---------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | --- | --- | --- |
| [**cli.rs**](https://github.com/tauri-apps/tauri/tree/dev/tooling/cli) | create, develop and build apps | [![](https://img.shields.io/crates/v/tauri-cli.svg)](https://crates.io/crates/tauri-cli) | ✅ | ✅ | ✅ |
| [**cli.js**](https://github.com/tauri-apps/tauri/tree/dev/tooling/cli/node) | Node.js CLI wrapper for cli.rs | [![](https://img.shields.io/npm/v/@tauri-apps/cli.svg)](https://www.npmjs.com/package/@tauri-apps/cli) | ✅ | ✅ | ✅ |
| [**api.js**](https://github.com/tauri-apps/tauri/tree/dev/tooling/api) | JS API for interaction with Rust backend | [![](https://img.shields.io/npm/v/@tauri-apps/api.svg)](https://www.npmjs.com/package/@tauri-apps/api) | ✅ | ✅ | ✅ |
| [**create-tauri-app**](https://github.com/tauri-apps/create-tauri-app) | Get started with your first Tauri app | [![](https://img.shields.io/npm/v/create-tauri-app.svg)](https://www.npmjs.com/package/create-tauri-app) | ✅ | ✅ | ✅ |
| [**vue-cli-plugin-tauri**](https://github.com/tauri-apps/vue-cli-plugin-tauri/) | Vue CLI plugin for Tauri | [![](https://img.shields.io/npm/v/vue-cli-plugin-tauri.svg)](https://www.npmjs.com/package/vue-cli-plugin-tauri) | ✅ | ✅ | ✅ |
| [**core**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri) | runtime core | [![](https://img.shields.io/crates/v/tauri.svg)](https://crates.io/crates/tauri) | ✅ | ✅ | ✅ |
| [**bundler**](https://github.com/tauri-apps/tauri/tree/dev/tooling/bundler) | manufacture the final binaries | [![](https://img.shields.io/crates/v/tauri-bundler.svg)](https://crates.io/crates/tauri-bundler) | ✅ | ✅ | ✅ |
### Core
| Component | Description | Version | Lin | Win | Mac |
| -------------------------------------------------------------------------------------------- | ----------------------------------------- | -------------------------------------------------------------------------------------------------------- | --- | --- | --- |
| [**tauri**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri) | runtime core | [![](https://img.shields.io/crates/v/tauri.svg)](https://crates.io/crates/tauri) | ✅ | ✅ | ✅ |
| [**tauri-build**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri-build) | applies macros at build-time | [![](https://img.shields.io/crates/v/tauri-build.svg)](https://crates.io/crates/tauri-build) | ✅ | ✅ | ✅ |
| [**tauri-codegen**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri-codegen) | handles assets, parses tauri.conf.json | [![](https://img.shields.io/crates/v/tauri-codegen.svg)](https://crates.io/crates/tauri-codegen) | ✅ | ✅ | ✅ |
| [**tauri-macros**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri-macros) | creates macros using tauri-codegen | [![](https://img.shields.io/crates/v/tauri-macros.svg)](https://crates.io/crates/tauri-macros) | ✅ | ✅ | ✅ |
| [**tauri-runtime**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri-runtime) | layer between Tauri and webview libraries | [![](https://img.shields.io/crates/v/tauri-runtime.svg)](https://crates.io/crates/tauri-runtime) | ✅ | ✅ | ✅ |
| [**tauri-runtime-wry**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri-runtime-wry) | enables system-level interaction via WRY | [![](https://img.shields.io/crates/v/tauri-runtime-wry.svg)](https://crates.io/crates/tauri-runtime-wry) | ✅ | ✅ | ✅ |
| [**tauri-utils**](https://github.com/tauri-apps/tauri/tree/dev/core/tauri-utils) | common code used across the tauri crates | [![](https://img.shields.io/crates/v/tauri-utils.svg)](https://crates.io/crates/tauri-utils) | ✅ | ✅ | ✅ |
### Tooling
| Component | Description | Version | Lin | Win | Mac |
| --------------------------------------------------------------------------- | ---------------------------------------- | ------------------------------------------------------------------------------------------------------ | --- | --- | --- |
| [**bundler**](https://github.com/tauri-apps/tauri/tree/dev/tooling/bundler) | manufacture the final binaries | [![](https://img.shields.io/crates/v/tauri-bundler.svg)](https://crates.io/crates/tauri-bundler) | ✅ | ✅ | ✅ |
| [**api.js**](https://github.com/tauri-apps/tauri/tree/dev/tooling/api) | JS API for interaction with Rust backend | [![](https://img.shields.io/npm/v/@tauri-apps/api.svg)](https://www.npmjs.com/package/@tauri-apps/api) | ✅ | ✅ | ✅ |
| [**cli.rs**](https://github.com/tauri-apps/tauri/tree/dev/tooling/cli) | create, develop and build apps | [![](https://img.shields.io/crates/v/tauri-cli.svg)](https://crates.io/crates/tauri-cli) | ✅ | ✅ | ✅ |
| [**cli.js**](https://github.com/tauri-apps/tauri/tree/dev/tooling/cli/node) | Node.js CLI wrapper for cli.rs | [![](https://img.shields.io/npm/v/@tauri-apps/cli.svg)](https://www.npmjs.com/package/@tauri-apps/cli) | ✅ | ✅ | ✅ |
### Utilities and Plugins
| Component | Description | Version | Lin | Win | Mac |
| ------------------------------------------------------------------------------- | ------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | --- | --- | --- |
| [**create-tauri-app**](https://github.com/tauri-apps/create-tauri-app) | Get started with your first Tauri app | [![](https://img.shields.io/npm/v/create-tauri-app.svg)](https://www.npmjs.com/package/create-tauri-app) | ✅ | ✅ | ✅ |
| [**vue-cli-plugin-tauri**](https://github.com/tauri-apps/vue-cli-plugin-tauri/) | Vue CLI plugin for Tauri | [![](https://img.shields.io/npm/v/vue-cli-plugin-tauri.svg)](https://www.npmjs.com/package/vue-cli-plugin-tauri) | ✅ | ✅ | ✅ |
## Introduction
Tauri is a framework for building tiny, blazingly fast binaries for all major desktop platforms. Developers can integrate any front-end framework that compiles to HTML, JS and CSS for building their user interface. The backend of the application is a rust-sourced binary with an API that the front-end can interact with.
The user interface in Tauri apps currently leverages [`tao`](https://docs.rs/tao) as a window handling library on macOS and Windows, and [`gtk`](https://gtk-rs.org/docs/gtk/) on Linux via the **Tauri-team** incubated and maintained [WRY](https://github.com/tauri-apps/wry), which creates a unified interface to the system webview (and other goodies like Menu and Taskbar), leveraging WebKit on macOS, WebView2 on Windows and WebKitGTK on Linux.
@@ -31,32 +48,49 @@ The user interface in Tauri apps currently leverages [`tao`](https://docs.rs/tao
To learn more about the details of how all of these pieces fit together, please consult this [ARCHITECTURE.md](https://github.com/tauri-apps/tauri/blob/dev/ARCHITECTURE.md) document.
## Get Started
If you are interested in making a tauri app, please visit the [documentation website](https://tauri.studio). This README is directed towards those who are interested in contributing to the core library. But if you just want a quick overview about where `tauri` is at in its development, here's a quick burndown:
If you are interested in making a tauri app, please visit the [documentation website](https://tauri.app). This README is directed towards those who are interested in contributing to the core library. But if you just want a quick overview about where `tauri` is at in its development, here's a quick burndown:
### Platforms
- [x] Windows 7,8,10
- [x] Linux
- [x] macOS
- [ ] iOS (in progress)
- [ ] android (soon)
### App Bundles
- [x] App Icons
- [x] Build on MacOS (.app, .dmg)
- [x] Build on Linux (.deb, AppImage)
- [x] Build on Windows (.exe, .msi)
- [x] Copy Buffer
- [x] Device Notifications (toast)
Tauri currently supports development and distribution on the following platforms:
| Platform | Versions |
| :----------------------- | :-------------- |
| Windows | 7 and above |
| macOS | 10.15 and above |
| Linux | See below |
| iOS/iPadOS (coming soon) | |
| Android (coming soon) | |
**Linux Support**
For **developing** Tauri apps refer to the [Getting Started guide on tauri.app](https://tauri.app/v1/guides/getting-started/prerequisites#setting-up-linux).
For **running** Tauri apps we support the below configurations (these are automatically added as dependencies for .deb and are bundled for AppImage so that your users don't need to manually install them):
- Debian (Ubuntu 18.04 and above or equivalent) with the following packages installed:
- `libwebkit2gtk-4.0-37`, `libgtk-3-0`, `libayatana-appindicator3-1`<sup>1</sup>
- Arch with the following packages installed:
- `webkit2gtk`, `gtk3`, `libayatana-appindicator`<sup>1</sup>
- Fedora (latest 2 versions) with the following packages installed:
- `webkit2gtk3`, `gtk3`, `libappindicator-gtk3`<sup>1</sup>
<sup>1</sup> `appindicator` is only required if system trays are used
### Features
- [x] Desktop Bundler (.app, .dmg, .deb, AppImage, .msi)
- [x] Self Updater
- [x] App Signing
- [x] Frameless Mode
- [x] Transparent Mode
- [x] Multiwindow Mode
- [x] Tray
- [ ] deeplink RPC (in progress)
- [ ] One-Time commands (coming soon)
- [x] Native Notifications (toast)
- [x] App Tray
- [x] Core Plugin System
- [x] Scoped Filesystem
- [x] Sidecar
### Security Features
- [x] localhost-free (:fire:)
- [x] custom protocol for secure mode
- [x] Dynamic ahead of Time Compilation (dAoT) with functional tree-shaking
@@ -65,65 +99,30 @@ If you are interested in making a tauri app, please visit the [documentation web
- [x] CSP Injection
### Utilities
- [x] Rust-based CLI
- [x] GH Action for creating binaries for all platforms
- [x] VS Code Extension
- [x] Tauri Core Plugins
- [x] Update core dependencies automatically from the command line
- [x] Rust-based CLI
### Comparison between Tauri and Electron
| Detail | Tauri | Electron |
| -------------------------- | ------ | -------------------- |
| Installer Size Linux | 3.1 MB | 52.1 MB |
| Memory Consumption Linux | 180 MB | 462 MB |
| Launch Time Linux | 0.39s | 0.80s |
| Interface Service Provider | WRY | Chromium |
| Backend Binding | Rust | Node.js (ECMAScript) |
| Underlying Engine | Rust | V8 (C/C++) |
| FLOSS | Yes | No |
| Multithreading | Yes | Yes |
| Bytecode Delivery | Yes | No |
| Multiple Windows | Yes | Yes |
| Auto Updater | Yes | Yes<sup>1</sup> |
| Custom App Icon | Yes | Yes |
| Windows Binary | Yes | Yes |
| MacOS Binary | Yes | Yes |
| Linux Binary | Yes | Yes |
| iOS Binary | Soon | No |
| Android Binary | Soon | No |
| Desktop Tray | Yes | Yes |
| Sidecar Binaries | Yes | No |
#### Notes
1. Electron has no native auto updater on Linux, but is offered by electron-packager
## Development
Tauri is a system composed of a number of moving pieces:
### Infrastructure
- Git for code management
- GitHub for project management
- GitHub actions for CI and CD
- Discord for discussions
- Netlify-hosted documentation website
- DigitalOcean meilisearch instance
### Major Runtimes
- Node.js for running the CLI (deno and pure rust are on the roadmap)
- Cargo for testing, running the dev service, building binaries and as the runtime harness for the webview
### Major Languages
- Rust for the CLI
- EcmaScript bindings to the Rust API, written in typescript
- Rust for bindings, rust side of the API, harnesses
- Rust plugins to Tauri backend
- DigitalOcean Meilisearch instance
### Operating systems
Tauri core can be developed on Mac, Linux and Windows, but you are encouraged to use the latest possible operating systems and build tools for your OS.
### Contributing
Before you start working on something, it's best to check if there is an existing issue first. It's also a good idea to stop by the Discord server and confirm with the team if it makes sense or if someone else is already working on it.
Please make sure to read the [Contributing Guide](./.github/CONTRIBUTING.md) before making a pull request.
@@ -131,31 +130,38 @@ Please make sure to read the [Contributing Guide](./.github/CONTRIBUTING.md) bef
Thank you to everyone contributing to Tauri!
### Documentation
Documentation in a polyglot system is a tricky proposition. To this end, we prefer to use inline documentation of Rust code and at JSDoc in typescript / javascript code. We autocollect these and publish them using Docusaurus v2 and netlify. Here is the hosting repository for the documentation site: https://github.com/tauri-apps/tauri-docs
### Testing & Linting
Test all the things! We have a number of test suites, but are always looking to improve our coverage:
- Rust (`cargo test`) => sourced via inline `#[cfg(test)]` declarations
- TS (`jest`) => via spec files
- Typescript (`jest`) => via spec files
- Smoke Tests (run on merges to latest)
- eslint, clippy
### CI/CD
We recommend you read this article to understand better how we run our pipelines: https://www.jacobbolda.com/setting-up-ci-and-cd-for-tauri/
## Organization
Tauri aims to be a sustainable collective based on principles that guide [sustainable free and open software communities](https://sfosc.org). To this end it has become a Programme within the [Commons Conservancy](https://commonsconservancy.org/), and you can contribute financially via [Open Collective](https://opencollective.com/tauri).
## Semver
**tauri** is following [Semantic Versioning 2.0](https://semver.org/).
## Licenses
Code: (c) 2015 - 2021 - The Tauri Programme within The Commons Conservancy.
MIT or MIT/Apache 2.0 where applicable.
Logo: CC-BY-NC-ND
- Original Tauri Logo Designs by [Alve Larsson](https://alve.io/), [Daniel Thompson-Yvetot](https://github.com/nothingismagick) and [Guillaume Chau](https://github.com/akryum)
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Ftauri-apps%2Ftauri.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2Ftauri-apps%2Ftauri?ref=badge_large)

View File

@@ -13,7 +13,16 @@ If you have found a potential security threat, vulnerability or exploit in Tauri
or one of its upstream dependencies, please DONT create a pull-request, DONT
file an issue on GitHub, DONT mention it on Discord and DONT create a forum thread.
We will be adding contact information to this page very soon.
Please submit your report via the GitHub Private Vulnerability Disclosure functionality.
Find out more about the reporting process [here](https://docs.github.com/en/code-security/security-advisories/guidance-on-reporting-and-writing/privately-reporting-a-security-vulnerability#privately-reporting-a-security-vulnerability).
Our team will triage your report and keep you informed about the progress.
We may ask questions or request further guidance on reproduction of the vulnerability in the comments of the advisory, which will be publicized.
Additionally, we may ask you to independently verify our patch, which will be available in the private advisory branch. Please do not publish your vulnerability during the process or before coordinated public disclosure from our side. We try to adhere to common standards of publication within 90-Days of disclosure.
Depending on your decision to accept or deny credit for the vulnerability, you will be publicly attributed to the vulnerability and may be mentioned in our announcements.
At the current time we do not have the financial ability to reward bounties,
but in extreme cases will at our discretion consider a reward.

View File

@@ -0,0 +1,13 @@
[package]
name = "config-schema"
version = "0.0.0"
edition = "2021"
publish = false
[build-dependencies]
tauri-utils = { version = "1.0.0", features = [ "schema" ], path = "../tauri-utils" }
schemars = { version = "0.8", features = [ "url", "preserve_order" ] }
serde = { version = "1.0", features = [ "derive" ] }
serde_json = "1.0"
serde_with = "1.12"
url = { version = "2.3", features = [ "serde" ] }

View File

@@ -0,0 +1,25 @@
// Copyright 2019-2022 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
use std::{
error::Error,
fs::File,
io::{BufWriter, Write},
path::PathBuf,
};
pub fn main() -> Result<(), Box<dyn Error>> {
let schema = schemars::schema_for!(tauri_utils::config::Config);
let schema_str = serde_json::to_string_pretty(&schema).unwrap();
let crate_dir = PathBuf::from(std::env::var("CARGO_MANIFEST_DIR")?);
for file in [
crate_dir.join("schema.json"),
crate_dir.join("../../tooling/cli/schema.json"),
] {
let mut schema_file = BufWriter::new(File::create(file)?);
write!(schema_file, "{schema_str}")?;
}
Ok(())
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1 @@
fn main() {}

View File

@@ -1,3 +0,0 @@
// Copyright {20\d{2}(-20\d{2})?} Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT

View File

@@ -1,5 +1,71 @@
# Changelog
## \[1.2.1]
- Fix `allowlist > app > show/hide` always disabled when `allowlist > app > all: false`.
- Bumped due to a bump in tauri-utils.
- [bb251087](https://www.github.com/tauri-apps/tauri/commit/bb2510876d0bdff736d36bf3a465cdbe4ad2b90c) fix(core): extend allowlist with `app`'s allowlist, closes [#5650](https://www.github.com/tauri-apps/tauri/pull/5650) ([#5652](https://www.github.com/tauri-apps/tauri/pull/5652)) on 2022-11-18
## \[1.2.0]
- - [7d9aa398](https://www.github.com/tauri-apps/tauri/commit/7d9aa3987efce2d697179ffc33646d086c68030c) feat: bump MSRV to 1.59 ([#5296](https://www.github.com/tauri-apps/tauri/pull/5296)) on 2022-09-28
## \[1.1.1]
- Add missing allowlist config for `set_cursor_grab`, `set_cursor_visible`, `set_cursor_icon` and `set_cursor_position` APIs.
- Bumped due to a bump in tauri-utils.
- [c764408d](https://www.github.com/tauri-apps/tauri/commit/c764408da7fae123edd41115bda42fa75a4731d2) fix: Add missing allowlist config for cursor apis, closes [#5207](https://www.github.com/tauri-apps/tauri/pull/5207) ([#5211](https://www.github.com/tauri-apps/tauri/pull/5211)) on 2022-09-16
## \[1.1.0]
- Rerun codegen if assets or icons change.
- [ff8fd761](https://www.github.com/tauri-apps/tauri/commit/ff8fd7619ae894b70f149b192d8635d842827141) fix(tauri-build): rerun if assets or icons change ([#4910](https://www.github.com/tauri-apps/tauri/pull/4910)) on 2022-08-10
- Create the `desktop` and `mobile` cfg aliases.
- [c04d0340](https://www.github.com/tauri-apps/tauri/commit/c04d0340e2f163483f3556c7aabe35322ee71e6a) feat(core): prepare build for mobile targets ([#4830](https://www.github.com/tauri-apps/tauri/pull/4830)) on 2022-08-02
- Added support to configuration files in TOML format (Tauri.toml file).
- [ae83d008](https://www.github.com/tauri-apps/tauri/commit/ae83d008f9e1b89bfc8dddaca42aa5c1fbc36f6d) feat: add support to TOML config file `Tauri.toml`, closes [#4806](https://www.github.com/tauri-apps/tauri/pull/4806) ([#4813](https://www.github.com/tauri-apps/tauri/pull/4813)) on 2022-08-02
- Enhance the dialog style on Windows via the manifest dependency `Microsoft.Windows.Common-Controls v6.0.0.0`.
- [5c5c42ed](https://www.github.com/tauri-apps/tauri/commit/5c5c42edb64adf4250af6891d7d226fda7d4d783) feat(build): use modern dialog styles on Windows, closes [#4709](https://www.github.com/tauri-apps/tauri/pull/4709) ([#4840](https://www.github.com/tauri-apps/tauri/pull/4840)) on 2022-08-02
- Fix root of codegen output when using the `CodegenContext` API.
- [ed581950](https://www.github.com/tauri-apps/tauri/commit/ed581950ea6fd0afee47aa73fb63083d2483429f) fix(tauri-build): use `::tauri` as root for the CodegenContext ([#4894](https://www.github.com/tauri-apps/tauri/pull/4894)) on 2022-08-08
- Return an error if a sidecar is configured with the same file name as the application.
- [5cc1fd0f](https://www.github.com/tauri-apps/tauri/commit/5cc1fd0f7b01b257a461d4e867ddc8cd5072ff15) feat(tauri-build): validate sidecar name, closes [#4780](https://www.github.com/tauri-apps/tauri/pull/4780) closes [#4823](https://www.github.com/tauri-apps/tauri/pull/4823) ([#4814](https://www.github.com/tauri-apps/tauri/pull/4814)) on 2022-08-02
- Only rewrite temporary icon files when the content change, avoid needless rebuilds.
- [f957cbb5](https://www.github.com/tauri-apps/tauri/commit/f957cbb56ccbd8d1c047a978b4579946252a6fd2) fix(codegen): write output file when contents change ([#4889](https://www.github.com/tauri-apps/tauri/pull/4889)) on 2022-08-09
## \[1.0.4]
- Reduce the amount of allocations when converting cases.
- [bc370e32](https://www.github.com/tauri-apps/tauri/commit/bc370e326810446e15b1f50fb962b980114ba16b) feat: reduce the amount of `heck`-related allocations ([#4634](https://www.github.com/tauri-apps/tauri/pull/4634)) on 2022-07-11
## \[1.0.3]
- Improve configuration deserialization error messages.
- [9170c920](https://www.github.com/tauri-apps/tauri/commit/9170c9207044fa561535f624916dfdbaa41ff79d) feat(core): improve config deserialization error messages ([#4607](https://www.github.com/tauri-apps/tauri/pull/4607)) on 2022-07-06
- The `TAURI_CONFIG` environment variable now represents the configuration to be merged instead of the entire JSON.
- [fa028ebf](https://www.github.com/tauri-apps/tauri/commit/fa028ebf3c8ca7b43a70d283a01dbea86217594f) refactor: do not pass entire config from CLI to core, send patch instead ([#4598](https://www.github.com/tauri-apps/tauri/pull/4598)) on 2022-07-06
## \[1.0.2]
- Expose `platform::windows_version` function.
- Bumped due to a bump in tauri-utils.
- [bf764e83](https://www.github.com/tauri-apps/tauri/commit/bf764e83e01e7443e6cc54572001e1c98c357465) feat(utils): expose `windows_version` function ([#4534](https://www.github.com/tauri-apps/tauri/pull/4534)) on 2022-06-30
## \[1.0.1]
- Changed the `BundleConfig::targets` to a `BundleTarget` enum to enhance generated documentation.
- Bumped due to a bump in tauri-utils.
- [31c15cd2](https://www.github.com/tauri-apps/tauri/commit/31c15cd2bd94dbe39fb94982a15cbe02ac5d8925) docs(config): enhance documentation for bundle targets, closes [#3251](https://www.github.com/tauri-apps/tauri/pull/3251) ([#4418](https://www.github.com/tauri-apps/tauri/pull/4418)) on 2022-06-21
- Added `platform::is_windows_7`.
- Bumped due to a bump in tauri-utils.
- [57039fb2](https://www.github.com/tauri-apps/tauri/commit/57039fb2166571de85271b014a8711a29f06be1a) fix(core): add windows 7 notification support ([#4491](https://www.github.com/tauri-apps/tauri/pull/4491)) on 2022-06-28
- Suppress unused variable warning in release builds.
- Bumped due to a bump in tauri-utils.
- [45981851](https://www.github.com/tauri-apps/tauri/commit/45981851e35119266c1a079e1ff27a39f1fdfaed) chore(lint): unused variable warnings for release builds ([#4411](https://www.github.com/tauri-apps/tauri/pull/4411)) on 2022-06-22
- Added webview install mode options.
- Bumped due to a bump in tauri-utils.
- [2ca762d2](https://www.github.com/tauri-apps/tauri/commit/2ca762d207030a892a6d128b519e150e2d733468) feat(bundler): extend webview2 installation options, closes [#2882](https://www.github.com/tauri-apps/tauri/pull/2882) [#2452](https://www.github.com/tauri-apps/tauri/pull/2452) ([#4466](https://www.github.com/tauri-apps/tauri/pull/4466)) on 2022-06-26
## \[1.0.0]
- Upgrade to `stable`!

View File

@@ -1,6 +1,6 @@
[package]
name = "tauri-build"
version = "1.0.0"
version = "1.2.1"
authors = [ "Tauri Programme within The Commons Conservancy" ]
categories = [ "gui", "web-programming" ]
license = "Apache-2.0 OR MIT"
@@ -8,8 +8,8 @@ homepage = "https://tauri.app"
repository = "https://github.com/tauri-apps/tauri/tree/dev/core/tauri-build"
description = "build time code to pair with https://crates.io/crates/tauri"
edition = "2021"
rust-version = "1.57"
exclude = [ ".license_template", "CHANGELOG.md", "/target" ]
rust-version = "1.59"
exclude = [ "CHANGELOG.md", "/target" ]
readme = "README.md"
[package.metadata.docs.rs]
@@ -19,11 +19,12 @@ rustdoc-args = [ "--cfg", "doc_cfg" ]
[dependencies]
anyhow = "1"
quote = { version = "1", optional = true }
tauri-codegen = { version = "1.0.0", path = "../tauri-codegen", optional = true }
tauri-utils = { version = "1.0.0", path = "../tauri-utils", features = [ "build", "resources" ] }
cargo_toml = "0.11"
tauri-codegen = { version = "1.2.1", path = "../tauri-codegen", optional = true }
tauri-utils = { version = "1.2.1", path = "../tauri-utils", features = [ "build", "resources" ] }
cargo_toml = "0.14"
serde_json = "1"
heck = "0.4"
json-patch = "0.3"
[target."cfg(windows)".dependencies]
winres = "0.1"
@@ -33,3 +34,4 @@ semver = "1"
codegen = [ "tauri-codegen", "quote" ]
isolation = [ "tauri-codegen/isolation", "tauri-utils/isolation" ]
config-json5 = [ "tauri-utils/config-json5" ]
config-toml = [ "tauri-utils/config-toml" ]

View File

@@ -2,38 +2,41 @@
<img align="right" src="https://github.com/tauri-apps/tauri/raw/dev/app-icon.png" height="128" width="128">
[![status](https://img.shields.io/badge/Status-Beta-green.svg)](https://github.com/tauri-apps/tauri)
[![Chat Server](https://img.shields.io/badge/chat-on%20discord-7289da.svg)](https://discord.gg/SpmNs4S)
[![devto](https://img.shields.io/badge/blog-dev.to-black.svg)](https://dev.to/tauri)
![](https://img.shields.io/github/workflow/status/tauri-apps/tauri/test%20library?label=test%20library
)
[![devto](https://img.shields.io/badge/documentation-site-purple.svg)](https://tauri.app)
[![status](https://img.shields.io/badge/status-stable-blue.svg)](https://github.com/tauri-apps/tauri/tree/dev)
[![License](https://img.shields.io/badge/License-MIT%20or%20Apache%202-green.svg)](https://opencollective.com/tauri)
[![test library](https://img.shields.io/github/workflow/status/tauri-apps/tauri/test%20library?label=test%20library)](https://github.com/tauri-apps/tauri/actions?query=workflow%3A%22test+library%22)
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Ftauri-apps%2Ftauri.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Ftauri-apps%2Ftauri?ref=badge_shield)
[![Chat Server](https://img.shields.io/badge/chat-discord-7289da.svg)](https://discord.gg/SpmNs4S)
[![website](https://img.shields.io/badge/website-tauri.app-purple.svg)](https://tauri.app)
[![https://good-labs.github.io/greater-good-affirmation/assets/images/badge.svg](https://good-labs.github.io/greater-good-affirmation/assets/images/badge.svg)](https://good-labs.github.io/greater-good-affirmation)
[![support](https://img.shields.io/badge/sponsor-Opencollective-blue.svg)](https://opencollective.com/tauri)
[![support](https://img.shields.io/badge/sponsor-Open%20Collective-blue.svg)](https://opencollective.com/tauri)
| Component | Version |
| --------- | ------------------------------------------- |
| tauri-build | [![](https://img.shields.io/crates/v/tauri-build?style=flat-square)](https://crates.io/crates/tauri-build) |
| Component | Version |
| ----------- | ---------------------------------------------------------------------------------------------------------- |
| tauri-build | [![](https://img.shields.io/crates/v/tauri-build?style=flat-square)](https://crates.io/crates/tauri-build) |
## About Tauri
Tauri is a polyglot and generic system that is very composable and allows engineers to make a wide variety of applications. It is used for building applications for Desktop Computers using a combination of Rust tools and HTML rendered in a Webview. Apps built with Tauri can ship with any number of pieces of an optional JS API / Rust API so that webviews can control the system via message passing. In fact, developers can extend the default API with their own functionality and bridge the Webview and Rust-based backend easily.
Tauri apps can have custom menus and have tray-type interfaces. They can be updated, and are managed by the user's operating system as expected. They are very small, because they use the system's webview. They do not ship a runtime, since the final binary is compiled from rust. This makes the reversing of Tauri apps not a trivial task.
## This module
This applies the macros at build-time in order to rig some special features needed by `cargo`.
To learn more about the details of how all of these pieces fit together, please consult this [ARCHITECTURE.md](https://github.com/tauri-apps/tauri/blob/dev/ARCHITECTURE.md) document.
## Semver
**tauri** is following [Semantic Versioning 2.0](https://semver.org/).
## Licenses
Code: (c) 2021 - The Tauri Programme within The Commons Conservancy.
MIT or MIT/Apache 2.0 where applicable.
Logo: CC-BY-NC-ND
- Original Tauri Logo Designs by [Daniel Thompson-Yvetot](https://github.com/nothingismagick) and [Guillaume Chau](https://github.com/akryum)

View File

@@ -1,4 +1,4 @@
// Copyright 2019-2021 Tauri Programme within The Commons Conservancy
// Copyright 2019-2022 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
@@ -10,6 +10,7 @@ use std::{
path::PathBuf,
};
use tauri_codegen::{context_codegen, ContextData};
use tauri_utils::config::{AppUrl, WindowUrl};
// TODO docs
/// A builder for generating a Tauri application context during compile time.
@@ -52,13 +53,13 @@ impl CodegenContext {
///
/// **Note:** This path should be relative to the `OUT_DIR`.
///
/// Don't set this if you are using [`tauri::include_codegen_context!`] as that helper macro
/// Don't set this if you are using [`tauri::tauri_build_context!`] as that helper macro
/// expects the default value. This option can be useful if you are not using the helper and
/// instead using [`std::include!`] on the generated code yourself.
///
/// Defaults to `tauri-build-context.rs`.
///
/// [`tauri::include_codegen_context!`]: https://docs.rs/tauri/0.12/tauri/macro.include_codegen_context.html
/// [`tauri::tauri_build_context!`]: https://docs.rs/tauri/latest/tauri/macro.tauri_build_context.html
#[must_use]
pub fn out_file(mut self, filename: PathBuf) -> Self {
self.out_file = filename;
@@ -85,20 +86,60 @@ impl CodegenContext {
pub fn build(self) -> PathBuf {
match self.try_build() {
Ok(out) => out,
Err(error) => panic!("Error found during Codegen::build: {}", error),
Err(error) => panic!("Error found during Codegen::build: {error}"),
}
}
/// Non-panicking [`Self::build`]
pub fn try_build(self) -> Result<PathBuf> {
let (config, config_parent) = tauri_codegen::get_config(&self.config_path)?;
// rerun if changed
let app_url = if self.dev {
&config.build.dev_path
} else {
&config.build.dist_dir
};
match app_url {
AppUrl::Url(WindowUrl::App(p)) => {
println!("cargo:rerun-if-changed={}", config_parent.join(p).display());
}
AppUrl::Files(files) => {
for path in files {
println!(
"cargo:rerun-if-changed={}",
config_parent.join(path).display()
);
}
}
_ => (),
}
for icon in &config.tauri.bundle.icon {
println!(
"cargo:rerun-if-changed={}",
config_parent.join(icon).display()
);
}
if let Some(tray_icon) = config.tauri.system_tray.as_ref().map(|t| &t.icon_path) {
println!(
"cargo:rerun-if-changed={}",
config_parent.join(tray_icon).display()
);
}
#[cfg(target_os = "macos")]
println!(
"cargo:rerun-if-changed={}",
config_parent.join("Info.plist").display()
);
let code = context_codegen(ContextData {
dev: self.dev,
config,
config_parent,
// it's very hard to have a build script for unit tests, so assume this is always called from
// outside the tauri crate, making the ::tauri root valid.
root: quote::quote!(::tauri::Context),
root: quote::quote!(::tauri),
})?;
// get the full output file path
@@ -120,7 +161,7 @@ impl CodegenContext {
)
})?;
writeln!(file, "{}", code).with_context(|| {
writeln!(file, "{code}").with_context(|| {
format!(
"Unable to write tokenstream to out file during tauri-build {}",
out.display()

View File

@@ -1,4 +1,4 @@
// Copyright 2019-2021 Tauri Programme within The Commons Conservancy
// Copyright 2019-2022 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT

View File

@@ -1,11 +1,12 @@
// Copyright 2019-2021 Tauri Programme within The Commons Conservancy
// Copyright 2019-2022 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
#![cfg_attr(doc_cfg, feature(doc_cfg))]
pub use anyhow::Result;
use heck::ToSnakeCase;
use heck::AsShoutySnakeCase;
use tauri_utils::resources::{external_binaries, resource_relpath, ResourcePaths};
use std::path::{Path, PathBuf};
@@ -34,17 +35,29 @@ fn copy_file(from: impl AsRef<Path>, to: impl AsRef<Path>) -> Result<()> {
Ok(())
}
fn copy_binaries<'a>(binaries: ResourcePaths<'a>, target_triple: &str, path: &Path) -> Result<()> {
fn copy_binaries(
binaries: ResourcePaths,
target_triple: &str,
path: &Path,
package_name: Option<&String>,
) -> Result<()> {
for src in binaries {
let src = src?;
println!("cargo:rerun-if-changed={}", src.display());
let dest = path.join(
src
.file_name()
.expect("failed to extract external binary filename")
.to_string_lossy()
.replace(&format!("-{}", target_triple), ""),
);
let file_name = src
.file_name()
.expect("failed to extract external binary filename")
.to_string_lossy()
.replace(&format!("-{target_triple}"), "");
if package_name.map_or(false, |n| n == &file_name) {
return Err(anyhow::anyhow!(
"Cannot define a sidecar with the same name as the Cargo package name `{}`. Please change the sidecar name in the filesystem and the Tauri configuration.",
file_name
));
}
let dest = path.join(file_name);
if dest.exists() {
std::fs::remove_file(&dest).unwrap();
}
@@ -59,7 +72,7 @@ fn copy_resources(resources: ResourcePaths<'_>, path: &Path) -> Result<()> {
let src = src?;
println!("cargo:rerun-if-changed={}", src.display());
let dest = path.join(resource_relpath(&src));
copy_file(&src, &dest)?;
copy_file(&src, dest)?;
}
Ok(())
}
@@ -68,19 +81,16 @@ fn copy_resources(resources: ResourcePaths<'_>, path: &Path) -> Result<()> {
fn has_feature(feature: &str) -> bool {
// when a feature is enabled, Cargo sets the `CARGO_FEATURE_<name` env var to 1
// https://doc.rust-lang.org/cargo/reference/environment-variables.html#environment-variables-cargo-sets-for-build-scripts
std::env::var(format!(
"CARGO_FEATURE_{}",
feature.to_snake_case().to_uppercase()
))
.map(|x| x == "1")
.unwrap_or(false)
std::env::var(format!("CARGO_FEATURE_{}", AsShoutySnakeCase(feature)))
.map(|x| x == "1")
.unwrap_or(false)
}
// creates a cfg alias if `has_feature` is true.
// `alias` must be a snake case string.
fn cfg_alias(alias: &str, has_feature: bool) {
if has_feature {
println!("cargo:rustc-cfg={}", alias);
println!("cargo:rustc-cfg={alias}");
}
}
@@ -96,10 +106,19 @@ pub struct WindowsAttributes {
///
/// For MSVC the Windows SDK has to be installed. It comes with the resource compiler rc.exe.
/// This should be set to the root directory of the Windows SDK, e.g., "C:\Program Files (x86)\Windows Kits\10" or,
/// if multiple 10 versions are installed, set it directly to the corret bin directory "C:\Program Files (x86)\Windows Kits\10\bin\10.0.14393.0\x64"
/// if multiple 10 versions are installed, set it directly to the correct bin directory "C:\Program Files (x86)\Windows Kits\10\bin\10.0.14393.0\x64"
///
/// If it is left unset, it will look up a path in the registry, i.e. HKLM\SOFTWARE\Microsoft\Windows Kits\Installed Roots
sdk_dir: Option<PathBuf>,
/// A string containing an [application manifest] to be included with the application on Windows.
///
/// Defaults to:
/// ```ignore
#[doc = include_str!("window-app-manifest.xml")]
/// ```
///
/// [application manifest]: https://learn.microsoft.com/en-us/windows/win32/sbscs/application-manifests
app_manifest: Option<String>,
}
impl WindowsAttributes {
@@ -118,13 +137,52 @@ impl WindowsAttributes {
self
}
/// Sets the sdk dir for windows. Currently only used on Windows. This must be a vaild UTF-8
/// Sets the sdk dir for windows. Currently only used on Windows. This must be a valid UTF-8
/// path. Defaults to whatever the `winres` crate determines is best.
#[must_use]
pub fn sdk_dir<P: AsRef<Path>>(mut self, sdk_dir: P) -> Self {
self.sdk_dir = Some(sdk_dir.as_ref().into());
self
}
/// Sets the Windows app [manifest].
///
/// # Example
///
/// The following manifest will brand the exe as requesting administrator privileges.
/// Thus, everytime it is executed, a Windows UAC dialog will appear.
///
/// Note that you can move the manifest contents to a separate file and use `include_str!("manifest.xml")`
/// instead of the inline string.
///
/// ```rust,no_run
/// let mut windows = tauri_build::WindowsAttributes::new();
/// windows = windows.app_manifest(r#"
/// <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
/// <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
/// <security>
/// <requestedPrivileges>
/// <requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
/// </requestedPrivileges>
/// </security>
/// </trustInfo>
/// </assembly>
/// "#);
/// tauri_build::try_build(
/// tauri_build::Attributes::new().windows_attributes(windows)
/// ).expect("failed to run build script");
/// ```
///
/// Defaults to:
/// ```ignore
#[doc = include_str!("window-app-manifest.xml")]
/// [manifest]: https://learn.microsoft.com/en-us/windows/win32/sbscs/application-manifests
/// ```
#[must_use]
pub fn app_manifest<S: AsRef<str>>(mut self, manifest: S) -> Self {
self.app_manifest = Some(manifest.as_ref().to_string());
self
}
}
/// The attributes used on the build.
@@ -169,7 +227,15 @@ impl Attributes {
/// This is typically desirable when running inside a build script; see [`try_build`] for no panics.
pub fn build() {
if let Err(error) = try_build(Attributes::default()) {
panic!("error found during tauri-build: {:#?}", error);
let error = format!("{error:#}");
println!("{error}");
if error.starts_with("unknown field") {
print!("found an unknown configuration field. This usually means that you are using a CLI version that is newer than `tauri-build` and is incompatible. ");
println!(
"Please try updating the Rust crates by running `cargo update` in the Tauri app folder."
);
}
std::process::exit(1);
}
}
@@ -184,14 +250,22 @@ pub fn try_build(attributes: Attributes) -> Result<()> {
println!("cargo:rerun-if-changed=tauri.conf.json");
#[cfg(feature = "config-json5")]
println!("cargo:rerun-if-changed=tauri.conf.json5");
#[cfg(feature = "config-toml")]
println!("cargo:rerun-if-changed=Tauri.toml");
let config: Config = if let Ok(env) = std::env::var("TAURI_CONFIG") {
serde_json::from_str(&env)?
} else {
serde_json::from_value(tauri_utils::config::parse::read_from(
std::env::current_dir().unwrap(),
)?)?
};
let target_os = std::env::var("CARGO_CFG_TARGET_OS").unwrap();
let mobile = target_os == "ios" || target_os == "android";
cfg_alias("desktop", !mobile);
cfg_alias("mobile", mobile);
let mut config = serde_json::from_value(tauri_utils::config::parse::read_from(
std::env::current_dir().unwrap(),
)?)?;
if let Ok(env) = std::env::var("TAURI_CONFIG") {
let merge_config: serde_json::Value = serde_json::from_str(&env)?;
json_patch::merge(&mut config, &merge_config);
}
let config: Config = serde_json::from_value(config)?;
cfg_alias("dev", !has_feature("custom-protocol"));
@@ -200,6 +274,7 @@ pub fn try_build(attributes: Attributes) -> Result<()> {
let features = match tauri {
Dependency::Simple(_) => Vec::new(),
Dependency::Detailed(dep) => dep.features,
Dependency::Inherited(dep) => dep.features,
};
let all_cli_managed_features = TauriConfig::all_features();
@@ -263,6 +338,7 @@ pub fn try_build(attributes: Attributes) -> Result<()> {
ResourcePaths::new(external_binaries(paths, &target_triple).as_slice(), true),
&target_triple,
target_dir,
manifest.package.as_ref().map(|p| &p.name),
)?;
}
@@ -307,6 +383,13 @@ pub fn try_build(attributes: Attributes) -> Result<()> {
if window_icon_path.exists() {
let mut res = WindowsResource::new();
if let Some(manifest) = attributes.windows_attributes.app_manifest {
res.set_manifest(&manifest);
} else {
res.set_manifest(include_str!("window-app-manifest.xml"));
}
if let Some(sdk_dir) = &attributes.windows_attributes.sdk_dir {
if let Some(sdk_dir_str) = sdk_dir.to_str() {
res.set_toolkit_path(sdk_dir_str);

View File

@@ -1,4 +1,4 @@
// Copyright 2019-2021 Tauri Programme within The Commons Conservancy
// Copyright 2019-2022 Tauri Programme within The Commons Conservancy
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
@@ -10,7 +10,7 @@ use std::{env, fs, io::Write, path::Path};
pub fn build() {
override_msvcrt_lib();
// Disable conflicting libraries that aren't hard coded by Rust.
// Disable conflicting libraries that aren't hard coded by Rust
println!("cargo:rustc-link-arg=/NODEFAULTLIB:libvcruntimed.lib");
println!("cargo:rustc-link-arg=/NODEFAULTLIB:vcruntime.lib");
println!("cargo:rustc-link-arg=/NODEFAULTLIB:vcruntimed.lib");

View File

@@ -0,0 +1,14 @@
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Common-Controls"
version="6.0.0.0"
processorArchitecture="*"
publicKeyToken="6595b64144ccf1df"
language="*"
/>
</dependentAssembly>
</dependency>
</assembly>

Some files were not shown because too many files have changed in this diff Show More