Skip to content

Commit 8edcc6e

Browse files
committed
Update backends:get command to match approved API design.
1 parent e361804 commit 8edcc6e

2 files changed

Lines changed: 3 additions & 8 deletions

File tree

src/commands/frameworks-backends-get.ts

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,13 @@ const TABLE_HEAD = [
1616
"Created Date",
1717
"Updated Date",
1818
];
19-
export const command = new Command("backends:get")
19+
export const command = new Command("backends:get <backendId>")
2020
.description("Get backend details of a Firebase project")
2121
.option("-l, --location <location>", "App Backend location", "-")
22-
.option("-b, --backend <backend>", "Backend Id", "")
2322
.before(ensureApiEnabled)
24-
.action(async (options: Options) => {
23+
.action(async (backendId: string, options: Options) => {
2524
const projectId = needProjectId(options);
2625
const location = options.location as string;
27-
const backendId = options.backend as string;
28-
if (!backendId) {
29-
throw new FirebaseError("Backend id can't be empty.");
30-
}
3126

3227
let backendsList: gcp.Backend[] = [];
3328
const table = new Table({

src/init/features/frameworks/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ export async function doSetup(setup: any, projectId: string): Promise<void> {
6565
logSuccess(`Successfully created backend:\n\t${backend.name}`);
6666
logSuccess(`Your site is being deployed at:\n\thttps://${backend.uri}`);
6767
logSuccess(
68-
`View the rollout status by running:\n\tfirebase backends:get --backend=${backend.name}`
68+
`View the rollout status by running:\n\tfirebase backends:get ${backendId} --project ${projectId}`
6969
);
7070
}
7171
}

0 commit comments

Comments
 (0)