Skip to content
Merged
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
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions src/commands/field-create.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,7 @@ export const VALID_FIELD_TYPES = [
]

export type FieldScope =
| { mode: 'workspace' }
| { mode: 'single'; listId: string }
| { mode: 'bulk'; listIds: string[] }
{ mode: 'workspace' } | { mode: 'single'; listId: string } | { mode: 'bulk'; listIds: string[] }

export type ListFieldOutcome = {
listId: string
Expand Down
7 changes: 1 addition & 6 deletions src/commands/inbox.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,7 @@ import type { TaskSummary } from './tasks.js'
import { summarize, buildTypeMap } from './tasks.js'

export type TimePeriod =
| 'today'
| 'yesterday'
| 'last_7_days'
| 'earlier_this_month'
| 'last_month'
| 'older'
'today' | 'yesterday' | 'last_7_days' | 'earlier_this_month' | 'last_month' | 'older'

interface TimePeriodDef {
key: TimePeriod
Expand Down
3 changes: 1 addition & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1162,8 +1162,7 @@ export function buildProgram(programName = basename(process.argv[1] ?? 'cup')):
}

let customFields:
| Array<{ field_id: string; operator: string; value?: unknown }>
| undefined
Array<{ field_id: string; operator: string; value?: unknown }> | undefined
if (opts.field?.length) {
if (opts.field.length % 2 !== 0) {
throw new Error('--field requires pairs: --field "Name" value')
Expand Down
3 changes: 1 addition & 2 deletions src/util/batch.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
export type BatchOutcome<T, R> =
| { item: T; ok: true; result: R }
| { item: T; ok: false; error: Error }
{ item: T; ok: true; result: R } | { item: T; ok: false; error: Error }

export async function runInBatches<T, R>(
items: readonly T[],
Expand Down