|
1 | | -This is the source repo for the [Talon wiki](https://talon.wiki), a community maintained wiki for [Talon voice](https://talonvoice.com/). For information on how to contribute, see our [Contributing](https://github.com/TalonCommunity/Wiki/blob/main/CONTRIBUTING.md) documentation. |
| 1 | +# Talon Wiki |
| 2 | + |
| 3 | +This is the source repo for the [https://talon.wiki/](https://talon.wiki), a community maintained wiki for [Talon voice](https://talonvoice.com/). |
| 4 | + |
| 5 | +Join the [Talon Slack](https://talonvoice.com/chat) to find other folks interested in or using Talon. If you want to support the project, consider donating to the [Patreon](https://www.patreon.com/lunixbochs). |
| 6 | + |
| 7 | +## Who can Contribute |
| 8 | + |
| 9 | +This wiki belongs to the Talon Community, and contributions are welcome from anyone. |
| 10 | + |
| 11 | +## Development Setup for Contributors |
| 12 | + |
| 13 | +### Prerequisites |
| 14 | + |
| 15 | +- [Node.js](https://nodejs.org/) (version 18 or higher) |
| 16 | +- npm (comes with Node.js) |
| 17 | +- A GitHub account |
| 18 | + |
| 19 | +### Getting Started |
| 20 | + |
| 21 | +1. **Fork the repository** on GitHub by clicking the "Fork" button at the top of the [TalonCommunity/Wiki](https://github.com/TalonCommunity/Wiki) repository page. |
| 22 | + |
| 23 | +2. **Clone your fork** (replace `YOUR_USERNAME` with your GitHub username): |
| 24 | + |
| 25 | + ```bash |
| 26 | + git clone https://github.com/YOUR_USERNAME/Wiki.git |
| 27 | + cd Wiki |
| 28 | + ``` |
| 29 | + |
| 30 | +3. **Add the upstream remote** to keep your fork in sync: |
| 31 | + |
| 32 | + ```bash |
| 33 | + git remote add upstream https://github.com/TalonCommunity/Wiki.git |
| 34 | + ``` |
| 35 | + |
| 36 | +4. **Install dependencies**: |
| 37 | + |
| 38 | + ```bash |
| 39 | + npm install |
| 40 | + ``` |
| 41 | + |
| 42 | +5. **Start the development server**: |
| 43 | + ```bash |
| 44 | + npm start |
| 45 | + ``` |
| 46 | + |
| 47 | +The site will open at `http://localhost:3000` and automatically reload when you make changes. |
| 48 | + |
| 49 | +### Contributing Workflow |
| 50 | + |
| 51 | +1. **Create a new branch** for your changes: |
| 52 | + |
| 53 | + ```bash |
| 54 | + git checkout -b your-feature-branch |
| 55 | + ``` |
| 56 | + |
| 57 | +2. **Make your changes** and test them locally |
| 58 | + |
| 59 | +3. **Commit your changes**: |
| 60 | + |
| 61 | + ```bash |
| 62 | + git add . |
| 63 | + git commit -m "Description of your changes" |
| 64 | + ``` |
| 65 | + |
| 66 | +4. **Push to your fork**: |
| 67 | + |
| 68 | + ```bash |
| 69 | + git push origin your-feature-branch |
| 70 | + ``` |
| 71 | + |
| 72 | +5. **Create a Pull Request** from your fork to the main repository |
| 73 | + |
| 74 | +### Keeping Your Fork Updated |
| 75 | + |
| 76 | +Before starting new work, sync your fork with the upstream repository: |
| 77 | + |
| 78 | +```bash |
| 79 | +git checkout main |
| 80 | +git fetch upstream |
| 81 | +git merge upstream/main |
| 82 | +git push origin main |
| 83 | +``` |
| 84 | + |
| 85 | +### Checklist for Contributors |
| 86 | + |
| 87 | +- [ ] Fork the repository and create a feature branch |
| 88 | +- [ ] Use relative markdown links |
| 89 | +- [ ] Run `npm run build` and ensure the build is successful (no broken links) |
| 90 | +- [ ] Test your changes locally before submitting a pull request |
| 91 | +- [ ] Create a pull request with a clear description of your changes |
| 92 | + |
| 93 | +## Available Commands |
| 94 | + |
| 95 | +| Command | Description | |
| 96 | +| ---------------------- | ----------------------------------------------- | |
| 97 | +| `npm start` | Start the development server with hot reloading | |
| 98 | +| `npm run build` | Build the static site for production | |
| 99 | +| `npm run serve` | Serve the production build locally | |
| 100 | +| `npm run update-repos` | Fetch fresh repository data from GitHub API | |
| 101 | +| `npm run clear` | Clear Docusaurus cache | |
| 102 | +| `npm run typecheck` | Run TypeScript type checking | |
| 103 | + |
| 104 | +## Repository Explorer |
| 105 | + |
| 106 | +The wiki includes a [Repository Explorer](https://talon.wiki/explorer/) that automatically displays Talon-related repositories from GitHub tagged with `talonvoice` topic. |
| 107 | + |
| 108 | +The repository data is cached locally to avoid hitting GitHub's API rate limits (60 requests per hour for unauthenticated users, 5,000 for authenticated users). To update the cached data, you can run: |
| 109 | + |
| 110 | +```bash |
| 111 | +npm run update-repos |
| 112 | +# or |
| 113 | +npm run build --fetch-repos |
| 114 | +``` |
| 115 | + |
| 116 | +Otherwise, the explorer will use the cached data until the next production build or scheduled update. |
| 117 | + |
| 118 | +### Omitting Repositories from the Explorer |
| 119 | + |
| 120 | +To exclude specific repositories from the explorer: |
| 121 | + |
| 122 | +1. Edit `plugins/repo-data-omit-list.json` |
| 123 | +2. Add repository full names to the `omitRepos` array: |
| 124 | + ```json |
| 125 | + { |
| 126 | + "omitRepos": ["owner/repo-name", "another-owner/another-repo"] |
| 127 | + } |
| 128 | + ``` |
| 129 | +3. Changes take effect on the next build |
| 130 | + |
| 131 | +## Technology Stack |
| 132 | + |
| 133 | +- [Docusaurus](https://docusaurus.io/) - Static site generator |
| 134 | +- [React](https://reactjs.org/) - Component framework |
| 135 | +- [TypeScript](https://www.typescriptlang.org/) - Type safety |
| 136 | +- [Shiki](https://shiki.style/) - Syntax highlighting |
0 commit comments