Creating A Project

A Doctave project has 2 parts:

  • The project files defining your documentation, stored in Git
  • The Doctave site you manage through the Doctave dashboard

Let's walk through setting both of these up.

Step 1: Create a local docs directory

First, let's create a location for your docs on your local machine. This can be in a subdirectory of an existing Git repository, or a brand new repository.

Existing repository

Create a subdirectory in your repository:

# Go to your repository
cd path/to/my/repository

# Create a location for your docs
mkdir docs

New repository

If you are creating a new repository, create the folder, and initialize a new Git repository in it.

# Create a location for your docs
mkdir docs-project

# Move into the directory
cd docs-project

# Initialize a blank Git repository
git init

Step 2: Bootstrap Doctave project files

Next, we will use the Doctave desktop app (installation instructions here) to create the required files to setup a Doctave app in the folder you just created:

  1. Open the Doctave desktop app
  2. Click the "Create new project" button
  3. Select the folder you created in the previous step.

Once selected, the app will generate a basic structure for your docs, and display it for you.

Congrats! You now have a functioning Doctave docs site running locally! ๐ŸŽ‰

If you look in the directory you created before, you can see the files Doctave created:

tree .
.
โ”œโ”€โ”€ Continue-Here.md
โ”œโ”€โ”€ README.md
โ”œโ”€โ”€ _partials
โ”‚   โ””โ”€โ”€ todo.md
โ”œโ”€โ”€ doctave.yaml
โ””โ”€โ”€ navigation.yaml

1 directory, 5 files

We will cover what exactly these files do shortly.

In the meantime, try editing the README.md file in the editor of your choice and see what happens! The desktop app should update automatically once you save your changes.

Step 3: Create a Doctave project in the dashboard

Currently, you have a documentation site running locally in the desktop app. In order to share it with your readers, we need to create the project in the Doctave dashboard as well. This will create a place we can publish your docs to and share your content with your readers.

First, make sure you have created a Doctave account.

  1. Go to the Doctave dashboard's projects page
  2. Click the "Create Project" button on the right
  3. Configure your project's name, subdomain, visibility, and the default Git branch
  4. Create the project

We'll come back to this project later, but for now, notice the "upload token" that was assigned to your project. This is what you will use when publishing your docs, and it will let Doctave know the content belongs to this project.

Next step

โžค Next, let's look at how to write documentation with Doctave.

Was this page helpful?