Skip to content

Create Your First Project

Welcome to Hagicode! After installation, let’s create your first project. This guide will walk you through the setup step by step, from preparing the code repository to initializing OpenSpec, just like a friend teaching you hand by hand.

Before creating your first project, make sure you have:

  • A code repository you want to manage with Hagicode
  • Git installed and configured
  • Basic understanding of command line operations

Don’t worry, these are all simple!

Before adding a project to Hagicode, you need to prepare a code repository that you want to manage with Hagicode.

If the code you want to manage is already in a remote repository (GitHub, GitLab, etc.), clone it locally:

Terminal window
# Clone your code repository locally
git clone https://github.com/your-username/your-repo.git
cd your-repo

After cloning, note down the repository’s local path (e.g., C:\Users\YourName\Projects\your-repo or /home/yourname/projects/your-repo), you will need this path in the next step.

If the code you want to manage is still local and hasn’t been pushed to a remote repository:

Terminal window
cd /path/to/your/project
git init
git add .
git commit -m "Initial commit"

It is recommended to create a remote repository on GitHub/GitLab and push:

Terminal window
git remote add origin https://github.com/your-username/your-repo.git
git push -u origin main

Now let’s add the project to the Hagicode interface.

  1. Navigate to http://127.0.0.1:34567 in your browser
  2. Click Projects in the navigation sidebar
  3. Click the Add Project button

Click new project button

Fill in project information:

Fill in general project information

After filling in the required information:

  1. Click the Create Project button to add the project
  2. Hagicode will verify the repository path
  3. Your project will appear in the project list

After creating a new project, you can see this project in the project list

SDD (Software Design Document) is an important component in Hagicode for managing project design and changes. Initializing SDD in a project creates the necessary structure for managing changes.

In the project overview, find the SDD section:

  1. Click the project’s SDD tab

Click the project's SDD tab to initialize SDD

  1. Click the Initialize SDD button

Status shown after initializing SDD

Hagicode will automatically optimize the project.md file for you, adding detailed project information and prompt configuration.

  1. On the project details page, click the Optimize button in the upper right corner

Click the optimize button to optimize Project.md

  1. Hagicode will automatically analyze your code repository and generate optimized project.md content

After completing SDD initialization and project.md optimization, you need to commit these important configuration files to your version control system.

Commit all generated files and optimized configuration to your repository:

Terminal window
cd /path/to/your/project
git add .
git commit -m "Initialize SDD and optimize project.md"

Congratulations! You have created your first project in Hagicode. Here are some recommended next steps: