Skip to content

Commit e00df1e

Browse files
authored
Fix invalid option names in Firestore backup schedule commands (#7481)
* Use `-d` short name for database * Remove invalid and ambiguous short names * Update CHANGELOG * Lint CHANGELOG
1 parent 8a4aa7a commit e00df1e

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@
99
- Released version [email protected], which adds Emulator UI support for firealerts events.
1010
- Improved errors when an incorrect service ID is passed to `firebase deploy --only dataconnect:serviceId`.
1111
- Fixed display of errors in Firestore commands when using JSON or noninteractive modes. (#7482)
12+
- Fixed an issue where Firestore backup schedule commands had invalid short option names. (#7481)

src/commands/firestore-backups-schedules-create.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,13 @@ import { FirebaseError } from "../error";
2020
export const command = new Command("firestore:backups:schedules:create")
2121
.description("Create a backup schedule under your Cloud Firestore database.")
2222
.option(
23-
"-db, --database <databaseId>",
23+
"-d, --database <databaseId>",
2424
"Database under which you want to create a schedule. Defaults to the (default) database",
2525
)
26-
.option("-rt, --retention <duration>", "duration string (e.g. 12h or 30d) for backup retention")
27-
.option("-rc, --recurrence <recurrence>", "Recurrence settings; either DAILY or WEEKLY")
26+
.option("--retention <duration>", "duration string (e.g. 12h or 30d) for backup retention")
27+
.option("--recurrence <recurrence>", "Recurrence settings; either DAILY or WEEKLY")
2828
.option(
29-
"-dw, --day-of-week <dayOfWeek>",
29+
"--day-of-week <dayOfWeek>",
3030
"On which day of the week to perform backups; one of MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY, or SUNDAY",
3131
)
3232
.before(requirePermissions, ["datastore.backupSchedules.create"])

src/commands/firestore-backups-schedules-list.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { PrettyPrint } from "../firestore/pretty-print";
1010
export const command = new Command("firestore:backups:schedules:list")
1111
.description("List backup schedules under your Cloud Firestore database.")
1212
.option(
13-
"-db, --database <databaseId>",
13+
"-d, --database <databaseId>",
1414
"Database whose schedules you wish to list. Defaults to the (default) database.",
1515
)
1616
.before(requirePermissions, ["datastore.backupSchedules.list"])

src/commands/firestore-backups-schedules-update.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import { FirebaseError } from "../error";
1313

1414
export const command = new Command("firestore:backups:schedules:update <backupSchedule>")
1515
.description("Update a backup schedule under your Cloud Firestore database.")
16-
.option("-rt, --retention <duration>", "duration string (e.g. 12h or 30d) for backup retention")
16+
.option("--retention <duration>", "duration string (e.g. 12h or 30d) for backup retention")
1717
.before(requirePermissions, ["datastore.backupSchedules.update"])
1818
.before(warnEmulatorNotSupported, Emulators.FIRESTORE)
1919
.action(async (backupScheduleName: string, options: FirestoreOptions) => {

0 commit comments

Comments
 (0)