Fossil SCM

In the UI and CL, output UUID's the same (almost) everywhere: The first 10 characters of UUID's are always displayed, but more are added until the UUID contains at least a single 'a'-'f'. Hyperlinks still usee the full-length UUID.

jan.nijtmans 2014-07-16 07:57 trunk merge
Commit fe6d393021d9205a33d490bdeed36cacaa8d1914
+1 -1
--- src/browse.c
+++ src/browse.c
@@ -179,11 +179,11 @@
179179
if( linkTip ){
180180
style_submenu_element("Tip", "Tip", "%s",
181181
url_render(&sURI, "ci", "tip", 0, 0));
182182
}
183183
if( zCI ){
184
- @ <h2>Files of check-in [%z(href("vinfo?name=%s",zUuid))%.10s(zUuid)</a>]
184
+ @ <h2>Files of check-in [%z(href("vinfo?name=%s",zUuid))%S(zUuid)</a>]
185185
@ %s(blob_str(&dirname))</h2>
186186
zSubdirLink = mprintf("%R/dir?ci=%s&name=%T", zUuid, zPrefix);
187187
if( nD==0 ){
188188
style_submenu_element("File Ages", "File Ages", "%R/fileage?name=%s",
189189
zUuid);
190190
--- src/browse.c
+++ src/browse.c
@@ -179,11 +179,11 @@
179 if( linkTip ){
180 style_submenu_element("Tip", "Tip", "%s",
181 url_render(&sURI, "ci", "tip", 0, 0));
182 }
183 if( zCI ){
184 @ <h2>Files of check-in [%z(href("vinfo?name=%s",zUuid))%.10s(zUuid)</a>]
185 @ %s(blob_str(&dirname))</h2>
186 zSubdirLink = mprintf("%R/dir?ci=%s&name=%T", zUuid, zPrefix);
187 if( nD==0 ){
188 style_submenu_element("File Ages", "File Ages", "%R/fileage?name=%s",
189 zUuid);
190
--- src/browse.c
+++ src/browse.c
@@ -179,11 +179,11 @@
179 if( linkTip ){
180 style_submenu_element("Tip", "Tip", "%s",
181 url_render(&sURI, "ci", "tip", 0, 0));
182 }
183 if( zCI ){
184 @ <h2>Files of check-in [%z(href("vinfo?name=%s",zUuid))%S(zUuid)</a>]
185 @ %s(blob_str(&dirname))</h2>
186 zSubdirLink = mprintf("%R/dir?ci=%s&name=%T", zUuid, zPrefix);
187 if( nD==0 ){
188 style_submenu_element("File Ages", "File Ages", "%R/fileage?name=%s",
189 zUuid);
190
+1 -1
--- src/checkin.c
+++ src/checkin.c
@@ -928,11 +928,11 @@
928928
" WHERE datetime(mtime)>=%Q"
929929
" AND type='ci' AND objid=%d",
930930
zDate, rid
931931
);
932932
if( b ){
933
- fossil_fatal("ancestor check-in [%.10s] (%s) is not older (clock skew?)"
933
+ fossil_fatal("ancestor check-in [%S] (%s) is not older (clock skew?)"
934934
" Use --allow-older to override.", zUuid, zDate);
935935
}
936936
#endif
937937
}
938938
939939
--- src/checkin.c
+++ src/checkin.c
@@ -928,11 +928,11 @@
928 " WHERE datetime(mtime)>=%Q"
929 " AND type='ci' AND objid=%d",
930 zDate, rid
931 );
932 if( b ){
933 fossil_fatal("ancestor check-in [%.10s] (%s) is not older (clock skew?)"
934 " Use --allow-older to override.", zUuid, zDate);
935 }
936 #endif
937 }
938
939
--- src/checkin.c
+++ src/checkin.c
@@ -928,11 +928,11 @@
928 " WHERE datetime(mtime)>=%Q"
929 " AND type='ci' AND objid=%d",
930 zDate, rid
931 );
932 if( b ){
933 fossil_fatal("ancestor check-in [%S] (%s) is not older (clock skew?)"
934 " Use --allow-older to override.", zUuid, zDate);
935 }
936 #endif
937 }
938
939
+1 -1
--- src/checkin.c
+++ src/checkin.c
@@ -928,11 +928,11 @@
928928
" WHERE datetime(mtime)>=%Q"
929929
" AND type='ci' AND objid=%d",
930930
zDate, rid
931931
);
932932
if( b ){
933
- fossil_fatal("ancestor check-in [%.10s] (%s) is not older (clock skew?)"
933
+ fossil_fatal("ancestor check-in [%S] (%s) is not older (clock skew?)"
934934
" Use --allow-older to override.", zUuid, zDate);
935935
}
936936
#endif
937937
}
938938
939939
--- src/checkin.c
+++ src/checkin.c
@@ -928,11 +928,11 @@
928 " WHERE datetime(mtime)>=%Q"
929 " AND type='ci' AND objid=%d",
930 zDate, rid
931 );
932 if( b ){
933 fossil_fatal("ancestor check-in [%.10s] (%s) is not older (clock skew?)"
934 " Use --allow-older to override.", zUuid, zDate);
935 }
936 #endif
937 }
938
939
--- src/checkin.c
+++ src/checkin.c
@@ -928,11 +928,11 @@
928 " WHERE datetime(mtime)>=%Q"
929 " AND type='ci' AND objid=%d",
930 zDate, rid
931 );
932 if( b ){
933 fossil_fatal("ancestor check-in [%S] (%s) is not older (clock skew?)"
934 " Use --allow-older to override.", zUuid, zDate);
935 }
936 #endif
937 }
938
939
+1 -1
--- src/checkout.c
+++ src/checkout.c
@@ -67,11 +67,11 @@
6767
vid = db_int(0, "SELECT rid FROM blob WHERE uuid=%B", &uuid);
6868
if( vid==0 ){
6969
fossil_fatal("no such check-in: %s", g.argv[2]);
7070
}
7171
if( !is_a_version(vid) ){
72
- fossil_fatal("object [%.10s] is not a check-in", blob_str(&uuid));
72
+ fossil_fatal("object [%S] is not a check-in", blob_str(&uuid));
7373
}
7474
if( load_vfile_from_rid(vid) && !forceMissingFlag ){
7575
fossil_fatal("missing content, unable to checkout");
7676
};
7777
return vid;
7878
--- src/checkout.c
+++ src/checkout.c
@@ -67,11 +67,11 @@
67 vid = db_int(0, "SELECT rid FROM blob WHERE uuid=%B", &uuid);
68 if( vid==0 ){
69 fossil_fatal("no such check-in: %s", g.argv[2]);
70 }
71 if( !is_a_version(vid) ){
72 fossil_fatal("object [%.10s] is not a check-in", blob_str(&uuid));
73 }
74 if( load_vfile_from_rid(vid) && !forceMissingFlag ){
75 fossil_fatal("missing content, unable to checkout");
76 };
77 return vid;
78
--- src/checkout.c
+++ src/checkout.c
@@ -67,11 +67,11 @@
67 vid = db_int(0, "SELECT rid FROM blob WHERE uuid=%B", &uuid);
68 if( vid==0 ){
69 fossil_fatal("no such check-in: %s", g.argv[2]);
70 }
71 if( !is_a_version(vid) ){
72 fossil_fatal("object [%S] is not a check-in", blob_str(&uuid));
73 }
74 if( load_vfile_from_rid(vid) && !forceMissingFlag ){
75 fossil_fatal("missing content, unable to checkout");
76 };
77 return vid;
78
--- src/descendants.c
+++ src/descendants.c
@@ -406,11 +406,11 @@
406406
zLastBr = fossil_strdup(zBr);
407407
}
408408
n++;
409409
sqlite3_snprintf(sizeof(zLineNo), zLineNo, "(%d)", n);
410410
fossil_print("%6s ", zLineNo);
411
- z = mprintf("%s [%.10s] %s", zDate, zId, zCom);
411
+ z = mprintf("%s [%S] %s", zDate, zId, zCom);
412412
comment_print(z, 7, width);
413413
fossil_free(z);
414414
}
415415
fossil_free(zLastBr);
416416
db_finalize(&q);
417417
--- src/descendants.c
+++ src/descendants.c
@@ -406,11 +406,11 @@
406 zLastBr = fossil_strdup(zBr);
407 }
408 n++;
409 sqlite3_snprintf(sizeof(zLineNo), zLineNo, "(%d)", n);
410 fossil_print("%6s ", zLineNo);
411 z = mprintf("%s [%.10s] %s", zDate, zId, zCom);
412 comment_print(z, 7, width);
413 fossil_free(z);
414 }
415 fossil_free(zLastBr);
416 db_finalize(&q);
417
--- src/descendants.c
+++ src/descendants.c
@@ -406,11 +406,11 @@
406 zLastBr = fossil_strdup(zBr);
407 }
408 n++;
409 sqlite3_snprintf(sizeof(zLineNo), zLineNo, "(%d)", n);
410 fossil_print("%6s ", zLineNo);
411 z = mprintf("%s [%S] %s", zDate, zId, zCom);
412 comment_print(z, 7, width);
413 fossil_free(z);
414 }
415 fossil_free(zLastBr);
416 db_finalize(&q);
417
+2 -2
--- src/finfo.c
+++ src/finfo.c
@@ -200,11 +200,11 @@
200200
char *zOut;
201201
if( zBr==0 ) zBr = "trunk";
202202
if( iBrief ){
203203
fossil_print("%s ", zDate);
204204
zOut = sqlite3_mprintf(
205
- "[%.10s] %s (user: %s, artifact: [%.10s], branch: %s)",
205
+ "[%S] %s (user: %s, artifact: [%S], branch: %s)",
206206
zCiUuid, zCom, zUser, zFileUuid, zBr);
207207
comment_print(zOut, 11, iWidth);
208208
sqlite3_free(zOut);
209209
}else{
210210
blob_reset(&line);
@@ -382,11 +382,11 @@
382382
if( baseCheckin ){
383383
char *zUuid = db_text(0, "SELECT uuid FROM blob WHERE rid=%d", baseCheckin);
384384
char *zLink = href("%R/info/%s", zUuid);
385385
blob_appendf(&title, "Ancestors of file ");
386386
hyperlinked_path(zFilename, &title, zUuid, "tree", "");
387
- blob_appendf(&title, " from check-in %z%.10s</a>", zLink, zUuid);
387
+ blob_appendf(&title, " from check-in %z%S</a>", zLink, zUuid);
388388
fossil_free(zUuid);
389389
}else{
390390
blob_appendf(&title, "History of files named ");
391391
hyperlinked_path(zFilename, &title, 0, "tree", "");
392392
}
393393
--- src/finfo.c
+++ src/finfo.c
@@ -200,11 +200,11 @@
200 char *zOut;
201 if( zBr==0 ) zBr = "trunk";
202 if( iBrief ){
203 fossil_print("%s ", zDate);
204 zOut = sqlite3_mprintf(
205 "[%.10s] %s (user: %s, artifact: [%.10s], branch: %s)",
206 zCiUuid, zCom, zUser, zFileUuid, zBr);
207 comment_print(zOut, 11, iWidth);
208 sqlite3_free(zOut);
209 }else{
210 blob_reset(&line);
@@ -382,11 +382,11 @@
382 if( baseCheckin ){
383 char *zUuid = db_text(0, "SELECT uuid FROM blob WHERE rid=%d", baseCheckin);
384 char *zLink = href("%R/info/%s", zUuid);
385 blob_appendf(&title, "Ancestors of file ");
386 hyperlinked_path(zFilename, &title, zUuid, "tree", "");
387 blob_appendf(&title, " from check-in %z%.10s</a>", zLink, zUuid);
388 fossil_free(zUuid);
389 }else{
390 blob_appendf(&title, "History of files named ");
391 hyperlinked_path(zFilename, &title, 0, "tree", "");
392 }
393
--- src/finfo.c
+++ src/finfo.c
@@ -200,11 +200,11 @@
200 char *zOut;
201 if( zBr==0 ) zBr = "trunk";
202 if( iBrief ){
203 fossil_print("%s ", zDate);
204 zOut = sqlite3_mprintf(
205 "[%S] %s (user: %s, artifact: [%S], branch: %s)",
206 zCiUuid, zCom, zUser, zFileUuid, zBr);
207 comment_print(zOut, 11, iWidth);
208 sqlite3_free(zOut);
209 }else{
210 blob_reset(&line);
@@ -382,11 +382,11 @@
382 if( baseCheckin ){
383 char *zUuid = db_text(0, "SELECT uuid FROM blob WHERE rid=%d", baseCheckin);
384 char *zLink = href("%R/info/%s", zUuid);
385 blob_appendf(&title, "Ancestors of file ");
386 hyperlinked_path(zFilename, &title, zUuid, "tree", "");
387 blob_appendf(&title, " from check-in %z%S</a>", zLink, zUuid);
388 fossil_free(zUuid);
389 }else{
390 blob_appendf(&title, "History of files named ");
391 hyperlinked_path(zFilename, &title, 0, "tree", "");
392 }
393
+1 -1
--- src/info.c
+++ src/info.c
@@ -531,11 +531,11 @@
531531
timeline_utc(), timeline_utc(), rid, rid
532532
);
533533
sideBySide = !is_false(PD("sbs","1"));
534534
if( db_step(&q1)==SQLITE_ROW ){
535535
const char *zUuid = db_column_text(&q1, 0);
536
- char *zTitle = mprintf("Check-in [%.10s]", zUuid);
536
+ char *zTitle = mprintf("Check-in [%S]", zUuid);
537537
char *zEUser, *zEComment;
538538
const char *zUser;
539539
const char *zComment;
540540
const char *zDate;
541541
const char *zOrigDate;
542542
--- src/info.c
+++ src/info.c
@@ -531,11 +531,11 @@
531 timeline_utc(), timeline_utc(), rid, rid
532 );
533 sideBySide = !is_false(PD("sbs","1"));
534 if( db_step(&q1)==SQLITE_ROW ){
535 const char *zUuid = db_column_text(&q1, 0);
536 char *zTitle = mprintf("Check-in [%.10s]", zUuid);
537 char *zEUser, *zEComment;
538 const char *zUser;
539 const char *zComment;
540 const char *zDate;
541 const char *zOrigDate;
542
--- src/info.c
+++ src/info.c
@@ -531,11 +531,11 @@
531 timeline_utc(), timeline_utc(), rid, rid
532 );
533 sideBySide = !is_false(PD("sbs","1"));
534 if( db_step(&q1)==SQLITE_ROW ){
535 const char *zUuid = db_column_text(&q1, 0);
536 char *zTitle = mprintf("Check-in [%S]", zUuid);
537 char *zEUser, *zEComment;
538 const char *zUser;
539 const char *zComment;
540 const char *zDate;
541 const char *zOrigDate;
542
+1 -1
--- src/manifest.c
+++ src/manifest.c
@@ -1983,11 +1983,11 @@
19831983
for(i=0; i<p->nTag; i++){
19841984
zTagUuid = p->aTag[i].zUuid;
19851985
if( !zTagUuid ) continue;
19861986
if( i==0 || fossil_strcmp(zTagUuid, p->aTag[i-1].zUuid)!=0 ){
19871987
blob_appendf(&comment,
1988
- " Edit [%s|%.10s]:",
1988
+ " Edit [%s|%S]:",
19891989
zTagUuid, zTagUuid);
19901990
branchMove = 0;
19911991
if( permitHooks && db_exists("SELECT 1 FROM event, blob"
19921992
" WHERE event.type='ci' AND event.objid=blob.rid"
19931993
" AND blob.uuid='%s'", zTagUuid) ){
19941994
--- src/manifest.c
+++ src/manifest.c
@@ -1983,11 +1983,11 @@
1983 for(i=0; i<p->nTag; i++){
1984 zTagUuid = p->aTag[i].zUuid;
1985 if( !zTagUuid ) continue;
1986 if( i==0 || fossil_strcmp(zTagUuid, p->aTag[i-1].zUuid)!=0 ){
1987 blob_appendf(&comment,
1988 " Edit [%s|%.10s]:",
1989 zTagUuid, zTagUuid);
1990 branchMove = 0;
1991 if( permitHooks && db_exists("SELECT 1 FROM event, blob"
1992 " WHERE event.type='ci' AND event.objid=blob.rid"
1993 " AND blob.uuid='%s'", zTagUuid) ){
1994
--- src/manifest.c
+++ src/manifest.c
@@ -1983,11 +1983,11 @@
1983 for(i=0; i<p->nTag; i++){
1984 zTagUuid = p->aTag[i].zUuid;
1985 if( !zTagUuid ) continue;
1986 if( i==0 || fossil_strcmp(zTagUuid, p->aTag[i-1].zUuid)!=0 ){
1987 blob_appendf(&comment,
1988 " Edit [%s|%S]:",
1989 zTagUuid, zTagUuid);
1990 branchMove = 0;
1991 if( permitHooks && db_exists("SELECT 1 FROM event, blob"
1992 " WHERE event.type='ci' AND event.objid=blob.rid"
1993 " AND blob.uuid='%s'", zTagUuid) ){
1994
+1 -1
--- src/manifest.c
+++ src/manifest.c
@@ -1983,11 +1983,11 @@
19831983
for(i=0; i<p->nTag; i++){
19841984
zTagUuid = p->aTag[i].zUuid;
19851985
if( !zTagUuid ) continue;
19861986
if( i==0 || fossil_strcmp(zTagUuid, p->aTag[i-1].zUuid)!=0 ){
19871987
blob_appendf(&comment,
1988
- " Edit [%s|%.10s]:",
1988
+ " Edit [%s|%S]:",
19891989
zTagUuid, zTagUuid);
19901990
branchMove = 0;
19911991
if( permitHooks && db_exists("SELECT 1 FROM event, blob"
19921992
" WHERE event.type='ci' AND event.objid=blob.rid"
19931993
" AND blob.uuid='%s'", zTagUuid) ){
19941994
--- src/manifest.c
+++ src/manifest.c
@@ -1983,11 +1983,11 @@
1983 for(i=0; i<p->nTag; i++){
1984 zTagUuid = p->aTag[i].zUuid;
1985 if( !zTagUuid ) continue;
1986 if( i==0 || fossil_strcmp(zTagUuid, p->aTag[i-1].zUuid)!=0 ){
1987 blob_appendf(&comment,
1988 " Edit [%s|%.10s]:",
1989 zTagUuid, zTagUuid);
1990 branchMove = 0;
1991 if( permitHooks && db_exists("SELECT 1 FROM event, blob"
1992 " WHERE event.type='ci' AND event.objid=blob.rid"
1993 " AND blob.uuid='%s'", zTagUuid) ){
1994
--- src/manifest.c
+++ src/manifest.c
@@ -1983,11 +1983,11 @@
1983 for(i=0; i<p->nTag; i++){
1984 zTagUuid = p->aTag[i].zUuid;
1985 if( !zTagUuid ) continue;
1986 if( i==0 || fossil_strcmp(zTagUuid, p->aTag[i-1].zUuid)!=0 ){
1987 blob_appendf(&comment,
1988 " Edit [%s|%S]:",
1989 zTagUuid, zTagUuid);
1990 branchMove = 0;
1991 if( permitHooks && db_exists("SELECT 1 FROM event, blob"
1992 " WHERE event.type='ci' AND event.objid=blob.rid"
1993 " AND blob.uuid='%s'", zTagUuid) ){
1994
+3 -3
--- src/name.c
+++ src/name.c
@@ -444,11 +444,11 @@
444444
" WHERE ticket.tkt_id = ticketchng.tkt_id"
445445
" AND tkt_uuid GLOB '%q*'"
446446
" GROUP BY tkt_uuid"
447447
" ORDER BY tkt_ctime DESC", z);
448448
while( db_step(&q)==SQLITE_ROW ){
449
- int rid = db_column_int(&q, 0);
449
+ int rid = db_column_int(&q, 0);
450450
const char *zUuid = db_column_text(&q, 1);
451451
const char *zTitle = db_column_text(&q, 2);
452452
@ <li><p><a href="%s(g.zTop)/%T(zSrc)/%s(zUuid)">
453453
@ %s(zUuid)</a> -
454454
@ <ul></ul>
@@ -465,11 +465,11 @@
465465
"SELECT rid, uuid FROM"
466466
" (SELECT tagxref.rid AS rid, substr(tagname, 7) AS uuid"
467467
" FROM tagxref, tag WHERE tagxref.tagid = tag.tagid"
468468
" AND tagname GLOB 'event-%q*') GROUP BY uuid", z);
469469
while( db_step(&q)==SQLITE_ROW ){
470
- int rid = db_column_int(&q, 0);
470
+ int rid = db_column_int(&q, 0);
471471
const char* zUuid = db_column_text(&q, 1);
472472
@ <li><p><a href="%s(g.zTop)/%T(zSrc)/%s(zUuid)">
473473
@ %s(zUuid)</a> -
474474
@ <ul><li>
475475
object_description(rid, 0, 0);
@@ -599,11 +599,11 @@
599599
" AND blob.rid=mlink.mid"
600600
" ORDER BY event.mtime DESC /*sort*/",
601601
timeline_utc(), rid);
602602
while( db_step(&q)==SQLITE_ROW ){
603603
fossil_print("file: %s\n", db_column_text(&q,0));
604
- fossil_print(" part of [%.10s] by %s on %s\n",
604
+ fossil_print(" part of [%S] by %s on %s\n",
605605
db_column_text(&q, 1),
606606
db_column_text(&q, 3),
607607
db_column_text(&q, 2));
608608
fossil_print(" ");
609609
comment_print(db_column_text(&q,4), 12, -1);
610610
--- src/name.c
+++ src/name.c
@@ -444,11 +444,11 @@
444 " WHERE ticket.tkt_id = ticketchng.tkt_id"
445 " AND tkt_uuid GLOB '%q*'"
446 " GROUP BY tkt_uuid"
447 " ORDER BY tkt_ctime DESC", z);
448 while( db_step(&q)==SQLITE_ROW ){
449 int rid = db_column_int(&q, 0);
450 const char *zUuid = db_column_text(&q, 1);
451 const char *zTitle = db_column_text(&q, 2);
452 @ <li><p><a href="%s(g.zTop)/%T(zSrc)/%s(zUuid)">
453 @ %s(zUuid)</a> -
454 @ <ul></ul>
@@ -465,11 +465,11 @@
465 "SELECT rid, uuid FROM"
466 " (SELECT tagxref.rid AS rid, substr(tagname, 7) AS uuid"
467 " FROM tagxref, tag WHERE tagxref.tagid = tag.tagid"
468 " AND tagname GLOB 'event-%q*') GROUP BY uuid", z);
469 while( db_step(&q)==SQLITE_ROW ){
470 int rid = db_column_int(&q, 0);
471 const char* zUuid = db_column_text(&q, 1);
472 @ <li><p><a href="%s(g.zTop)/%T(zSrc)/%s(zUuid)">
473 @ %s(zUuid)</a> -
474 @ <ul><li>
475 object_description(rid, 0, 0);
@@ -599,11 +599,11 @@
599 " AND blob.rid=mlink.mid"
600 " ORDER BY event.mtime DESC /*sort*/",
601 timeline_utc(), rid);
602 while( db_step(&q)==SQLITE_ROW ){
603 fossil_print("file: %s\n", db_column_text(&q,0));
604 fossil_print(" part of [%.10s] by %s on %s\n",
605 db_column_text(&q, 1),
606 db_column_text(&q, 3),
607 db_column_text(&q, 2));
608 fossil_print(" ");
609 comment_print(db_column_text(&q,4), 12, -1);
610
--- src/name.c
+++ src/name.c
@@ -444,11 +444,11 @@
444 " WHERE ticket.tkt_id = ticketchng.tkt_id"
445 " AND tkt_uuid GLOB '%q*'"
446 " GROUP BY tkt_uuid"
447 " ORDER BY tkt_ctime DESC", z);
448 while( db_step(&q)==SQLITE_ROW ){
449 int rid = db_column_int(&q, 0);
450 const char *zUuid = db_column_text(&q, 1);
451 const char *zTitle = db_column_text(&q, 2);
452 @ <li><p><a href="%s(g.zTop)/%T(zSrc)/%s(zUuid)">
453 @ %s(zUuid)</a> -
454 @ <ul></ul>
@@ -465,11 +465,11 @@
465 "SELECT rid, uuid FROM"
466 " (SELECT tagxref.rid AS rid, substr(tagname, 7) AS uuid"
467 " FROM tagxref, tag WHERE tagxref.tagid = tag.tagid"
468 " AND tagname GLOB 'event-%q*') GROUP BY uuid", z);
469 while( db_step(&q)==SQLITE_ROW ){
470 int rid = db_column_int(&q, 0);
471 const char* zUuid = db_column_text(&q, 1);
472 @ <li><p><a href="%s(g.zTop)/%T(zSrc)/%s(zUuid)">
473 @ %s(zUuid)</a> -
474 @ <ul><li>
475 object_description(rid, 0, 0);
@@ -599,11 +599,11 @@
599 " AND blob.rid=mlink.mid"
600 " ORDER BY event.mtime DESC /*sort*/",
601 timeline_utc(), rid);
602 while( db_step(&q)==SQLITE_ROW ){
603 fossil_print("file: %s\n", db_column_text(&q,0));
604 fossil_print(" part of [%S] by %s on %s\n",
605 db_column_text(&q, 1),
606 db_column_text(&q, 3),
607 db_column_text(&q, 2));
608 fossil_print(" ");
609 comment_print(db_column_text(&q,4), 12, -1);
610
+8 -4
--- src/printf.c
+++ src/printf.c
@@ -608,22 +608,26 @@
608608
case etROOT: {
609609
bufpt = g.zTop ? g.zTop : "";
610610
length = (int)strlen(bufpt);
611611
break;
612612
}
613
- case etSTRINGID: {
614
- precision = 16;
615
- /* Fall through */
616
- }
613
+ case etSTRINGID:
617614
case etSTRING:
618615
case etDYNSTRING: {
619616
int limit = flag_alternateform ? va_arg(ap,int) : -1;
620617
bufpt = va_arg(ap,char*);
621618
if( bufpt==0 ){
622619
bufpt = "";
623620
}else if( xtype==etDYNSTRING ){
624621
zExtra = bufpt;
622
+ }else if( xtype==etSTRINGID ){
623
+ precision = 0;
624
+ while( bufpt[precision]>='0' && bufpt[precision]<='9' ){
625
+ precision++;
626
+ }
627
+ if( bufpt[precision]!=0 ) precision++;
628
+ if( precision<10 ) precision=10;
625629
}
626630
length = StrNLen32(bufpt, limit);
627631
if( precision>=0 && precision<length ) length = precision;
628632
break;
629633
}
630634
--- src/printf.c
+++ src/printf.c
@@ -608,22 +608,26 @@
608 case etROOT: {
609 bufpt = g.zTop ? g.zTop : "";
610 length = (int)strlen(bufpt);
611 break;
612 }
613 case etSTRINGID: {
614 precision = 16;
615 /* Fall through */
616 }
617 case etSTRING:
618 case etDYNSTRING: {
619 int limit = flag_alternateform ? va_arg(ap,int) : -1;
620 bufpt = va_arg(ap,char*);
621 if( bufpt==0 ){
622 bufpt = "";
623 }else if( xtype==etDYNSTRING ){
624 zExtra = bufpt;
 
 
 
 
 
 
 
625 }
626 length = StrNLen32(bufpt, limit);
627 if( precision>=0 && precision<length ) length = precision;
628 break;
629 }
630
--- src/printf.c
+++ src/printf.c
@@ -608,22 +608,26 @@
608 case etROOT: {
609 bufpt = g.zTop ? g.zTop : "";
610 length = (int)strlen(bufpt);
611 break;
612 }
613 case etSTRINGID:
 
 
 
614 case etSTRING:
615 case etDYNSTRING: {
616 int limit = flag_alternateform ? va_arg(ap,int) : -1;
617 bufpt = va_arg(ap,char*);
618 if( bufpt==0 ){
619 bufpt = "";
620 }else if( xtype==etDYNSTRING ){
621 zExtra = bufpt;
622 }else if( xtype==etSTRINGID ){
623 precision = 0;
624 while( bufpt[precision]>='0' && bufpt[precision]<='9' ){
625 precision++;
626 }
627 if( bufpt[precision]!=0 ) precision++;
628 if( precision<10 ) precision=10;
629 }
630 length = StrNLen32(bufpt, limit);
631 if( precision>=0 && precision<length ) length = precision;
632 break;
633 }
634
+6 -30
--- src/timeline.c
+++ src/timeline.c
@@ -20,41 +20,19 @@
2020
*/
2121
#include "config.h"
2222
#include <string.h>
2323
#include <time.h>
2424
#include "timeline.h"
25
-
26
-/*
27
-** Shorten a UUID so that is the minimum length needed to contain
28
-** at least one digit in the range 'a'..'f'. The minimum length is 10.
29
-*/
30
-static void shorten_uuid(char *zDest, const char *zSrc){
31
- int i;
32
- for(i=0; i<10 && zSrc[i]<='9'; i++){}
33
- memcpy(zDest, zSrc, 10);
34
- if( i==10 && zSrc[i] ){
35
- do{
36
- zDest[i] = zSrc[i];
37
- i++;
38
- }while( zSrc[i-1]<='9' );
39
- }else{
40
- i = 10;
41
- }
42
- zDest[i] = 0;
43
-}
44
-
4525
4626
/*
4727
** Generate a hyperlink to a version.
4828
*/
4929
void hyperlink_to_uuid(const char *zUuid){
50
- char z[UUID_SIZE+1];
51
- shorten_uuid(z, zUuid);
5230
if( g.perm.Hyperlink ){
53
- @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%s(z)]</a>
31
+ @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%S(zUuid)]</a>
5432
}else{
55
- @ <span class="timelineHistDsp">[%s(z)]</span>
33
+ @ <span class="timelineHistDsp">[%S(zUuid)]</span>
5634
}
5735
}
5836
5937
/*
6038
** Generate a hyperlink to a date & time.
@@ -1220,11 +1198,11 @@
12201198
blob_appendf(&desc, "%d ancestors", np);
12211199
db_multi_exec("%s", blob_str(&sql));
12221200
}
12231201
if( d_rid==0 && useDividers ) timeline_add_dividers(0, p_rid);
12241202
}
1225
- blob_appendf(&desc, " of %z[%.10s]</a>",
1203
+ blob_appendf(&desc, " of %z[%S]</a>",
12261204
href("%R/info/%s", zUuid), zUuid);
12271205
if( p_rid ){
12281206
url_add_parameter(&url, "p", zUuid);
12291207
}
12301208
if( d_rid ){
@@ -1261,11 +1239,11 @@
12611239
blob_appendf(&sql, " AND event.objid IN ok");
12621240
db_multi_exec("%s", blob_str(&sql));
12631241
if( useDividers ) timeline_add_dividers(0, f_rid);
12641242
blob_appendf(&desc, "Parents and children of check-in ");
12651243
zUuid = db_text("", "SELECT uuid FROM blob WHERE rid=%d", f_rid);
1266
- blob_appendf(&desc, "%z[%.10s]</a>", href("%R/info/%s", zUuid), zUuid);
1244
+ blob_appendf(&desc, "%z[%S]</a>", href("%R/info/%s", zUuid), zUuid);
12671245
tmFlags |= TIMELINE_DISJOINT;
12681246
url_add_parameter(&url, "f", zUuid);
12691247
if( tmFlags & TIMELINE_FCHANGES ){
12701248
timeline_submenu(&url, "Hide Files", "v", 0, 0);
12711249
}else{
@@ -1587,11 +1565,10 @@
15871565
int nChild = db_column_int(q, 4);
15881566
int nParent = db_column_int(q, 5);
15891567
char *zFree = 0;
15901568
int n = 0;
15911569
char zPrefix[80];
1592
- char zUuid[UUID_SIZE+1];
15931570
15941571
if( nAbsLimit!=0 ){
15951572
if( nLimit<0 && nLine>=nAbsLimit ){
15961573
fossil_print("--- line limit (%d) reached ---\n", nAbsLimit);
15971574
break; /* line count limit hit, stop. */
@@ -1598,11 +1575,10 @@
15981575
}else if( nEntry>=nAbsLimit ){
15991576
fossil_print("--- entry limit (%d) reached ---\n", nAbsLimit);
16001577
break; /* entry count limit hit, stop. */
16011578
}
16021579
}
1603
- sqlite3_snprintf(sizeof(zUuid), zUuid, "%.10s", zId);
16041580
if( fossil_strnicmp(zDate, zPrevDate, 10) ){
16051581
fossil_print("=== %.10s ===\n", zDate);
16061582
memcpy(zPrevDate, zDate, 10);
16071583
nLine++; /* record another line */
16081584
}
@@ -1625,13 +1601,13 @@
16251601
}
16261602
if( fossil_strcmp(zCurrentUuid,zId)==0 ){
16271603
sqlite3_snprintf(sizeof(zPrefix)-n, &zPrefix[n], "*CURRENT* ");
16281604
n += strlen(zPrefix);
16291605
}
1630
- zFree = sqlite3_mprintf("[%.10s] %s%s", zUuid, zPrefix, zCom);
1606
+ zFree = mprintf("[%S] %s%s", zId, zPrefix, zCom);
16311607
nLine += comment_print(zFree, 9, width); /* record another X lines */
1632
- sqlite3_free(zFree);
1608
+ fossil_free(zFree);
16331609
16341610
if(verboseFlag){
16351611
if( !fchngQueryInit ){
16361612
db_prepare(&fchngQuery,
16371613
"SELECT (pid==0) AS isnew,"
16381614
--- src/timeline.c
+++ src/timeline.c
@@ -20,41 +20,19 @@
20 */
21 #include "config.h"
22 #include <string.h>
23 #include <time.h>
24 #include "timeline.h"
25
26 /*
27 ** Shorten a UUID so that is the minimum length needed to contain
28 ** at least one digit in the range 'a'..'f'. The minimum length is 10.
29 */
30 static void shorten_uuid(char *zDest, const char *zSrc){
31 int i;
32 for(i=0; i<10 && zSrc[i]<='9'; i++){}
33 memcpy(zDest, zSrc, 10);
34 if( i==10 && zSrc[i] ){
35 do{
36 zDest[i] = zSrc[i];
37 i++;
38 }while( zSrc[i-1]<='9' );
39 }else{
40 i = 10;
41 }
42 zDest[i] = 0;
43 }
44
45
46 /*
47 ** Generate a hyperlink to a version.
48 */
49 void hyperlink_to_uuid(const char *zUuid){
50 char z[UUID_SIZE+1];
51 shorten_uuid(z, zUuid);
52 if( g.perm.Hyperlink ){
53 @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%s(z)]</a>
54 }else{
55 @ <span class="timelineHistDsp">[%s(z)]</span>
56 }
57 }
58
59 /*
60 ** Generate a hyperlink to a date & time.
@@ -1220,11 +1198,11 @@
1220 blob_appendf(&desc, "%d ancestors", np);
1221 db_multi_exec("%s", blob_str(&sql));
1222 }
1223 if( d_rid==0 && useDividers ) timeline_add_dividers(0, p_rid);
1224 }
1225 blob_appendf(&desc, " of %z[%.10s]</a>",
1226 href("%R/info/%s", zUuid), zUuid);
1227 if( p_rid ){
1228 url_add_parameter(&url, "p", zUuid);
1229 }
1230 if( d_rid ){
@@ -1261,11 +1239,11 @@
1261 blob_appendf(&sql, " AND event.objid IN ok");
1262 db_multi_exec("%s", blob_str(&sql));
1263 if( useDividers ) timeline_add_dividers(0, f_rid);
1264 blob_appendf(&desc, "Parents and children of check-in ");
1265 zUuid = db_text("", "SELECT uuid FROM blob WHERE rid=%d", f_rid);
1266 blob_appendf(&desc, "%z[%.10s]</a>", href("%R/info/%s", zUuid), zUuid);
1267 tmFlags |= TIMELINE_DISJOINT;
1268 url_add_parameter(&url, "f", zUuid);
1269 if( tmFlags & TIMELINE_FCHANGES ){
1270 timeline_submenu(&url, "Hide Files", "v", 0, 0);
1271 }else{
@@ -1587,11 +1565,10 @@
1587 int nChild = db_column_int(q, 4);
1588 int nParent = db_column_int(q, 5);
1589 char *zFree = 0;
1590 int n = 0;
1591 char zPrefix[80];
1592 char zUuid[UUID_SIZE+1];
1593
1594 if( nAbsLimit!=0 ){
1595 if( nLimit<0 && nLine>=nAbsLimit ){
1596 fossil_print("--- line limit (%d) reached ---\n", nAbsLimit);
1597 break; /* line count limit hit, stop. */
@@ -1598,11 +1575,10 @@
1598 }else if( nEntry>=nAbsLimit ){
1599 fossil_print("--- entry limit (%d) reached ---\n", nAbsLimit);
1600 break; /* entry count limit hit, stop. */
1601 }
1602 }
1603 sqlite3_snprintf(sizeof(zUuid), zUuid, "%.10s", zId);
1604 if( fossil_strnicmp(zDate, zPrevDate, 10) ){
1605 fossil_print("=== %.10s ===\n", zDate);
1606 memcpy(zPrevDate, zDate, 10);
1607 nLine++; /* record another line */
1608 }
@@ -1625,13 +1601,13 @@
1625 }
1626 if( fossil_strcmp(zCurrentUuid,zId)==0 ){
1627 sqlite3_snprintf(sizeof(zPrefix)-n, &zPrefix[n], "*CURRENT* ");
1628 n += strlen(zPrefix);
1629 }
1630 zFree = sqlite3_mprintf("[%.10s] %s%s", zUuid, zPrefix, zCom);
1631 nLine += comment_print(zFree, 9, width); /* record another X lines */
1632 sqlite3_free(zFree);
1633
1634 if(verboseFlag){
1635 if( !fchngQueryInit ){
1636 db_prepare(&fchngQuery,
1637 "SELECT (pid==0) AS isnew,"
1638
--- src/timeline.c
+++ src/timeline.c
@@ -20,41 +20,19 @@
20 */
21 #include "config.h"
22 #include <string.h>
23 #include <time.h>
24 #include "timeline.h"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
25
26 /*
27 ** Generate a hyperlink to a version.
28 */
29 void hyperlink_to_uuid(const char *zUuid){
 
 
30 if( g.perm.Hyperlink ){
31 @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%S(zUuid)]</a>
32 }else{
33 @ <span class="timelineHistDsp">[%S(zUuid)]</span>
34 }
35 }
36
37 /*
38 ** Generate a hyperlink to a date & time.
@@ -1220,11 +1198,11 @@
1198 blob_appendf(&desc, "%d ancestors", np);
1199 db_multi_exec("%s", blob_str(&sql));
1200 }
1201 if( d_rid==0 && useDividers ) timeline_add_dividers(0, p_rid);
1202 }
1203 blob_appendf(&desc, " of %z[%S]</a>",
1204 href("%R/info/%s", zUuid), zUuid);
1205 if( p_rid ){
1206 url_add_parameter(&url, "p", zUuid);
1207 }
1208 if( d_rid ){
@@ -1261,11 +1239,11 @@
1239 blob_appendf(&sql, " AND event.objid IN ok");
1240 db_multi_exec("%s", blob_str(&sql));
1241 if( useDividers ) timeline_add_dividers(0, f_rid);
1242 blob_appendf(&desc, "Parents and children of check-in ");
1243 zUuid = db_text("", "SELECT uuid FROM blob WHERE rid=%d", f_rid);
1244 blob_appendf(&desc, "%z[%S]</a>", href("%R/info/%s", zUuid), zUuid);
1245 tmFlags |= TIMELINE_DISJOINT;
1246 url_add_parameter(&url, "f", zUuid);
1247 if( tmFlags & TIMELINE_FCHANGES ){
1248 timeline_submenu(&url, "Hide Files", "v", 0, 0);
1249 }else{
@@ -1587,11 +1565,10 @@
1565 int nChild = db_column_int(q, 4);
1566 int nParent = db_column_int(q, 5);
1567 char *zFree = 0;
1568 int n = 0;
1569 char zPrefix[80];
 
1570
1571 if( nAbsLimit!=0 ){
1572 if( nLimit<0 && nLine>=nAbsLimit ){
1573 fossil_print("--- line limit (%d) reached ---\n", nAbsLimit);
1574 break; /* line count limit hit, stop. */
@@ -1598,11 +1575,10 @@
1575 }else if( nEntry>=nAbsLimit ){
1576 fossil_print("--- entry limit (%d) reached ---\n", nAbsLimit);
1577 break; /* entry count limit hit, stop. */
1578 }
1579 }
 
1580 if( fossil_strnicmp(zDate, zPrevDate, 10) ){
1581 fossil_print("=== %.10s ===\n", zDate);
1582 memcpy(zPrevDate, zDate, 10);
1583 nLine++; /* record another line */
1584 }
@@ -1625,13 +1601,13 @@
1601 }
1602 if( fossil_strcmp(zCurrentUuid,zId)==0 ){
1603 sqlite3_snprintf(sizeof(zPrefix)-n, &zPrefix[n], "*CURRENT* ");
1604 n += strlen(zPrefix);
1605 }
1606 zFree = mprintf("[%S] %s%s", zId, zPrefix, zCom);
1607 nLine += comment_print(zFree, 9, width); /* record another X lines */
1608 fossil_free(zFree);
1609
1610 if(verboseFlag){
1611 if( !fchngQueryInit ){
1612 db_prepare(&fchngQuery,
1613 "SELECT (pid==0) AS isnew,"
1614
+6 -30
--- src/timeline.c
+++ src/timeline.c
@@ -20,41 +20,19 @@
2020
*/
2121
#include "config.h"
2222
#include <string.h>
2323
#include <time.h>
2424
#include "timeline.h"
25
-
26
-/*
27
-** Shorten a UUID so that is the minimum length needed to contain
28
-** at least one digit in the range 'a'..'f'. The minimum length is 10.
29
-*/
30
-static void shorten_uuid(char *zDest, const char *zSrc){
31
- int i;
32
- for(i=0; i<10 && zSrc[i]<='9'; i++){}
33
- memcpy(zDest, zSrc, 10);
34
- if( i==10 && zSrc[i] ){
35
- do{
36
- zDest[i] = zSrc[i];
37
- i++;
38
- }while( zSrc[i-1]<='9' );
39
- }else{
40
- i = 10;
41
- }
42
- zDest[i] = 0;
43
-}
44
-
4525
4626
/*
4727
** Generate a hyperlink to a version.
4828
*/
4929
void hyperlink_to_uuid(const char *zUuid){
50
- char z[UUID_SIZE+1];
51
- shorten_uuid(z, zUuid);
5230
if( g.perm.Hyperlink ){
53
- @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%s(z)]</a>
31
+ @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%S(zUuid)]</a>
5432
}else{
55
- @ <span class="timelineHistDsp">[%s(z)]</span>
33
+ @ <span class="timelineHistDsp">[%S(zUuid)]</span>
5634
}
5735
}
5836
5937
/*
6038
** Generate a hyperlink to a date & time.
@@ -1220,11 +1198,11 @@
12201198
blob_appendf(&desc, "%d ancestors", np);
12211199
db_multi_exec("%s", blob_str(&sql));
12221200
}
12231201
if( d_rid==0 && useDividers ) timeline_add_dividers(0, p_rid);
12241202
}
1225
- blob_appendf(&desc, " of %z[%.10s]</a>",
1203
+ blob_appendf(&desc, " of %z[%S]</a>",
12261204
href("%R/info/%s", zUuid), zUuid);
12271205
if( p_rid ){
12281206
url_add_parameter(&url, "p", zUuid);
12291207
}
12301208
if( d_rid ){
@@ -1261,11 +1239,11 @@
12611239
blob_appendf(&sql, " AND event.objid IN ok");
12621240
db_multi_exec("%s", blob_str(&sql));
12631241
if( useDividers ) timeline_add_dividers(0, f_rid);
12641242
blob_appendf(&desc, "Parents and children of check-in ");
12651243
zUuid = db_text("", "SELECT uuid FROM blob WHERE rid=%d", f_rid);
1266
- blob_appendf(&desc, "%z[%.10s]</a>", href("%R/info/%s", zUuid), zUuid);
1244
+ blob_appendf(&desc, "%z[%S]</a>", href("%R/info/%s", zUuid), zUuid);
12671245
tmFlags |= TIMELINE_DISJOINT;
12681246
url_add_parameter(&url, "f", zUuid);
12691247
if( tmFlags & TIMELINE_FCHANGES ){
12701248
timeline_submenu(&url, "Hide Files", "v", 0, 0);
12711249
}else{
@@ -1587,11 +1565,10 @@
15871565
int nChild = db_column_int(q, 4);
15881566
int nParent = db_column_int(q, 5);
15891567
char *zFree = 0;
15901568
int n = 0;
15911569
char zPrefix[80];
1592
- char zUuid[UUID_SIZE+1];
15931570
15941571
if( nAbsLimit!=0 ){
15951572
if( nLimit<0 && nLine>=nAbsLimit ){
15961573
fossil_print("--- line limit (%d) reached ---\n", nAbsLimit);
15971574
break; /* line count limit hit, stop. */
@@ -1598,11 +1575,10 @@
15981575
}else if( nEntry>=nAbsLimit ){
15991576
fossil_print("--- entry limit (%d) reached ---\n", nAbsLimit);
16001577
break; /* entry count limit hit, stop. */
16011578
}
16021579
}
1603
- sqlite3_snprintf(sizeof(zUuid), zUuid, "%.10s", zId);
16041580
if( fossil_strnicmp(zDate, zPrevDate, 10) ){
16051581
fossil_print("=== %.10s ===\n", zDate);
16061582
memcpy(zPrevDate, zDate, 10);
16071583
nLine++; /* record another line */
16081584
}
@@ -1625,13 +1601,13 @@
16251601
}
16261602
if( fossil_strcmp(zCurrentUuid,zId)==0 ){
16271603
sqlite3_snprintf(sizeof(zPrefix)-n, &zPrefix[n], "*CURRENT* ");
16281604
n += strlen(zPrefix);
16291605
}
1630
- zFree = sqlite3_mprintf("[%.10s] %s%s", zUuid, zPrefix, zCom);
1606
+ zFree = mprintf("[%S] %s%s", zId, zPrefix, zCom);
16311607
nLine += comment_print(zFree, 9, width); /* record another X lines */
1632
- sqlite3_free(zFree);
1608
+ fossil_free(zFree);
16331609
16341610
if(verboseFlag){
16351611
if( !fchngQueryInit ){
16361612
db_prepare(&fchngQuery,
16371613
"SELECT (pid==0) AS isnew,"
16381614
--- src/timeline.c
+++ src/timeline.c
@@ -20,41 +20,19 @@
20 */
21 #include "config.h"
22 #include <string.h>
23 #include <time.h>
24 #include "timeline.h"
25
26 /*
27 ** Shorten a UUID so that is the minimum length needed to contain
28 ** at least one digit in the range 'a'..'f'. The minimum length is 10.
29 */
30 static void shorten_uuid(char *zDest, const char *zSrc){
31 int i;
32 for(i=0; i<10 && zSrc[i]<='9'; i++){}
33 memcpy(zDest, zSrc, 10);
34 if( i==10 && zSrc[i] ){
35 do{
36 zDest[i] = zSrc[i];
37 i++;
38 }while( zSrc[i-1]<='9' );
39 }else{
40 i = 10;
41 }
42 zDest[i] = 0;
43 }
44
45
46 /*
47 ** Generate a hyperlink to a version.
48 */
49 void hyperlink_to_uuid(const char *zUuid){
50 char z[UUID_SIZE+1];
51 shorten_uuid(z, zUuid);
52 if( g.perm.Hyperlink ){
53 @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%s(z)]</a>
54 }else{
55 @ <span class="timelineHistDsp">[%s(z)]</span>
56 }
57 }
58
59 /*
60 ** Generate a hyperlink to a date & time.
@@ -1220,11 +1198,11 @@
1220 blob_appendf(&desc, "%d ancestors", np);
1221 db_multi_exec("%s", blob_str(&sql));
1222 }
1223 if( d_rid==0 && useDividers ) timeline_add_dividers(0, p_rid);
1224 }
1225 blob_appendf(&desc, " of %z[%.10s]</a>",
1226 href("%R/info/%s", zUuid), zUuid);
1227 if( p_rid ){
1228 url_add_parameter(&url, "p", zUuid);
1229 }
1230 if( d_rid ){
@@ -1261,11 +1239,11 @@
1261 blob_appendf(&sql, " AND event.objid IN ok");
1262 db_multi_exec("%s", blob_str(&sql));
1263 if( useDividers ) timeline_add_dividers(0, f_rid);
1264 blob_appendf(&desc, "Parents and children of check-in ");
1265 zUuid = db_text("", "SELECT uuid FROM blob WHERE rid=%d", f_rid);
1266 blob_appendf(&desc, "%z[%.10s]</a>", href("%R/info/%s", zUuid), zUuid);
1267 tmFlags |= TIMELINE_DISJOINT;
1268 url_add_parameter(&url, "f", zUuid);
1269 if( tmFlags & TIMELINE_FCHANGES ){
1270 timeline_submenu(&url, "Hide Files", "v", 0, 0);
1271 }else{
@@ -1587,11 +1565,10 @@
1587 int nChild = db_column_int(q, 4);
1588 int nParent = db_column_int(q, 5);
1589 char *zFree = 0;
1590 int n = 0;
1591 char zPrefix[80];
1592 char zUuid[UUID_SIZE+1];
1593
1594 if( nAbsLimit!=0 ){
1595 if( nLimit<0 && nLine>=nAbsLimit ){
1596 fossil_print("--- line limit (%d) reached ---\n", nAbsLimit);
1597 break; /* line count limit hit, stop. */
@@ -1598,11 +1575,10 @@
1598 }else if( nEntry>=nAbsLimit ){
1599 fossil_print("--- entry limit (%d) reached ---\n", nAbsLimit);
1600 break; /* entry count limit hit, stop. */
1601 }
1602 }
1603 sqlite3_snprintf(sizeof(zUuid), zUuid, "%.10s", zId);
1604 if( fossil_strnicmp(zDate, zPrevDate, 10) ){
1605 fossil_print("=== %.10s ===\n", zDate);
1606 memcpy(zPrevDate, zDate, 10);
1607 nLine++; /* record another line */
1608 }
@@ -1625,13 +1601,13 @@
1625 }
1626 if( fossil_strcmp(zCurrentUuid,zId)==0 ){
1627 sqlite3_snprintf(sizeof(zPrefix)-n, &zPrefix[n], "*CURRENT* ");
1628 n += strlen(zPrefix);
1629 }
1630 zFree = sqlite3_mprintf("[%.10s] %s%s", zUuid, zPrefix, zCom);
1631 nLine += comment_print(zFree, 9, width); /* record another X lines */
1632 sqlite3_free(zFree);
1633
1634 if(verboseFlag){
1635 if( !fchngQueryInit ){
1636 db_prepare(&fchngQuery,
1637 "SELECT (pid==0) AS isnew,"
1638
--- src/timeline.c
+++ src/timeline.c
@@ -20,41 +20,19 @@
20 */
21 #include "config.h"
22 #include <string.h>
23 #include <time.h>
24 #include "timeline.h"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
25
26 /*
27 ** Generate a hyperlink to a version.
28 */
29 void hyperlink_to_uuid(const char *zUuid){
 
 
30 if( g.perm.Hyperlink ){
31 @ %z(xhref("class='timelineHistLink'","%R/info/%s",zUuid))[%S(zUuid)]</a>
32 }else{
33 @ <span class="timelineHistDsp">[%S(zUuid)]</span>
34 }
35 }
36
37 /*
38 ** Generate a hyperlink to a date & time.
@@ -1220,11 +1198,11 @@
1198 blob_appendf(&desc, "%d ancestors", np);
1199 db_multi_exec("%s", blob_str(&sql));
1200 }
1201 if( d_rid==0 && useDividers ) timeline_add_dividers(0, p_rid);
1202 }
1203 blob_appendf(&desc, " of %z[%S]</a>",
1204 href("%R/info/%s", zUuid), zUuid);
1205 if( p_rid ){
1206 url_add_parameter(&url, "p", zUuid);
1207 }
1208 if( d_rid ){
@@ -1261,11 +1239,11 @@
1239 blob_appendf(&sql, " AND event.objid IN ok");
1240 db_multi_exec("%s", blob_str(&sql));
1241 if( useDividers ) timeline_add_dividers(0, f_rid);
1242 blob_appendf(&desc, "Parents and children of check-in ");
1243 zUuid = db_text("", "SELECT uuid FROM blob WHERE rid=%d", f_rid);
1244 blob_appendf(&desc, "%z[%S]</a>", href("%R/info/%s", zUuid), zUuid);
1245 tmFlags |= TIMELINE_DISJOINT;
1246 url_add_parameter(&url, "f", zUuid);
1247 if( tmFlags & TIMELINE_FCHANGES ){
1248 timeline_submenu(&url, "Hide Files", "v", 0, 0);
1249 }else{
@@ -1587,11 +1565,10 @@
1565 int nChild = db_column_int(q, 4);
1566 int nParent = db_column_int(q, 5);
1567 char *zFree = 0;
1568 int n = 0;
1569 char zPrefix[80];
 
1570
1571 if( nAbsLimit!=0 ){
1572 if( nLimit<0 && nLine>=nAbsLimit ){
1573 fossil_print("--- line limit (%d) reached ---\n", nAbsLimit);
1574 break; /* line count limit hit, stop. */
@@ -1598,11 +1575,10 @@
1575 }else if( nEntry>=nAbsLimit ){
1576 fossil_print("--- entry limit (%d) reached ---\n", nAbsLimit);
1577 break; /* entry count limit hit, stop. */
1578 }
1579 }
 
1580 if( fossil_strnicmp(zDate, zPrevDate, 10) ){
1581 fossil_print("=== %.10s ===\n", zDate);
1582 memcpy(zPrevDate, zDate, 10);
1583 nLine++; /* record another line */
1584 }
@@ -1625,13 +1601,13 @@
1601 }
1602 if( fossil_strcmp(zCurrentUuid,zId)==0 ){
1603 sqlite3_snprintf(sizeof(zPrefix)-n, &zPrefix[n], "*CURRENT* ");
1604 n += strlen(zPrefix);
1605 }
1606 zFree = mprintf("[%S] %s%s", zId, zPrefix, zCom);
1607 nLine += comment_print(zFree, 9, width); /* record another X lines */
1608 fossil_free(zFree);
1609
1610 if(verboseFlag){
1611 if( !fchngQueryInit ){
1612 db_prepare(&fchngQuery,
1613 "SELECT (pid==0) AS isnew,"
1614

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button