From 06cc6e7d88acdac44a2903b741b4993d6e92aaa9 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Thu, 24 Oct 2024 15:59:12 -0400 Subject: [PATCH 1/7] sv blog post --- .../blog/2024-10-24-sv-the-svelte-cli.md | 76 +++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md diff --git a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md new file mode 100644 index 0000000000..83415d5a32 --- /dev/null +++ b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md @@ -0,0 +1,76 @@ +--- +title: Terminal velocity +description: Introducing `sv`, the brand new Svelte CLI +author: Ben McCann +authorURL: https://www.benmccann.com/ +--- + +We’ve just released [sv](https://npmjs.com/package/sv), a new Command Line Interface (CLI) for creating, enhancing, and upgrading Svelte projects. + +One of the most common question we hear is "how to I set up Tailwind on my new project?" Tailwind has SvelteKit documentation, but it lists eight steps. While the community-led `svelte-add` project could automate it, few knew about it. + +
+
+
+ +
+ +
Introducing sv at Svelte Summit Fall 2024
+
+
+ +Now, we're offering that functionality via our own CLI, directly within the project creation screen. And not just for Tailwind — we have built-in add-ons for formatting, linting, testing, setting up databases and auth and i18n and more. Just run `npx sv create` and follow the prompts: + +``` +$ npx sv create + +Need to install the following packages: +sv@0.5.8 +Ok to proceed? (y) + +┌ Welcome to the Svelte CLI! (v0.5.8) +│ +◇ Where would you like your project to be created? +│ my-new-app +│ +◇ Which template would you like? +│ SvelteKit minimal +│ +◇ Add type checking with Typescript? +│ Yes, using Typescript syntax +│ +◆ Project created +│ +◆ What would you like to add to your project? (use arrow keys / space bar) +│ ◻ prettier (https://prettier.io) +│ ◻ eslint +│ ◻ vitest +│ ◻ playwright +│ ◻ tailwindcss +│ ◻ drizzle +│ ◻ lucia +│ ◻ mdsvex +│ ◻ paraglide +│ ◻ storybook +└ +``` + +You can also run `npx sv add` to apply add-ons to existing projects. In the near future, we will also be supporting add-ons contributed by the community within `sv`. If you’re interested in building one, please subscribe to [the issue](https://github.com/sveltejs/cli/issues/184) in [the CLI repository](https://github.com/sveltejs/cli) to be notified when third party add-ons are supported. + +You can also run `sv migrate svelte-5` to upgrade your Svelte 4 projects to Svelte 5. The migration functionality can also be found in the Svelte VS Code extension as well as svelte.dev/playground. + +A huge thank you to Christopher Brown ([chbrown](https://github.com/chbrown)) who donated the sv package name on npm to make this CLI possible. This package merges the previous `create-svelte` and community-led `svelte-add` tools into a single package. Thank you to Manuel ([manuel3108](https://github.com/manuel3108)) and Adrian ([CokaKoala](https://github.com/AdrianGonz97)) who recently took over maintenance of the `svelte-add` project and have joined as the newest Svelte maintainers in making this project an official part of Svelte. Also thank you to J ([babichjacob](https://github.com/babichjacob)) for creating the `svelte-add` project and successfully stewarding it for years as an important part of the Svelte community. + +To see the CLI in action, check out this demo from Ben Davis and t3.gg... + +
+
+
+ +
+ +
Introducing sv at Svelte Summit Fall 2024
+
+
+ +...or run `npx sv` to try it out yourself. From a65f86b6df07c85175f28cf39f6a9468ce4f6fae Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Thu, 24 Oct 2024 16:07:37 -0400 Subject: [PATCH 2/7] link --- apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md index 83415d5a32..9e1807f9b9 100644 --- a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md +++ b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md @@ -7,7 +7,7 @@ authorURL: https://www.benmccann.com/ We’ve just released [sv](https://npmjs.com/package/sv), a new Command Line Interface (CLI) for creating, enhancing, and upgrading Svelte projects. -One of the most common question we hear is "how to I set up Tailwind on my new project?" Tailwind has SvelteKit documentation, but it lists eight steps. While the community-led `svelte-add` project could automate it, few knew about it. +One of the most common question we hear is "how to I set up Tailwind on my new project?" Tailwind has [SvelteKit documentation](https://tailwindcss.com/docs/guides/sveltekit), but it lists eight steps. While the community-led `svelte-add` project could automate it, few knew about it.
From ab9cba248091e0447a4e246273f155c40d78f911 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Thu, 24 Oct 2024 16:08:16 -0400 Subject: [PATCH 3/7] tweaks --- apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md index 9e1807f9b9..74adb5e67d 100644 --- a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md +++ b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md @@ -7,7 +7,7 @@ authorURL: https://www.benmccann.com/ We’ve just released [sv](https://npmjs.com/package/sv), a new Command Line Interface (CLI) for creating, enhancing, and upgrading Svelte projects. -One of the most common question we hear is "how to I set up Tailwind on my new project?" Tailwind has [SvelteKit documentation](https://tailwindcss.com/docs/guides/sveltekit), but it lists eight steps. While the community-led `svelte-add` project could automate it, few knew about it. +One of the most common question we hear is "how to I set up Tailwind on my new project?". Tailwind has [SvelteKit documentation](https://tailwindcss.com/docs/guides/sveltekit), but it lists eight steps. While the community-led `svelte-add` project could automate the process, few knew about it.
From af49a5bb4f278f89a8bd28c3ee575b40bc16f2cb Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Thu, 24 Oct 2024 16:09:30 -0400 Subject: [PATCH 4/7] tweak --- apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md index 74adb5e67d..3ce68046e3 100644 --- a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md +++ b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md @@ -57,7 +57,7 @@ Ok to proceed? (y) You can also run `npx sv add` to apply add-ons to existing projects. In the near future, we will also be supporting add-ons contributed by the community within `sv`. If you’re interested in building one, please subscribe to [the issue](https://github.com/sveltejs/cli/issues/184) in [the CLI repository](https://github.com/sveltejs/cli) to be notified when third party add-ons are supported. -You can also run `sv migrate svelte-5` to upgrade your Svelte 4 projects to Svelte 5. The migration functionality can also be found in the Svelte VS Code extension as well as svelte.dev/playground. +You can also run `sv migrate svelte-5` to upgrade your Svelte 4 projects to Svelte 5. The migration functionality can also be found in [Svelte for VS Code](https://marketplace.visualstudio.com/items?itemName=svelte.svelte-vscode) as well as in the [playground](/playground). A huge thank you to Christopher Brown ([chbrown](https://github.com/chbrown)) who donated the sv package name on npm to make this CLI possible. This package merges the previous `create-svelte` and community-led `svelte-add` tools into a single package. Thank you to Manuel ([manuel3108](https://github.com/manuel3108)) and Adrian ([CokaKoala](https://github.com/AdrianGonz97)) who recently took over maintenance of the `svelte-add` project and have joined as the newest Svelte maintainers in making this project an official part of Svelte. Also thank you to J ([babichjacob](https://github.com/babichjacob)) for creating the `svelte-add` project and successfully stewarding it for years as an important part of the Svelte community. From ea0f1b1da5cd899b50ffc1723797f3ecd2ed91c4 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Thu, 24 Oct 2024 17:27:29 -0400 Subject: [PATCH 5/7] Update apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md Co-authored-by: Simon H <5968653+dummdidumm@users.noreply.github.com> --- apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md index 3ce68046e3..613bdd2d57 100644 --- a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md +++ b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md @@ -57,7 +57,7 @@ Ok to proceed? (y) You can also run `npx sv add` to apply add-ons to existing projects. In the near future, we will also be supporting add-ons contributed by the community within `sv`. If you’re interested in building one, please subscribe to [the issue](https://github.com/sveltejs/cli/issues/184) in [the CLI repository](https://github.com/sveltejs/cli) to be notified when third party add-ons are supported. -You can also run `sv migrate svelte-5` to upgrade your Svelte 4 projects to Svelte 5. The migration functionality can also be found in [Svelte for VS Code](https://marketplace.visualstudio.com/items?itemName=svelte.svelte-vscode) as well as in the [playground](/playground). +It doesn't stop there. Over time, Svelte has accumulated a handful of CLIs: `svelte-check` type-checks your project from the command line, `npx svelte-migrate` helps you upgrade to new major versions, and in the future we might have even more capabilities. Remembering the package name of each tool is cumbersome, which is why we unify the experience under one roof, `sv`. That means you can now run `sv migrate svelte-5` to upgrade your Svelte 4 projects to Svelte 5. (The migration functionality can also be found in [Svelte for VS Code](https://marketplace.visualstudio.com/items?itemName=svelte.svelte-vscode) as well as in the [playground](/playground).) A huge thank you to Christopher Brown ([chbrown](https://github.com/chbrown)) who donated the sv package name on npm to make this CLI possible. This package merges the previous `create-svelte` and community-led `svelte-add` tools into a single package. Thank you to Manuel ([manuel3108](https://github.com/manuel3108)) and Adrian ([CokaKoala](https://github.com/AdrianGonz97)) who recently took over maintenance of the `svelte-add` project and have joined as the newest Svelte maintainers in making this project an official part of Svelte. Also thank you to J ([babichjacob](https://github.com/babichjacob)) for creating the `svelte-add` project and successfully stewarding it for years as an important part of the Svelte community. From 80bca346a858fe8f982879035d5e20e650ad9ca6 Mon Sep 17 00:00:00 2001 From: Simon H <5968653+dummdidumm@users.noreply.github.com> Date: Fri, 25 Oct 2024 07:54:56 +0200 Subject: [PATCH 6/7] Update apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md Co-authored-by: Tobias Kohlbau --- apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md index 613bdd2d57..d357816837 100644 --- a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md +++ b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md @@ -7,7 +7,7 @@ authorURL: https://www.benmccann.com/ We’ve just released [sv](https://npmjs.com/package/sv), a new Command Line Interface (CLI) for creating, enhancing, and upgrading Svelte projects. -One of the most common question we hear is "how to I set up Tailwind on my new project?". Tailwind has [SvelteKit documentation](https://tailwindcss.com/docs/guides/sveltekit), but it lists eight steps. While the community-led `svelte-add` project could automate the process, few knew about it. +One of the most common question we hear is "how do I set up Tailwind on my new project?". Tailwind has [SvelteKit documentation](https://tailwindcss.com/docs/guides/sveltekit), but it lists eight steps. While the community-led `svelte-add` project could automate the process, few knew about it.
From fbb9cc54e4e4b1a4bbac454cd16dcd9dabf225f3 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Fri, 25 Oct 2024 10:15:32 -0400 Subject: [PATCH 7/7] tweaks --- .../content/blog/2024-10-24-sv-the-svelte-cli.md | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md index d357816837..0fd59b0908 100644 --- a/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md +++ b/apps/svelte.dev/content/blog/2024-10-24-sv-the-svelte-cli.md @@ -1,6 +1,6 @@ --- -title: Terminal velocity -description: Introducing `sv`, the brand new Svelte CLI +title: Introducing the new Svelte CLI +description: Tailwind, auth, databases and more — just an `npx sv` away author: Ben McCann authorURL: https://www.benmccann.com/ --- @@ -24,10 +24,6 @@ Now, we're offering that functionality via our own CLI, directly within the proj ``` $ npx sv create -Need to install the following packages: -sv@0.5.8 -Ok to proceed? (y) - ┌ Welcome to the Svelte CLI! (v0.5.8) │ ◇ Where would you like your project to be created?