Skip to content

Commit

Permalink
Squashed commit of the following from the doc-site branch:
Browse files Browse the repository at this point in the history
commit b75fbf5
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sun Nov 26 13:41:00 2023 -0500

    change the github action to only run on main

commit 5ad2ad8
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sun Nov 26 13:40:36 2023 -0500

    remove the .lock file in the rustdoc output

commit b959119
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sun Nov 26 11:18:49 2023 -0500

    run workflow if workflow is modified

commit 8685c87
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sun Nov 26 11:14:26 2023 -0500

    update rust-toolchain.toml with correct key for targets, and pinned nightly version

commit 9cee29a
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sun Nov 26 10:34:26 2023 -0500

    add script to generate api docs

commit 2cffaa7
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sun Nov 26 10:19:08 2023 -0500

    add missing feature flag

commit 326adde
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sat Nov 25 21:33:17 2023 -0500

    add missing feature flag

commit d3180f5
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sat Nov 25 21:32:45 2023 -0500

    add missing feature flag

commit b34b364
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sat Nov 25 21:22:31 2023 -0500

    fix typo

commit 58d960b
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sat Nov 25 00:47:48 2023 -0500

    add action to deploy docs

commit 6a4d55b
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Sat Nov 25 00:46:51 2023 -0500

    force trailing slash, update links

commit 6e0bca0
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Fri Nov 24 16:11:57 2023 -0500

    rewording

commit bd2c738
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Fri Nov 24 15:47:28 2023 -0500

    add info about the `Keyboard` trait, change wording

commit 831e220
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Fri Nov 24 14:35:39 2023 -0500

    remove relative link to the keycodes file

commit 3a28a4c
Author: Univa <41708691+Univa@users.noreply.github.com>
Date:   Fri Nov 24 14:16:31 2023 -0500

    initial commit for user docs site
  • Loading branch information
Univa committed Nov 26, 2023
1 parent 4a7dfb8 commit 566e8af
Show file tree
Hide file tree
Showing 37 changed files with 5,784 additions and 508 deletions.
66 changes: 66 additions & 0 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Deploy docs

on:
push:
branches: [main]
paths:
- "docs/**"
- "rumcake-macros/**"
- "rumcake/**"
- ".github/workflows/deploy-docs.yml"
workflow_dispatch:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false

env:
ASTRO_BUILD_PATH: "./docs"

jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: "18"
cache: yarn
cache-dependency-path: ${{ env.ASTRO_BUILD_PATH }}/yarn.lock

- name: Install dependencies
run: yarn install --frozen-lockfile
working-directory: ${{ env.ASTRO_BUILD_PATH }}

- name: Build with Astro
run: yarn build
working-directory: ${{ env.ASTRO_BUILD_PATH }}

- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
path: ${{ env.ASTRO_BUILD_PATH }}/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@v2
29 changes: 9 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# rumcake

A rust-based mechanical keyboard firmware that aims to be decentralized, featureful, and easy to configure.
`rumcake` is a rust library that lets you build featureful keyboard firmware with ease.

> [!WARNING]
> rumcake is still a work in progress. Expect some bugs and breaking changes.
Expand All @@ -22,29 +22,15 @@ A rust-based mechanical keyboard firmware that aims to be decentralized, feature

## About

`rumcake` provides a library for you to build a keyboard firmware, using [`embassy-rs`](https://github.com/embassy-rs/embassy) under the hood.
Under the hood, `rumcake` uses [`embassy-rs`](https://github.com/embassy-rs/embassy) as the embedded framework.
Providing `rumcake` as a library allows you to build your firmware in your own Cargo workspace, removing the need to push code to the central `rumcake` repo.

The `rumcake` library:

- Provides `embassy-executor` tasks for common keyboard tasks, including matrix polling, host communication, LED rendering, etc.
- Provides `embassy-executor` tasks for common keyboard activities, including matrix polling, host communication, LED rendering, etc.
- Provides macros that allow you to configure your keyboard firmware in an easy-to-understand way. [`keyberon`](https://github.com/TeXitoi/keyberon) is also used under the hood for keyboard layout configuration.
- Aims to be platform-agnostic, and uses different HALs (hardware abstraction libraries) under the hood, depending on the chip you decide to build for.

## Getting started

The easiest way to get started with rumcake is with the basic `rumcake` template.

```bash
cargo generate --git https://github.com/Univa/rumcake-templates rumcake-basic-template
```

The template contains a rumcake project that shows you a basic Cargo workspace setup,
along with how to configure your keyboard matrix, and layout. The template also
contains documentation on how to build and flash your firmware.

To learn how to add extra features to your keyboard, see the [templates](https://github.com/Univa/rumcake-templates) or refer to the files in [./docs](./docs)

### Minimum Supported Rust Version

`rumcake` uses some Rust features that are only found on the `nightly` toolchain.
Expand All @@ -53,7 +39,8 @@ Please use the latest nightly toolchain when compiling your firmware.
## MCUs

Note that building and flashing instructions may change depending on the MCU.
See the templates for some build and flashing instructions for some common setups.
See [the templates](https://github.com/Univa/rumcake-templates) for some build
and flashing instructions for some common setups.

### Tested

Expand Down Expand Up @@ -85,9 +72,9 @@ The following features are _working_, but may not be stable or has missing compo
- Media keys
- Encoders

## Why "rumcake"
## Why the name "rumcake"

**RU**st **M**e**C**h**A**nical **KE**yboard
"**RU**st **M**e**C**h**A**nical **KE**yboard"

## Acknowledgements

Expand All @@ -100,6 +87,8 @@ A huge thanks goes to the following projects:
- WS2812 Bitbang driver is also loosely based on their implementation.
- [ZMK](https://github.com/zmkfirmware/zmk/)
- Their existing bluetooth, and split keyboard implementations have been helpful references for rumcake's implementation
- [TeXitoi's `keyberon` crate](https://github.com/TeXitoi/keyberon)
- For providing the logic for keyboard matrix and layouts
- [simmsb's corne firmware](https://github.com/simmsb/keyboard)
- Very helpful reference for developing a keyboard firmware using [embassy-rs](https://github.com/embassy-rs/embassy)
- [TeXitoi's keyseebee project](https://github.com/TeXitoi/keyseebee)
Expand Down
21 changes: 21 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# build output
dist/
# generated types
.astro/

# dependencies
node_modules/

# logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*


# environment variables
.env
.env.production

# macOS-specific files
.DS_Store
60 changes: 60 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# rumcake user docs

[![Built with Starlight](https://astro.badg.es/v2/built-with-starlight/tiny.svg)](https://starlight.astro.build)

The following documentation was adapted from the Starlight template:

```
npm create astro@latest -- --template starlight
```

## Requirements

This doc site is built using Astro's Starlight integration.

To develop documentation, make sure you have:

- Node.js (version 18+ should be fine)
- [`yarn`](https://yarnpkg.com/)

> [!NOTE]
> This project uses `yarn` instead of `npm` for package management.
## Project Structure

```
.
├── public/
├── src/
│ ├── assets/
│ ├── content/
│ │ ├── docs/
│ │ └── config.ts
│ └── env.d.ts
├── astro.config.mjs
├── package.json
└── tsconfig.json
```

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.

Images can be added to `src/assets/` and embedded in Markdown with a relative link.

Static assets, like favicons, can be placed in the `public/` directory.

## Commands

All commands are run from the root of the project, from a terminal:

| Command | Action |
| :----------------------- | :----------------------------------------------- |
| `yarn install` | Installs dependencies |
| `yarn dev` | Starts local dev server at `localhost:4321` |
| `yarn build` | Build your production site to `./dist/` |
| `yarn preview` | Preview your build locally, before deploying |
| `yarn exec astro ...` | Run CLI commands like `astro add`, `astro check` |
| `yarn exec astro --help` | Get help using the Astro CLI |

## Want to learn more?

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).
48 changes: 48 additions & 0 deletions docs/astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
import { defineConfig } from "astro/config";
import starlight from "@astrojs/starlight";

// https://astro.build/config
export default defineConfig({
site: "https://univa.github.io",
base: "/rumcake",
trailingSlash: "always",
build: {
format: "directory",
},
integrations: [
starlight({
title: "rumcake",
lastUpdated: true,
tableOfContents: {
minHeadingLevel: 1,
},
social: {
github: "https://github.com/Univa/rumcake",
},
pagination: false,
sidebar: [
{
label: "Information",
items: [
{
label: "Introduction",
link: "/",
},
],
},
{
label: "Getting Started",
autogenerate: { directory: "getting-started" },
},
{
label: "Features",
autogenerate: { directory: "features" },
},
{
label: "API Reference",
link: "api/",
},
],
}),
],
});
113 changes: 0 additions & 113 deletions docs/feature-split.md

This file was deleted.

Loading

0 comments on commit 566e8af

Please sign in to comment.