Re: [PATCH 3/5] git-submodule: New subcommand 'summary' (3) - limit summary size

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: [PATCH 3/5] git-submodule: New subcommand 'summary' (3) - limit summary size

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:44:04

Ping Yin [off-list ref] writes:
quoted hunk
@@ -265,6 +267,10 @@ set_name_rev () {
 #
 modules_summary()
 {
+	summary_limit=${summary_limit:-1000000}
Why a million?
+	summary_limit=$((summary_limit<0?1000000:summary_limit))
This is doubly bashism.  Variables must be referenced with $,
and $(( conditional ? iftrue : iffalse )) is not POSIX.

Re: [PATCH 3/5] git-submodule: New subcommand 'summary' (3) - limit summary size

From: Ping Yin <hidden>
Date: 2016-06-15 22:44:04

On Jan 12, 2008 4:36 PM, Junio C Hamano [off-list ref] wrote:
Ping Yin [off-list ref] writes:
quoted
@@ -265,6 +267,10 @@ set_name_rev () {
 #
 modules_summary()
 {
+     summary_limit=${summary_limit:-1000000}
Why a million?
Because i think a million is big enough. I'd better define a constant
for unlimited number.
quoted
+     summary_limit=$((summary_limit<0?1000000:summary_limit))
This is doubly bashism.  Variables must be referenced with $,
and $(( conditional ? iftrue : iffalse )) is not POSIX.
Ok, i'll fix this.


-- 
Ping Yin
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help