Fossil SCM
[/help?cmd=new|fossil new] no longer creates an initial empty commit by default (but it still does when using --date-override). The first commit after checking out a new empty repository will become the initial commit.
Commit
cac91b6cd17ab74663d2876548c0d4856b08b6af
Parent
ec44f61a831e422…
2 files changed
+1
-1
+3
M
src/db.c
+1
-1
| --- src/db.c | ||
| +++ src/db.c | ||
| @@ -1441,10 +1441,11 @@ | ||
| 1441 | 1441 | ** |
| 1442 | 1442 | ** Options: |
| 1443 | 1443 | ** --template FILE copy settings from repository file |
| 1444 | 1444 | ** --admin-user|-A USERNAME select given USERNAME as admin user |
| 1445 | 1445 | ** --date-override DATETIME use DATETIME as time of the initial checkin |
| 1446 | +** (default: don't create initial checkin) | |
| 1446 | 1447 | ** |
| 1447 | 1448 | ** See also: clone |
| 1448 | 1449 | */ |
| 1449 | 1450 | void create_repository_cmd(void){ |
| 1450 | 1451 | char *zPassword; |
| @@ -1453,11 +1454,10 @@ | ||
| 1453 | 1454 | const char *zDefaultUser; /* Optional name of the default user */ |
| 1454 | 1455 | |
| 1455 | 1456 | zTemplate = find_option("template",0,1); |
| 1456 | 1457 | zDate = find_option("date-override",0,1); |
| 1457 | 1458 | zDefaultUser = find_option("admin-user","A",1); |
| 1458 | - if( zDate==0 ) zDate = "now"; | |
| 1459 | 1459 | if( g.argc!=3 ){ |
| 1460 | 1460 | usage("REPOSITORY-NAME"); |
| 1461 | 1461 | } |
| 1462 | 1462 | db_create_repository(g.argv[2]); |
| 1463 | 1463 | db_open_repository(g.argv[2]); |
| 1464 | 1464 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -1441,10 +1441,11 @@ | |
| 1441 | ** |
| 1442 | ** Options: |
| 1443 | ** --template FILE copy settings from repository file |
| 1444 | ** --admin-user|-A USERNAME select given USERNAME as admin user |
| 1445 | ** --date-override DATETIME use DATETIME as time of the initial checkin |
| 1446 | ** |
| 1447 | ** See also: clone |
| 1448 | */ |
| 1449 | void create_repository_cmd(void){ |
| 1450 | char *zPassword; |
| @@ -1453,11 +1454,10 @@ | |
| 1453 | const char *zDefaultUser; /* Optional name of the default user */ |
| 1454 | |
| 1455 | zTemplate = find_option("template",0,1); |
| 1456 | zDate = find_option("date-override",0,1); |
| 1457 | zDefaultUser = find_option("admin-user","A",1); |
| 1458 | if( zDate==0 ) zDate = "now"; |
| 1459 | if( g.argc!=3 ){ |
| 1460 | usage("REPOSITORY-NAME"); |
| 1461 | } |
| 1462 | db_create_repository(g.argv[2]); |
| 1463 | db_open_repository(g.argv[2]); |
| 1464 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -1441,10 +1441,11 @@ | |
| 1441 | ** |
| 1442 | ** Options: |
| 1443 | ** --template FILE copy settings from repository file |
| 1444 | ** --admin-user|-A USERNAME select given USERNAME as admin user |
| 1445 | ** --date-override DATETIME use DATETIME as time of the initial checkin |
| 1446 | ** (default: don't create initial checkin) |
| 1447 | ** |
| 1448 | ** See also: clone |
| 1449 | */ |
| 1450 | void create_repository_cmd(void){ |
| 1451 | char *zPassword; |
| @@ -1453,11 +1454,10 @@ | |
| 1454 | const char *zDefaultUser; /* Optional name of the default user */ |
| 1455 | |
| 1456 | zTemplate = find_option("template",0,1); |
| 1457 | zDate = find_option("date-override",0,1); |
| 1458 | zDefaultUser = find_option("admin-user","A",1); |
| 1459 | if( g.argc!=3 ){ |
| 1460 | usage("REPOSITORY-NAME"); |
| 1461 | } |
| 1462 | db_create_repository(g.argv[2]); |
| 1463 | db_open_repository(g.argv[2]); |
| 1464 |
+3
| --- www/changes.wiki | ||
| +++ www/changes.wiki | ||
| @@ -48,10 +48,13 @@ | ||
| 48 | 48 | * Issue a warning if a [/help?cmd=add|fossil add] command tries to add a file |
| 49 | 49 | that matches the ignore-glob. |
| 50 | 50 | * Add option -W|--width to "[/help?cmd=stash|fossil stash ls]" |
| 51 | 51 | and "[/help?cmd=leaves|fossil leaves]" commands. |
| 52 | 52 | * Enhance support for running as the root user. Now works on Haiku. |
| 53 | + * [/help?cmd=new|fossil new] no longer creates an initial empty commit by | |
| 54 | + default. The first commit after checking out a new empty repository will | |
| 55 | + become the initial commit. | |
| 53 | 56 | |
| 54 | 57 | <h2>Changes For Version 1.28 (2014-01-27)</h2> |
| 55 | 58 | * Enhance [/help?cmd=/reports | /reports] to support event type filtering. |
| 56 | 59 | * When cloning a repository, the user name passed via the URL (if any) |
| 57 | 60 | is now used as the default local admin user's name. |
| 58 | 61 |
| --- www/changes.wiki | |
| +++ www/changes.wiki | |
| @@ -48,10 +48,13 @@ | |
| 48 | * Issue a warning if a [/help?cmd=add|fossil add] command tries to add a file |
| 49 | that matches the ignore-glob. |
| 50 | * Add option -W|--width to "[/help?cmd=stash|fossil stash ls]" |
| 51 | and "[/help?cmd=leaves|fossil leaves]" commands. |
| 52 | * Enhance support for running as the root user. Now works on Haiku. |
| 53 | |
| 54 | <h2>Changes For Version 1.28 (2014-01-27)</h2> |
| 55 | * Enhance [/help?cmd=/reports | /reports] to support event type filtering. |
| 56 | * When cloning a repository, the user name passed via the URL (if any) |
| 57 | is now used as the default local admin user's name. |
| 58 |
| --- www/changes.wiki | |
| +++ www/changes.wiki | |
| @@ -48,10 +48,13 @@ | |
| 48 | * Issue a warning if a [/help?cmd=add|fossil add] command tries to add a file |
| 49 | that matches the ignore-glob. |
| 50 | * Add option -W|--width to "[/help?cmd=stash|fossil stash ls]" |
| 51 | and "[/help?cmd=leaves|fossil leaves]" commands. |
| 52 | * Enhance support for running as the root user. Now works on Haiku. |
| 53 | * [/help?cmd=new|fossil new] no longer creates an initial empty commit by |
| 54 | default. The first commit after checking out a new empty repository will |
| 55 | become the initial commit. |
| 56 | |
| 57 | <h2>Changes For Version 1.28 (2014-01-27)</h2> |
| 58 | * Enhance [/help?cmd=/reports | /reports] to support event type filtering. |
| 59 | * When cloning a repository, the user name passed via the URL (if any) |
| 60 | is now used as the default local admin user's name. |
| 61 |