1.1.3 • Published 1 year ago

0ty v1.1.3

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

0ty: A Zero-Config Static Site Generator

0ty is a static site generator that (hopefully) requires no fuss outside of installing 0ty and deploying your static site.

There is nothing to configure. Write your content in Markdown then run 0ty on it. 0ty will spit out a styled website with a navbar based on your content.

Example

Suppose you have a directory personal-website containing Markdown, images, etc.

personal-website/
├── about.md
├── image.jpg (This image is linked in the about.md file.)
├── blog/
│   ├── bar.md
│   └── foo.md
└── index.md

If personal-website is in your current working directory, you can enter the command npx 0ty personal-website site, it will spit out the following site directory:

site/
├── about/
│   ├── image.jpg
│   └── index.html
├── blog/
│   ├── bar/
│   │   └── index.html
│   ├── foo/
│   │   └── index.html
│   └── index.html
├── index.html
└── lemur.css (This is the styling that 0ty provides.)

Requirements

  • Requires Node.js. (0ty was built and tested using Node.js version 16.15.1.)

Installation

  • Install in your project: npm install 0ty
  • Install globally: sudo npm install --global 0ty

Setting up a 0ty NPM project

  • Initialize your NPM project: npm init.
  • Install 0ty: npm install --save-dev 0ty.
  • Make a src directory, put your Markdown etc. in there.
  • Install http-server so you can serve your built site: npm install --save-dev http-server.
  • Add the following to your package.json:
  "scripts": {
    "serve": "http-server site",
    "0ty": "0ty src site && npm run serve"
  }
  • When you are ready to preview your site, enter npm run 0ty.

Usage

Run on a directory

npx 0ty <input-directory>

Optionally supply an output directory: npm 0ty <input-directory> [output-directory]

Run on a single file

npx 0ty <input-file>

Optionally supply an output directory: npx 0ty <input-file> [output-directory]

Docs

For users

For devs

1.1.3

1 year ago

1.1.2

1 year ago

1.0.0

1 year ago

0.21.11

1 year ago

0.20.9

1 year ago

0.20.8

1 year ago

0.20.6

1 year ago

0.9.3

1 year ago

0.9.0

1 year ago

0.8.1

1 year ago

0.8.2

1 year ago

0.6.1

1 year ago

0.6.0

1 year ago