Repository navigation
fix(init): clarify starter messages and cd into a new subfolder - #853
Merged
Merged
Conversation
Scaffolding a starter no longer reports that the project "already has pages, routes, or migrations, skipping demo", and it no longer repeats the database that the starter prompt just showed. The empty-project notice now reads "Creating a Pages starter." because prompts follow it. When init creates the project in a new subfolder, the final dev command starts with `cd <folder> &&`, since the shell stays in the parent directory. The initial commit hint shares the same path quoting. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
morinokami
marked this pull request as draft
November 16, 2026 13:18
cpojer
approved these changes
Nov 17, 2026
cpojer
left a comment
Member
There was a problem hiding this comment.
Nice improvements and fixes, thanks!
cpojer
marked this pull request as ready for review
November 17, 2026 00:28
This was referenced Nov 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR fixes the output of
void initwhen it creates a new project. Some messages were misleading, and the suggested dev command did not work when init created the project in a new subfolder.More PRs will follow to shorten the rest of the
void initoutput in the style ofvp create, for example with a short summary instead of one line per created file.Changes
No "skipping demo" after creating a starter
Right after writing the starter's files, init printed "Project already has pages, routes, or migrations, skipping demo". This reads as if init found files it did not expect, or failed to add something. The demo is only offered to existing projects without pages, routes, migrations or a schema. A new starter already comes with its own pages, so there is nothing to report. The demo check now runs only for existing projects, which keep all three of its messages.
No repeat of the database chosen for a starter
Right after the user chose the database (at the starter prompt or with
--starter), init repeated it: "Using default D1 (SQLite) configuration", or "Configured PostgreSQL in void.config.ts" for PostgreSQL. The D1 line also uses the blue●marker, which stands out more than the gray lines around it. The starter flow now writes the database setting without a message. Existing projects keep these lines, because there they tell whethervoid.config.tschanged.No progress wording before the questions
"Empty project detected. Scaffolding a Pages starter..." reads like a progress line, but init then asks for the toolchain, framework and starter before it writes anything. The new wording, "Creating a Pages starter.", drops the trailing "...".
cdin the dev command for a new subfolder (bug fix)When init runs in a non-empty folder and the user chooses "Create a new subfolder", the shell stays in the parent folder. The last line still said
Run `vp dev`, which does not start the new app from there. TheGit (optional)hint already covers this case withgit -C <path>, andvp createprintscd my-app && vp dev. The last line now starts withcd <folder> &&when the project is not in the current folder. The folder is relative to the shell and quoted like the Git hint. Both now use the newinit-shell.ts.Before / after
New project (
--git --toolchain vite-plus --framework react --starter sqlite --deploy none). Blank lines are omitted and thevp installoutput is shortened.With
--starter postgresql, theDATABASE_URLnote stays:◇ Created .gitignore -◇ Configured PostgreSQL in void.config.ts ╭─PostgreSQL local dev──────────────────────────────╮From a non-empty parent directory, choosing "Create a new subfolder" and
my-app:Design decisions
{ quiet: true }toapplyDatabaseDialect(), whose branches are unchanged. Existing projects print the same messages.cd. TheDATABASE_URLnote and the demo note still sayvp dev.-becomescd ./-name, as invp create, becausecd -changes to the previous directory.Git (optional)hint keeps its absolutegit -Cpath.Checked
init.test.ts,init-git.test.tsand the newinit-shell.test.ts. The new assertions fail without the source changes.vp run check,vp lintandvp fmt --checkvp test run): 815 files passed, 1 skippednode --test .github/scripts/packed-*.test.mjs, and the packed consumer with npm and pnpm (React). The Vite+ variant could not finish locally: the globalvp(1.5.0) waits for a reply to its terminal query, which the pseudo-terminal inpacked-init.mjsdoes not send. A barevp installin an empty project stalls the same way.void@1.9.1, whoseinitcode matches the base commit) and after, for the three flows above.🤖 Generated with Claude Code