Fossil SCM

Second attempt to get --page working for "fossil ui remote:/".

drh 2026-08-06 16:07 UTC repo-list-home
Commit e6732228f10a6f7084b9d9ac0e7766af971447ac697b338647e38362ea588594
1 file changed +3 -7
+3 -7
--- src/main.c
+++ src/main.c
@@ -3531,10 +3531,13 @@
35313531
if( isUiCmd && !fNoBrowser ){
35323532
char *zBrowserArg;
35333533
const char *zProtocol = g.httpUseSSL ? "https" : "http";
35343534
db_open_config(0,0);
35353535
zBrowser = fossil_web_browser();
3536
+ if( zRemote && fossil_strcmp(g.argv[2],"/")==0 ){
3537
+ zInitPage = mprintf("?home=%T", zInitPage);
3538
+ }
35363539
if( zIpAddr==0 ){
35373540
zBrowserArg = mprintf("%s://localhost:%%d/%s", zProtocol, zInitPage);
35383541
}else if( strchr(zIpAddr,':') ){
35393542
zBrowserArg = mprintf("%s://[%s]:%%d/%s", zProtocol, zIpAddr, zInitPage);
35403543
}else{
@@ -3584,17 +3587,10 @@
35843587
blob_appendf(&ssh, " --extroot %$", g.zExtRoot);
35853588
}
35863589
if( skin_in_use() ) blob_appendf(&ssh, " --skin %s", skin_in_use());
35873590
if( zJsMode ) blob_appendf(&ssh, " --jsmode %s", zJsMode);
35883591
if( fCreate ) blob_appendf(&ssh, " --create");
3589
- if( zInitPage && zInitPage[0] ){
3590
- if( fossil_strcmp(zUrl,"/")==0 ){
3591
- zInitPage = mprintf("/?home=%T", zInitPage);
3592
- }else{
3593
- blob_appendf(&ssh, " --page %!$", zInitPage);
3594
- }
3595
- }
35963592
blob_appendf(&ssh, " %$", zUrl);
35973593
if( isRetry ){
35983594
fossil_print("First attempt to run \"fossil\" on %s failed\n"
35993595
"Retry: ", zRemote);
36003596
}
36013597
--- src/main.c
+++ src/main.c
@@ -3531,10 +3531,13 @@
3531 if( isUiCmd && !fNoBrowser ){
3532 char *zBrowserArg;
3533 const char *zProtocol = g.httpUseSSL ? "https" : "http";
3534 db_open_config(0,0);
3535 zBrowser = fossil_web_browser();
 
 
 
3536 if( zIpAddr==0 ){
3537 zBrowserArg = mprintf("%s://localhost:%%d/%s", zProtocol, zInitPage);
3538 }else if( strchr(zIpAddr,':') ){
3539 zBrowserArg = mprintf("%s://[%s]:%%d/%s", zProtocol, zIpAddr, zInitPage);
3540 }else{
@@ -3584,17 +3587,10 @@
3584 blob_appendf(&ssh, " --extroot %$", g.zExtRoot);
3585 }
3586 if( skin_in_use() ) blob_appendf(&ssh, " --skin %s", skin_in_use());
3587 if( zJsMode ) blob_appendf(&ssh, " --jsmode %s", zJsMode);
3588 if( fCreate ) blob_appendf(&ssh, " --create");
3589 if( zInitPage && zInitPage[0] ){
3590 if( fossil_strcmp(zUrl,"/")==0 ){
3591 zInitPage = mprintf("/?home=%T", zInitPage);
3592 }else{
3593 blob_appendf(&ssh, " --page %!$", zInitPage);
3594 }
3595 }
3596 blob_appendf(&ssh, " %$", zUrl);
3597 if( isRetry ){
3598 fossil_print("First attempt to run \"fossil\" on %s failed\n"
3599 "Retry: ", zRemote);
3600 }
3601
--- src/main.c
+++ src/main.c
@@ -3531,10 +3531,13 @@
3531 if( isUiCmd && !fNoBrowser ){
3532 char *zBrowserArg;
3533 const char *zProtocol = g.httpUseSSL ? "https" : "http";
3534 db_open_config(0,0);
3535 zBrowser = fossil_web_browser();
3536 if( zRemote && fossil_strcmp(g.argv[2],"/")==0 ){
3537 zInitPage = mprintf("?home=%T", zInitPage);
3538 }
3539 if( zIpAddr==0 ){
3540 zBrowserArg = mprintf("%s://localhost:%%d/%s", zProtocol, zInitPage);
3541 }else if( strchr(zIpAddr,':') ){
3542 zBrowserArg = mprintf("%s://[%s]:%%d/%s", zProtocol, zIpAddr, zInitPage);
3543 }else{
@@ -3584,17 +3587,10 @@
3587 blob_appendf(&ssh, " --extroot %$", g.zExtRoot);
3588 }
3589 if( skin_in_use() ) blob_appendf(&ssh, " --skin %s", skin_in_use());
3590 if( zJsMode ) blob_appendf(&ssh, " --jsmode %s", zJsMode);
3591 if( fCreate ) blob_appendf(&ssh, " --create");
 
 
 
 
 
 
 
3592 blob_appendf(&ssh, " %$", zUrl);
3593 if( isRetry ){
3594 fossil_print("First attempt to run \"fossil\" on %s failed\n"
3595 "Retry: ", zRemote);
3596 }
3597

Keyboard Shortcuts

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