338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
|
);
print_timeline(&q, 0, width, 0);
db_finalize(&q);
}
/*
** COMMAND: leaves*
** COMMAND: forks*
**
** Usage: %fossil leaves|forks ?OPTIONS?
**
** Find leaves/forks of all branches. By default show only open leaves.
** The -a|--all flag causes all leaves (closed and open) to be shown.
** The -c|--closed flag shows only closed leaves.
**
** The --recompute flag causes the content of the "leaf" table in the
** repository database to be recomputed.
**
** Options:
|
<
|
|
|
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
|
);
print_timeline(&q, 0, width, 0);
db_finalize(&q);
}
/*
** COMMAND: leaves*
**
** Usage: %fossil leaves ?OPTIONS?
**
** Find leaves of all branches. By default show only open leaves.
** The -a|--all flag causes all leaves (closed and open) to be shown.
** The -c|--closed flag shows only closed leaves.
**
** The --recompute flag causes the content of the "leaf" table in the
** repository database to be recomputed.
**
** Options:
|
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
|
*/
void leaves_cmd(void){
Stmt q;
Blob sql;
int showAll = find_option("all", "a", 0)!=0;
int showClosed = find_option("closed", "c", 0)!=0;
int recomputeFlag = find_option("recompute",0,0)!=0;
int byBranch = find_option("bybranch",0,0)!=0;
int showForks = g.argv[1][0]=='f';
const char *zWidth = find_option("width","W",1);
char *zLastBr = 0;
int n, width;
char zLineNo[10];
if( zWidth ){
width = atoi(zWidth);
|
<
|
>
|
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
|
*/
void leaves_cmd(void){
Stmt q;
Blob sql;
int showAll = find_option("all", "a", 0)!=0;
int showClosed = find_option("closed", "c", 0)!=0;
int recomputeFlag = find_option("recompute",0,0)!=0;
int showForks = g.argv[1][0]!='l';
int byBranch = (find_option("bybranch",0,0)!=0) || showForks;
const char *zWidth = find_option("width","W",1);
char *zLastBr = 0;
int n, width;
char zLineNo[10];
if( zWidth ){
width = atoi(zWidth);
|
428
429
430
431
432
433
434
435
436
437
438
439
440
441
|
z = mprintf("%s [%S] %s", zDate, zId, zCom);
comment_print(z, zCom, 7, width, g.comFmtFlags);
fossil_free(z);
}
}
fossil_free(zLastBr);
db_finalize(&q);
}
/*
** WEBPAGE: leaves
**
** Find leaves of all branches.
*/
|
>
|
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
|
z = mprintf("%s [%S] %s", zDate, zId, zCom);
comment_print(z, zCom, 7, width, g.comFmtFlags);
fossil_free(z);
}
}
fossil_free(zLastBr);
db_finalize(&q);
if( showForks && !zLastBr ) fossil_print("*** OK, no ambigeous branches found ***\n");
}
/*
** WEBPAGE: leaves
**
** Find leaves of all branches.
*/
|