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

fix(apps/prod/tekton/configs/tasks): fix clone-ext for hotfix cases #1270

Merged
merged 1 commit into from
Sep 27, 2024

Conversation

wuhuizuo
Copy link
Collaborator

before:

~/tidb # MAJOR_MINOR_PATCH=$(echo "$RELEASE_VERSION" | awk -F. '{print $1 "." $2 "." $3}')
~/tidb # echo $MAJOR_MINOR_PATCH
v7.5.2-20240705-eaff0fb

after:

~/tidb #  MAJOR_MINOR_PATCH=$(echo "$RELEASE_VERSION" |grep -oE "^v[0-9]+[.][0-9]+[.][0-9]+")
~/tidb # echo $MAJOR_MINOR_PATCH
v7.5.2

Signed-off-by: wuhuizuo [email protected]

before:
```
~/tidb # MAJOR_MINOR_PATCH=$(echo "$RELEASE_VERSION" | awk -F. '{print $1 "." $2 "." $3}')
~/tidb # echo $MAJOR_MINOR_PATCH
v7.5.2-20240705-eaff0fb
```

after:
```
~/tidb #  MAJOR_MINOR_PATCH=$(echo "$RELEASE_VERSION" |grep -oE "^v[0-9]+[.][0-9]+[.][0-9]+")
~/tidb # echo $MAJOR_MINOR_PATCH
v7.5.2
```

Signed-off-by: wuhuizuo <[email protected]>
@ti-chi-bot ti-chi-bot bot requested a review from purelind September 27, 2024 08:42
@ti-chi-bot ti-chi-bot bot added area/apps env/prod will deploy on the main product cluster labels Sep 27, 2024
Copy link
Contributor

ti-chi-bot bot commented Sep 27, 2024

I have already done a preliminary review for you, and I hope to help you do a better job.

Based on the GitHub Pull Request title and description, it seems that the changes made in the pull request are related to fixing the clone-ext function of the pingcap-git-clone-ext.yaml file in the apps/prod/tekton/configs/tasks directory. Specifically, it replaces the awk command with grep command to extract the MAJOR_MINOR_PATCH value from the RELEASE_VERSION variable.

The changes look simple and straightforward, and the diff only affects the MAJOR_MINOR_PATCH variable value. However, here are some potential problems that can be identified:

  1. It is unclear why the awk command was replaced with the grep command. This may cause confusion for reviewers who are not familiar with the codebase.

  2. The pull request description does not provide enough context about why the changes were made or what problem they aim to solve.

  3. It is not clear if this change has been tested and verified to be working as expected.

To address these potential problems, the following suggestions can be made:

  1. Add a brief description of why the awk command was replaced with the grep command in the pull request description.

  2. Provide more context about the problem that is being fixed and why this change is necessary.

  3. Add a statement confirming that the changes have been tested and verified to be working as expected.

  4. Consider adding some comments in the code explaining the reason for the changes.

Overall, the changes in the pull request seem reasonable, but providing more context and explanation can help with the review process and make it easier for other contributors to understand the code changes.

@ti-chi-bot ti-chi-bot bot added the size/XS label Sep 27, 2024
@wuhuizuo
Copy link
Collaborator Author

/approve

Copy link
Contributor

ti-chi-bot bot commented Sep 27, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: wuhuizuo

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added the approved label Sep 27, 2024
@ti-chi-bot ti-chi-bot bot merged commit 58fcdcf into main Sep 27, 2024
4 checks passed
@ti-chi-bot ti-chi-bot bot deleted the fix/hotfix-build branch September 27, 2024 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved area/apps env/prod will deploy on the main product cluster size/XS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant