Check-in [3c637382b4]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
SHA1 Hash:3c637382b43d4baae71659076b3de408214a334c
Date: 2012-04-17 22:31:38
User: drh
Comment:Merge the msw-docco changes into trunk.
Tags And Properties
Changes

Changes to src/branch.c

18 ** This file contains code used to create new branches within a repository. 18 ** This file contains code used to create new branches within a repository. 19 */ 19 */ 20 #include "config.h" 20 #include "config.h" 21 #include "branch.h" 21 #include "branch.h" 22 #include <assert.h> 22 #include <assert.h> 23 23 24 /* 24 /* 25 ** fossil branch new BRANCH-NAME ?ORIGIN-CHECK-IN? ?-bgcolor COLOR? | 25 ** fossil branch new NAME BASIS ?OPTIONS? 26 ** argv0 argv1 argv2 argv3 argv4 | 26 ** argv0 argv1 argv2 argv3 argv4 27 */ 27 */ 28 void branch_new(void){ 28 void branch_new(void){ 29 int rootid; /* RID of the root check-in - what we branch off of */ 29 int rootid; /* RID of the root check-in - what we branch off of */ 30 int brid; /* RID of the branch check-in */ 30 int brid; /* RID of the branch check-in */ 31 int noSign; /* True if the branch is unsigned */ 31 int noSign; /* True if the branch is unsigned */ 32 int i; /* Loop counter */ 32 int i; /* Loop counter */ 33 char *zUuid; /* Artifact ID of origin */ 33 char *zUuid; /* Artifact ID of origin */ ................................................................................................................................................................................ 46 noSign = find_option("nosign","",0)!=0; 46 noSign = find_option("nosign","",0)!=0; 47 zColor = find_option("bgcolor","c",1); 47 zColor = find_option("bgcolor","c",1); 48 isPrivate = find_option("private",0,0)!=0; 48 isPrivate = find_option("private",0,0)!=0; 49 zDateOvrd = find_option("date-override",0,1); 49 zDateOvrd = find_option("date-override",0,1); 50 zUserOvrd = find_option("user-override",0,1); 50 zUserOvrd = find_option("user-override",0,1); 51 verify_all_options(); 51 verify_all_options(); 52 if( g.argc<5 ){ 52 if( g.argc<5 ){ 53 usage("new BRANCH-NAME CHECK-IN ?-bgcolor COLOR?"); | 53 usage("new BRANCH-NAME BASIS ?OPTIONS?"); 54 } 54 } 55 db_find_and_open_repository(0, 0); 55 db_find_and_open_repository(0, 0); 56 noSign = db_get_int("omitsign", 0)|noSign; 56 noSign = db_get_int("omitsign", 0)|noSign; 57 57 58 /* fossil branch new name */ 58 /* fossil branch new name */ 59 zBranch = g.argv[3]; 59 zBranch = g.argv[3]; 60 if( zBranch==0 || zBranch[0]==0 ){ 60 if( zBranch==0 || zBranch[0]==0 ){ ................................................................................................................................................................................ 224 ** COMMAND: branch 224 ** COMMAND: branch 225 ** 225 ** 226 ** Usage: %fossil branch SUBCOMMAND ... ?OPTIONS? 226 ** Usage: %fossil branch SUBCOMMAND ... ?OPTIONS? 227 ** 227 ** 228 ** Run various subcommands to manage branches of the open repository or 228 ** Run various subcommands to manage branches of the open repository or 229 ** of the repository identified by the -R or --repository option. 229 ** of the repository identified by the -R or --repository option. 230 ** 230 ** 231 ** %fossil branch new BRANCH-NAME BASIS ?--bgcolor COLOR? ?--private? | 231 ** %fossil branch new BRANCH-NAME BASIS ?OPTIONS? 232 ** 232 ** 233 ** Create a new branch BRANCH-NAME off of check-in BASIS. 233 ** Create a new branch BRANCH-NAME off of check-in BASIS. 234 ** You can optionally give the branch a default color. The | 234 ** Supported options for this subcommand include: 235 ** --private option makes the branch private. | 235 ** --private branch is private (i.e., remains local) > 236 ** --bgcolor COLOR use COLOR instead of automatic background > 237 ** --nosign do not sign contents on this branch > 238 ** --date-override DATE DATE to use instead of 'now' > 239 ** --user-override USER USER to use instead of the current default 236 ** 240 ** 237 ** %fossil branch list ?-all | --closed? | 241 ** %fossil branch list ?--all | --closed? 238 ** %fossil branch ls ?-all | --closed? | 242 ** %fossil branch ls ?--all | --closed? 239 ** 243 ** 240 ** List all branches. Use --all or --closed to list all branches 244 ** List all branches. Use --all or --closed to list all branches 241 ** or closed branches. The default is to show only open branches. 245 ** or closed branches. The default is to show only open branches. 242 ** 246 ** 243 ** Options: 247 ** Options: 244 ** -R|--repository FILE Run commands on repository FILE 248 ** -R|--repository FILE Run commands on repository FILE 245 */ 249 */