Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .github/ISSUE_TEMPLATE/bug_report.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ body:
description: What package is affected?
options:
- lucia
- ​@lucia-auth/adapter-test
- ​@lucia-auth/adapter-mongodb
- ​@lucia-auth/adapter-mysql
- ​@lucia-auth/adapter-postgresql
- ​@lucia-auth/adapter-prisma
- ​@lucia-auth/adapter-sqlite
- ​@lifeworld/adapter-test
- ​@lifeworld/adapter-mongodb
- ​@lifeworld/adapter-mysql
- ​@lifeworld/adapter-postgresql
- ​@lifeworld/adapter-prisma
- ​@lifeworld/adapter-sqlite
- ​@lucia-auth/session-drizzle
validations:
required: true
Expand Down
12 changes: 6 additions & 6 deletions .github/ISSUE_TEMPLATE/feature_request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ body:
label: Package
options:
- lucia
- ​@lucia-auth/adapter-test
- ​@lucia-auth/adapter-mongodb
- ​@lucia-auth/adapter-mysql
- ​@lucia-auth/adapter-postgresql
- ​@lucia-auth/adapter-prisma
- ​@lucia-auth/adapter-sqlite
- ​@lifeworld/adapter-test
- ​@lifeworld/adapter-mongodb
- ​@lifeworld/adapter-mysql
- ​@lifeworld/adapter-postgresql
- ​@lifeworld/adapter-prisma
- ​@lifeworld/adapter-sqlite
- ​@lucia-auth/session-drizzle
validations:
required: true
Expand Down
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Lucia

THIS IS A FORK FROM LUCIA: ORIGINAL SOURCE CODE HERE:
https://github.com/lucia-auth/lucia

s.o pilcrow n em

Lucia is an auth library written in TypeScript that abstracts away the complexity of handling sessions. It works alongside your database to provide an API that's easy to use, understand, and extend.

- No more endless configuration and callbacks
Expand All @@ -26,7 +31,7 @@ Lucia is an open source library released under the MIT license, with the help of

**[Examples](https://github.com/lucia-auth/examples)**

**[Changelog](https://github.com/pilcrowOnPaper/lucia/blob/main/packages/lucia/CHANGELOG.md)**
**[Changelog](https://github.com/1ifeworld/lucia/blob/main/packages/lucia/CHANGELOG.md)**

## Installation

Expand Down
10 changes: 5 additions & 5 deletions docs/pages/database/drizzle.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ title: "Drizzle ORM"

# Drizzle ORM

Adapters for Drizzle ORM are provided by `@lucia-auth/adapter-drizzle`. Supports MySQL, PostgreSQL, and SQLite. You're free to rename the underlying table and column names as long as the field names are the same (e.g. `expiresAt`).
Adapters for Drizzle ORM are provided by `@lifeworld/adapter-drizzle`. Supports MySQL, PostgreSQL, and SQLite. You're free to rename the underlying table and column names as long as the field names are the same (e.g. `expiresAt`).

```
npm install @lucia-auth/adapter-drizzle
npm install @lifeworld/adapter-drizzle
```

## MySQL
Expand All @@ -17,7 +17,7 @@ npm install @lucia-auth/adapter-drizzle
User ID can be numeric (see [Define user ID type](/basics/users#define-user-id-type)) but session ID must be a string type.

```ts
import { DrizzleMySQLAdapter } from "@lucia-auth/adapter-drizzle";
import { DrizzleMySQLAdapter } from "@lifeworld/adapter-drizzle";

import mysql from "mysql2/promise";
import { mysqlTable, varchar, datetime } from "drizzle-orm/mysql-core";
Expand Down Expand Up @@ -54,7 +54,7 @@ const adapter = new DrizzleMySQLAdapter(db, sessionTable, userTable);
User ID can be numeric (see [Define user ID type](/basics/users#define-user-id-type)) but session ID must be a string type.

```ts
import { DrizzlePostgreSQLAdapter } from "@lucia-auth/adapter-drizzle";
import { DrizzlePostgreSQLAdapter } from "@lifeworld/adapter-drizzle";

import pg from "pg";
import { pgTable, text, timestamp } from "drizzle-orm/pg-core";
Expand Down Expand Up @@ -88,7 +88,7 @@ const adapter = new DrizzlePostgreSQLAdapter(db, sessionTable, userTable);
User ID can be numeric (see [Define user ID type](/basics/users#define-user-id-type)) but session ID must be a string type.

```ts
import { DrizzleSQLiteAdapter } from "@lucia-auth/adapter-drizzle";
import { DrizzleSQLiteAdapter } from "@lifeworld/adapter-drizzle";

import sqlite from "better-sqlite3";
import { sqliteTable, text, integer } from "drizzle-orm/sqlite-core";
Expand Down
4 changes: 2 additions & 2 deletions docs/pages/database/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ A database is required for storing your users and sessions. Lucia connects to yo

```ts
import { Lucia } from "lucia";
import { BetterSqlite3Adapter } from "@lucia-auth/adapter-sqlite";
import { BetterSqlite3Adapter } from "@lifeworld/adapter-sqlite";

const lucia = new Lucia(new BetterSqlite3Adapter(db));
```
Expand All @@ -32,6 +32,6 @@ Refer to these guides on setting up your database, ORMs, and query builders:

These adapters are not routinely checked by the maintainers of Lucia. Make sure to check the source code and use them at your own risk!

- [Astro DB adapter by Pilcrow](https://github.com/pilcrowOnPaper/lucia-adapter-astrodb)
- [Astro DB adapter by Pilcrow](https://github.com/1ifeworld/lucia-adapter-astrodb)
- [DynamoDB adapter by GNK Softworks](https://github.com/gnk-softworks/lucia-dynamodb-adapter)
- [remult adapter by jycouet](https://github.com/jycouet/firstly/tree/main/packages/firstly/src/lib/auth)
6 changes: 3 additions & 3 deletions docs/pages/database/kysely.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ See the [MySQL](/database/mysql) page for the schema.

```ts
import { Lucia } from "lucia";
import { Mysql2Adapter } from "@lucia-auth/adapter-mysql";
import { Mysql2Adapter } from "@lifeworld/adapter-mysql";

import { createPool } from "mysql2/promise";
import { Kysely, MysqlDialect } from "kysely";
Expand Down Expand Up @@ -49,7 +49,7 @@ See the [PostgreSQL](/database/postgresql) page for the schema.

```ts
import { Lucia } from "lucia";
import { NodePostgresAdapter } from "@lucia-auth/adapter-postgresql";
import { NodePostgresAdapter } from "@lifeworld/adapter-postgresql";

import { Pool } from "pg";
import { Kysely, PostgresDialect } from "kysely";
Expand Down Expand Up @@ -86,7 +86,7 @@ See the [SQLite](/database/sqlite) page for the schema.

```ts
import { Lucia } from "lucia";
import { BetterSqlite3Adapter } from "@lucia-auth/adapter-sqlite";
import { BetterSqlite3Adapter } from "@lifeworld/adapter-sqlite";

import sqlite from "better-sqlite3";
import { Kysely, SqliteDialect } from "kysely";
Expand Down
6 changes: 3 additions & 3 deletions docs/pages/database/mongodb.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ title: "MongoDB"

# MongoDB

The `@lucia-auth/adapter-mongodb` package provides adapters for MongoDB.
The `@lifeworld/adapter-mongodb` package provides adapters for MongoDB.

```
npm install @lucia-auth/adapter-mongodb
npm install @lifeworld/adapter-mongodb
```

## Usage
Expand All @@ -18,7 +18,7 @@ User ID can be numeric or object ID (see [Define user ID type](/basics/users#def

```ts
import { Lucia } from "lucia";
import { MongodbAdapter } from "@lucia-auth/adapter-mongodb";
import { MongodbAdapter } from "@lifeworld/adapter-mongodb";
import { Collection, MongoClient } from "mongodb";

const client = new MongoClient();
Expand Down
6 changes: 3 additions & 3 deletions docs/pages/database/mongoose.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ title: "Mongoose"

# Mongoose

You can use the [MongoDB adapter](/database/mongodb) from the `@lucia-auth/adapter-mongodb` package with Mongoose.
You can use the [MongoDB adapter](/database/mongodb) from the `@lifeworld/adapter-mongodb` package with Mongoose.

```
npm install @lucia-auth/adapter-mongodb
npm install @lifeworld/adapter-mongodb
```

## Usage
Expand All @@ -18,7 +18,7 @@ User ID can be numeric or object ID (see [Define user ID type](/basics/users#def

```ts
import { Lucia } from "lucia";
import { MongodbAdapter } from "@lucia-auth/adapter-mongodb";
import { MongodbAdapter } from "@lifeworld/adapter-mongodb";
import mongoose from "mongoose";

await mongoose.connect();
Expand Down
8 changes: 4 additions & 4 deletions docs/pages/database/mysql.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ title: "MySQL"

# MySQL

`@lucia-auth/adapter-mysql` package provides adapters for MySQL drivers:
`@lifeworld/adapter-mysql` package provides adapters for MySQL drivers:

- `mysql2`
- PlanetScale serverless

```
npm install @lucia-auth/adapter-mysql
npm install @lifeworld/adapter-mysql
```

## Schema
Expand Down Expand Up @@ -39,7 +39,7 @@ CREATE TABLE user_session (

```ts
import { Lucia } from "lucia";
import { Mysql2Adapter } from "@lucia-auth/adapter-mysql";
import { Mysql2Adapter } from "@lifeworld/adapter-mysql";
import mysql from "mysql2/promise";

const pool = mysql.createPool();
Expand All @@ -56,7 +56,7 @@ const adapter = new Mysql2Adapter(pool, {

```ts
import { Lucia } from "lucia";
import { PlanetScaleAdapter } from "@lucia-auth/adapter-mysql";
import { PlanetScaleAdapter } from "@lifeworld/adapter-mysql";
import { Client } from "@planetscale/database";

const client = new Client();
Expand Down
10 changes: 5 additions & 5 deletions docs/pages/database/postgresql.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ title: "PostgreSQL"

> If you use Drizzle ORM in your project, use the [Drizzle adapter](https://lucia-auth.com/database/drizzle#postgresql) instead as Drizzle ORM overrides how your database driver handles dates.

`@lucia-auth/adapter-postgresql` package provides adapters for PostgreSQL drivers:
`@lifeworld/adapter-postgresql` package provides adapters for PostgreSQL drivers:

- Neon HTTP serverless driver (`@neondatabase/serverless`)
- node-postgres (`pg`)
- Postgres.js (`postgres`)

```
npm install @lucia-auth/adapter-postgresql
npm install @lifeworld/adapter-postgresql
```

## Schema
Expand All @@ -40,7 +40,7 @@ CREATE TABLE user_session (

```ts
import { Lucia } from "lucia";
import { NeonHTTPAdapter } from "@lucia-auth/adapter-postgresql";
import { NeonHTTPAdapter } from "@lifeworld/adapter-postgresql";
import { neon } from "@neondatabase/serverless";

const sql = neon();
Expand All @@ -57,7 +57,7 @@ const adapter = new NeonHTTPAdapter(sql, {

```ts
import { Lucia } from "lucia";
import { NodePostgresAdapter } from "@lucia-auth/adapter-postgresql";
import { NodePostgresAdapter } from "@lifeworld/adapter-postgresql";
import pg from "pg";

const pool = new pg.Pool();
Expand All @@ -74,7 +74,7 @@ const adapter = new NodePostgresAdapter(pool, {

```ts
import { Lucia } from "lucia";
import { PostgresJsAdapter } from "@lucia-auth/adapter-postgresql";
import { PostgresJsAdapter } from "@lifeworld/adapter-postgresql";
import postgres from "postgres";

const sql = postgres();
Expand Down
6 changes: 3 additions & 3 deletions docs/pages/database/prisma.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ title: "Prisma"

# Prisma

The `@lucia-auth/adapter-prisma` package provides adapters for Prisma.
The `@lifeworld/adapter-prisma` package provides adapters for Prisma.

```
npm install @lucia-auth/adapter-prisma
npm install @lifeworld/adapter-prisma
```

## Schema
Expand Down Expand Up @@ -36,7 +36,7 @@ model Session {
`PrismaAdapter` takes a session and user model.

```ts
import { PrismaAdapter } from "@lucia-auth/adapter-prisma";
import { PrismaAdapter } from "@lifeworld/adapter-prisma";
import { PrismaClient } from "@prisma/client";

const client = new PrismaClient();
Expand Down
12 changes: 6 additions & 6 deletions docs/pages/database/sqlite.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ title: "SQLite"

# SQLite

The `@lucia-auth/adapter-sqlite` package provides adapters for SQLites drivers:
The `@lifeworld/adapter-sqlite` package provides adapters for SQLites drivers:

- `better-sqlite3`
- Bun SQLite (`bun:sqlite`)
- Cloudflare D1
- LibSQL (Turso)

```
npm install @lucia-auth/adapter-sqlite
npm install @lifeworld/adapter-sqlite
```

## Schema
Expand Down Expand Up @@ -40,7 +40,7 @@ CREATE TABLE session (

```ts
import { Lucia } from "lucia";
import { BetterSqlite3Adapter } from "@lucia-auth/adapter-sqlite";
import { BetterSqlite3Adapter } from "@lifeworld/adapter-sqlite";
import sqlite from "better-sqlite3";

const db = sqlite();
Expand All @@ -57,7 +57,7 @@ const adapter = new BetterSqlite3Adapter(db, {

```ts
import { Lucia } from "lucia";
import { BunSQLiteAdapter } from "@lucia-auth/adapter-sqlite";
import { BunSQLiteAdapter } from "@lifeworld/adapter-sqlite";
import { Database } from "bun:sqlite";

const db = new Database();
Expand All @@ -76,7 +76,7 @@ Since the D1 binding is included with the request, create an `initializeLucia()`

```ts
import { Lucia } from "lucia";
import { D1Adapter } from "@lucia-auth/adapter-sqlite";
import { D1Adapter } from "@lifeworld/adapter-sqlite";

export function initializeLucia(D1: D1Database) {
const adapter = new D1Adapter(D1, {
Expand All @@ -99,7 +99,7 @@ declare module "lucia" {

```ts
import { Lucia } from "lucia";
import { LibSQLAdapter } from "@lucia-auth/adapter-sqlite";
import { LibSQLAdapter } from "@lifeworld/adapter-sqlite";
import { createClient } from "@libsql/client";

const db = createClient({
Expand Down
4 changes: 2 additions & 2 deletions docs/pages/upgrade-v3/mongoose.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ Read this guide carefully as some parts depend on your current structure (**espe
The Mongoose adapter has been replaced with the MongoDB adapter.

```
npm install @lucia-auth/adapter-mongodb
npm install @lifeworld/adapter-mongodb
```

Initialize the adapter:

```ts
import { MongoDBAdapter } from "@lucia-auth/adapter-mongodb";
import { MongoDBAdapter } from "@lifeworld/adapter-mongodb";
import mongoose from "mongoose";

const adapter = new MongodbAdapter(
Expand Down
4 changes: 2 additions & 2 deletions docs/pages/upgrade-v3/mysql.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ title: "Upgrade your MySQL database to v3"
Install the latest version of the MySQL adapter package.

```
npm install @lucia-auth/adapter-mysql
npm install @lifeworld/adapter-mysql
```

Initialize the adapter:

```ts
import { Mysql2Adapter, PlanetScaleAdapter } from "@lucia-auth/adapter-mysql";
import { Mysql2Adapter, PlanetScaleAdapter } from "@lifeworld/adapter-mysql";

new Mysql2Adapter(pool, {
// table names
Expand Down
4 changes: 2 additions & 2 deletions docs/pages/upgrade-v3/postgresql.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ title: "Upgrade your PostgreSQL database to v3"
Install the latest version of the PostgreSQL adapter package.

```
npm install @lucia-auth/adapter-postgresql
npm install @lifeworld/adapter-postgresql
```

Initialize the adapter:

```ts
import { NodePostgresAdapter, PostgresJsAdapter } from "@lucia-auth/adapter-postgresql";
import { NodePostgresAdapter, PostgresJsAdapter } from "@lifeworld/adapter-postgresql";

// previously named `pg` adapter
new NodePostgresAdapter(pool, {
Expand Down
Loading