Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Deploy Docs

on:
push:
branches:
- main
workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: pages
cancel-in-progress: false

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
cache-dependency-path: docs/package-lock.json

- name: Setup Pages
uses: actions/configure-pages@v4

- name: Install dependencies
run: npm ci
working-directory: docs

- name: Build with VitePress
run: npm run docs:build
working-directory: docs

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: docs/.vitepress/dist

deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
needs: build
runs-on: ubuntu-latest
name: Deploy
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
[![License](https://img.shields.io/badge/license-MIT-blue?style=flat-square)](LICENSE)

A powerful and flexible command-line parser and command executor framework for .NET applications. Build beautiful CLI tools with minimal boilerplate code.

**[📚 Documentation](https://stho01.github.io/promty/)** · **[🚀 Getting Started](https://stho01.github.io/promty/guide/getting-started)** · **[💡 Examples](https://stho01.github.io/promty/examples/basic)**
</div>

## Features
Expand Down
4 changes: 4 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
node_modules/
.vitepress/cache/
.vitepress/dist/
package-lock.json
63 changes: 63 additions & 0 deletions docs/.vitepress/config.mts
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
import { defineConfig } from 'vitepress'

export default defineConfig({
title: "Promty",
description: "A powerful command-line parser and command executor framework for .NET",
base: '/promty/',

themeConfig: {
logo: '/logo.png',

nav: [
{ text: 'Home', link: '/' },
{ text: 'Guide', link: '/guide/getting-started' },
{ text: 'API Reference', link: '/api/commands' },
{ text: 'Examples', link: '/examples/basic' }
],

sidebar: [
{
text: 'Guide',
items: [
{ text: 'Getting Started', link: '/guide/getting-started' },
{ text: 'Commands', link: '/guide/commands' },
{ text: 'Arguments & Flags', link: '/guide/arguments' },
{ text: 'Flags Enums', link: '/guide/flags-enums' },
{ text: 'Process Commands', link: '/guide/process-commands' },
{ text: 'Help Text', link: '/guide/help-text' }
]
},
{
text: 'API Reference',
items: [
{ text: 'Commands', link: '/api/commands' },
{ text: 'Attributes', link: '/api/attributes' },
{ text: 'Command Executor', link: '/api/executor' }
]
},
{
text: 'Examples',
items: [
{ text: 'Basic Command', link: '/examples/basic' },
{ text: 'File Operations', link: '/examples/file-operations' },
{ text: 'Flags Enums', link: '/examples/flags-enums' },
{ text: 'Process Wrapper', link: '/examples/process-wrapper' }
]
}
],

socialLinks: [
{ icon: 'github', link: 'https://github.com/stho01/promty' },
{ icon: 'npm', link: 'https://www.nuget.org/packages/Promty' }
],

footer: {
message: 'Released under the MIT License.',
copyright: 'Copyright © 2024-present STHO'
},

search: {
provider: 'local'
}
}
})
31 changes: 31 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Promty Documentation

This directory contains the VitePress documentation site for Promty.

## Local Development

Install dependencies:
```bash
npm install
```

Start the development server:
```bash
npm run docs:dev
```

Build for production:
```bash
npm run docs:build
```

Preview production build:
```bash
npm run docs:preview
```

## Deployment

The documentation is automatically deployed to GitHub Pages when changes are pushed to the `main` branch.

Visit: https://stho01.github.io/promty/
Loading