Fossil SCM

Fix minor typo and sort options in command-line timeline.

danield 2021-03-23 15:53 trunk
Commit f4af604aa56c0ed7ff7d15e2bee7d1de7cb225a4ab96bf020159b31532dfd520
1 file changed +23 -21
+23 -21
--- src/timeline.c
+++ src/timeline.c
@@ -3037,30 +3037,10 @@
30373037
** (westward) or "+HH:MM" (eastward). Either no timezone suffix or "Z"
30383038
** means UTC.
30393039
**
30403040
**
30413041
** Options:
3042
-** -n|--limit N If N is positive, output the first N entries. If
3043
-** N is negative, output the first -N lines. If N is
3044
-** zero, no limit. Default is -20 meaning 20 lines.
3045
-** -p|--path PATH Output items affecting PATH only.
3046
-** PATH can be a file or a sub directory.
3047
-** --offset P skip P changes
3048
-** --sql Show the SQL used to generate the timeline
3049
-** -t|--type TYPE Output items from the given types only, such as:
3050
-** ci = file commits only
3051
-** e = technical notes only
3052
-** f = forum posts only
3053
-** t = tickets only
3054
-** w = wiki commits only
3055
-** -v|--verbose Output the list of files changed by each commit
3056
-** and the type of each change (edited, deleted,
3057
-** etc.) after the check-in comment.
3058
-** -W|--width N Width of lines (default is to auto-detect). N must be
3059
-** either greater than 20 or it ust be zero 0 to
3060
-** indicate no limit, resulting in a single line per
3061
-** entry.
30623042
** -F|--format Entry format. Values "oneline", "medium", and "full"
30633043
** get mapped to the full options below. Otherwise a
30643044
** string which can contain these placeholders:
30653045
** %n newline
30663046
** %% a raw %
@@ -3074,12 +3054,34 @@
30743054
** %p phase: zero or more of *CURRENT*, *MERGE*,
30753055
** *FORK*, *UNPUBLISHED*, *LEAF*, *BRANCH*
30763056
** --oneline Show only short hash and comment for each entry
30773057
** --medium Medium-verbose entry formatting
30783058
** --full Extra verbose entry formatting
3059
+**
3060
+** -n|--limit N If N is positive, output the first N entries. If
3061
+** N is negative, output the first -N lines. If N is
3062
+** zero, no limit. Default is -20 meaning 20 lines.
3063
+** --offset P skip P changes
3064
+** -p|--path PATH Output items affecting PATH only.
3065
+** PATH can be a file or a sub directory.
30793066
** -R REPO_FILE Specifies the repository db to use. Default is
30803067
** the current checkout's repository.
3068
+
3069
+** --sql Show the SQL used to generate the timeline
3070
+** -t|--type TYPE Output items from the given types only, such as:
3071
+** ci = file commits only
3072
+** e = technical notes only
3073
+** f = forum posts only
3074
+** t = tickets only
3075
+** w = wiki commits only
3076
+** -v|--verbose Output the list of files changed by each commit
3077
+** and the type of each change (edited, deleted,
3078
+** etc.) after the check-in comment.
3079
+** -W|--width N Width of lines (default is to auto-detect). N must be
3080
+** either greater than 20 or it ust be zero 0 to
3081
+** indicate no limit, resulting in a single line per
3082
+** entry.
30813083
*/
30823084
void timeline_cmd(void){
30833085
Stmt q;
30843086
int n, k, width;
30853087
const char *zLimit;
@@ -3154,11 +3156,11 @@
31543156
mode = TIMELINE_MODE_PARENTS;
31553157
}else if( strncmp(g.argv[2],"parents",k)==0 ){
31563158
mode = TIMELINE_MODE_PARENTS;
31573159
}else if(!zType && !zLimit){
31583160
usage("?WHEN? ?CHECKIN|DATETIME? ?-n|--limit #? ?-t|--type TYPE? "
3159
- "?-W|--width WIDTH? ?-p|--path PATH");
3161
+ "?-W|--width WIDTH? ?-p|--path PATH?");
31603162
}
31613163
if( '-' != *g.argv[3] ){
31623164
zOrigin = g.argv[3];
31633165
}else{
31643166
zOrigin = "now";
31653167
--- src/timeline.c
+++ src/timeline.c
@@ -3037,30 +3037,10 @@
3037 ** (westward) or "+HH:MM" (eastward). Either no timezone suffix or "Z"
3038 ** means UTC.
3039 **
3040 **
3041 ** Options:
3042 ** -n|--limit N If N is positive, output the first N entries. If
3043 ** N is negative, output the first -N lines. If N is
3044 ** zero, no limit. Default is -20 meaning 20 lines.
3045 ** -p|--path PATH Output items affecting PATH only.
3046 ** PATH can be a file or a sub directory.
3047 ** --offset P skip P changes
3048 ** --sql Show the SQL used to generate the timeline
3049 ** -t|--type TYPE Output items from the given types only, such as:
3050 ** ci = file commits only
3051 ** e = technical notes only
3052 ** f = forum posts only
3053 ** t = tickets only
3054 ** w = wiki commits only
3055 ** -v|--verbose Output the list of files changed by each commit
3056 ** and the type of each change (edited, deleted,
3057 ** etc.) after the check-in comment.
3058 ** -W|--width N Width of lines (default is to auto-detect). N must be
3059 ** either greater than 20 or it ust be zero 0 to
3060 ** indicate no limit, resulting in a single line per
3061 ** entry.
3062 ** -F|--format Entry format. Values "oneline", "medium", and "full"
3063 ** get mapped to the full options below. Otherwise a
3064 ** string which can contain these placeholders:
3065 ** %n newline
3066 ** %% a raw %
@@ -3074,12 +3054,34 @@
3074 ** %p phase: zero or more of *CURRENT*, *MERGE*,
3075 ** *FORK*, *UNPUBLISHED*, *LEAF*, *BRANCH*
3076 ** --oneline Show only short hash and comment for each entry
3077 ** --medium Medium-verbose entry formatting
3078 ** --full Extra verbose entry formatting
 
 
 
 
 
 
 
3079 ** -R REPO_FILE Specifies the repository db to use. Default is
3080 ** the current checkout's repository.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3081 */
3082 void timeline_cmd(void){
3083 Stmt q;
3084 int n, k, width;
3085 const char *zLimit;
@@ -3154,11 +3156,11 @@
3154 mode = TIMELINE_MODE_PARENTS;
3155 }else if( strncmp(g.argv[2],"parents",k)==0 ){
3156 mode = TIMELINE_MODE_PARENTS;
3157 }else if(!zType && !zLimit){
3158 usage("?WHEN? ?CHECKIN|DATETIME? ?-n|--limit #? ?-t|--type TYPE? "
3159 "?-W|--width WIDTH? ?-p|--path PATH");
3160 }
3161 if( '-' != *g.argv[3] ){
3162 zOrigin = g.argv[3];
3163 }else{
3164 zOrigin = "now";
3165
--- src/timeline.c
+++ src/timeline.c
@@ -3037,30 +3037,10 @@
3037 ** (westward) or "+HH:MM" (eastward). Either no timezone suffix or "Z"
3038 ** means UTC.
3039 **
3040 **
3041 ** Options:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3042 ** -F|--format Entry format. Values "oneline", "medium", and "full"
3043 ** get mapped to the full options below. Otherwise a
3044 ** string which can contain these placeholders:
3045 ** %n newline
3046 ** %% a raw %
@@ -3074,12 +3054,34 @@
3054 ** %p phase: zero or more of *CURRENT*, *MERGE*,
3055 ** *FORK*, *UNPUBLISHED*, *LEAF*, *BRANCH*
3056 ** --oneline Show only short hash and comment for each entry
3057 ** --medium Medium-verbose entry formatting
3058 ** --full Extra verbose entry formatting
3059 **
3060 ** -n|--limit N If N is positive, output the first N entries. If
3061 ** N is negative, output the first -N lines. If N is
3062 ** zero, no limit. Default is -20 meaning 20 lines.
3063 ** --offset P skip P changes
3064 ** -p|--path PATH Output items affecting PATH only.
3065 ** PATH can be a file or a sub directory.
3066 ** -R REPO_FILE Specifies the repository db to use. Default is
3067 ** the current checkout's repository.
3068
3069 ** --sql Show the SQL used to generate the timeline
3070 ** -t|--type TYPE Output items from the given types only, such as:
3071 ** ci = file commits only
3072 ** e = technical notes only
3073 ** f = forum posts only
3074 ** t = tickets only
3075 ** w = wiki commits only
3076 ** -v|--verbose Output the list of files changed by each commit
3077 ** and the type of each change (edited, deleted,
3078 ** etc.) after the check-in comment.
3079 ** -W|--width N Width of lines (default is to auto-detect). N must be
3080 ** either greater than 20 or it ust be zero 0 to
3081 ** indicate no limit, resulting in a single line per
3082 ** entry.
3083 */
3084 void timeline_cmd(void){
3085 Stmt q;
3086 int n, k, width;
3087 const char *zLimit;
@@ -3154,11 +3156,11 @@
3156 mode = TIMELINE_MODE_PARENTS;
3157 }else if( strncmp(g.argv[2],"parents",k)==0 ){
3158 mode = TIMELINE_MODE_PARENTS;
3159 }else if(!zType && !zLimit){
3160 usage("?WHEN? ?CHECKIN|DATETIME? ?-n|--limit #? ?-t|--type TYPE? "
3161 "?-W|--width WIDTH? ?-p|--path PATH?");
3162 }
3163 if( '-' != *g.argv[3] ){
3164 zOrigin = g.argv[3];
3165 }else{
3166 zOrigin = "now";
3167

Keyboard Shortcuts

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