From b481fa449b0aa85e76c5d1905e8f5921de313e8d Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Wed, 8 Nov 2023 02:53:33 -0300 Subject: [PATCH 01/19] copied files from v1 (.md -> .mdx) --- .../docs/guides/develop/development-cycle.mdx | 30 ++++ .../guides/develop/updating-dependencies.mdx | 132 ++++++++++++++++++ 2 files changed, 162 insertions(+) create mode 100644 src/content/docs/guides/develop/development-cycle.mdx create mode 100644 src/content/docs/guides/develop/updating-dependencies.mdx diff --git a/src/content/docs/guides/develop/development-cycle.mdx b/src/content/docs/guides/develop/development-cycle.mdx new file mode 100644 index 0000000000..b1cfd4e916 --- /dev/null +++ b/src/content/docs/guides/develop/development-cycle.mdx @@ -0,0 +1,30 @@ +--- +sidebar_position: 2 +--- + +import Command from '@theme/Command' + +# Development Cycle + +### 1. Start Your Dev server + +Now that you have everything set up, you should start your application development server provided by your UI framework or bundler (assuming you're using one, of course). + +:::note + +Every framework has its own development tooling. It is outside of the scope of this document to cover them all or stay up to date. +::: + +### 2. Start Tauri Development Window + + + +The first time you run this command, the Rust package manager takes several minutes to download and build all the required packages. Since they are cached, subsequent builds are much faster, as only your code needs rebuilding. + +Once Rust has finished building, the webview opens, displaying your web app. You can make changes to your web app, and if your tooling enables it, the webview should update automatically, just like a browser. When you make changes to your Rust files, they are rebuilt automatically, and your app automatically restarts. + +:::info About Cargo.toml and Source Control + +In your project repository, you SHOULD commit the "src-tauri/Cargo.lock" along with the "src-tauri/Cargo.toml" to git because Cargo uses the lockfile to provide deterministic builds. As a result, it is recommended that all applications check in their `Cargo.lock`. You SHOULD NOT commit the `src-tauri/target` folder or any of its contents. + +::: diff --git a/src/content/docs/guides/develop/updating-dependencies.mdx b/src/content/docs/guides/develop/updating-dependencies.mdx new file mode 100644 index 0000000000..2e9bc0eddc --- /dev/null +++ b/src/content/docs/guides/develop/updating-dependencies.mdx @@ -0,0 +1,132 @@ +--- +sidebar_position: 3 +--- + +import Tabs from '@theme/Tabs' +import TabItem from '@theme/TabItem' + +# Updating Dependencies + +## Update npm Packages + +If you are using the `tauri` package: + + + + +```shell +npm install @tauri-apps/cli@latest @tauri-apps/api@latest +``` + + + + +```shell +yarn upgrade @tauri-apps/cli @tauri-apps/api --latest +``` + + + + +```shell +yarn up @tauri-apps/cli @tauri-apps/api +``` + + + + +```shell +pnpm update @tauri-apps/cli @tauri-apps/api --latest +``` + + + + +You can also detect what the latest version of Tauri is on the command line, using: + + + + +```shell +npm outdated @tauri-apps/cli +``` + + + + +```shell +yarn outdated @tauri-apps/cli +``` + + + + +```shell +pnpm outdated @tauri-apps/cli +``` + + + + +Alternatively, if you are using the `vue-cli-plugin-tauri` approach: + + + + +```shell +npm install vue-cli-plugin-tauri@latest +``` + + + + +```shell +yarn upgrade vue-cli-plugin-tauri --latest +``` + + + + +```shell +yarn up vue-cli-plugin-tauri +``` + + + + +```shell +pnpm update vue-cli-plugin-tauri --latest +``` + + + + +## Update Cargo Packages + +You can check for outdated packages with [`cargo outdated`] or on the crates.io pages: [tauri] / [tauri-build]. + +Go to `src-tauri/Cargo.toml` and change `tauri` and `tauri-build` to + +```toml +[build-dependencies] +tauri-build = "%version%" + +[dependencies] +tauri = { version = "%version%" } +``` + +where `%version%` is the corresponding version number from above. + +Then do the following: + +```shell +cd src-tauri +cargo update +``` + +Alternatively, you can run the `cargo upgrade` command provided by [cargo-edit] which does all of this automatically. + +[`cargo outdated`]: https://github.com/kbknapp/cargo-outdated +[tauri]: https://crates.io/crates/tauri/versions +[tauri-build]: https://crates.io/crates/tauri-build/versions +[cargo-edit]: https://github.com/killercup/cargo-edit From 3b7adc3ba9da1fc80e6e3f98575bb2958692b9b0 Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Wed, 8 Nov 2023 02:59:11 -0300 Subject: [PATCH 02/19] update to v2 --- .../docs/guides/develop/development-cycle.mdx | 20 ++-- .../guides/develop/updating-dependencies.mdx | 109 ++++-------------- 2 files changed, 34 insertions(+), 95 deletions(-) diff --git a/src/content/docs/guides/develop/development-cycle.mdx b/src/content/docs/guides/develop/development-cycle.mdx index b1cfd4e916..ad4d813d1c 100644 --- a/src/content/docs/guides/develop/development-cycle.mdx +++ b/src/content/docs/guides/develop/development-cycle.mdx @@ -1,10 +1,10 @@ --- -sidebar_position: 2 +title: Development Cycle +description: Core concepts for developing with Tauri. --- +{/*TODO: REVISE COPY TO V2 */} -import Command from '@theme/Command' - -# Development Cycle +import CommandTabs from '@components/CommandTabs.astro'; ### 1. Start Your Dev server @@ -17,14 +17,20 @@ Every framework has its own development tooling. It is outside of the scope of t ### 2. Start Tauri Development Window - + + The first time you run this command, the Rust package manager takes several minutes to download and build all the required packages. Since they are cached, subsequent builds are much faster, as only your code needs rebuilding. Once Rust has finished building, the webview opens, displaying your web app. You can make changes to your web app, and if your tooling enables it, the webview should update automatically, just like a browser. When you make changes to your Rust files, they are rebuilt automatically, and your app automatically restarts. -:::info About Cargo.toml and Source Control +:::caution[About Cargo.toml and Source Control] -In your project repository, you SHOULD commit the "src-tauri/Cargo.lock" along with the "src-tauri/Cargo.toml" to git because Cargo uses the lockfile to provide deterministic builds. As a result, it is recommended that all applications check in their `Cargo.lock`. You SHOULD NOT commit the `src-tauri/target` folder or any of its contents. +In your project repository, you **SHOULD** commit the `src-tauri/Cargo.lock` along with the `src-tauri/Cargo.toml` to git because Cargo uses the lockfile to provide deterministic builds. As a result, it is recommended that all applications check in their `Cargo.lock`. You **SHOULD NOT** commit the `src-tauri/target` folder or any of its contents. ::: diff --git a/src/content/docs/guides/develop/updating-dependencies.mdx b/src/content/docs/guides/develop/updating-dependencies.mdx index 2e9bc0eddc..cb2d9cd6af 100644 --- a/src/content/docs/guides/develop/updating-dependencies.mdx +++ b/src/content/docs/guides/develop/updating-dependencies.mdx @@ -1,105 +1,38 @@ --- -sidebar_position: 3 +title: Updating Dependencies +description: Core concepts for developing with Tauri. --- +{/*TODO: REVISE COPY TO V2 */} -import Tabs from '@theme/Tabs' -import TabItem from '@theme/TabItem' - -# Updating Dependencies +import CommandTabs from '@components/CommandTabs.astro'; ## Update npm Packages If you are using the `tauri` package: - - - -```shell -npm install @tauri-apps/cli@latest @tauri-apps/api@latest -``` - - - - -```shell -yarn upgrade @tauri-apps/cli @tauri-apps/api --latest -``` - - - - -```shell -yarn up @tauri-apps/cli @tauri-apps/api -``` - - - - -```shell -pnpm update @tauri-apps/cli @tauri-apps/api --latest -``` - - - + You can also detect what the latest version of Tauri is on the command line, using: - - - -```shell -npm outdated @tauri-apps/cli -``` - - - - -```shell -yarn outdated @tauri-apps/cli -``` - - - -```shell -pnpm outdated @tauri-apps/cli -``` + - - Alternatively, if you are using the `vue-cli-plugin-tauri` approach: - - - -```shell -npm install vue-cli-plugin-tauri@latest -``` - - - - -```shell -yarn upgrade vue-cli-plugin-tauri --latest -``` - - - - -```shell -yarn up vue-cli-plugin-tauri -``` - - - - -```shell -pnpm update vue-cli-plugin-tauri --latest -``` - - - + ## Update Cargo Packages @@ -114,8 +47,8 @@ tauri-build = "%version%" [dependencies] tauri = { version = "%version%" } ``` - -where `%version%` is the corresponding version number from above. +{/* _TODO MIGRATED FROM V1 ->*/} +where `%version%` is the corresponding version number from above. {/* TODO: (You can just use the `MAJOR.MINOR`) version, like `0.9`.*/} Then do the following: From ef7f2f72b14972d30ce38a693457cc7c71e321c2 Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Wed, 8 Nov 2023 02:59:15 -0300 Subject: [PATCH 03/19] Delete develop.mdx --- src/content/docs/guides/develop.mdx | 11 ----------- 1 file changed, 11 deletions(-) delete mode 100644 src/content/docs/guides/develop.mdx diff --git a/src/content/docs/guides/develop.mdx b/src/content/docs/guides/develop.mdx deleted file mode 100644 index 2b82a7c7f6..0000000000 --- a/src/content/docs/guides/develop.mdx +++ /dev/null @@ -1,11 +0,0 @@ ---- -title: Develop ---- - -import Stub from '@components/Stub.astro'; - - - -- `pnpm tauri [android|ios] dev [--open]` - - From 0f53293213920f5637e14107fa342ea329a4ab16 Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Wed, 8 Nov 2023 02:59:20 -0300 Subject: [PATCH 04/19] update sidebar --- astro.config.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/astro.config.mjs b/astro.config.mjs index 4564f40263..83975cf9bf 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -137,7 +137,7 @@ export default defineConfig({ items: [ { label: 'Develop', - link: 'guides/develop', + autogenerate: { directory: 'guides/develop' }, }, { label: 'Debug', From f1ddfda466c00d295fcc10cea0afdc417d64d424 Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Wed, 8 Nov 2023 18:30:55 -0300 Subject: [PATCH 05/19] migrate i18n-fr --- .../fr/guides/develop/development-cycle.mdx | 34 ++++++++++ .../guides/develop/updating-dependencies.mdx | 63 +++++++++++++++++++ 2 files changed, 97 insertions(+) create mode 100644 src/content/docs/fr/guides/develop/development-cycle.mdx create mode 100644 src/content/docs/fr/guides/develop/updating-dependencies.mdx diff --git a/src/content/docs/fr/guides/develop/development-cycle.mdx b/src/content/docs/fr/guides/develop/development-cycle.mdx new file mode 100644 index 0000000000..c57352df24 --- /dev/null +++ b/src/content/docs/fr/guides/develop/development-cycle.mdx @@ -0,0 +1,34 @@ +--- +title: Development Cycle +description: Concepts de base pour le développement avec Tauri +--- + +import CommandTabs from '@components/CommandTabs.astro'; + +### 1. Démarrez votre serveur de développement + +Maintenant que tout est configuré, vous devez démarrer votre serveur de développement d'applications fourni par votre framework ou bundler d'interface utilisateur (en supposant que vous en utilisiez un, bien sûr). + +:::note + +Chaque framework possède ses propres outils de développement. Il n'entre pas dans le cadre de ce document de les couvrir tous ou de rester à jour. +::: + +### 2. Démarrer la fenêtre de développement de Tauri + + + +La première fois que vous exécutez cette commande, le gestionnaire de packages Rust prend plusieurs minutes pour télécharger et créer tous les packages requis. Comme ils sont mis en cache, les builds suivants sont beaucoup plus rapides, car seul votre code a besoin d'être reconstruit. + +Une fois que Rust a terminé la construction, la vue Web s'ouvre et affiche votre application Web. Vous pouvez apporter des modifications à votre application Web, et si vos outils le permettent, la vue Web devrait se mettre à jour automatiquement, tout comme un navigateur. Lorsque vous apportez des modifications à vos fichiers Rust, ils sont reconstruits automatiquement et votre application redémarre automatiquement. + +:::caution[À propos de Cargo.toml et du contrôle de code source] + +Dans votre référentiel de projet, vous **DEVEZ** valider le `src-tauri/Cargo.lock` avec le `src-tauri/Cargo.toml` sur git car Cargo utilise le fichier de verrouillage pour fournir des versions déterministes. Par conséquent, il est recommandé que toutes les applications enregistrent leur `Cargo.lock`. Vous **NE DEVEZ PAS** valider le dossier `src-tauri/target` ou l'un de ses contenus. + +::: diff --git a/src/content/docs/fr/guides/develop/updating-dependencies.mdx b/src/content/docs/fr/guides/develop/updating-dependencies.mdx new file mode 100644 index 0000000000..9af13aff63 --- /dev/null +++ b/src/content/docs/fr/guides/develop/updating-dependencies.mdx @@ -0,0 +1,63 @@ +--- +title: Mise à jour des dépendances +description: Concepts de base pour le développement avec Tauri +--- + +import CommandTabs from '@components/CommandTabs.astro'; + +## Mettre à jour les packages npm + +Si vous utilisez le package `tauri` : + + + +Vous pouvez également détecter la dernière version de Tauri sur la ligne de commande, en utilisant : + + + + +Sinon, si vous utilisez l'approche `vue-cli-plugin-tauri` : + + + +## Mettre à jour les packages Cargo + +Vous pouvez vérifier les packages obsolètes avec [`cargo outdated`][] ou sur les pages crates.io : [tauri][] / [tauri-build][]. + +Accédez à `src-tauri/Cargo.toml` et remplacez `tauri` et `tauri-build` par + +```toml +[build-dependencies] +tauri-build = "%version%" + +[dependencies] +tauri = { version = "%version%" } +``` + +où `%version%` est le numéro de version correspondant ci-dessus. + +Ensuite, procédez comme suit : + +```shell +cd src-tauri +cargo update +``` + +Vous pouvez également exécuter la commande `cargo upgrade` fournie par [cargo-edit][] qui fait tout cela automatiquement. + +[`cargo outdated`]: https://github.com/kbknapp/cargo-outdated +[tauri]: https://crates.io/crates/tauri/versions +[tauri-build]: https://crates.io/crates/tauri-build/versions +[cargo-edit]: https://github.com/killercup/cargo-edit From ea7241d89bd17c026a424bd7aa1577806ee0aa0f Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Wed, 8 Nov 2023 19:09:34 -0300 Subject: [PATCH 06/19] migrate i18n-zh-cn --- .../guides/develop/development-cycle.mdx | 34 ++++++++++ .../guides/develop/updating-dependencies.mdx | 64 +++++++++++++++++++ 2 files changed, 98 insertions(+) create mode 100644 src/content/docs/zh-CN/guides/develop/development-cycle.mdx create mode 100644 src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx diff --git a/src/content/docs/zh-CN/guides/develop/development-cycle.mdx b/src/content/docs/zh-CN/guides/develop/development-cycle.mdx new file mode 100644 index 0000000000..511f3820df --- /dev/null +++ b/src/content/docs/zh-CN/guides/develop/development-cycle.mdx @@ -0,0 +1,34 @@ +--- +title: 开发周期 +description: 使用 Tauri 开发的核心概念 +--- + +import CommandTabs from '@components/CommandTabs.astro'; + +### 1. 启动开发服务器 + +现在您已经设置好了一切,您应该启动由 UI 框架或捆绑器提供的应用程序开发服务器(当然,假设您使用的是)。 + +:::note + +每个框架都有自己的开发工具。 涵盖所有内容或保持最新状态超出了本文档的范围。 +::: + +### 2. 启动 Tauri 开发窗口 + + + +第一次运行此命令时,Rust 包管理器需要几分钟来下载和构建所有必需的包。 由于它们是缓存的,因此后续构建要快得多,因为只有新的代码需要重新构建。 + +一旦 Rust 完成构建,Web 视图就会打开,显示您的 Web 应用程序。 您可以对 Web 应用程序进行更改,如果您的工具启用了它,则 Web 视图应自动更新,就像浏览器一样。 当您对 Rust 文件进行更改时,它们会自动重建,并且您的应用程序会自动重新启动。 + +:::caution[info 关于 Cargo.toml 和源代码管理] + +在您的项目仓库中,您应该将`src-tauri/Cargo.lock`和`src-tauri/Cargo.toml`提交到 git,因为 Cargo 使用锁文件来提供确定性构建。 因此,建议所有应用程序都签入到 `Cargo.lock`。 您不应该提交`src-tauri/target`文件夹或其任何内容。 + +::: diff --git a/src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx b/src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx new file mode 100644 index 0000000000..b6ee911144 --- /dev/null +++ b/src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx @@ -0,0 +1,64 @@ +--- +title: 更新依赖关系 +description: 使用 Tauri 开发的核心概念 +--- + +import CommandTabs from '@components/CommandTabs.astro'; + +## 更新 npm 包 + +如果您正在使用 `tauri` 包: + + + +您还可以通过以下方式检测最新版本的 Tauri 在命令行上: + + + + + +或者,如果您正在使用 `vue-cli-plugin-tauri` 方法: + + + + +## 更新 Cargo 包 + +您可以用 [`Cargo outdated`][] 或在 crates.io 页面上检查过期的包: [tauri][] / [tauri-build][] + +打开 `src-tauri/Cargo.toml` 并更改 `tauri` 和 `tauri-build` + +```toml +[build-dependencies] +tauri-build = "%version%" + +[dependencies] +tauri = { version = "%version%" } +``` +其中 `%version%` 是上面相应的版本号 + +然后执行以下操作: + +```shell +cd src-tauri +cargo update +``` + +或者,您可以运行 `cargo upgrade` 命令,由 [ cargo-edit][] 提供,这将自动完成所有这一切。 + +[`cargo outdated`]: https://github.com/kbknapp/cargo-outdated +[tauri]: https://crates.io/crates/tauri/versions +[tauri-build]: https://crates.io/crates/tauri-build/versions +[cargo-edit]: https://github.com/killercup/cargo-edit From 984dcf414310e90467e1e338780b21b5b3cd5f26 Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Thu, 16 Nov 2023 23:46:42 -0300 Subject: [PATCH 07/19] add redirects --- astro.config.mjs | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/astro.config.mjs b/astro.config.mjs index 83975cf9bf..da6dca9c59 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -227,5 +227,23 @@ export default defineConfig({ '/blog/2023/06/14/tauri-1-4': '/blog/tauri-1-4', '/blog/2023/06/15/tauri-board-elections-and-governance-updates': '/blog/tauri-board-elections-and-governance-updates', + // + // v1 /guides/development -> /guides/develop + '/v1/guides/development/development-cycle': '/guides/develop/development-cycle', + '/v1/guides/development/updating-dependencies': '/guides/develop/updating-dependencies', + // i18n fr + '/fr/v1/guides/development/development-cycle/': '/fr/guides/develop/development-cycle/', + '/fr/v1/guides/development/updating-dependencies/': '/fr/guides/develop/updating-dependencies/', + // i18n ko + '/ko/v1/guides/development/development-cycle/': '/ko/guides/develop/development-cycle/', + '/ko/v1/guides/development/updating-dependencies/': '/ko/guides/develop/updating-dependencies/', + // i18n zh-cn + '/zh-cn/v1/guides/development/development-cycle/': '/zh-cn/guides/develop/development-cycle/', + '/zh-cn/v1/guides/development/updating-dependencies/': '/zh-cn/guides/develop/updating-dependencies/', + // i18n it + '/it/v1/guides/development/development-cycle/': '/it/guides/develop/development-cycle/', + '/it/v1/guides/development/updating-dependencies/': '/it/guides/develop/updating-dependencies/' + // }, }); + From 74c147ccaa18d9cb59f44fcefb122a7381134fa2 Mon Sep 17 00:00:00 2001 From: Vitor Ayres Date: Mon, 27 Nov 2023 22:17:29 -0300 Subject: [PATCH 08/19] Update `development-cycle.mdx` Co-authored-by: Lorenzo Lewis --- src/content/docs/fr/guides/develop/development-cycle.mdx | 1 + 1 file changed, 1 insertion(+) diff --git a/src/content/docs/fr/guides/develop/development-cycle.mdx b/src/content/docs/fr/guides/develop/development-cycle.mdx index c57352df24..c872f1e8af 100644 --- a/src/content/docs/fr/guides/develop/development-cycle.mdx +++ b/src/content/docs/fr/guides/develop/development-cycle.mdx @@ -12,6 +12,7 @@ Maintenant que tout est configuré, vous devez démarrer votre serveur de dével :::note Chaque framework possède ses propres outils de développement. Il n'entre pas dans le cadre de ce document de les couvrir tous ou de rester à jour. + ::: ### 2. Démarrer la fenêtre de développement de Tauri From 41863f4e1f8b138b4377e2114f6a2c4041e40292 Mon Sep 17 00:00:00 2001 From: Vitor Ayres Date: Mon, 27 Nov 2023 22:18:35 -0300 Subject: [PATCH 09/19] Update `development-cycle.mdx` Co-authored-by: Lorenzo Lewis --- src/content/docs/guides/develop/development-cycle.mdx | 1 + 1 file changed, 1 insertion(+) diff --git a/src/content/docs/guides/develop/development-cycle.mdx b/src/content/docs/guides/develop/development-cycle.mdx index ad4d813d1c..e66e78478a 100644 --- a/src/content/docs/guides/develop/development-cycle.mdx +++ b/src/content/docs/guides/develop/development-cycle.mdx @@ -13,6 +13,7 @@ Now that you have everything set up, you should start your application developme :::note Every framework has its own development tooling. It is outside of the scope of this document to cover them all or stay up to date. + ::: ### 2. Start Tauri Development Window From b8196856da47a9ae05edd1f04e295d657324b870 Mon Sep 17 00:00:00 2001 From: Vitor Ayres Date: Mon, 27 Nov 2023 22:18:54 -0300 Subject: [PATCH 10/19] Update `development-cycle.mdx` Co-authored-by: Lorenzo Lewis --- src/content/docs/zh-CN/guides/develop/development-cycle.mdx | 1 + 1 file changed, 1 insertion(+) diff --git a/src/content/docs/zh-CN/guides/develop/development-cycle.mdx b/src/content/docs/zh-CN/guides/develop/development-cycle.mdx index 511f3820df..4c408bf10e 100644 --- a/src/content/docs/zh-CN/guides/develop/development-cycle.mdx +++ b/src/content/docs/zh-CN/guides/develop/development-cycle.mdx @@ -12,6 +12,7 @@ import CommandTabs from '@components/CommandTabs.astro'; :::note 每个框架都有自己的开发工具。 涵盖所有内容或保持最新状态超出了本文档的范围。 + ::: ### 2. 启动 Tauri 开发窗口 From 089fc62fe25e072a7ab2b2dd9a03930520efb801 Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Mon, 27 Nov 2023 22:33:17 -0300 Subject: [PATCH 11/19] Revert "Delete develop.mdx" This reverts commit ef7f2f72b14972d30ce38a693457cc7c71e321c2. --- src/content/docs/guides/develop.mdx | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 src/content/docs/guides/develop.mdx diff --git a/src/content/docs/guides/develop.mdx b/src/content/docs/guides/develop.mdx new file mode 100644 index 0000000000..2b82a7c7f6 --- /dev/null +++ b/src/content/docs/guides/develop.mdx @@ -0,0 +1,11 @@ +--- +title: Develop +--- + +import Stub from '@components/Stub.astro'; + + + +- `pnpm tauri [android|ios] dev [--open]` + + From f98a8193eee1cc9bc28131a890006355bc32e74c Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Mon, 27 Nov 2023 22:52:37 -0300 Subject: [PATCH 12/19] Revert "update sidebar" This reverts commit 0f53293213920f5637e14107fa342ea329a4ab16. --- astro.config.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/astro.config.mjs b/astro.config.mjs index da6dca9c59..51d14c6059 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -137,7 +137,7 @@ export default defineConfig({ items: [ { label: 'Develop', - autogenerate: { directory: 'guides/develop' }, + link: 'guides/develop', }, { label: 'Debug', From 4f14d79d9f5eae42e55984d0249e4839544e6fce Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Mon, 27 Nov 2023 22:53:14 -0300 Subject: [PATCH 13/19] LinkCards --- src/content/docs/guides/develop.mdx | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/content/docs/guides/develop.mdx b/src/content/docs/guides/develop.mdx index 2b82a7c7f6..4188b4aceb 100644 --- a/src/content/docs/guides/develop.mdx +++ b/src/content/docs/guides/develop.mdx @@ -2,10 +2,11 @@ title: Develop --- -import Stub from '@components/Stub.astro'; +import { LinkCard, CardGrid } from '@astrojs/starlight/components'; - + + -- `pnpm tauri [android|ios] dev [--open]` - - +{/* */} +{/* description="Now that you have everything set up, you should start your application development server provided by your UI frame..." */} +{/* description="See how to update to the latest version of Tauri with npm, pnpm, yarn or cargo" */} \ No newline at end of file From cc6abc0ecfa767a520419d7db986900fe859a996 Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Mon, 27 Nov 2023 22:53:38 -0300 Subject: [PATCH 14/19] Linkcard list without description --- src/content/docs/guides/develop.mdx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/content/docs/guides/develop.mdx b/src/content/docs/guides/develop.mdx index 4188b4aceb..897ba8e7db 100644 --- a/src/content/docs/guides/develop.mdx +++ b/src/content/docs/guides/develop.mdx @@ -2,11 +2,7 @@ title: Develop --- -import { LinkCard, CardGrid } from '@astrojs/starlight/components'; +import { LinkCard } from '@astrojs/starlight/components'; - - -{/* */} -{/* description="Now that you have everything set up, you should start your application development server provided by your UI frame..." */} -{/* description="See how to update to the latest version of Tauri with npm, pnpm, yarn or cargo" */} \ No newline at end of file + \ No newline at end of file From 84c4523c9b02dc04baf623d5cec7a935f8a82e0d Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Mon, 27 Nov 2023 23:10:37 -0300 Subject: [PATCH 15/19] add _ko pages - disabled --- .../docs/_ko/develop/development-cycle.mdx | 36 ++++++++++ .../_ko/develop/updating-dependencies.mdx | 65 +++++++++++++++++++ 2 files changed, 101 insertions(+) create mode 100644 src/content/docs/_ko/develop/development-cycle.mdx create mode 100644 src/content/docs/_ko/develop/updating-dependencies.mdx diff --git a/src/content/docs/_ko/develop/development-cycle.mdx b/src/content/docs/_ko/develop/development-cycle.mdx new file mode 100644 index 0000000000..311c765c85 --- /dev/null +++ b/src/content/docs/_ko/develop/development-cycle.mdx @@ -0,0 +1,36 @@ +--- +title: 개발 주기 +description: Tauri로 개발하기 위한 핵심 개념 +--- + +import CommandTabs from '@components/CommandTabs.astro'; + +### 1. 개발 서버 시작 + +이제 모든 것이 설정되었으므로 UI 프레임워크 또는 번들러에서 제공하는 애플리케이션 개발 서버를 시작해야 합니다(물론, 둘 중 하나를 사용한다고 가정). + +:::note + +모든 프레임워크에는 자체 개발 도구가 있습니다. 모든 내용을 다루거나 최신 정보로 갱신하는 것은 이 문서의 범위를 밖입니다. + +::: + +### 2. Tauri 개발 윈도우 시작 + + + + +이 명령을 처음 실행하면 Rust 패키지 관리자가 필요한 모든 패키지를 다운로드하고 빌드하는 데 몇 분이 소요됩니다. 이들은 캐시되기 때문에 코드만 재빌드하면 되므로 후속 빌드가 훨씬 더 빠릅니다. + +Rust가 빌드를 완료하면 Webview가 열리고 웹 앱이 표시됩니다. 웹 앱을 변경할 수 있으며 도구에서 지원하는 경우, WebView는 브라우저처럼 자동으로 업데이트됩니다. Rust 파일을 변경하면 자동으로 다시 빌드되고 앱이 자동으로 다시 시작됩니다. + +:::caution[Cargo.toml 및 소스 제어 정보] + +프로젝트 저장소에서 `src-tauri/Cargo.toml`과 함께 `src-tauri/Cargo.lock`을 git에 커밋해야 합니다. 왜냐하면 Cargo는 결정된 빌드를 제공하기 위해 잠금 파일을 사용하기 때문입니다. 따라서, 모든 애플리케이션의 Cargo.lock을 체크인하는 것이 좋습니다. 단, `src-tauri/target` 폴더 또는 그 내용을 커밋하면 안 됩니다. + +::: diff --git a/src/content/docs/_ko/develop/updating-dependencies.mdx b/src/content/docs/_ko/develop/updating-dependencies.mdx new file mode 100644 index 0000000000..05e597149b --- /dev/null +++ b/src/content/docs/_ko/develop/updating-dependencies.mdx @@ -0,0 +1,65 @@ +--- +title: 종속성 업데이트하기 +description: Tauri로 개발하기 위한 핵심 개념 +--- +{/*TODO: REVISE COPY TO V2 */} + +import CommandTabs from '@components/CommandTabs.astro'; + +## Npm 패키지 업데이트 + +`tauri` 패키지를 사용할 경우: + + + +다음 항목을 사용하여 명령줄에서 최신 버전의 Tauri를 검색할 수 있습니다: + + + + + +대안으로 `vue-cli-plugin-tauri` 방식을 사용하는 경우: + + + +## Cargo 패키지 업데이트 + +[`cargo outdated`][]나 crates.io 페이지에서 이전 패키지 내용을 확인할 수 있습니다: [tauri][] / [tauri-build][]. + +`src-tauri/Cargo.toml`에서 `tauri`와 `tauri-build` 를 아래와 같이 바꿔줍니다. + +```toml +[build-dependencies] +tauri-build = "%version%" + +[dependencies] +tauri = { version = "%version%" } +``` + +여기서 `%version%`는 위에 버전 번호입니다. {/* TODO: (You can just use the `MAJOR.MINOR`) version, like `0.9`. .*/} + +그리고, 아래와 같이 실행합니다. + +```shell +cd src-tauri +cargo update +``` + +또한, [cargo-edit][]에서 제공하는 `cargo upgrade` 명령을 실행하여 이 모든 작업을 자동으로 수행할 수 있습니다. + +[`cargo outdated`]: https://github.com/kbknapp/cargo-outdated +[tauri]: https://crates.io/crates/tauri/versions +[tauri-build]: https://crates.io/crates/tauri-build/versions +[cargo-edit]: https://github.com/killercup/cargo-edit From 0ba0d4f86ebef27fda9e4ef57520f35f9277250e Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Mon, 27 Nov 2023 23:40:12 -0300 Subject: [PATCH 16/19] move `develop.mdx` -> `develop/index.mdx` --- astro.config.mjs | 2 +- src/content/docs/guides/{develop.mdx => develop/index.mdx} | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename src/content/docs/guides/{develop.mdx => develop/index.mdx} (100%) diff --git a/astro.config.mjs b/astro.config.mjs index 51d14c6059..b26a60f2b3 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -137,7 +137,7 @@ export default defineConfig({ items: [ { label: 'Develop', - link: 'guides/develop', + link: 'guides/develop/', }, { label: 'Debug', diff --git a/src/content/docs/guides/develop.mdx b/src/content/docs/guides/develop/index.mdx similarity index 100% rename from src/content/docs/guides/develop.mdx rename to src/content/docs/guides/develop/index.mdx From 5ca0b4a15e31287cc04cee7d05650e5eda38409a Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Thu, 30 Nov 2023 12:24:18 -0300 Subject: [PATCH 17/19] LinkCard List without description (for now) --- src/content/docs/guides/develop/index.mdx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/content/docs/guides/develop/index.mdx b/src/content/docs/guides/develop/index.mdx index 897ba8e7db..847184ed5a 100644 --- a/src/content/docs/guides/develop/index.mdx +++ b/src/content/docs/guides/develop/index.mdx @@ -1,8 +1,11 @@ --- title: Develop +description: Core concepts for developing with Tauri. --- -import { LinkCard } from '@astrojs/starlight/components'; +import { LinkCard, CardGrid } from '@astrojs/starlight/components'; - - \ No newline at end of file + + + + \ No newline at end of file From 78cb3e6d0a29d1fb4a461c7b78ba9298d3204adc Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Thu, 30 Nov 2023 12:36:39 -0300 Subject: [PATCH 18/19] move descriptions and create index page `index.md` was `develop.md`. Page title was present in v1 docs. --- src/content/docs/_ko/develop/development-cycle.mdx | 1 - src/content/docs/_ko/develop/index.mdx | 11 +++++++++++ .../docs/_ko/develop/updating-dependencies.mdx | 2 -- .../docs/fr/guides/develop/development-cycle.mdx | 1 - src/content/docs/fr/guides/develop/index.mdx | 11 +++++++++++ .../docs/fr/guides/develop/updating-dependencies.mdx | 1 - src/content/docs/guides/develop/development-cycle.mdx | 1 - .../docs/guides/develop/updating-dependencies.mdx | 1 - .../docs/zh-CN/guides/develop/development-cycle.mdx | 1 - src/content/docs/zh-CN/guides/develop/index.mdx | 11 +++++++++++ .../zh-CN/guides/develop/updating-dependencies.mdx | 1 - 11 files changed, 33 insertions(+), 9 deletions(-) create mode 100644 src/content/docs/_ko/develop/index.mdx create mode 100644 src/content/docs/fr/guides/develop/index.mdx create mode 100644 src/content/docs/zh-CN/guides/develop/index.mdx diff --git a/src/content/docs/_ko/develop/development-cycle.mdx b/src/content/docs/_ko/develop/development-cycle.mdx index 311c765c85..4f84c7f43a 100644 --- a/src/content/docs/_ko/develop/development-cycle.mdx +++ b/src/content/docs/_ko/develop/development-cycle.mdx @@ -1,6 +1,5 @@ --- title: 개발 주기 -description: Tauri로 개발하기 위한 핵심 개념 --- import CommandTabs from '@components/CommandTabs.astro'; diff --git a/src/content/docs/_ko/develop/index.mdx b/src/content/docs/_ko/develop/index.mdx new file mode 100644 index 0000000000..6eea60091a --- /dev/null +++ b/src/content/docs/_ko/develop/index.mdx @@ -0,0 +1,11 @@ +--- +title: 개발 +description: Tauri로 개발하기 위한 핵심 개념 +--- + +import { LinkCard, CardGrid } from '@astrojs/starlight/components'; + + + + + \ No newline at end of file diff --git a/src/content/docs/_ko/develop/updating-dependencies.mdx b/src/content/docs/_ko/develop/updating-dependencies.mdx index 05e597149b..aa6c445445 100644 --- a/src/content/docs/_ko/develop/updating-dependencies.mdx +++ b/src/content/docs/_ko/develop/updating-dependencies.mdx @@ -1,8 +1,6 @@ --- title: 종속성 업데이트하기 -description: Tauri로 개발하기 위한 핵심 개념 --- -{/*TODO: REVISE COPY TO V2 */} import CommandTabs from '@components/CommandTabs.astro'; diff --git a/src/content/docs/fr/guides/develop/development-cycle.mdx b/src/content/docs/fr/guides/develop/development-cycle.mdx index c872f1e8af..0c837fab31 100644 --- a/src/content/docs/fr/guides/develop/development-cycle.mdx +++ b/src/content/docs/fr/guides/develop/development-cycle.mdx @@ -1,6 +1,5 @@ --- title: Development Cycle -description: Concepts de base pour le développement avec Tauri --- import CommandTabs from '@components/CommandTabs.astro'; diff --git a/src/content/docs/fr/guides/develop/index.mdx b/src/content/docs/fr/guides/develop/index.mdx new file mode 100644 index 0000000000..bb9c83f723 --- /dev/null +++ b/src/content/docs/fr/guides/develop/index.mdx @@ -0,0 +1,11 @@ +--- +title: Développement +description: Concepts de base pour le développement avec Tauri +--- + +import { LinkCard, CardGrid } from '@astrojs/starlight/components'; + + + + + \ No newline at end of file diff --git a/src/content/docs/fr/guides/develop/updating-dependencies.mdx b/src/content/docs/fr/guides/develop/updating-dependencies.mdx index 9af13aff63..4dd4788571 100644 --- a/src/content/docs/fr/guides/develop/updating-dependencies.mdx +++ b/src/content/docs/fr/guides/develop/updating-dependencies.mdx @@ -1,6 +1,5 @@ --- title: Mise à jour des dépendances -description: Concepts de base pour le développement avec Tauri --- import CommandTabs from '@components/CommandTabs.astro'; diff --git a/src/content/docs/guides/develop/development-cycle.mdx b/src/content/docs/guides/develop/development-cycle.mdx index e66e78478a..1a76ac8294 100644 --- a/src/content/docs/guides/develop/development-cycle.mdx +++ b/src/content/docs/guides/develop/development-cycle.mdx @@ -1,6 +1,5 @@ --- title: Development Cycle -description: Core concepts for developing with Tauri. --- {/*TODO: REVISE COPY TO V2 */} diff --git a/src/content/docs/guides/develop/updating-dependencies.mdx b/src/content/docs/guides/develop/updating-dependencies.mdx index cb2d9cd6af..78cfcd12c4 100644 --- a/src/content/docs/guides/develop/updating-dependencies.mdx +++ b/src/content/docs/guides/develop/updating-dependencies.mdx @@ -1,6 +1,5 @@ --- title: Updating Dependencies -description: Core concepts for developing with Tauri. --- {/*TODO: REVISE COPY TO V2 */} diff --git a/src/content/docs/zh-CN/guides/develop/development-cycle.mdx b/src/content/docs/zh-CN/guides/develop/development-cycle.mdx index 4c408bf10e..bbe0c1fe5a 100644 --- a/src/content/docs/zh-CN/guides/develop/development-cycle.mdx +++ b/src/content/docs/zh-CN/guides/develop/development-cycle.mdx @@ -1,6 +1,5 @@ --- title: 开发周期 -description: 使用 Tauri 开发的核心概念 --- import CommandTabs from '@components/CommandTabs.astro'; diff --git a/src/content/docs/zh-CN/guides/develop/index.mdx b/src/content/docs/zh-CN/guides/develop/index.mdx new file mode 100644 index 0000000000..804b643a93 --- /dev/null +++ b/src/content/docs/zh-CN/guides/develop/index.mdx @@ -0,0 +1,11 @@ +--- +title: 开发 +description: C使用 Tauri 开发的核心概念 +--- + +import { LinkCard, CardGrid } from '@astrojs/starlight/components'; + + + + + \ No newline at end of file diff --git a/src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx b/src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx index b6ee911144..6b9b7e0a75 100644 --- a/src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx +++ b/src/content/docs/zh-CN/guides/develop/updating-dependencies.mdx @@ -1,6 +1,5 @@ --- title: 更新依赖关系 -description: 使用 Tauri 开发的核心概念 --- import CommandTabs from '@components/CommandTabs.astro'; From 104e8101857932351b8f0414231e33cd59fbb71c Mon Sep 17 00:00:00 2001 From: vasfvitor Date: Thu, 30 Nov 2023 12:39:52 -0300 Subject: [PATCH 19/19] fix closing tags --- src/content/docs/_ko/develop/index.mdx | 2 +- src/content/docs/fr/guides/develop/index.mdx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/content/docs/_ko/develop/index.mdx b/src/content/docs/_ko/develop/index.mdx index 6eea60091a..325a9f450b 100644 --- a/src/content/docs/_ko/develop/index.mdx +++ b/src/content/docs/_ko/develop/index.mdx @@ -8,4 +8,4 @@ import { LinkCard, CardGrid } from '@astrojs/starlight/components'; - \ No newline at end of file + \ No newline at end of file diff --git a/src/content/docs/fr/guides/develop/index.mdx b/src/content/docs/fr/guides/develop/index.mdx index bb9c83f723..e75dd53dec 100644 --- a/src/content/docs/fr/guides/develop/index.mdx +++ b/src/content/docs/fr/guides/develop/index.mdx @@ -8,4 +8,4 @@ import { LinkCard, CardGrid } from '@astrojs/starlight/components'; - \ No newline at end of file + \ No newline at end of file