summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile4
-rw-r--r--cgit-70.c7
-rw-r--r--ui_70-shared.c6
-rw-r--r--ui_70-tree.c1
4 files changed, 5 insertions, 13 deletions
diff --git a/Makefile b/Makefile
index f8cf61c..883a5a1 100644
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,10 @@
all::
CGIT_VERSION = v1.2
-CGIT_SCRIPT_NAME = cgit.cgi
+CGIT_SCRIPT_NAME = cgit-70.cgi
CGIT_SCRIPT_PATH = /var/www/htdocs/cgit-70
CGIT_DATA_PATH = $(CGIT_SCRIPT_PATH)
-CGIT_CONFIG = /var/www/htdocs/etc/cgitrc
+CGIT_CONFIG = /etc/cgit-70rc
CACHE_ROOT = /var/cache/cgit
prefix = /usr/local
libdir = $(prefix)/lib
diff --git a/cgit-70.c b/cgit-70.c
index 90ddb6f..14e1425 100644
--- a/cgit-70.c
+++ b/cgit-70.c
@@ -303,7 +303,6 @@ static void querystring_cb(const char *name, const char *value)
if (*value == '/')
value++;
ctx.qry.url = xstrdup(value);
- fprintf(stderr, " --- got url: %s\n", value);
cgit_parse_url(value);
} else if (!strcmp(name, "qt")) {
ctx.qry.grep = xstrdup(value);
@@ -950,24 +949,18 @@ out:
static void cgit_parse_args(int argc, const char **argv)
{
while (--argc > 4);
- fprintf(stderr, " -- argc: %d\n", argc);
switch (++argc){
case 5:
ctx.env.server_port = xstrdup(argv[4]);
- fprintf(stderr, "server_port: %s\n", ctx.env.server_port);
case 4:
ctx.env.server_name = xstrdup(argv[3]);
- fprintf(stderr, "server_name: %s\n", ctx.env.server_name);
case 3:
ctx.env.query_string = xstrdup(argv[2]);
ctx.qry.raw = xstrdup(argv[2]);
- fprintf(stderr, "query_string: %s\n", ctx.env.query_string);
case 2:
ctx.env.gopher_search = xstrdup(argv[1]);
- fprintf(stderr, "gopher_search: %s\n", ctx.env.gopher_search);
case 1:
ctx.env.script_name = xstrdup(argv[0]);
- fprintf(stderr, "script_name: %s\n", ctx.env.script_name);
}
}
diff --git a/ui_70-shared.c b/ui_70-shared.c
index a0a9139..3262320 100644
--- a/ui_70-shared.c
+++ b/ui_70-shared.c
@@ -242,9 +242,9 @@ char *cgit_currenturl(void)
const char *cgit_rooturl(void)
{
if (ctx.cfg.virtual_root)
- return fmtalloc("/%s", ctx.cfg.virtual_root);
+ return ctx.cfg.virtual_root;
else
- return fmtalloc("/%s", ctx.cfg.script_name);
+ return ctx.cfg.script_name;
}
const char *cgit_loginurl(void)
@@ -1153,7 +1153,7 @@ static void print_header(void)
} else
cgit_gopher_info(ctx.cfg.root_title);
if (ctx.repo) {
- cgit_gopher_start_selector(GOPHER_MENU);
+ cgit_gopher_start_selector(GOPHER_INFO);
cgit_gopher_text("Owner: ");
cgit_gopher_text(ctx.repo->owner);
cgit_gopher_tab();
diff --git a/ui_70-tree.c b/ui_70-tree.c
index ecef53e..c0c2be3 100644
--- a/ui_70-tree.c
+++ b/ui_70-tree.c
@@ -197,7 +197,6 @@ static int ls_item(const struct object_id *oid, struct strbuf *base,
cgit_blame_link("blame", NULL, "button", ctx.qry.head,
walk_tree_ctx->curr_rev, fullpath.buf);
*/
- cgit_gopher_tab();
cgit_gopher_end_selector();
free(name);
strbuf_release(&fullpath);