@getpaseo/cli 0.1.87 → 0.1.88

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,7 @@ import { type ScheduleCommandOptions, type ScheduleRow } from "./shared.js";
4
4
  export interface ScheduleCreateOptions extends ScheduleCommandOptions {
5
5
  every?: string;
6
6
  cron?: string;
7
+ timezone?: string;
7
8
  name?: string;
8
9
  target?: string;
9
10
  provider?: string;
@@ -7,6 +7,7 @@ export async function runCreateCommand(prompt, options, command) {
7
7
  prompt,
8
8
  every: options.every,
9
9
  cron: options.cron,
10
+ timezone: options.timezone,
10
11
  name: options.name,
11
12
  target: options.target,
12
13
  provider: options.provider,
@@ -18,6 +18,7 @@ export function createScheduleCommand() {
18
18
  .argument("<prompt>", "Prompt to run on the schedule")
19
19
  .option("--every <duration>", "Fixed interval cadence (for example: 5m, 1h)")
20
20
  .option("--cron <expr>", "Cron cadence expression")
21
+ .option("--timezone <iana>", "IANA time zone for cron cadence (default: UTC)")
21
22
  .option("--name <name>", "Optional schedule name")
22
23
  .option("--target <self|new-agent|agent-id>", "Run target")
23
24
  .option("--provider <provider>", "Agent provider, or provider/model (e.g. codex or codex/gpt-5.4)")
@@ -49,6 +50,7 @@ export function createScheduleCommand() {
49
50
  .argument("<id>", "Schedule ID")
50
51
  .option("--every <duration>", "Switch to fixed interval cadence (for example: 5m, 1h)")
51
52
  .option("--cron <expr>", "Switch to cron cadence expression")
53
+ .option("--timezone <iana>", "IANA time zone for cron cadence (requires --cron)")
52
54
  .option("--name <name>", "Rename the schedule (empty string clears the name)")
53
55
  .option("--prompt <text>", "Replace the schedule prompt")
54
56
  .option("--provider <provider>", "New agent provider, or provider/model (only for new-agent target)")
@@ -1,4 +1,4 @@
1
- import { formatTarget } from "./shared.js";
1
+ import { formatCadence, formatTarget } from "./shared.js";
2
2
  export const scheduleSchema = {
3
3
  idField: "id",
4
4
  columns: [
@@ -49,7 +49,7 @@ export function createScheduleInspectRows(schedule) {
49
49
  {
50
50
  key: "Cadence",
51
51
  value: schedule.cadence.type === "cron"
52
- ? `cron:${schedule.cadence.expression}`
52
+ ? formatCadence(schedule.cadence)
53
53
  : `every:${schedule.cadence.everyMs}ms`,
54
54
  },
55
55
  { key: "Target", value: formatTarget(schedule.target) },
@@ -15,6 +15,7 @@ export declare function parseScheduleCreateInput(options: {
15
15
  prompt: string;
16
16
  every?: string;
17
17
  cron?: string;
18
+ timezone?: string;
18
19
  name?: string;
19
20
  target?: string;
20
21
  provider?: string;
@@ -29,6 +30,7 @@ export interface ScheduleUpdateOptionsInput {
29
30
  id: string;
30
31
  every?: string;
31
32
  cron?: string;
33
+ timezone?: string;
32
34
  name?: string;
33
35
  prompt?: string;
34
36
  provider?: string;
@@ -30,7 +30,8 @@ export function toScheduleCommandError(code, action, error) {
30
30
  }
31
31
  export function formatCadence(cadence) {
32
32
  if (cadence.type === "cron") {
33
- return `cron:${cadence.expression}`;
33
+ const timezoneSuffix = cadence.timezone ? ` (${cadence.timezone})` : "";
34
+ return `cron:${cadence.expression}${timezoneSuffix}`;
34
35
  }
35
36
  return `every:${formatDurationMs(cadence.everyMs)}`;
36
37
  }
@@ -101,7 +102,7 @@ export function parseScheduleCreateInput(options) {
101
102
  message: "Schedule prompt cannot be empty",
102
103
  };
103
104
  }
104
- const cadence = parseCadenceFromFlags(options.every, options.cron);
105
+ const cadence = parseCadenceFromFlags(options.every, options.cron, options.timezone);
105
106
  if (!cadence) {
106
107
  throw {
107
108
  code: "INVALID_CADENCE",
@@ -177,7 +178,7 @@ export function parseScheduleUpdateInput(options) {
177
178
  message: "Schedule id cannot be empty",
178
179
  };
179
180
  }
180
- const cadence = parseCadenceFromFlags(options.every, options.cron);
181
+ const cadence = parseCadenceFromFlags(options.every, options.cron, options.timezone);
181
182
  const newAgentConfig = buildNewAgentConfigPatch(options);
182
183
  const maxRuns = parseUpdateMaxRuns(options);
183
184
  const expiresAt = parseUpdateExpiresAt(options);
@@ -204,21 +205,45 @@ export function parseScheduleUpdateInput(options) {
204
205
  ...(expiresAt !== undefined ? { expiresAt } : {}),
205
206
  };
206
207
  }
207
- function parseCadenceFromFlags(every, cron) {
208
+ function parseCadenceFromFlags(every, cron, timezone) {
208
209
  if (every !== undefined && cron !== undefined) {
209
210
  throw {
210
211
  code: "INVALID_CADENCE",
211
212
  message: "Specify at most one of --every or --cron",
212
213
  };
213
214
  }
215
+ const trimmedTimeZone = parseTimeZoneFlag(timezone);
216
+ if (trimmedTimeZone !== undefined && cron === undefined) {
217
+ throw {
218
+ code: "INVALID_TIME_ZONE",
219
+ message: "--timezone can only be used with --cron",
220
+ };
221
+ }
214
222
  if (every !== undefined) {
215
223
  return { type: "every", everyMs: parseDuration(every) };
216
224
  }
217
225
  if (cron !== undefined) {
218
- return { type: "cron", expression: cron.trim() };
226
+ return {
227
+ type: "cron",
228
+ expression: cron.trim(),
229
+ ...(trimmedTimeZone ? { timezone: trimmedTimeZone } : {}),
230
+ };
219
231
  }
220
232
  return undefined;
221
233
  }
234
+ function parseTimeZoneFlag(timeZone) {
235
+ if (timeZone === undefined) {
236
+ return undefined;
237
+ }
238
+ const trimmed = timeZone.trim();
239
+ if (!trimmed) {
240
+ throw {
241
+ code: "INVALID_TIME_ZONE",
242
+ message: "--timezone cannot be empty",
243
+ };
244
+ }
245
+ return trimmed;
246
+ }
222
247
  function parseUpdateMaxRuns(options) {
223
248
  if (options.maxRuns !== undefined && options.clearMaxRuns) {
224
249
  throw {
@@ -5,6 +5,7 @@ export type ScheduleCadence = {
5
5
  } | {
6
6
  type: "cron";
7
7
  expression: string;
8
+ timezone?: string;
8
9
  };
9
10
  export type ScheduleTarget = {
10
11
  type: "self";
@@ -5,6 +5,7 @@ import { type ScheduleCommandOptions } from "./shared.js";
5
5
  export interface ScheduleUpdateOptions extends ScheduleCommandOptions {
6
6
  every?: string;
7
7
  cron?: string;
8
+ timezone?: string;
8
9
  name?: string;
9
10
  prompt?: string;
10
11
  provider?: string;
@@ -5,6 +5,7 @@ export async function runUpdateCommand(id, options, _command) {
5
5
  id,
6
6
  every: options.every,
7
7
  cron: options.cron,
8
+ timezone: options.timezone,
8
9
  name: options.name,
9
10
  prompt: options.prompt,
10
11
  provider: options.provider,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getpaseo/cli",
3
- "version": "0.1.87",
3
+ "version": "0.1.88",
4
4
  "description": "Paseo CLI - control your AI coding agents from the command line",
5
5
  "bin": {
6
6
  "paseo": "bin/paseo"
@@ -25,9 +25,9 @@
25
25
  },
26
26
  "dependencies": {
27
27
  "@clack/prompts": "^1.0.0",
28
- "@getpaseo/client": "0.1.87",
29
- "@getpaseo/protocol": "0.1.87",
30
- "@getpaseo/server": "0.1.87",
28
+ "@getpaseo/client": "0.1.88",
29
+ "@getpaseo/protocol": "0.1.88",
30
+ "@getpaseo/server": "0.1.88",
31
31
  "chalk": "^5.3.0",
32
32
  "commander": "^12.0.0",
33
33
  "mime-types": "^2.1.35",