Skip to content

Commit 567476d

Browse files
committed
add docs
1 parent 90064b8 commit 567476d

29 files changed

+8436
-0
lines changed

devenv.nix

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
{
22
languages.rust.enable = true;
3+
languages.javascript.enable = true;
4+
languages.javascript.npm.enable = true;
5+
languages.javascript.npm.install.enable = true;
36

47
git-hooks.hooks = {
58
cargo-check.enable = true;
@@ -10,4 +13,8 @@
1013
enterTest = ''
1114
cargo test --all --verbose
1215
'';
16+
17+
processes.docs.exec = ''
18+
cd docs && astro dev
19+
'';
1320
}

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/.vscode/extensions.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"recommendations": ["astro-build.astro-vscode"],
3+
"unwantedRecommendations": []
4+
}

docs/.vscode/launch.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"version": "0.2.0",
3+
"configurations": [
4+
{
5+
"command": "./node_modules/.bin/astro dev",
6+
"name": "Development server",
7+
"request": "launch",
8+
"type": "node-terminal"
9+
}
10+
]
11+
}

docs/README.md

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
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+
[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/starlight/tree/main/examples/basics)
10+
[![Open with CodeSandbox](https://assets.codesandbox.io/github/button-edit-lime.svg)](https://codesandbox.io/p/sandbox/github/withastro/starlight/tree/main/examples/basics)
11+
[![Deploy to Netlify](https://www.netlify.com/img/deploy/button.svg)](https://app.netlify.com/start/deploy?repository=https://github.com/withastro/starlight&create_from_path=examples/basics)
12+
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fwithastro%2Fstarlight%2Ftree%2Fmain%2Fexamples%2Fbasics&project-name=my-starlight-docs&repository-name=my-starlight-docs)
13+
14+
> 🧑‍🚀 **Seasoned astronaut?** Delete this file. Have fun!
15+
16+
## 🚀 Project Structure
17+
18+
Inside of your Astro + Starlight project, you'll see the following folders and files:
19+
20+
```
21+
.
22+
├── public/
23+
├── src/
24+
│ ├── assets/
25+
│ ├── content/
26+
│ │ ├── docs/
27+
│ └── content.config.ts
28+
├── astro.config.mjs
29+
├── package.json
30+
└── tsconfig.json
31+
```
32+
33+
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.
34+
35+
Images can be added to `src/assets/` and embedded in Markdown with a relative link.
36+
37+
Static assets, like favicons, can be placed in the `public/` directory.
38+
39+
## 🧞 Commands
40+
41+
All commands are run from the root of the project, from a terminal:
42+
43+
| Command | Action |
44+
| :------------------------ | :----------------------------------------------- |
45+
| `npm install` | Installs dependencies |
46+
| `npm run dev` | Starts local dev server at `localhost:4321` |
47+
| `npm run build` | Build your production site to `./dist/` |
48+
| `npm run preview` | Preview your build locally, before deploying |
49+
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` |
50+
| `npm run astro -- --help` | Get help using the Astro CLI |
51+
52+
## 👀 Want to learn more?
53+
54+
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: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
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+
integrations: [
8+
starlight({
9+
title: 'SecretSpec',
10+
tagline: 'Declarative secrets for development workflows',
11+
social: [
12+
{ icon: 'github', label: 'GitHub', href: 'https://github.com/cachix/secretspec' },
13+
{ icon: 'discord', label: 'Discord', href: 'https://discord.gg/naMgvexb6q' },
14+
],
15+
sidebar: [
16+
{
17+
label: 'Getting Started',
18+
items: [
19+
{ label: 'Introduction', slug: 'introduction' },
20+
{ label: 'Quick Start', slug: 'quick-start' },
21+
{ label: 'Installation', slug: 'installation' },
22+
],
23+
},
24+
{
25+
label: 'Concepts',
26+
items: [
27+
{ label: 'Overview', slug: 'concepts/overview' },
28+
{ label: 'Profiles', slug: 'concepts/profiles' },
29+
{ label: 'Providers', slug: 'concepts/providers' },
30+
{ label: 'Configuration Inheritance', slug: 'concepts/inheritance' },
31+
],
32+
},
33+
{
34+
label: 'Providers',
35+
items: [
36+
{ label: 'Keyring', slug: 'providers/keyring' },
37+
{ label: 'Dotenv', slug: 'providers/dotenv' },
38+
{ label: 'Environment Variables', slug: 'providers/env' },
39+
{ label: 'LastPass', slug: 'providers/lastpass' },
40+
{ label: '1Password', slug: 'providers/1password' },
41+
],
42+
},
43+
{
44+
label: 'SDK',
45+
items: [
46+
{ label: 'Rust SDK', slug: 'sdk/rust' },
47+
],
48+
},
49+
{
50+
label: 'Reference',
51+
items: [
52+
{ label: 'Configuration', slug: 'reference/configuration' },
53+
{ label: 'CLI Commands', slug: 'reference/cli' },
54+
{ label: 'Adding Providers', slug: 'reference/adding-providers' },
55+
],
56+
},
57+
],
58+
}),
59+
],
60+
});

0 commit comments

Comments
 (0)