Help us shape the future of Go! Take the 2026 Go Developer Survey

pkg/

directory
v0.0.0-...-af5a29e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 17, 2026 License: Apache-2.0

Directories

Path Synopsis
Package config declares every setting of the pcom binary as a go-flags option with paired `long:` and `env:` tags, so `web --help` is the configuration reference.
Package config declares every setting of the pcom binary as a go-flags option with paired `long:` and `env:` tags, so `web --help` is the configuration reference.
feedops
Package logging carries pcom's one logger, a *zap.Logger.
Package logging carries pcom's one logger, a *zap.Logger.
Package mail formats the mail pcom sends.
Package mail formats the mail pcom sends.
mdext/strikethrough
Package strikethrough renders ~~text~~ as <del>text</del>.
Package strikethrough renders ~~text~~ as <del>text</del>.
Package model holds pcom's database rows: one struct per table, written by hand.
Package model holds pcom's database rows: one struct per table, written by hand.
rss
Package proofread is what pcom asks a language model about a post and what it accepts back: the grammar check (suggestions to replace exact passages) and the style review (notes on the text as a whole, which follow up the post's previous review).
Package proofread is what pcom asks a language model about a post and what it accepts back: the grammar check (suggestions to replace exact passages) and the style review (notes on the text as a whole, which follow up the post's previous review).
claude
Package claude is the proofread.Model over the Claude API, through the official Go SDK.
Package claude is the proofread.Model over the Claude API, through the official Go SDK.
proofreadtest
Package proofreadtest is an in-memory proofread.Model for tests.
Package proofreadtest is an in-memory proofread.Model for tests.
Package repo holds database queries.
Package repo holds database queries.
Package service holds the errors every service returns.
Package service holds the errors every service returns.
accounts
Package accounts holds everything about who a user is and how they get in: signup, the waiting list, invitations, login credentials, passwords, the settings page, user styles, API keys, feed tokens and the registration switch.
Package accounts holds everything about who a user is and how they get in: signup, the waiting list, invitations, login credentials, passwords, the settings page, user styles, API keys, feed tokens and the registration switch.
connections
Package connections manages who is connected to whom: whitelist grants (people allowed to connect without mediation), connections themselves and mediation requests, where common connections vouch for a stranger.
Package connections manages who is connected to whom: whitelist grants (people allowed to connect without mediation), connections themselves and mediation requests, where common connections vouch for a stranger.
feeds
Package feeds manages RSS subscriptions: what a user follows, the items the poller delivers to them, and dismissing an item.
Package feeds manages RSS subscriptions: what a user follows, the items the poller delivers to them, and dismissing an item.
graph
Package graph answers how two users are connected.
Package graph answers how two users are connected.
media
Package media handles media uploads.
Package media handles media uploads.
posts
Package posts is everything users do with posts: write, edit, autosave, publish and delete them, comment on them, prompt others to write, export and import a blog, and the API v1 that does the same for scripts.
Package posts is everything users do with posts: write, edit, autosave, publish and delete them, comment on them, prompt others to write, export and import a blog, and the API v1 that does the same for scripts.
proofread
Package proofread is the grammar check and the style review of a post the author is writing: it enforces the per-user hourly limits and the site's daily cap, records every call to the model, keeps a post's style reviews and the status of their notes, and ties the model's answers to the text (pkg/proofread).
Package proofread is the grammar check and the style review of a post the author is writing: it enforces the per-user hourly limits and the site's daily cap, records every call to the model, keeps a post's style reviews and the status of their notes, and ties the model's answers to the text (pkg/proofread).
reading
Package reading decides who may read what: a single post with its comments, a user's journal, the explore page, the feed and the RSS feeds built from them.
Package reading decides who may read what: a single post with its comments, a user's journal, the explore page, the feed and the RSS feeds built from them.
registry
Package registry builds every service over one store.
Package registry builds every service over one store.
shares
Package shares manages share links: a secret URL that shows one published post to anybody who has it, logged in or not.
Package shares manages share links: a secret URL that shows one published post to anybody who has it, logged in or not.
Package testutil holds the smallest, most widely used test helper: Must.
Package testutil holds the smallest, most widely used test helper: Must.
factory
Package factory builds valid rows for pcom's tables so that tests (and cmd/seed) don't have to know the schema.
Package factory builds valid rows for pcom's tables so that tests (and cmd/seed) don't have to know the schema.
fakesender
Package fakesender is a fake of github.com/can3p/pcom/pkg/repo.MailQueue for unit and package tests: it records every mail instead of delivering it.
Package fakesender is a fake of github.com/can3p/pcom/pkg/repo.MailQueue for unit and package tests: it records every mail instead of delivering it.
fakestorage
Package fakestorage is an in-memory implementation of github.com/can3p/pcom/pkg/media/server.MediaStorage, for tests that exercise upload/download code without a real object store.
Package fakestorage is an in-memory implementation of github.com/can3p/pcom/pkg/media/server.MediaStorage, for tests that exercise upload/download code without a real object store.
ginctx
Package ginctx builds a *gin.Context for a handler test, wired up the way cmd/web/main.go wires a real request: a cookie-backed session under the name "sess".
Package ginctx builds a *gin.Context for a handler test, wired up the way cmd/web/main.go wires a real request: a cookie-backed session under the name "sess".
golden
Package golden compares test output against a checked-in file, the convention docs/testing.md uses for mail content: run with UPDATE_GOLDEN=1 to write the file, and without it to check the current output still matches.
Package golden compares test output against a checked-in file, the convention docs/testing.md uses for mail content: run with UPDATE_GOLDEN=1 to write the file, and without it to check the current output still matches.
seed
Package seed fills a development database with a small, named world that exercises every feature of pcom.
Package seed fills a development database with a small, named world that exercises every feature of pcom.
testdb
Package testdb gives a test its own empty Postgres database with pcom's migrations applied.
Package testdb gives a test its own empty Postgres database with pcom's migrations applied.
testlog
Package testlog records what code under test logs, so a test can assert on the entries.
Package testlog records what code under test logs, so a test can assert on the entries.
tommy
Package tommy runs one tommy container (github.com/can3p/tommy) per test binary: the Mailjet API mail is sent to, and the S3 bucket user media is stored in.
Package tommy runs one tommy container (github.com/can3p/tommy) per test binary: the Mailjet API mail is sent to, and the S3 bucket user media is stored in.
wiremock
Package wiremock runs one WireMock container per test binary.
Package wiremock runs one WireMock container per test binary.
web
app
Package app assembles the web server: it wires the handlers of every area onto one gin engine.
Package app assembles the web server: it wires the handlers of every area onto one gin engine.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL