-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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(api): implement branch/commit comparison API #30349
Merged
Merged
Commits on Apr 13, 2024
-
feat: implement commit comparison API endpoint
- Add new `Compare` struct to represent comparison between two commits - Introduce new API endpoint `/compare/*` to get commit comparison information - Create new file `repo_compare.go` with the `Compare` struct definition - Add new file `compare.go` in `routers/api/v1/repo` to handle comparison logic - Add new file `compare.go` in `routers/common` to define `CompareInfo` struct - Refactor `ParseCompareInfo` function to use `common.CompareInfo` struct - Update Swagger documentation to include the new API endpoint for commit comparison - Remove duplicate `CompareInfo` struct from `routers/web/repo/compare.go` - Adjust base path in Swagger template to be relative (`/api/v1`) Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 0740351 - Browse repository at this point
Copy the full SHA 0740351View commit details -
feat: refactor API comparison structures
- Add a new `swaggerCompare` struct for API response in `repo.go` - Update the `basePath` in `v1_json.tmpl` to include `AppSubUrl` - Define a new `Compare` object in Swagger JSON template with properties `commits` and `total_commits` - Add a reference to the `Compare` definition in Swagger JSON template Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for b39e615 - Browse repository at this point
Copy the full SHA b39e615View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6b8c322 - Browse repository at this point
Copy the full SHA 6b8c322View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1719ef5 - Browse repository at this point
Copy the full SHA 1719ef5View commit details -
Configuration menu - View commit details
-
Copy full SHA for e37ebf2 - Browse repository at this point
Copy the full SHA e37ebf2View commit details -
Configuration menu - View commit details
-
Copy full SHA for ab5dcda - Browse repository at this point
Copy the full SHA ab5dcdaView commit details -
Configuration menu - View commit details
-
Copy full SHA for c2c3e59 - Browse repository at this point
Copy the full SHA c2c3e59View commit details -
Configuration menu - View commit details
-
Copy full SHA for a21234b - Browse repository at this point
Copy the full SHA a21234bView commit details -
Signed-off-by: appleboy <appleboy.tw@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 6ce81db - Browse repository at this point
Copy the full SHA 6ce81dbView commit details -
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 7d9723d - Browse repository at this point
Copy the full SHA 7d9723dView commit details
Commits on Apr 14, 2024
-
Configuration menu - View commit details
-
Copy full SHA for dc7078d - Browse repository at this point
Copy the full SHA dc7078dView commit details
Commits on Apr 15, 2024
-
refactor: simplify logic and improve variable clarity
- Remove unused imports and functions - Refactor the `ParseCompareInfo` function to simplify the logic - Update variable names for clarity - Adjust the comparison of commits in the `CompareDiff` function Signed-off-by: appleboy <appleboy.tw@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 94746ec - Browse repository at this point
Copy the full SHA 94746ecView commit details
Commits on Apr 16, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 944c525 - Browse repository at this point
Copy the full SHA 944c525View commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.