The new command
There is some minimal boilerplate that is the same for every new project. The
new
command was created to allow you to get started quickly without worrying
about creating that boilerplate yourself.
The new
command is used like this:
ct new <path>
The <path>
argument is where the directory for the new project will be
created.
Running this command creates the following directory structure:
<path>
├── first-step
│ ├── Cargo.toml
│ ├── first-step.md
│ ├── .gitignore
│ └── src
│ └── main.rs
├── .gitignore
├── intro.md
├── SUMMARY.md
└── tour.toml
- The
tour.toml
file contains the configuration for this project. See Manifest Format for more information. - The
SUMMARY.md
file is the table of contents of your project. See Table of Contents for more information. - The
.gitignore
file is generated because as part of your project's creation, we also initialize a git repository as well. This file ignores the folder in which the website is generated so that it does not accidentally get added to your version control system. You can configure which VCS we use (or disable initializing a VCS) with the--vcs
option.
The rest of the generated files are just to give you an idea of the various features of codetour.
- The
intro.md
file results in codetour generating a Content-only Page - The
first-step
directory creates a page with both content and Attachments. The fact that this is a Rust project is just for demonstration purposes. You can use codetour with any language(s).
See Project Structure for more information about these files and how to structure your project.
--vcs
The --vcs
option allows you to specify the version control system of the
created project. See ct new --help
for more information about the version
control systems that are supported.