Skip to content

Commit cd9edae

Browse files
committed
added docs site
1 parent 7833229 commit cd9edae

37 files changed

Lines changed: 13889 additions & 0 deletions

.github/workflows/docs.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Deploy Documentation
2+
3+
on:
4+
push:
5+
branches: [main]
6+
paths: ['docs/**']
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: "pages"
16+
cancel-in-progress: false
17+
18+
jobs:
19+
build:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- name: Checkout
23+
uses: actions/checkout@v4
24+
25+
- name: Setup Node.js
26+
uses: actions/setup-node@v4
27+
with:
28+
node-version: '20'
29+
cache: 'npm'
30+
cache-dependency-path: 'docs/package-lock.json'
31+
32+
- name: Install dependencies
33+
run: cd docs && npm ci
34+
35+
- name: Build with Astro
36+
run: cd docs && npm run build
37+
38+
- name: Setup Pages
39+
uses: actions/configure-pages@v4
40+
41+
- name: Upload artifact
42+
uses: actions/upload-pages-artifact@v3
43+
with:
44+
path: docs/dist
45+
46+
deploy:
47+
environment:
48+
name: github-pages
49+
url: ${{ steps.deployment.outputs.page_url }}
50+
runs-on: ubuntu-latest
51+
needs: build
52+
steps:
53+
- name: Deploy to GitHub Pages
54+
id: deployment
55+
uses: actions/deploy-pages@v4

docs/.gitignore

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# build output
2+
dist/
3+
# generated types
4+
.astro/
5+
6+
# dependencies
7+
node_modules/
8+
9+
# logs
10+
npm-debug.log*
11+
yarn-debug.log*
12+
yarn-error.log*
13+
pnpm-debug.log*
14+
15+
16+
# environment variables
17+
.env
18+
.env.production
19+
20+
# macOS-specific files
21+
.DS_Store

docs/README.md

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Starlight Starter Kit: Basics
2+
3+
[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build)
4+
5+
```
6+
npm create astro@latest -- --template starlight
7+
```
8+
9+
> 🧑‍🚀 **Seasoned astronaut?** Delete this file. Have fun!
10+
11+
## 🚀 Project Structure
12+
13+
Inside of your Astro + Starlight project, you'll see the following folders and files:
14+
15+
```
16+
.
17+
├── public/
18+
├── src/
19+
│ ├── assets/
20+
│ ├── content/
21+
│ │ └── docs/
22+
│ └── content.config.ts
23+
├── astro.config.mjs
24+
├── package.json
25+
└── tsconfig.json
26+
```
27+
28+
Starlight looks for `.md` or `.mdx` files in the `src/content/docs/` directory. Each file is exposed as a route based on its file name.
29+
30+
Images can be added to `src/assets/` and embedded in Markdown with a relative link.
31+
32+
Static assets, like favicons, can be placed in the `public/` directory.
33+
34+
## 🧞 Commands
35+
36+
All commands are run from the root of the project, from a terminal:
37+
38+
| Command | Action |
39+
| :------------------------ | :----------------------------------------------- |
40+
| `npm install` | Installs dependencies |
41+
| `npm run dev` | Starts local dev server at `localhost:4321` |
42+
| `npm run build` | Build your production site to `./dist/` |
43+
| `npm run preview` | Preview your build locally, before deploying |
44+
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` |
45+
| `npm run astro -- --help` | Get help using the Astro CLI |
46+
47+
## 👀 Want to learn more?
48+
49+
Check out [Starlight’s docs](https://starlight.astro.build/), read [the Astro documentation](https://docs.astro.build), or jump into the [Astro Discord server](https://astro.build/chat).

docs/astro.config.mjs

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
// @ts-check
2+
import { defineConfig } from "astro/config";
3+
import starlight from "@astrojs/starlight";
4+
5+
// https://astro.build/config
6+
export default defineConfig({
7+
site: "https://docspring.github.io",
8+
base: "/",
9+
integrations: [
10+
starlight({
11+
title: "Refaktor",
12+
description:
13+
"Smart search & replace for code and files with case-aware transformations",
14+
social: [
15+
{
16+
icon: "github",
17+
label: "GitHub",
18+
href: "https://github.com/DocSpring/refaktor",
19+
},
20+
],
21+
sidebar: [
22+
{
23+
label: "Getting Started",
24+
items: [
25+
{ label: "Installation", slug: "installation" },
26+
{ label: "Quick Start", slug: "quick-start" },
27+
],
28+
},
29+
{
30+
label: "Features",
31+
items: [
32+
{
33+
label: "Case-Aware Transformations",
34+
slug: "features/case-transformations",
35+
},
36+
{
37+
label: "File and Directory Renaming",
38+
slug: "features/file-renaming",
39+
},
40+
{ label: "Safety Features", slug: "features/safety" },
41+
{ label: "Filtering and Ignore Rules", slug: "features/filtering" },
42+
],
43+
},
44+
{
45+
label: "Commands",
46+
autogenerate: { directory: "commands" },
47+
},
48+
{
49+
label: "Examples",
50+
autogenerate: { directory: "examples" },
51+
},
52+
{
53+
label: "Integration",
54+
items: [
55+
{ label: "VS Code Extension", slug: "integration/vscode" },
56+
{ label: "MCP Server", slug: "integration/mcp" },
57+
],
58+
},
59+
{
60+
label: "Reference",
61+
items: [
62+
{ label: "Configuration", slug: "reference/configuration" },
63+
{ label: "Platform Support", slug: "reference/platform-support" },
64+
],
65+
},
66+
],
67+
}),
68+
],
69+
});

0 commit comments

Comments
 (0)