Skip to content

Repository files navigation

arandu-io/database

The SQL adapters for Arandu.

Build Status Go Reference Latest Version License

About the SQL adapters

One repository, one module per driver, because Go has no optional dependency: a project on PostgreSQL should not compile the MySQL driver into its binary.

import _ "github.com/arandu-io/database/pgx"     // PostgreSQL
import _ "github.com/arandu-io/database/sqlite"  // SQLite, pure Go, no cgo
import _ "github.com/arandu-io/database/mysql" // MySQL

A blank import in main.go is the whole wiring, and DB_CONNECTION decides which one opens.

Every query the generator writes is portable across the three, and the conformance suite runs them against a real server of each — not a fake that implements the happy path and proves nothing about the case that matters.

PostgreSQL is the recommendation and not a requirement: SQLite is the default so a new project runs with nothing installed.

Learning Arandu

The API reference is generated from the doc comments and lives on pkg.go.dev. Every exported symbol carries one, and that is deliberate: it is the documentation that cannot drift from the code, because it sits in the same file.

The CLI documents itself. aru help lists every command, and each one explains what it writes and what to do with it. aru doctor explains what it found and what breaks, not which rule was violated.

A guide and a website do not exist yet, and that is a decision rather than a gap: a guide written against an API that still moves is work done twice, and the second time is worse — there is wrong documentation published. The site is the next phase, and it will be an Arandu application.

Contributing

See CONTRIBUTING.md. Before opening a pull request, the three commands at the top of that file have to pass, and CI runs exactly them.

Security Vulnerabilities

Please review our security policy on how to report a vulnerability. Never open a public issue for one.

License

Open-sourced software licensed under the MIT license.

About

Database adapter for Arandu: one Open, one pool policy, and each driver in its own module so a SQLite project does not carry Postgres.

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages