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
Revert to any single Commit #3040
Comments
|
I could need some help on the following issue: I plan to to ask Git if a commit is existent. We only have a method which fetches all branches from Git, but not anything like it for commits. Does anyone know which request is to be send to Git to ask if a specific commit is existent in a branch? It would be nice if the short and the long form (SHA1) of commits would be supported. At the moment I check if the response is returning valid objects via exceptions and this works. But it would be better, if there'd be some check before the request and parsing of the response. |
|
I dont have much time today or tomorrow, so remind me when I forget to answer 😄 |
|
Added the question above also to Stackoverflow. |
|
cool if possible, when doing the PR, try splitting it into multiple steps, I'd like to avoid large PRs |
|
Few questions:
|
Its like 'git reset --hard ' only without the automation. You first checkout a commit, reset your local repo, checkout the latest commit and then decide to stage it (hard reset remote repo) or reset the local repo to the latest commit via Pull or Reset Local. |
* Create pull.yml * Update zcl_abapgit_git_transport.clas.abap * Update zcl_abapgit_git_transport.clas.abap * Update pull.yml * Delete pull.yml * Improved time conversion Preparation for #3040 > rename time%3D>get to time%3D>get_unix > added time conversion from unix to real (get_real) > added unit tests for time conversion * abapLint * Raise cx_static_check and removed exc handling
|
sorry, I've removed the linked word file, no need to share files that potentially can contain bad stuff |
|
Implementation is nearly done. Only one small problem with loading more commits remains: It seems I have to do a http request with the sha of the repo branch and a rising deepen level to get the next 20 sub commits of a branch, which is really time-consuming at a specific deepen level. My first approach was to get sub commits by the last gotten sub commit hash but it seems sometimes not every older commit is being fetched due to the commit hierarchie. So I suggest we remove the 'load more' function and always load a max. specific amount (e. g. max. last 100 commits). |
|
some of the new git features supports only getting the commits, and ignoring the blobs, guess it can be used in this case, like for the branch overview page |
|
Yes, I already reuse the related function like it is being used in branch overview page. But it's just very time-consuming to load over 3500 commits (> 12 Minutes last time I tested it). So we have to limit it. Yet I don't know how to do it. Additionally branch overview page just filters the commits from the response. Within the response there are still the blobs. So at the moment we don't have a function that only requests the commits. |
|
@larshp I plan to ship the changes now in the following chunks: MODEL: GUI: LOGIC: Is this ok with you? |
|
yea, some of the classes I would not expect any changes to, but lets see |
* Create pull.yml * Update zcl_abapgit_git_transport.clas.abap * Update zcl_abapgit_git_transport.clas.abap * Update pull.yml * Update pull.yml * Delete pull.yml * Refactored popup logic Related to #3040 Refactoring of popup logic/calling to be able to reuse it as commit list. * Removed reset flag Removed reset flag cause it doesn't belong to this PR (will be readded later) Co-authored-by: pull[bot] <39814207+pull[bot]@users.noreply.github.com> Co-authored-by: Lars Hvam <larshp@hotmail.com>
|
Some people asked where the commit can be selected, maybe this can be useful to comment here with a screenshot. Answer valid as of 1.116.0. Select the repository, click Settings, select the Commit and then Pull: |

I didn't find this feature and need it so I suggest it: I think it would be useful to be able to revert to any single commit. For this it should be possible to select any existent commit and revert the repository to it.
Related to Issue #753.
The text was updated successfully, but these errors were encountered: