···11# Yōten
2233A social platform for tracking the essential points of your language learning.
44-Log your study sessions, visualize your progress, and share your milestones
55-with a community of fellow learners on the [AT Protocol](https://atproto.com).
44+55+Read our [devlogs](https://yoten.leaflet.pub/).
66+Join the [Discord](https://discord.gg/XAUWY3zvD4).
77+68Find your focus and turn daily practice into visible results.
99+1010+## docs
1111+- [contributing guide - **please read before opening a PR**](./docs/contributing.md)
1212+- [hacking on yōten](./docs/hacking.md)
+109
docs/contributing.md
···11+# Contributing guide
22+33+## Commit guidelines
44+55+We follow a commit style similar to the Go project. Please keep commits:
66+77+- **Atomic**: Each commit should represent one logical change.
88+- **Descriptive**: The commit message should clearly describe what the change
99+ does and why it's needed.
1010+1111+### Message format
1212+1313+```
1414+<type>(affected system): <short summary of change>
1515+1616+1717+Optional longer description, if necessary. Explain what the change does and
1818+why. Reference relevant issues or PRs when applicable via links.
1919+```
2020+2121+Examples
2222+2323+```
2424+fix(xp): update xp when a study session is deleted
2525+```
2626+2727+```
2828+refactor(views/edit-activity): remove page handler in favor of direct invocation
2929+```
3030+3131+### General notes
3232+3333+- PRs get merged "as-is" (fast-forward) - like applying a patch-series using
3434+ `git am`. There is no squashing so please author your commits as they would
3535+ appear on `master`, following the above guidelines.
3636+- Keep commits lowercased with no trailing period.
3737+- Use the imperative mood in the summary line (e.g., "fix bug" not "fixed bug"
3838+ or "fixes bug").
3939+- Try to keep the summary line under 72 characters.
4040+- Follow the same formatting for PR titles if filled manually.
4141+- Don't include unrelated changes in the same commit.
4242+- Avoid noisy commit messages like "wip" or "final fix". Rewrite history before
4343+ submitting if necessary.
4444+4545+## Code formatting
4646+4747+Format templates and code before submitting for final review.
4848+```
4949+go tool templ fmt ./internal/server/views/ && go fmt ./...
5050+```
5151+5252+## Proposals for bigger changes
5353+5454+Small fixes like typos, minor bugs, or trivial refactors can be submitted
5555+directly as PRs.
5656+5757+For larger changes—especially those introducing new features, significant
5858+refactoring, or altering system behavior—please open a proposal first. This
5959+helps us evaluate the scope, design, and potential impact before
6060+implementation.
6161+6262+### Proposal format
6363+6464+Create a new issue titled:
6565+6666+```
6767+proposal: <affected scope>: <summary of change>
6868+```
6969+7070+In the description, explain:
7171+7272+- What the change is
7373+- Why it's needed
7474+- How you plan to implement it (roughly)
7575+- Any open questions or tradeoffs
7676+7777+We'll use the issue thread to discuss and refine the idea before moving
7878+forward.
7979+8080+## Developer certificate of origin (DCO)
8181+8282+We require all contributors to certify that they have the right to submit the
8383+code they're contributing. To do this, we follow the [Developer Certificate of
8484+Origin (DCO)](https://developercertificate.org/).
8585+8686+By signing your commits, you're stating that the contribution is your own work,
8787+or that you have the right to submit it under the project's license. This helps
8888+us keep things clean and legally sound.
8989+9090+To sign your commit, just add the `-s` flag when committing:
9191+9292+```sh
9393+git commit -s -m "your commit message"
9494+```
9595+9696+This appends a line like:
9797+9898+```
9999+Signed-off-by: Your Name <your.email@example.com>
100100+```
101101+102102+We won't merge commits if they aren't signed off. If you forget, you can amend
103103+the last commit like this:
104104+105105+```sh
106106+git commit --amend -s
107107+```
108108+109109+If you're submitting a PR with multiple commits, make sure each one is signed.
+43
docs/hacking.md
···11+# Hacking guide
22+33+## Required tools
44+- [tailwind-cli](https://tailwindcss.com/docs/installation/tailwind-cli)
55+- [templ](https://templ.guide/quick-start/installation)
66+77+## Running yōten
88+99+To authenticate, you will need OAUTH JWKs to be setup:
1010+```bash
1111+go build -o genjwks.out ./cmd/genjwks
1212+export YOTEN_OAUTH_JWKS="$(./genjwks.out)"
1313+```
1414+1515+You will need to fetch a series of static assets yōten depends on:
1616+```bash
1717+mkdir -p ./static/files
1818+1919+# HTMX
2020+curl -sLo ./static/files/htmx.min.js https://cdn.jsdelivr.net/npm/htmx.org@2.0.6/dist/htmx.min.js
2121+# Lucide (icons)
2222+curl -sLo ./static/files/lucide.min.js https://unpkg.com/lucide@0.525.0/dist/umd/lucide.min.js
2323+# AlpineJS
2424+curl -sLo ./static/files/alpinejs.min.js https://cdn.jsdelivr.net/npm/alpinejs@3.x.x/dist/cdn.min.js
2525+# Toast components
2626+curl -sLo ./static/files/htmx-toaster.min.js https://unpkg.com/htmx-toaster@0.0.20/dist/htmx-toaster.min.js
2727+```
2828+2929+To run:
3030+```bash
3131+YOTEN_DEV=true go run cmd/server/main.go
3232+```
3333+3434+If you modified the views, you will need to regenerate them:
3535+```bash
3636+go tool templ generate
3737+go tool templ fmt ./internal/server/views/
3838+```
3939+4040+If you modified the tailwind styles, you will need to regenerate the css:
4141+```bash
4242+tailwindcss -i ./input.css -o ./static/files/style.css
4343+```