Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Nov 10, 2025

Implements hyperbook.new command for creating Hyperbook projects directly from VSCode, using a multi-step QuickInput wizard. Adds platform selection (GitHub, GitLab, EduGit, Vercel, Custom) to the creation workflow.

Changes

  • New @hyperbook/create package: Extracts creation logic into reusable library

    • Environment-agnostic core (no process.exit, console output handled by callers)
    • Handles file operations, git init, template copying
    • Returns structured results for error handling
  • VSCode command (hyperbook.new): 8-step wizard for project creation

    • Folder selection, project metadata (name, description, author)
    • License picker (CC variants, custom)
    • Language code with validation
    • Platform selection for publishing intent
  • CLI refactor: Updated hyperbook new to use @hyperbook/create, maintaining existing UX while adding platform selection step

Example

// VSCode extension usage
const result = await createHyperbook({
  bookPath: "/path/to/my-book",
  name: "my-book",
  description: "A new hyperbook",
  platform: "github",
  license: "cc-by",
  language: "en"
});

Command accessible via Command Palette (Ctrl+Shift+P) → "Hyperbook: Create new Hyperbook"

Original prompt

This section details on the original issue you should resolve

<issue_title>Create hyperbook from VS Code extension</issue_title>
<issue_description>We should add a new command hyperbook.new for creating a new hyperbook. It should work the same as the cli application. Therefore, we need to implement something similiar to this: https://github.com/microsoft/vscode-extension-samples/tree/main/quickinput-sample

We should also add a step for asking a platform for publishing: (GitHub, GitLab, EduGit, Vercel or custom).

Maybe we can extract the functionality of creating a new hyperbook of the hyperbook package into a new package to keep the cli and the vs code extension in sync.</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@vercel
Copy link

vercel bot commented Nov 10, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
hyperbook-4fwa Ready Ready Preview Comment Nov 10, 2025 1:06pm

Copilot AI changed the title [WIP] Add new command for creating hyperbook in VS Code extension Add hyperbook.new command to VSCode extension Nov 10, 2025
Copilot AI requested a review from mikebarkmin November 10, 2025 13:09
Copilot finished work on behalf of mikebarkmin November 10, 2025 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create hyperbook from VS Code extension

2 participants