Fossil SCM

Make [/help?cmd=new|fossil new --empty] the default way to create a new repository. THIS COMMIT WILL BE REVERTED BEFORE FOSSIL 1.30 IS BEING RELEASED, (UNLESS RICHARD DECIDES OTHERWISE AT THAT TIME). The intent of this commit is to expose [/help?cmd=new|fossil new --empty] to more field-testing. It should be 100% upwards/downwards compatible, but if there still turn out to be some corner-cases, now is the right time to find out (I am not aware of any!).

jan.nijtmans 2014-07-11 07:22 trunk
Commit 8364065c45ec839d01e0a0535ebd754f81e9cac4
2 files changed +2 -7 +5
+2 -7
--- src/db.c
+++ src/db.c
@@ -1465,29 +1465,24 @@
14651465
**
14661466
** Options:
14671467
** --template FILE copy settings from repository file
14681468
** --admin-user|-A USERNAME select given USERNAME as admin user
14691469
** --date-override DATETIME use DATETIME as time of the initial checkin
1470
-** (overrides --empty as well)
1471
-** --empty Do not create an initial empty checkin.
1470
+** (default: do not create an initial checkin)
14721471
**
14731472
** See also: clone
14741473
*/
14751474
void create_repository_cmd(void){
14761475
char *zPassword;
14771476
const char *zTemplate; /* Repository from which to copy settings */
14781477
const char *zDate; /* Date of the initial check-in */
14791478
const char *zDefaultUser; /* Optional name of the default user */
1480
- char const *zCreateEmpty; /* --empty flag set? */
14811479
14821480
zTemplate = find_option("template",0,1);
14831481
zDate = find_option("date-override",0,1);
14841482
zDefaultUser = find_option("admin-user","A",1);
1485
- zCreateEmpty = find_option("empty", 0, 0);
1486
- if( !zDate && !zCreateEmpty ){
1487
- zDate = "now";
1488
- }
1483
+ find_option("empty", 0, 0); /* deprecated */
14891484
if( g.argc!=3 ){
14901485
usage("REPOSITORY-NAME");
14911486
}
14921487
db_create_repository(g.argv[2]);
14931488
db_open_repository(g.argv[2]);
14941489
--- src/db.c
+++ src/db.c
@@ -1465,29 +1465,24 @@
1465 **
1466 ** Options:
1467 ** --template FILE copy settings from repository file
1468 ** --admin-user|-A USERNAME select given USERNAME as admin user
1469 ** --date-override DATETIME use DATETIME as time of the initial checkin
1470 ** (overrides --empty as well)
1471 ** --empty Do not create an initial empty checkin.
1472 **
1473 ** See also: clone
1474 */
1475 void create_repository_cmd(void){
1476 char *zPassword;
1477 const char *zTemplate; /* Repository from which to copy settings */
1478 const char *zDate; /* Date of the initial check-in */
1479 const char *zDefaultUser; /* Optional name of the default user */
1480 char const *zCreateEmpty; /* --empty flag set? */
1481
1482 zTemplate = find_option("template",0,1);
1483 zDate = find_option("date-override",0,1);
1484 zDefaultUser = find_option("admin-user","A",1);
1485 zCreateEmpty = find_option("empty", 0, 0);
1486 if( !zDate && !zCreateEmpty ){
1487 zDate = "now";
1488 }
1489 if( g.argc!=3 ){
1490 usage("REPOSITORY-NAME");
1491 }
1492 db_create_repository(g.argv[2]);
1493 db_open_repository(g.argv[2]);
1494
--- src/db.c
+++ src/db.c
@@ -1465,29 +1465,24 @@
1465 **
1466 ** Options:
1467 ** --template FILE copy settings from repository file
1468 ** --admin-user|-A USERNAME select given USERNAME as admin user
1469 ** --date-override DATETIME use DATETIME as time of the initial checkin
1470 ** (default: do not create an initial checkin)
 
1471 **
1472 ** See also: clone
1473 */
1474 void create_repository_cmd(void){
1475 char *zPassword;
1476 const char *zTemplate; /* Repository from which to copy settings */
1477 const char *zDate; /* Date of the initial check-in */
1478 const char *zDefaultUser; /* Optional name of the default user */
 
1479
1480 zTemplate = find_option("template",0,1);
1481 zDate = find_option("date-override",0,1);
1482 zDefaultUser = find_option("admin-user","A",1);
1483 find_option("empty", 0, 0); /* deprecated */
 
 
 
1484 if( g.argc!=3 ){
1485 usage("REPOSITORY-NAME");
1486 }
1487 db_create_repository(g.argv[2]);
1488 db_open_repository(g.argv[2]);
1489
--- www/changes.wiki
+++ www/changes.wiki
@@ -15,10 +15,15 @@
1515
to TH1, primarily for use by TH1 hooks.
1616
* Bring in the latest version of autosetup from upstream.
1717
* When committing a (non-binary) file which contains bytes forming an
1818
invalid UTF-8 stream, fossil now adds the possibility to convert it
1919
to a valid UTF-8 stream ('c') if you like.
20
+ * Let [/help?cmd=new|fossil new] no longer create an initial empty commit
21
+ by default. The first commit after checking out an empty repository will
22
+ become the initial commit. (NOT PLANNED FOR 1.30, BUT DONE TO EXPOSE
23
+ [/help?cmd=new|fossil new --empty] TO MORE FIELD TESTING BEFORE
24
+ MAKING ANY DECISION ON IT!)
2025
2126
<h2>Changes For Version 1.29 (2014-06-12)</h2>
2227
* Add the ability to display content, diffs and annotations for UTF16
2328
text files in the web interface.
2429
* Add the "SaveAs..." and "Invert" buttons
2530
--- www/changes.wiki
+++ www/changes.wiki
@@ -15,10 +15,15 @@
15 to TH1, primarily for use by TH1 hooks.
16 * Bring in the latest version of autosetup from upstream.
17 * When committing a (non-binary) file which contains bytes forming an
18 invalid UTF-8 stream, fossil now adds the possibility to convert it
19 to a valid UTF-8 stream ('c') if you like.
 
 
 
 
 
20
21 <h2>Changes For Version 1.29 (2014-06-12)</h2>
22 * Add the ability to display content, diffs and annotations for UTF16
23 text files in the web interface.
24 * Add the "SaveAs..." and "Invert" buttons
25
--- www/changes.wiki
+++ www/changes.wiki
@@ -15,10 +15,15 @@
15 to TH1, primarily for use by TH1 hooks.
16 * Bring in the latest version of autosetup from upstream.
17 * When committing a (non-binary) file which contains bytes forming an
18 invalid UTF-8 stream, fossil now adds the possibility to convert it
19 to a valid UTF-8 stream ('c') if you like.
20 * Let [/help?cmd=new|fossil new] no longer create an initial empty commit
21 by default. The first commit after checking out an empty repository will
22 become the initial commit. (NOT PLANNED FOR 1.30, BUT DONE TO EXPOSE
23 [/help?cmd=new|fossil new --empty] TO MORE FIELD TESTING BEFORE
24 MAKING ANY DECISION ON IT!)
25
26 <h2>Changes For Version 1.29 (2014-06-12)</h2>
27 * Add the ability to display content, diffs and annotations for UTF16
28 text files in the web interface.
29 * Add the "SaveAs..." and "Invert" buttons
30

Keyboard Shortcuts

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