[Pkg-cgit-commits] [pkg-cgit] 33/49: Refresh patches
Peter Colberg
peter at colberg.org
Thu Jun 16 01:49:18 UTC 2016
This is an automated email from the git hooks/post-receive script.
pc-guest pushed a commit to branch master
in repository pkg-cgit.
commit 8a696dd222795b8916baaf262889749ce9a8e1f2
Author: Alexander Wirt <formorer at debian.org>
Date: Mon Aug 10 19:48:02 2015 +0200
Refresh patches
---
debian/patches/debianize_makefile | 2 +-
debian/patches/fix_status_code_for_unknown_repos | 32 +++++++++++-------------
2 files changed, 16 insertions(+), 18 deletions(-)
diff --git a/debian/patches/debianize_makefile b/debian/patches/debianize_makefile
index 79e166b..3446c0a 100644
--- a/debian/patches/debianize_makefile
+++ b/debian/patches/debianize_makefile
@@ -2,7 +2,7 @@
+++ b/Makefile
@@ -2,11 +2,11 @@
- CGIT_VERSION = v0.10.2
+ CGIT_VERSION = v0.11.2
CGIT_SCRIPT_NAME = cgit.cgi
-CGIT_SCRIPT_PATH = /var/www/htdocs/cgit
+CGIT_SCRIPT_PATH = /usr/share/cgit
diff --git a/debian/patches/fix_status_code_for_unknown_repos b/debian/patches/fix_status_code_for_unknown_repos
index cd68120..c16679c 100644
--- a/debian/patches/fix_status_code_for_unknown_repos
+++ b/debian/patches/fix_status_code_for_unknown_repos
@@ -8,9 +8,6 @@ Subject: Return a proper status code when there is no repository found
2 files changed, 48 insertions(+), 13 deletions(-)
create mode 100755 tests/t0112-no-repo-found.sh
-diff --git a/tests/t0112-no-repo-found.sh b/tests/t0112-no-repo-found.sh
-new file mode 100755
-index 0000000..211aa61
--- /dev/null
+++ b/tests/t0112-no-repo-found.sh
@@ -0,0 +1,12 @@
@@ -26,13 +23,11 @@ index 0000000..211aa61
+test_expect_success 'verify there is no log link' '! grep /log/ tmp'
+
+test_done
-diff --git a/ui-repolist.c b/ui-repolist.c
-index c2bcce1..29b1f3f 100644
--- a/ui-repolist.c
+++ b/ui-repolist.c
-@@ -248,17 +248,44 @@ static int sort_repolist(char *field)
+@@ -249,37 +249,59 @@
- void cgit_print_repolist()
+ void cgit_print_repolist(void)
{
- int i, columns = 3, hits = 0, header = 0;
+ int i, columns = 3, hits = 0, header = 0, found_repos = 0, matched_size = 0;
@@ -76,31 +71,34 @@ index c2bcce1..29b1f3f 100644
cgit_print_http_headers();
cgit_print_docstart();
cgit_print_pageheader();
-@@ -266,17 +293,14 @@ void cgit_print_repolist()
+
if (ctx.cfg.index_header)
html_include(ctx.cfg.index_header);
-
+-
- if (ctx.qry.sort)
- sorted = sort_repolist(ctx.qry.sort);
- else if (ctx.cfg.section_sort)
- sort_repolist("section");
-+ if (!found_repos) {
-+ cgit_print_error("No repositories found");
-+ goto docend;
-+ }
++
++ if (!found_repos) {
++ cgit_print_error("No repositories found");
++ goto docend;
++ }
html("<table summary='repository list' class='list nowrap'>");
- for (i = 0; i < cgit_repolist.count; i++) {
- ctx.repo = &cgit_repolist.repos[i];
+- if (ctx.repo->hide || ctx.repo->ignore)
+- continue;
- if (!(is_match(ctx.repo) && is_in_url(ctx.repo)))
- continue;
- hits++;
-+ for (hits = 1; hits <= found_repos; hits++) {
-+ ctx.repo = matched_repos[hits-1];
++ for (hits = 1; hits <= found_repos; hits++) {
++ ctx.repo = matched_repos[hits-1];
if (hits <= ctx.qry.ofs)
continue;
if (hits > ctx.qry.ofs + ctx.cfg.max_repo_count)
-@@ -328,11 +352,12 @@ void cgit_print_repolist()
+@@ -337,11 +359,12 @@
html("</tr>\n");
}
html("</table>");
@@ -115,4 +113,4 @@ index c2bcce1..29b1f3f 100644
+ free(matched_repos);
}
- void cgit_print_site_readme()
+ void cgit_print_site_readme(void)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-cgit/pkg-cgit.git
More information about the Pkg-cgit-commits
mailing list