mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-07-28 16:49:50 -07:00
feat(launcher): add -H/--history command to browse local watch history
- New `subminer -H` flag opens an fzf/rofi menu of watched series from the immersion tracker DB - Actions: replay last episode, play next episode (cross-season), or browse episodes - Adds `history.ts` with DB query, series grouping, season dir listing, and next-episode logic - Adds `bun-sqlite.d.ts` ambient types for tsc compat - Includes full test coverage in `history.test.ts`
This commit is contained in:
Vendored
+26
@@ -0,0 +1,26 @@
|
||||
// Minimal ambient typing for bun:sqlite. The launcher always runs under bun
|
||||
// (see the build banner in package.json), but the repo typechecks with plain
|
||||
// tsc which has no bun type definitions.
|
||||
declare module 'bun:sqlite' {
|
||||
export interface RunResult {
|
||||
changes: number;
|
||||
lastInsertRowid: number | bigint;
|
||||
}
|
||||
|
||||
export interface Statement {
|
||||
all(...params: unknown[]): unknown[];
|
||||
get(...params: unknown[]): unknown;
|
||||
run(...params: unknown[]): RunResult;
|
||||
}
|
||||
|
||||
export class Database {
|
||||
constructor(
|
||||
filename: string,
|
||||
options?: { readonly?: boolean; readwrite?: boolean; create?: boolean },
|
||||
);
|
||||
query(sql: string): Statement;
|
||||
prepare(sql: string): Statement;
|
||||
run(sql: string, ...params: unknown[]): RunResult;
|
||||
close(): void;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user