summaryrefslogtreecommitdiff
path: root/app/views/projects/diffs
Commit message (Collapse)AuthorAgeFilesLines
* prevent nonewline type diff lines from containing unfolding link26829-diff-unfolding-links-erroneously-present-on-no-newline-linesMike Greiling2017-01-181-2/+10
|
* Merge branch 'issue_25017' into 'master' Sean McGivern2017-01-171-2/+2
|\ | | | | | | | | | | | | Show 'too many changes' message for merge request Closes #25017 See merge request !8444
| * Show 'too many changes' message for merge requestissue_25017Felipe Artur2017-01-121-2/+2
| |
* | fixed commit diff linking and added specsfix/diff-titleLuke "Jared" Bennett2017-01-141-1/+1
|/
* HAMLLint: Fix `SpaceInsideHashAttributes` offencesKushal Pandya2016-12-316-30/+29
|
* HAMLLint: Fix `ImplicitDiv` offencesKushal Pandya2016-12-312-4/+4
|
* HAMLLint: fix `AltText` offencesKushal Pandya2016-12-311-7/+7
|
* Rename filename to file path in tooltip of file header in merge request diffVictor Wu2016-12-261-1/+1
|
* Merge branch 'hoopes/gitlab-ce-21027-add-diff-hunks-to-notification-emails' ↵Douwe Maan2016-11-291-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into 'master' Add diff hunks to notification emails Add diff hunks to notification emails. Continued from https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/5855 - thanks @hoopes! This also fixes an issue where the + / - prefixes were missing from diffs in emails. Screenshots (from my browser) of the HTML emails, along with text screenshots :stuck_out_tongue: ![image](/uploads/cb31400becf5149d40c8bb98a655aa93/image.png) ``` New comment for Merge Request !1 on app/views/admin/builds/index.html.haml: http://localhost:3000/gitlab-org/gitlab-ce/merge_requests/1#note_1023 > Finished This is a comment at the top of a match section. ``` ![image](/uploads/704dd3845797530697a27f5c1953c053/image.png) ``` New comment for Merge Request !1 on app/views/admin/builds/index.html.haml: http://localhost:3000/gitlab-org/gitlab-ce/merge_requests/1#note_1022 > Finished > %span.badge.js-running-count= @all_builds.finished.count(:id) > > - %li{class: ('active' if @scope == 'all')} > - = link_to admin_builds_path(scope: :all) do > - All > - %span.badge.js-totalbuilds-count= @all_builds.count(:id) > - > .gray-content-block > #{(@scope || 'running').capitalize} builds > This is a comment at the bottom of a match section. ``` ![image](/uploads/4063f3d9738aea8ebf3c0e690d0eddee/image.png) ``` New comment for Merge Request !1 on app/views/admin/builds/index.html.haml: http://localhost:3000/gitlab-org/gitlab-ce/merge_requests/1#note_1024 > = link_to 'Cancel all', cancel_all_admin_builds_path, data: { confirm: 'Are you sure?' }, class: 'btn btn-danger', method: :post > > %ul.center-top-menu > - %li{class: ('active' if @scope.nil?)} > + %li{class: ('active' if @scope == 'all')} > = link_to admin_builds_path do > + All This is a comment with some deleted and added lines above it. ``` Closes #21027, closes #24340. See merge request !7660
| * Don't use diff_line_content for emailsSean McGivern2016-11-281-1/+1
| |
| * Don't remove + / - signs from diff emailsSean McGivern2016-11-281-1/+1
| | | | | | | | | | | | | | In the browser, we remove the + and - signs from the front of a diff line because we add them in with CSS, so they aren't copied. We can't do that in an email, because the CSS isn't supported, so we should keep them in that case.
* | Merge branch 'jej-22869' into 'security'Douwe Maan2016-11-281-1/+1
|/ | | | | | | | | | | | | | | | | | Fix information disclosure in `Projects::BlobController#update` It was possible to discover private project names by modifying `from_merge_request`parameter in `Projects::BlobController#update`. This fixes that. - [ ] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG.md) entry added - Tests - [x] Added for this feature/bug - [ ] All builds are passing - [x] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) https://gitlab.com/gitlab-org/gitlab-ce/issues/22869 See merge request !2023
* Merge branch '24010-Add-named-anchors-for-diffs-in-the-commit-page' into ↵Sean McGivern2016-11-173-9/+11
|\ | | | | | | | | | | | | | | | | | | 'master' Adds hash anchors to diff_files to make possible linking exact file in commit Closes #24010 See merge request !7298
| * Unify anchor link format for MR diff files !7298Yar2016-11-153-9/+11
| | | | | | | | | | | | | | | | Right now, the following naming scheme for diff files is used: diff-1, diff-2, ... and also we have "internal" format which is file-path-HASH, where HASH is sha1 of file path. Besides, we have HASH_lineA_lineB format to link exact line number in MR diff. It makes sence to unify the way we link diff from outside, while leave "file-path-HASH" format for internal (js) usage. Changes in this commit allow to link diff just by HASH, if we don't want specify exact lines, also it changes "file-path-HASH" and "diff-NUMBER" links in code to this unified format. Inspired by #24010 and !7298
* | Fix Error 500 when creating a merge request that contains an image that was ↵stanhu/gitlab-ce-fix-error-500-with-mr-imagesStan Hu2016-11-141-1/+1
|/ | | | | | | | | | | | | | | | | deleted and added Steps to reproduce: 1. Start with a repo with an image 2. Add a commit to delete the image 3. Add another commit to replace the image with another image In a diff comparison, we really just compare about what the image was before the diff, not the direct parent of the last commit. This MR fixes that. Closes #3893, gitlab-org/gitlab-ee#678 Signed-off-by: Rémy Coutable <remy@rymai.me>
* Fix expanding a collapsed diff when converting a symlink to a regular fileadam-fix-collapsed-diff-symlink-file-conversionAdam Niedzielski2016-11-101-1/+1
| | | | | In this case comparing old_path and new_path is not enough because there are two entires that match.
* Merge branch 'remove-heading-space-from-diff-content' into 'master' Alfredo Sumaran2016-11-091-2/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove an extra leading space from diff paste data ## What does this MR do? Remove an extra leading space from diff paste data. ## Are there points in the code the reviewer needs to double check? I have checked the following three patterns. * inline diff * parallel diff * blob preview ## Why was this MR needed? Diff paste data contain an extra leading space. So it need to remove an extra leading space manually from pasted diff data. ## Screenshots (if relevant) ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG.md) entry added - [ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [ ] API support added - Tests - [ ] Added for this feature/bug - [ ] All builds are passing - [ ] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [ ] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [ ] Branch has no merge conflicts with `master` (if it does - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? #14176 Closes #23899 See merge request !7133
| * Remove an extra leading space from diff contentHiroyuki Sato2016-11-041-2/+2
| |
* | Add width to caret to rid ourselves of the shiftfixed-width-caretJacob Schatz2016-11-041-1/+1
|/ | | | | | | | | | Add CHANGELOG uses fa-fw from font awesome instead of using declaring fix width explicitly moves changelog entry under 8.14 rebased with master
* Updated positioning of copy file path button in diffsmr-copy-filename-btn-updatePhil Hughes2016-10-312-1/+2
| | | | Closes #23591
* Fix horizontal padding for highlight blocks23661-lacking-padding-on-syntax-highlight-blocks-in-diff-commentsLuke Bennett2016-10-251-1/+1
|
* Added copy file path button to diffsmr-file-path-copy-btnPhil Hughes2016-10-101-1/+1
| | | | Closes #23108
* MergeRequest new form load diff asynchronouslynew-merge-requests-commit-tab-activePaco Guzman2016-10-061-1/+2
|
* Merge branch '22343-honor-user-fixed-layout-pref' into 'master' Fatih Acet2016-10-041-2/+0
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ensure the 'fixed layout' preference is honored whenever possible ## What does this MR do? Currently, when viewing any Merge Request the user's fixed-layout preference is overridden if they have set "Side-by-Side" view as their preference when viewing diffs. This makes sense if they are currently viewing a diff, but this is confusing when their layout preference is overridden while they are on another tab (i.e. "Discussion" or "Builds"). This MR moves all responsibility for overriding the fixed layout from the Ruby page layout helper into frontend JavaScript where it is only applied when needed. ## Are there points in the code the reviewer needs to double check? Check that nothing broke for users which have their layout preference set to "Fluid" as well as those which have it set to "Fixed". I've already done this but double checking is always good idea :smile:. ## Screenshots (if relevant) ![side-by-side-toggle-fixed](/uploads/033dc73e70b73da5692b75606733c938/side-by-side-toggle-fixed.gif) ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - Tests - [ ] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? Closes #22343 ## Other Notes As @lbennett noted in #22343, this is something of a band-aid. It fixed most of the issue, but we still need to have a discussion about whether or not is acceptable to override user layout preferences for "Side-by-Side" views in general. At least this MR limits the scope of this behavior to a single tab within an MR or merge conflict page. See merge request !6422
| * ensure the 'fixed layout' preference is honored whenever possibleMike Greiling2016-09-201-2/+0
| | | | | | | | see #22343 for issue description
* | Merge branch '21369-make-it-clearer-that-diffs-can-be-collapsed' into 'master' Jacob Schatz2016-10-012-1/+4
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Updated diff toggle targets and added icon ## What does this MR do? Adds the new diff toggle icon and alters the toggle targets. User can now click on the file header bar _(where no other elements are above it, apart from the icon)_ and the `Click to expand` link to expand the diff and no where else. ## Are there points in the code the reviewer needs to double check? ## Why was this MR needed? ## Screenshots (if relevant) ![Screen_Shot_2016-09-02_at_15.35.15](/uploads/c1cb8c0547328153250294d6c95dd96a/Screen_Shot_2016-09-02_at_15.35.15.png) #### Gif ![2016-09-02_15.34.31](/uploads/abaefaeba9ce8ef129522dae34574c57/2016-09-02_15.34.31.gif) ## Does this MR meet the acceptance criteria? - [ ] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [ ] API support added - Tests - [ ] Added for this feature/bug - [ ] All builds are passing - [ ] Conform by the [merge request performance guides](http://docs.gitlab.com/ce/development/merge_request_performance_guidelines.html) - [ ] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [ ] Branch has no merge conflicts with `master` (if you do - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) ## What are the relevant issue numbers? Closes #21369 Closes #20326 See merge request !6183
| * | Updated diff toggle targets and added iconLuke Bennett2016-09-032-1/+4
| |/
* | fix typo "this files" -> "this file"Mike Greiling2016-09-291-1/+1
| |
* | Style merge request diff dropdowns & disable comments.Bryce Johnson2016-09-141-1/+1
|/
* Fix expansion of discussions in diffdiff-line-comment-vuejsDouwe Maan2016-08-182-4/+2
|
* Improve performance of MR show pageDouwe Maan2016-08-182-10/+16
|
* Merge branch '20454-edit-button-mr' into 'master' Douwe Maan2016-08-181-4/+3
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | edit_blob_link can receive the blob to avoid access to the repository ## What does this MR do? Avoid access to the repository to get the blob when can be passed on context ## Are there points in the code the reviewer needs to double check? ## Why was this MR needed? #20454 to try to speed up the diff pages ## What are the relevant issue numbers? Relates #20454 probably we want and UI solution not just a backend solution ## Screenshots (if relevant) ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - ~~[ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md)~~ - ~~[ ] API support added~~ - Tests - [x] Added for this feature/bug - [ ] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !5850
| * edit_blob_link can receive the blob to avoid access to the repository20454-edit-button-mrPaco Guzman2016-08-181-4/+3
| |
* | Fix email line-height in Outlookoutlook-email-spacingSean McGivern2016-08-171-1/+6
|/ | | | | Outlook seems to handle `white-space: pre` weirdly, so just use `pre` elements (but only for emails!).
* Avoid commit lookup on diff_helperexplicit-arguments-on-diff_file_html_dataPaco Guzman2016-08-101-1/+1
|
* Merge branch 'side-by-side-unfold' into 'master' Douwe Maan2016-08-056-18/+11
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add unfold links for Side-by-Side view ## What does this MR do? Add unfold links for Side-by-Side view and refactor some diff related code ## What are the relevant issue numbers? Closes #3877 ## Does this MR meet the acceptance criteria? - [x] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [x] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [x] API support added - Tests - [x] Added for this feature/bug - [x] All builds are passing - [x] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [x] Branch has no merge conflicts with `master` (if you do - rebase it please) - [x] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !5415
| * Add unfold links for Side-by-Side viewTim Masliuchenko2016-08-046-18/+11
| |
* | Fix Mystery GuestHerminio Torres2016-08-042-3/+3
|/ | | | | | Magic Variable - Change the name of the variable to assign the local variable for partial, rather than `i` use the `index`. Don't pass a local variable called `i` to a partial.
* switch from diff_file_collection to diffs20034-safe-diffsPaco Guzman2016-08-031-7/+7
| | | | So we have raw_diffs too
* Introduce Compare model in the codebase.Paco Guzman2016-08-031-3/+4
| | | This object will manage Gitlab::Git::Compare instances
* Move to Gitlab::Diff::FileCollectionPaco Guzman2016-08-031-1/+1
| | | Instead calling diff_collection.count use diff_collection.size which is cache on the diff_collection
* Cache highlighted diff lines for merge requestsPaco Guzman2016-08-033-5/+3
| | | | Introducing the concept of SafeDiffs which relates diffs with UI highlighting.
* Avoid line_code and position calculation on line partial for plain view14202-avoid-line-code-position-calculationsPaco Guzman2016-08-011-4/+3
|
* Improve diff performance by eliminating redundant checks for text blobsremove-redundant-blob-text-callsStan Hu2016-07-291-4/+5
| | | | | | | On a merge request with over 1000 changed files, there were redundant calls to blob_text_viewable?, which incurred about 7% of the time. Improves #14775
* Bump gitlab_git to speedup DiffCollection iterationsPaco Guzman2016-07-292-2/+2
|
* Fix expand all diffs button in compare view20241-expand-all-button-breaks-diff-comparison-viewSean McGivern2016-07-261-1/+1
| | | | | | | | We can't reuse the existing value of the format parameter, because on the merge request page that's 'json', so the link would go to a JSON file. We can't set it to HTML, because that adds '.html' the URL, which breaks the compare view (and looks bad). Setting it to nil uses the default format, which in all of these cases is HTML anyway.
* Add Discussion model to represent MR/diff discussiondiscussion-modelDouwe Maan2016-07-203-31/+30
|
* Collapsed diffs lines/size don't accumulate to overflow diffs.19820-safer-diffsPaco Guzman2016-07-182-6/+6
|
* Merge branch 'master' into faster-diffsfaster-diffsJacob Schatz2016-07-114-28/+32
|\
| * Support renames in diff_for_path actionsSean McGivern2016-07-111-1/+1
| |