Konstantin Ryabitsev wrote:
> Hi, all:
>
> One of the recent additions to public-inbox was auto-indexing of patches by
> their patch-id (see git-patch-id.1). This allows to see a history of many
> commits through public-inbox discussions. Using a random commit as an example:
>
>
=/mirrors/git.git/diff
export QUERY_STRING PATH_INFO
time ./cgit >/dev/null
Before:
real0m1.585s
user0m0.904s
sys 0m0.658s
After:
real0m0.750s
user0m0.666s
sys 0m0.076s
Signed-off-by: Eric Wong
---
I've been running this with Lua commit filter for the past two
ye
Text-based browsers without CSS support show all the decorations
bunched together without spacing. Rely on a whitespace instead
of CSS support.
Signed-off-by: Eric Wong
---
cgit.css | 1 -
ui-log.c | 5 +
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/cgit.css b/cgit.css
mplete CSS
support.
The only incompatible (with existing CSS customisations) change
might be the one to use instead of for commit-msg.
I'm not sure how much of a stable interface the CSS styles are
expected to be for this project.
Eric Wong (5):
ui-shared: improve pageheader display on
ss
for you to fetch changes up to ab8ff5295cfed27f6c827600fed28376b4540bb4:
ui-{tree,repolist}: improve button spacing for browsers w/o CSS (2021-03-19
20:17:01 +)
----
Eric Wong (5):
ui-shared: improve pageheader display on
We need to use a non-breaking space entity to preserve
spacing for browsers without CSS support.
Signed-off-by: Eric Wong
---
html.c| 46 ++
html.h| 1 +
ui-diff.c | 5 +
3 files changed, 48 insertions(+), 4 deletions(-)
diff --git
For browsers on low-end machines running browsers without CSS
support, the default tree view displayed "logplain" when it
should be "log plain". Stop relying on CSS and add a space
in between elements to improve accessibility.
Signed-off-by: Eric Wong
---
cgit.css |
has type ‘unsigned int’ [-Wformat=]
> htmlf("%lu", (uintptr_t)date->util);
> ^
Signed-off-by: Eric Wong
---
ui-stats.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/ui-stats.c b/ui-stats.c
index 09b3625..ad22dae 100644
--- a
Eric Wong wrote:
> Here are a few changes to improve rendering for people with
> low-end machines using text-based browsers (w3m, lynx) or
> lightweight GUI browsers such as dillo, which has incomplete CSS
> support.
Ping. Any feedback on this ser
strncat is slow and error-prone, use the git strbuf API instead.
We can steal much of our logic from git/pretty.c::strbuf_add_tabexpand,
but maybe keep the invalid characters for now *shrug*.
---
v2: call "strbuf_add(, line, linelen);" at the end
to ensure tab-less lines are shown.
ui-ssdiff.c
Chris Mayo wrote:
> The title attribute was being set to the same value as the anchor
> element text.
>
> Signed-off-by: Chris Mayo
I am not an HTML expert; but it looks like a reasonable change to
avoid the redundant tooltip.
Acked-b
I've been running this for a few months, now, but forgot to send
it out for review. Perhaps I'm missing something obvious, but
I've never understood the purpose exposing the "diff" endpoint
at the top navigation bar...
The following applies on top of my:
"ui-shared: improve pageheader display on
Christian Hesse wrote:
> From: Christian Hesse
>
> Git version v2.21.0 marks strncat() as banned (commit
> ace5707a803eda0f1dde3d776dc3729d3bc7759a), so replace it.
Btw, I posted a similar-in-spirit patch to replace strncat
in ui-ssdiff.c back in January: <20190102073710.580-...@80x24.org>
It
In the future, I think it could be even more beneficial to
buffer to zlib (if the client accepts gzip) and bypass stdio
buffering in those cases. Smaller responses via gzip means less
IPC overhead and wakeups for the reader.
cgit is linked against zlib anyways because of git, so no extra
For browsers on low-end machines running browsers without CSS
support, the default tree view displayed "logplain" when it
should be "log plain". Stop relying on CSS and add a space
in between elements to improve accessibility.
---
cgit.css | 1 -
ui-repolist.c | 2 ++
ui-tree.c | 12
Eric Wong wrote:
> We need to use a non-breaking space entity to preserve
> spacing for browsers without CSS support.
Btw, an alternative patch which could save bandwidth but
possibly break compatibility with existing CSS would be to wrap
the whole diff area in a , and use
i
> index 70f5b74..2c387c1 100644
> --- a/filter.c
> +++ b/filter.c
> @@ -143,22 +145,22 @@ void cgit_init_filters(void)
> #endif
>
> #ifndef NO_LUA
> -static ssize_t (*libc_write)(int fd, const void *buf, size_t count);
> +static ssize_t (*libc_fwrite)(const void *buf, size_t size, size_t n,
strncat is slow and error-prone, use the git strbuf API instead.
We can steal much of our logic from git/pretty.c::strbuf_add_tabexpand,
but maybe keep the invalid characters for now *shrug*.
---
ui-ssdiff.c | 58 +++--
1 file changed, 25
The following invocation of strncat uses a bogus size and
caused segfaults on my system:
strncat(new_title, ctx.page.title, sizeof(new_title) - strlen(new_title) - 1);
Since str*cat functions are all bug-prone and slow (need to
search for '\0' at every invocation), switch to the safer and
We need to use a non-breaking space entity to preserve
spacing for browsers without CSS support.
---
html.c| 46 ++
html.h| 1 +
ui-diff.c | 5 +
3 files changed, 48 insertions(+), 4 deletions(-)
diff --git a/html.c b/html.c
index
Text-based browsers without CSS support show all the decorations
bunched together without spacing. Rely on a whitespace instead
of CSS support.
---
cgit.css | 1 -
ui-log.c | 5 +
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/cgit.css b/cgit.css
index 9f70d14..6fcd984 100644
Text-based browsers (and some GUI browsers such as dillo) display
the pageheader as:
"summaryrefslogtreecommitdiff"
This is difficult-to-read. Improve accessibility for users who
cannot run memory-hungry browsers by using whitespace instead of
relying on CSS.
---
cgit.css| 1 -
and
uniform font-size all around to make it easier for people
who need to use gigantic fonts).
Eric Wong (4):
ui-shared: improve pageheader display on text-based browsers
ui-{commit,tag}: use for commit-msg
ui-log: improve decoration display for browsers without CSS
ui-diff: preserve spaces w/o
gcc 6.3.0-18 on Debian stable emits the following warning,
despite uintptr_t and "unsigned long" having the same size:
> ../ui-stats.c: In function ‘print_authors’:
> ../ui-stats.c:340:18: warning: format ‘%lu’ expects argument of type ‘long
> unsigned int’, but argument 2 has type ‘unsigned
From: Eric Wong <e...@80x24.org>
pathspec.c::parse_pathspec in git assumes the `argv' array
is terminated with a NULL entry, so do not let it iterate
past the end of the array.
Signed-off-by: Eric Wong <e...@80x24.org>
---
ui-patch.c | 2 +-
1 file changed, 1 insertion(+), 1 delet
Not sure if there's a better fix for this. defbranch is
NULL here on my setup when a crawler hit an invalid URL,
causing strcmp to segfault.
Signed-off-by: Eric Wong <normalper...@yhbt.net>
---
ui-shared.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ui-shared.
"Jason A. Donenfeld" wrote:
> We have another potential issue, however. git.zx2c4.com/cgit and
> git.zx2c4.com/cgit/ have the same content, yet different URLs. This
> might be looked upon unfavorably by search engines. One rectification
> is to add a meta tag. Another, and one
"Jason A. Donenfeld" <ja...@zx2c4.com> wrote:
> On Tue, Feb 23, 2016 at 2:19 AM, Eric Wong <normalper...@yhbt.net> wrote:
> > git already has plenty of integrity checking built-in and
> > getting the proper hashes for the heads/tags over a
> > trusted-e
Lars Hjemli hje...@gmail.com wrote:
On Thu, Jan 16, 2014 at 2:00 AM, Jason A. Donenfeld ja...@zx2c4.com wrote:
On Thu, Jan 16, 2014 at 1:59 AM, Eric Wong normalper...@yhbt.net wrote:
This. I prefer we keep passing around the ctx variable to keep the code
more flexible for future reuse
Jason A. Donenfeld ja...@zx2c4.com wrote:
In theory, passing around the variable, and not relying on a global,
is better. It allows us at somepoint to have multiple contexts, for,
say, implementing FastCGI or an event loop single-process multi
response model.
This. I prefer we keep passing
30 matches
Mail list logo