From 246dd97af3913134c92a279b5fd1a7f39b5b888c Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Thu, 10 Oct 2019 14:07:06 +0200 Subject: [PATCH 1/6] Add Diff Download to Compare List --- docs/content/doc/features/comparison.en-us.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/content/doc/features/comparison.en-us.md b/docs/content/doc/features/comparison.en-us.md index 6bbbfba3b4351..bd8545bbb2351 100644 --- a/docs/content/doc/features/comparison.en-us.md +++ b/docs/content/doc/features/comparison.en-us.md @@ -105,6 +105,7 @@ _Symbols used in table:_ | Revert specific commits or a merge request | [✘](https://github.com/go-gitea/gitea/issues/5158) | ✘ | ✓ | ✓ | ✓ | ✓ | ✘ | | Pull/Merge requests templates | ✓ | ✓ | ✓ | ✓ | ✓ | ✘ | ✘ | | Cherry-picking changes | [✘](https://github.com/go-gitea/gitea/issues/5158) | ✘ | ✘ | ✓ | ✓ | ✘ | ✘ | +| Download Patch | [✓](https://github.com/go-gitea/gitea/issues/8444) | ? | ✓ | ✓ | ✓ | ? | ? | #### 3rd-party integrations From 5fe7e7952b95d56b09eff48dd36679c0fab6c991 Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Fri, 11 Oct 2019 23:01:23 +0200 Subject: [PATCH 2/6] Add&Change Text for Diff Options --- options/locale/locale_en-US.ini | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/options/locale/locale_en-US.ini b/options/locale/locale_en-US.ini index ca09b6120d717..df2c8e1453f9f 100644 --- a/options/locale/locale_en-US.ini +++ b/options/locale/locale_en-US.ini @@ -1367,7 +1367,10 @@ diff.parent = parent diff.commit = commit diff.git-notes = Notes diff.data_not_available = Diff Content Not Available -diff.show_diff_stats = Show Diff Stats +diff.options_button = Diff Options +diff.show_diff_stats = Show Stats +diff.download_patch = Download Patch File +diff.download_diff = Download Diff File diff.show_split_view = Split View diff.show_unified_view = Unified View diff.whitespace_button = Whitespace From d8bb539477080b6cc1af3a346a8f0433e3ecb189 Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Fri, 11 Oct 2019 23:01:58 +0200 Subject: [PATCH 3/6] move button to seperate template --- templates/repo/diff/box.tmpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/repo/diff/box.tmpl b/templates/repo/diff/box.tmpl index b5fde36a6f1fc..0179af2a515f0 100644 --- a/templates/repo/diff/box.tmpl +++ b/templates/repo/diff/box.tmpl @@ -7,7 +7,7 @@ {{else}} {{ if .IsSplitStyle }}{{.i18n.Tr "repo.diff.show_unified_view"}}{{else}}{{.i18n.Tr "repo.diff.show_split_view"}}{{end}} {{end}} - {{.i18n.Tr "repo.diff.show_diff_stats"}} + {{template "repo/diff/options_dropdown" .}} {{if and .PageIsPullFiles $.SignedUserID (not .IsArchived)}} {{template "repo/diff/new_review" .}} {{end}} @@ -26,7 +26,7 @@ {{else}} {{ if .IsSplitStyle }}{{.i18n.Tr "repo.diff.show_unified_view"}}{{else}}{{.i18n.Tr "repo.diff.show_split_view"}}{{end}} {{end}} - {{.i18n.Tr "repo.diff.show_diff_stats"}} + {{template "repo/diff/options_dropdown" .}} {{if and .PageIsPullFiles $.SignedUserID (not .IsArchived)}} {{template "repo/diff/new_review" .}} {{end}} From c0b24a0e02a6c9289b39c67ab02a5eff47569e53 Mon Sep 17 00:00:00 2001 From: 6543 <6543@obermui.de> Date: Fri, 11 Oct 2019 23:02:24 +0200 Subject: [PATCH 4/6] add drop down menue with options --- templates/repo/diff/options_dropdown.tmpl | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 templates/repo/diff/options_dropdown.tmpl diff --git a/templates/repo/diff/options_dropdown.tmpl b/templates/repo/diff/options_dropdown.tmpl new file mode 100644 index 0000000000000..759d8980e14c4 --- /dev/null +++ b/templates/repo/diff/options_dropdown.tmpl @@ -0,0 +1,9 @@ +
From 69d85b74b54293f7ac4d2020938453420abfb5ef Mon Sep 17 00:00:00 2001 From: 6543 <24977596+6543@users.noreply.github.com> Date: Sat, 12 Oct 2019 19:55:31 +0200 Subject: [PATCH 5/6] Update: Compare update Gogs, BitBucket, RhodeCode and remove gitea issue link Co-Authored-By: Lauris BH