Linux command
aws-codecommit 命令
网络
复制后可按需替换文件名、目录或参数。
常用示例
Create a new repository
aws codecommit create-repository --repository-name [my-repo] --repository-description "[Description]"
List all repositories
aws codecommit list-repositories
Clone a repository
git clone codecommit::[region]://[my-repo]
Create a branch
aws codecommit create-branch --repository-name [my-repo] --branch-name [feature-branch] --commit-id [abc123]
Create a pull request
aws codecommit create-pull-request --title "[PR Title]" --targets repositoryName=[my-repo],sourceReference=[feature-branch],destinationReference=main
Put a file
aws codecommit put-file --repository-name [my-repo] --branch-name main --file-content file://[local-file.txt] --file-path [path/in/repo.txt] --commit-message "[message]"
说明
aws codecommit is the AWS CLI interface for AWS CodeCommit, a fully managed source control service hosting secure Git repositories. CodeCommit eliminates the need to operate your own source control system and scales automatically to meet project needs. CodeCommit supports standard Git functionality including branches, commits, and merges. It adds AWS-specific features like pull request approval rules, repository triggers for event notifications, and integration with AWS IAM for access control.
FAQ
What is the aws-codecommit command used for?
aws codecommit is the AWS CLI interface for AWS CodeCommit, a fully managed source control service hosting secure Git repositories. CodeCommit eliminates the need to operate your own source control system and scales automatically to meet project needs. CodeCommit supports standard Git functionality including branches, commits, and merges. It adds AWS-specific features like pull request approval rules, repository triggers for event notifications, and integration with AWS IAM for access control.
How do I run a basic aws-codecommit example?
Run `aws codecommit create-repository --repository-name [my-repo] --repository-description "[Description]"` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
Where can I find more aws-codecommit examples?
This page includes 6 examples for aws-codecommit, plus related commands for nearby Linux tasks.