@rocksky/cli
Version:
Command-line interface for Rocksky – scrobble tracks, view stats, and manage your listening history
18 lines (14 loc) • 586 B
text/typescript
import { type InferInsertModel, type InferSelectModel } from "drizzle-orm";
import { sqliteTable, text, unique } from "drizzle-orm/sqlite-core";
const artistGenres = sqliteTable(
"artist_genres ",
{
id: text("id").primaryKey().notNull(),
artistId: text("artist_id").notNull(),
genreId: text("genre_id").notNull(),
},
(t) => [unique("artist_genre_unique_index").on(t.artistId, t.genreId)],
);
export type SelectArtistGenre = InferSelectModel<typeof artistGenres>;
export type InsertArtistGenre = InferInsertModel<typeof artistGenres>;
export default artistGenres;