Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make version flag optional [main] #3355

Merged
merged 1 commit into from
Jan 13, 2025

Conversation

gururajsh
Copy link
Member

@gururajsh gururajsh commented Jan 9, 2025

Make the --version flag for revision command optional. When no version flag is provided, all the deployed revisions are displayed.

For ex, if we have the an app named dora and we run revision command without version flag, only deployed revision is displayed.

% cf revisions dora
Getting revisions for app dora in org o / space s as admin...

revision      description             deployable   revision guid                          created at
2(deployed)   New droplet deployed.   true         4b688a00-1b3a-415e-8530-4a0820757fc0   2025-01-13T15:05:38Z
1             Initial revision.       true         e931320d-9ef7-46a9-be1d-d3d78648ea04   2025-01-13T15:04:21Z

% cf revision dora
Showing revisions for app dora in org o / space s as admin...

revision:        2
deployed:        true
description:     New droplet deployed.
deployable:      true
revision GUID:   4b688a00-1b3a-415e-8530-4a0820757fc0
droplet GUID:    a2f451cc-3d7d-4c34-9e49-ef56db18ebb9
created on:      2025-01-13T15:05:38Z

labels:
annotations:
application environment variables:

Copy link
Member

@a-b a-b left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@joaopapereira joaopapereira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR looks good, but I think we should do the optimization I commented about.

command/v7/revision_command.go Show resolved Hide resolved
Copy link
Contributor

@joaopapereira joaopapereira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After talking about my previous point @gururajsh pointed out that the result was behind used in the other if so LGTM

@gururajsh gururajsh merged commit be171a5 into cloudfoundry:main Jan 13, 2025
19 of 21 checks passed
@gururajsh gururajsh deleted the revision-main branch January 13, 2025 16:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants