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

feat(cargo-shuttle): update project name command #1912

Merged
merged 9 commits into from
Nov 4, 2024
Merged

Conversation

jonaro00
Copy link
Member

@jonaro00 jonaro00 commented Oct 31, 2024

  • syntax: shuttle project update name <name>
  • name is validated in backend
  • tested that default subdomain correctly updates

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR adds project renaming functionality to the cargo-shuttle CLI, allowing users to update project names through a new project update name command in the beta platform.

  • Added update_project_beta method in /api-client/src/lib.rs to handle PUT requests for project updates
  • Introduced ProjectUpdateCommand enum in /cargo-shuttle/src/args.rs to support project renaming functionality
  • Implemented project_rename_beta function in /cargo-shuttle/src/lib.rs to execute project rename operations

3 file(s) reviewed, 3 comment(s)
Edit PR Review Bot Settings | Greptile

cargo-shuttle/src/args.rs Outdated Show resolved Hide resolved
cargo-shuttle/src/lib.rs Show resolved Hide resolved
cargo-shuttle/src/lib.rs Show resolved Hide resolved
Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

(updates since last review)

This PR adds command aliases and enhances the CLI interface for better usability in the Shuttle platform.

  • Added visible alias 'stat' for Status command in both DeploymentCommand and ProjectCommand for consistency with existing aliases
  • Added visible alias 'upd' for the Update command in ProjectCommand enum
  • Added visible alias 'depl' for the Deployment command in the main Command enum

The changes focus on improving CLI ergonomics by providing shorter command alternatives while maintaining consistency with existing alias patterns.

2 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

(updates since last review)

(updates since last review)

Fixed a minor grammatical error in the documentation comment for ProjectUpdateCommand::Name in cargo-shuttle/src/args.rs, changing "it's" to "its" for proper possessive form.

  • Fixed grammatical error in documentation comment for ProjectUpdateCommand::Name variant
  • No functional changes or behavior modifications in this update
  • Documentation improvement maintains code clarity and professionalism

1 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

cargo-shuttle/src/args.rs Show resolved Hide resolved
Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

(updates since last review)

Based on the most recent changes, I'll provide a summary focusing only on new modifications not covered in previous reviews:

Added error handling improvements and validation for the project rename functionality in the cargo-shuttle CLI.

  • Added input validation in /cargo-shuttle/src/lib.rs to ensure new project names meet required format
  • Improved error messaging for failed rename operations with more specific context
  • Enhanced response handling for the rename API endpoint

1 file(s) reviewed, 3 comment(s)
Edit PR Review Bot Settings | Greptile

cargo-shuttle/src/lib.rs Show resolved Hide resolved
cargo-shuttle/src/lib.rs Show resolved Hide resolved
cargo-shuttle/src/lib.rs Show resolved Hide resolved
Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

(updates since last review)

Based on the recent changes and previous reviews, I'll focus on the latest modifications to the project:

Added validation and error handling for the project rename command in the Shuttle CLI.

  • Added project name validation in cargo-shuttle/src/lib.rs to ensure names meet format requirements before API calls
  • Enhanced error context in project_rename_beta function to provide clearer feedback on rename failures
  • Improved response handling for the rename endpoint with better error propagation

The changes strengthen the robustness of the project rename functionality while maintaining good user experience through clear error messaging.

1 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

cargo-shuttle/src/lib.rs Show resolved Hide resolved
@jonaro00 jonaro00 changed the title feat(cargo-shuttle): project update name <name> feat(cargo-shuttle): update project name command Nov 4, 2024
Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

(updates since last review)

Based on the recent changes, I'll provide a summary focusing only on new modifications not covered in previous reviews:

Updated dependency versions and type definitions to support the project rename functionality.

The changes ensure proper dependency versioning and type support for the project rename feature while maintaining stability.

4 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

(updates since last review)

Based on the recent changes, I'll provide a summary focusing only on new modifications not covered in previous reviews:

Downgraded typeshare-cli version across configuration files, potentially impacting type generation functionality.

  • Downgraded typeshare-cli from v1.12.0 to v1.11.0 in .circleci/config.yml and Makefile.toml
  • Changed from min_version to version in Makefile.toml, making version requirement more strict
  • Modified version header in common/types.ts to match downgraded typeshare version

The version downgrade appears to be a regression from previous changes and should be reviewed to understand the compatibility requirements driving this change.

3 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

(updates since last review)

Based on the recent changes and previous reviews, I'll provide a focused summary of the latest modifications:

Updated help text in cargo-shuttle CLI to better reflect the project rename functionality.

  • Modified help text in cargo-shuttle/src/args.rs from 'hosted subdomain' to 'default subdomain' for improved clarity
  • Documentation change accurately reflects that the renamed subdomain is the default one assigned to projects
  • No functional changes to the actual rename behavior

The change improves documentation accuracy while maintaining the existing functionality of the project rename feature.

1 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

cargo-shuttle/src/args.rs Show resolved Hide resolved
@jonaro00 jonaro00 merged commit 40ff642 into main Nov 4, 2024
31 of 33 checks passed
@jonaro00 jonaro00 deleted the project-rename branch November 4, 2024 15:20
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.

1 participant