Fossil SCM
Merge the (still experimental) hooks implementation onto trunk.
Commit
9d8db79c03ce14d6901b0f6bc6a2d0a110c8d1b7481044234ff9533887101048
Parent
a382145a2bd7e14…
10 files changed
+3
+76
-3
+1
+12
+1
+1
+10
-4
+12
+10
+122
+3
| --- src/backoffice.c | ||
| +++ src/backoffice.c | ||
| @@ -19,10 +19,11 @@ | ||
| 19 | 19 | ** occur after user interaction with the repository. Examples of |
| 20 | 20 | ** backoffice processing includes: |
| 21 | 21 | ** |
| 22 | 22 | ** * Sending alerts and notifications |
| 23 | 23 | ** * Processing the email queue |
| 24 | +** * Handling post-receive hooks | |
| 24 | 25 | ** * Automatically syncing to peer repositories |
| 25 | 26 | ** |
| 26 | 27 | ** Backoffice processing is automatically started whenever there are |
| 27 | 28 | ** changes to the repository. The backoffice process dies off after |
| 28 | 29 | ** a period of inactivity. |
| @@ -627,10 +628,12 @@ | ||
| 627 | 628 | /* Here is where the actual work of the backoffice happens */ |
| 628 | 629 | nThis = alert_backoffice(0); |
| 629 | 630 | if( nThis ){ backoffice_log("%d alerts", nThis); nTotal += nThis; } |
| 630 | 631 | nThis = smtp_cleanup(); |
| 631 | 632 | if( nThis ){ backoffice_log("%d SMTPs", nThis); nTotal += nThis; } |
| 633 | + nThis = hook_backoffice(); | |
| 634 | + if( nThis ){ backoffice_log("%d hooks", nThis); nTotal += nThis; } | |
| 632 | 635 | |
| 633 | 636 | /* Close the log */ |
| 634 | 637 | if( backofficeFILE ){ |
| 635 | 638 | if( nTotal || backofficeLogDetail ){ |
| 636 | 639 | if( nTotal==0 ) backoffice_log("no-op"); |
| 637 | 640 |
| --- src/backoffice.c | |
| +++ src/backoffice.c | |
| @@ -19,10 +19,11 @@ | |
| 19 | ** occur after user interaction with the repository. Examples of |
| 20 | ** backoffice processing includes: |
| 21 | ** |
| 22 | ** * Sending alerts and notifications |
| 23 | ** * Processing the email queue |
| 24 | ** * Automatically syncing to peer repositories |
| 25 | ** |
| 26 | ** Backoffice processing is automatically started whenever there are |
| 27 | ** changes to the repository. The backoffice process dies off after |
| 28 | ** a period of inactivity. |
| @@ -627,10 +628,12 @@ | |
| 627 | /* Here is where the actual work of the backoffice happens */ |
| 628 | nThis = alert_backoffice(0); |
| 629 | if( nThis ){ backoffice_log("%d alerts", nThis); nTotal += nThis; } |
| 630 | nThis = smtp_cleanup(); |
| 631 | if( nThis ){ backoffice_log("%d SMTPs", nThis); nTotal += nThis; } |
| 632 | |
| 633 | /* Close the log */ |
| 634 | if( backofficeFILE ){ |
| 635 | if( nTotal || backofficeLogDetail ){ |
| 636 | if( nTotal==0 ) backoffice_log("no-op"); |
| 637 |
| --- src/backoffice.c | |
| +++ src/backoffice.c | |
| @@ -19,10 +19,11 @@ | |
| 19 | ** occur after user interaction with the repository. Examples of |
| 20 | ** backoffice processing includes: |
| 21 | ** |
| 22 | ** * Sending alerts and notifications |
| 23 | ** * Processing the email queue |
| 24 | ** * Handling post-receive hooks |
| 25 | ** * Automatically syncing to peer repositories |
| 26 | ** |
| 27 | ** Backoffice processing is automatically started whenever there are |
| 28 | ** changes to the repository. The backoffice process dies off after |
| 29 | ** a period of inactivity. |
| @@ -627,10 +628,12 @@ | |
| 628 | /* Here is where the actual work of the backoffice happens */ |
| 629 | nThis = alert_backoffice(0); |
| 630 | if( nThis ){ backoffice_log("%d alerts", nThis); nTotal += nThis; } |
| 631 | nThis = smtp_cleanup(); |
| 632 | if( nThis ){ backoffice_log("%d SMTPs", nThis); nTotal += nThis; } |
| 633 | nThis = hook_backoffice(); |
| 634 | if( nThis ){ backoffice_log("%d hooks", nThis); nTotal += nThis; } |
| 635 | |
| 636 | /* Close the log */ |
| 637 | if( backofficeFILE ){ |
| 638 | if( nTotal || backofficeLogDetail ){ |
| 639 | if( nTotal==0 ) backoffice_log("no-op"); |
| 640 |
+76
-3
| --- src/checkin.c | ||
| +++ src/checkin.c | ||
| @@ -1323,10 +1323,66 @@ | ||
| 1323 | 1323 | ); |
| 1324 | 1324 | } |
| 1325 | 1325 | prompt_for_user_comment(pComment, &prompt); |
| 1326 | 1326 | blob_reset(&prompt); |
| 1327 | 1327 | } |
| 1328 | + | |
| 1329 | +/* | |
| 1330 | +** Prepare text that describes a pending commit and write it into | |
| 1331 | +** a file at the root of the check-in. Return the name of that file. | |
| 1332 | +** | |
| 1333 | +** Space to hold the returned filename is obtained from fossil_malloc() | |
| 1334 | +** and should be freed by the caller. The caller should also unlink | |
| 1335 | +** the file when it is done. | |
| 1336 | +*/ | |
| 1337 | +static char *prepare_commit_description_file( | |
| 1338 | + CheckinInfo *p, /* Information about this commit */ | |
| 1339 | + int parent_rid /* parent check-in */ | |
| 1340 | +){ | |
| 1341 | + Blob *pDesc; | |
| 1342 | + char *zTags; | |
| 1343 | + char *zFilename; | |
| 1344 | + Blob desc; | |
| 1345 | + unsigned int r[2]; | |
| 1346 | + blob_init(&desc, 0, 0); | |
| 1347 | + pDesc = &desc; | |
| 1348 | + blob_appendf(pDesc, "checkout %s\n", g.zLocalRoot); | |
| 1349 | + blob_appendf(pDesc, "repository %s\n", g.zRepositoryName); | |
| 1350 | + blob_appendf(pDesc, "user %s\n", | |
| 1351 | + p->zUserOvrd ? p->zUserOvrd : login_name()); | |
| 1352 | + blob_appendf(pDesc, "branch %s\n", | |
| 1353 | + (p->zBranch && p->zBranch[0]) ? p->zBranch : "trunk"); | |
| 1354 | + zTags = info_tags_of_checkin(parent_rid, 1); | |
| 1355 | + if( zTags || p->azTag ){ | |
| 1356 | + blob_append(pDesc, "tags ", -1); | |
| 1357 | + if(zTags){ | |
| 1358 | + blob_appendf(pDesc, "%z%s", zTags, p->azTag ? ", " : ""); | |
| 1359 | + } | |
| 1360 | + if(p->azTag){ | |
| 1361 | + int i = 0; | |
| 1362 | + for( ; p->azTag[i]; ++i ){ | |
| 1363 | + blob_appendf(pDesc, "%s%s", p->azTag[i], | |
| 1364 | + p->azTag[i+1] ? ", " : ""); | |
| 1365 | + } | |
| 1366 | + } | |
| 1367 | + blob_appendf(pDesc, "\n"); | |
| 1368 | + } | |
| 1369 | + status_report(pDesc, C_DEFAULT | C_FATAL); | |
| 1370 | + if( g.markPrivate ){ | |
| 1371 | + blob_append(pDesc, "private-branch\n", -1); | |
| 1372 | + } | |
| 1373 | + if( p->integrateFlag ){ | |
| 1374 | + blob_append(pDesc, "integrate\n", -1); | |
| 1375 | + } | |
| 1376 | + sqlite3_randomness(sizeof(r), r); | |
| 1377 | + zFilename = mprintf("%scommit-description-%08x%08x.txt", | |
| 1378 | + g.zLocalRoot, r[0], r[1]); | |
| 1379 | + blob_write_to_file(pDesc, zFilename); | |
| 1380 | + blob_reset(pDesc); | |
| 1381 | + return zFilename; | |
| 1382 | +} | |
| 1383 | + | |
| 1328 | 1384 | |
| 1329 | 1385 | /* |
| 1330 | 1386 | ** Populate the Global.aCommitFile[] based on the command line arguments |
| 1331 | 1387 | ** to a [commit] command. Global.aCommitFile is an array of integers |
| 1332 | 1388 | ** sized at (N+1), where N is the number of arguments passed to [commit]. |
| @@ -2008,27 +2064,29 @@ | ||
| 2008 | 2064 | ** --baseline use a baseline manifest in the commit process |
| 2009 | 2065 | ** --bgcolor COLOR apply COLOR to this one check-in only |
| 2010 | 2066 | ** --branch NEW-BRANCH-NAME check in to this new branch |
| 2011 | 2067 | ** --branchcolor COLOR apply given COLOR to the branch |
| 2012 | 2068 | ** --close close the branch being committed |
| 2069 | +** --date-override DATETIME DATE to use instead of 'now' | |
| 2013 | 2070 | ** --delta use a delta manifest in the commit process |
| 2071 | +** --hash verify file status using hashing rather | |
| 2072 | +** than relying on file mtimes | |
| 2014 | 2073 | ** --integrate close all merged-in branches |
| 2015 | 2074 | ** -m|--comment COMMENT-TEXT use COMMENT-TEXT as commit comment |
| 2016 | 2075 | ** -M|--message-file FILE read the commit comment from given file |
| 2017 | 2076 | ** --mimetype MIMETYPE mimetype of check-in comment |
| 2018 | 2077 | ** -n|--dry-run If given, display instead of run actions |
| 2019 | 2078 | ** --no-prompt This option disables prompting the user for |
| 2020 | 2079 | ** input and assumes an answer of 'No' for every |
| 2021 | 2080 | ** question. |
| 2022 | 2081 | ** --no-warnings omit all warnings about file contents |
| 2082 | +** --no-verify do not run before-commit hooks | |
| 2023 | 2083 | ** --nosign do not attempt to sign this commit with gpg |
| 2024 | 2084 | ** --override-lock allow a check-in even though parent is locked |
| 2025 | 2085 | ** --private do not sync changes and their descendants |
| 2026 | -** --hash verify file status using hashing rather | |
| 2027 | -** than relying on file mtimes | |
| 2028 | 2086 | ** --tag TAG-NAME assign given tag TAG-NAME to the check-in |
| 2029 | -** --date-override DATETIME DATE to use instead of 'now' | |
| 2087 | +** --trace debug tracing. | |
| 2030 | 2088 | ** --user-override USER USER to use instead of the current default |
| 2031 | 2089 | ** |
| 2032 | 2090 | ** DATETIME may be "now" or "YYYY-MM-DDTHH:MM:SS.SSS". If in |
| 2033 | 2091 | ** year-month-day form, it may be truncated, the "T" may be replaced by |
| 2034 | 2092 | ** a space, and it may also name a timezone offset from UTC as "-HH:MM" |
| @@ -2050,10 +2108,12 @@ | ||
| 2050 | 2108 | int noSign = 0; /* True to omit signing the manifest using GPG */ |
| 2051 | 2109 | int privateFlag = 0; /* True if the --private option is present */ |
| 2052 | 2110 | int privateParent = 0; /* True if the parent check-in is private */ |
| 2053 | 2111 | int isAMerge = 0; /* True if checking in a merge */ |
| 2054 | 2112 | int noWarningFlag = 0; /* True if skipping all warnings */ |
| 2113 | + int noVerify = 0; /* Do not run before-commit hooks */ | |
| 2114 | + int bTrace = 0; /* Debug tracing */ | |
| 2055 | 2115 | int noPrompt = 0; /* True if skipping all prompts */ |
| 2056 | 2116 | int forceFlag = 0; /* Undocumented: Disables all checks */ |
| 2057 | 2117 | int forceDelta = 0; /* Force a delta-manifest */ |
| 2058 | 2118 | int forceBaseline = 0; /* Force a baseline-manifest */ |
| 2059 | 2119 | int allowConflict = 0; /* Allow unresolve merge conflicts */ |
| @@ -2109,10 +2169,12 @@ | ||
| 2109 | 2169 | allowFork = find_option("allow-fork",0,0)!=0; |
| 2110 | 2170 | if( find_option("override-lock",0,0)!=0 ) allowFork = 1; |
| 2111 | 2171 | allowOlder = find_option("allow-older",0,0)!=0; |
| 2112 | 2172 | noPrompt = find_option("no-prompt", 0, 0)!=0; |
| 2113 | 2173 | noWarningFlag = find_option("no-warnings", 0, 0)!=0; |
| 2174 | + noVerify = find_option("no-verify",0,0)!=0; | |
| 2175 | + bTrace = find_option("trace",0,0)!=0; | |
| 2114 | 2176 | sCiInfo.zBranch = find_option("branch","b",1); |
| 2115 | 2177 | sCiInfo.zColor = find_option("bgcolor",0,1); |
| 2116 | 2178 | sCiInfo.zBrClr = find_option("branchcolor",0,1); |
| 2117 | 2179 | sCiInfo.closeFlag = find_option("close",0,0)!=0; |
| 2118 | 2180 | sCiInfo.integrateFlag = find_option("integrate",0,0)!=0; |
| @@ -2340,10 +2402,21 @@ | ||
| 2340 | 2402 | fossil_fatal("cannot commit against a closed leaf"); |
| 2341 | 2403 | } |
| 2342 | 2404 | |
| 2343 | 2405 | /* Always exit the loop on the second pass */ |
| 2344 | 2406 | if( bRecheck ) break; |
| 2407 | + | |
| 2408 | + /* Run before-commit hooks */ | |
| 2409 | + if( !noVerify ){ | |
| 2410 | + char *zAuxFile = prepare_commit_description_file(&sCiInfo,vid); | |
| 2411 | + int rc = hook_run("before-commit",zAuxFile,bTrace); | |
| 2412 | + file_delete(zAuxFile); | |
| 2413 | + fossil_free(zAuxFile); | |
| 2414 | + if( rc ){ | |
| 2415 | + fossil_fatal("Before-commit hook failed\n"); | |
| 2416 | + } | |
| 2417 | + } | |
| 2345 | 2418 | |
| 2346 | 2419 | /* Get the check-in comment. This might involve prompting the |
| 2347 | 2420 | ** user for the check-in comment, in which case we should resync |
| 2348 | 2421 | ** to renew the check-in lock and repeat the checks for conflicts. |
| 2349 | 2422 | */ |
| 2350 | 2423 | |
| 2351 | 2424 | ADDED src/hook.c |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -1323,10 +1323,66 @@ | |
| 1323 | ); |
| 1324 | } |
| 1325 | prompt_for_user_comment(pComment, &prompt); |
| 1326 | blob_reset(&prompt); |
| 1327 | } |
| 1328 | |
| 1329 | /* |
| 1330 | ** Populate the Global.aCommitFile[] based on the command line arguments |
| 1331 | ** to a [commit] command. Global.aCommitFile is an array of integers |
| 1332 | ** sized at (N+1), where N is the number of arguments passed to [commit]. |
| @@ -2008,27 +2064,29 @@ | |
| 2008 | ** --baseline use a baseline manifest in the commit process |
| 2009 | ** --bgcolor COLOR apply COLOR to this one check-in only |
| 2010 | ** --branch NEW-BRANCH-NAME check in to this new branch |
| 2011 | ** --branchcolor COLOR apply given COLOR to the branch |
| 2012 | ** --close close the branch being committed |
| 2013 | ** --delta use a delta manifest in the commit process |
| 2014 | ** --integrate close all merged-in branches |
| 2015 | ** -m|--comment COMMENT-TEXT use COMMENT-TEXT as commit comment |
| 2016 | ** -M|--message-file FILE read the commit comment from given file |
| 2017 | ** --mimetype MIMETYPE mimetype of check-in comment |
| 2018 | ** -n|--dry-run If given, display instead of run actions |
| 2019 | ** --no-prompt This option disables prompting the user for |
| 2020 | ** input and assumes an answer of 'No' for every |
| 2021 | ** question. |
| 2022 | ** --no-warnings omit all warnings about file contents |
| 2023 | ** --nosign do not attempt to sign this commit with gpg |
| 2024 | ** --override-lock allow a check-in even though parent is locked |
| 2025 | ** --private do not sync changes and their descendants |
| 2026 | ** --hash verify file status using hashing rather |
| 2027 | ** than relying on file mtimes |
| 2028 | ** --tag TAG-NAME assign given tag TAG-NAME to the check-in |
| 2029 | ** --date-override DATETIME DATE to use instead of 'now' |
| 2030 | ** --user-override USER USER to use instead of the current default |
| 2031 | ** |
| 2032 | ** DATETIME may be "now" or "YYYY-MM-DDTHH:MM:SS.SSS". If in |
| 2033 | ** year-month-day form, it may be truncated, the "T" may be replaced by |
| 2034 | ** a space, and it may also name a timezone offset from UTC as "-HH:MM" |
| @@ -2050,10 +2108,12 @@ | |
| 2050 | int noSign = 0; /* True to omit signing the manifest using GPG */ |
| 2051 | int privateFlag = 0; /* True if the --private option is present */ |
| 2052 | int privateParent = 0; /* True if the parent check-in is private */ |
| 2053 | int isAMerge = 0; /* True if checking in a merge */ |
| 2054 | int noWarningFlag = 0; /* True if skipping all warnings */ |
| 2055 | int noPrompt = 0; /* True if skipping all prompts */ |
| 2056 | int forceFlag = 0; /* Undocumented: Disables all checks */ |
| 2057 | int forceDelta = 0; /* Force a delta-manifest */ |
| 2058 | int forceBaseline = 0; /* Force a baseline-manifest */ |
| 2059 | int allowConflict = 0; /* Allow unresolve merge conflicts */ |
| @@ -2109,10 +2169,12 @@ | |
| 2109 | allowFork = find_option("allow-fork",0,0)!=0; |
| 2110 | if( find_option("override-lock",0,0)!=0 ) allowFork = 1; |
| 2111 | allowOlder = find_option("allow-older",0,0)!=0; |
| 2112 | noPrompt = find_option("no-prompt", 0, 0)!=0; |
| 2113 | noWarningFlag = find_option("no-warnings", 0, 0)!=0; |
| 2114 | sCiInfo.zBranch = find_option("branch","b",1); |
| 2115 | sCiInfo.zColor = find_option("bgcolor",0,1); |
| 2116 | sCiInfo.zBrClr = find_option("branchcolor",0,1); |
| 2117 | sCiInfo.closeFlag = find_option("close",0,0)!=0; |
| 2118 | sCiInfo.integrateFlag = find_option("integrate",0,0)!=0; |
| @@ -2340,10 +2402,21 @@ | |
| 2340 | fossil_fatal("cannot commit against a closed leaf"); |
| 2341 | } |
| 2342 | |
| 2343 | /* Always exit the loop on the second pass */ |
| 2344 | if( bRecheck ) break; |
| 2345 | |
| 2346 | /* Get the check-in comment. This might involve prompting the |
| 2347 | ** user for the check-in comment, in which case we should resync |
| 2348 | ** to renew the check-in lock and repeat the checks for conflicts. |
| 2349 | */ |
| 2350 | |
| 2351 | DDED src/hook.c |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -1323,10 +1323,66 @@ | |
| 1323 | ); |
| 1324 | } |
| 1325 | prompt_for_user_comment(pComment, &prompt); |
| 1326 | blob_reset(&prompt); |
| 1327 | } |
| 1328 | |
| 1329 | /* |
| 1330 | ** Prepare text that describes a pending commit and write it into |
| 1331 | ** a file at the root of the check-in. Return the name of that file. |
| 1332 | ** |
| 1333 | ** Space to hold the returned filename is obtained from fossil_malloc() |
| 1334 | ** and should be freed by the caller. The caller should also unlink |
| 1335 | ** the file when it is done. |
| 1336 | */ |
| 1337 | static char *prepare_commit_description_file( |
| 1338 | CheckinInfo *p, /* Information about this commit */ |
| 1339 | int parent_rid /* parent check-in */ |
| 1340 | ){ |
| 1341 | Blob *pDesc; |
| 1342 | char *zTags; |
| 1343 | char *zFilename; |
| 1344 | Blob desc; |
| 1345 | unsigned int r[2]; |
| 1346 | blob_init(&desc, 0, 0); |
| 1347 | pDesc = &desc; |
| 1348 | blob_appendf(pDesc, "checkout %s\n", g.zLocalRoot); |
| 1349 | blob_appendf(pDesc, "repository %s\n", g.zRepositoryName); |
| 1350 | blob_appendf(pDesc, "user %s\n", |
| 1351 | p->zUserOvrd ? p->zUserOvrd : login_name()); |
| 1352 | blob_appendf(pDesc, "branch %s\n", |
| 1353 | (p->zBranch && p->zBranch[0]) ? p->zBranch : "trunk"); |
| 1354 | zTags = info_tags_of_checkin(parent_rid, 1); |
| 1355 | if( zTags || p->azTag ){ |
| 1356 | blob_append(pDesc, "tags ", -1); |
| 1357 | if(zTags){ |
| 1358 | blob_appendf(pDesc, "%z%s", zTags, p->azTag ? ", " : ""); |
| 1359 | } |
| 1360 | if(p->azTag){ |
| 1361 | int i = 0; |
| 1362 | for( ; p->azTag[i]; ++i ){ |
| 1363 | blob_appendf(pDesc, "%s%s", p->azTag[i], |
| 1364 | p->azTag[i+1] ? ", " : ""); |
| 1365 | } |
| 1366 | } |
| 1367 | blob_appendf(pDesc, "\n"); |
| 1368 | } |
| 1369 | status_report(pDesc, C_DEFAULT | C_FATAL); |
| 1370 | if( g.markPrivate ){ |
| 1371 | blob_append(pDesc, "private-branch\n", -1); |
| 1372 | } |
| 1373 | if( p->integrateFlag ){ |
| 1374 | blob_append(pDesc, "integrate\n", -1); |
| 1375 | } |
| 1376 | sqlite3_randomness(sizeof(r), r); |
| 1377 | zFilename = mprintf("%scommit-description-%08x%08x.txt", |
| 1378 | g.zLocalRoot, r[0], r[1]); |
| 1379 | blob_write_to_file(pDesc, zFilename); |
| 1380 | blob_reset(pDesc); |
| 1381 | return zFilename; |
| 1382 | } |
| 1383 | |
| 1384 | |
| 1385 | /* |
| 1386 | ** Populate the Global.aCommitFile[] based on the command line arguments |
| 1387 | ** to a [commit] command. Global.aCommitFile is an array of integers |
| 1388 | ** sized at (N+1), where N is the number of arguments passed to [commit]. |
| @@ -2008,27 +2064,29 @@ | |
| 2064 | ** --baseline use a baseline manifest in the commit process |
| 2065 | ** --bgcolor COLOR apply COLOR to this one check-in only |
| 2066 | ** --branch NEW-BRANCH-NAME check in to this new branch |
| 2067 | ** --branchcolor COLOR apply given COLOR to the branch |
| 2068 | ** --close close the branch being committed |
| 2069 | ** --date-override DATETIME DATE to use instead of 'now' |
| 2070 | ** --delta use a delta manifest in the commit process |
| 2071 | ** --hash verify file status using hashing rather |
| 2072 | ** than relying on file mtimes |
| 2073 | ** --integrate close all merged-in branches |
| 2074 | ** -m|--comment COMMENT-TEXT use COMMENT-TEXT as commit comment |
| 2075 | ** -M|--message-file FILE read the commit comment from given file |
| 2076 | ** --mimetype MIMETYPE mimetype of check-in comment |
| 2077 | ** -n|--dry-run If given, display instead of run actions |
| 2078 | ** --no-prompt This option disables prompting the user for |
| 2079 | ** input and assumes an answer of 'No' for every |
| 2080 | ** question. |
| 2081 | ** --no-warnings omit all warnings about file contents |
| 2082 | ** --no-verify do not run before-commit hooks |
| 2083 | ** --nosign do not attempt to sign this commit with gpg |
| 2084 | ** --override-lock allow a check-in even though parent is locked |
| 2085 | ** --private do not sync changes and their descendants |
| 2086 | ** --tag TAG-NAME assign given tag TAG-NAME to the check-in |
| 2087 | ** --trace debug tracing. |
| 2088 | ** --user-override USER USER to use instead of the current default |
| 2089 | ** |
| 2090 | ** DATETIME may be "now" or "YYYY-MM-DDTHH:MM:SS.SSS". If in |
| 2091 | ** year-month-day form, it may be truncated, the "T" may be replaced by |
| 2092 | ** a space, and it may also name a timezone offset from UTC as "-HH:MM" |
| @@ -2050,10 +2108,12 @@ | |
| 2108 | int noSign = 0; /* True to omit signing the manifest using GPG */ |
| 2109 | int privateFlag = 0; /* True if the --private option is present */ |
| 2110 | int privateParent = 0; /* True if the parent check-in is private */ |
| 2111 | int isAMerge = 0; /* True if checking in a merge */ |
| 2112 | int noWarningFlag = 0; /* True if skipping all warnings */ |
| 2113 | int noVerify = 0; /* Do not run before-commit hooks */ |
| 2114 | int bTrace = 0; /* Debug tracing */ |
| 2115 | int noPrompt = 0; /* True if skipping all prompts */ |
| 2116 | int forceFlag = 0; /* Undocumented: Disables all checks */ |
| 2117 | int forceDelta = 0; /* Force a delta-manifest */ |
| 2118 | int forceBaseline = 0; /* Force a baseline-manifest */ |
| 2119 | int allowConflict = 0; /* Allow unresolve merge conflicts */ |
| @@ -2109,10 +2169,12 @@ | |
| 2169 | allowFork = find_option("allow-fork",0,0)!=0; |
| 2170 | if( find_option("override-lock",0,0)!=0 ) allowFork = 1; |
| 2171 | allowOlder = find_option("allow-older",0,0)!=0; |
| 2172 | noPrompt = find_option("no-prompt", 0, 0)!=0; |
| 2173 | noWarningFlag = find_option("no-warnings", 0, 0)!=0; |
| 2174 | noVerify = find_option("no-verify",0,0)!=0; |
| 2175 | bTrace = find_option("trace",0,0)!=0; |
| 2176 | sCiInfo.zBranch = find_option("branch","b",1); |
| 2177 | sCiInfo.zColor = find_option("bgcolor",0,1); |
| 2178 | sCiInfo.zBrClr = find_option("branchcolor",0,1); |
| 2179 | sCiInfo.closeFlag = find_option("close",0,0)!=0; |
| 2180 | sCiInfo.integrateFlag = find_option("integrate",0,0)!=0; |
| @@ -2340,10 +2402,21 @@ | |
| 2402 | fossil_fatal("cannot commit against a closed leaf"); |
| 2403 | } |
| 2404 | |
| 2405 | /* Always exit the loop on the second pass */ |
| 2406 | if( bRecheck ) break; |
| 2407 | |
| 2408 | /* Run before-commit hooks */ |
| 2409 | if( !noVerify ){ |
| 2410 | char *zAuxFile = prepare_commit_description_file(&sCiInfo,vid); |
| 2411 | int rc = hook_run("before-commit",zAuxFile,bTrace); |
| 2412 | file_delete(zAuxFile); |
| 2413 | fossil_free(zAuxFile); |
| 2414 | if( rc ){ |
| 2415 | fossil_fatal("Before-commit hook failed\n"); |
| 2416 | } |
| 2417 | } |
| 2418 | |
| 2419 | /* Get the check-in comment. This might involve prompting the |
| 2420 | ** user for the check-in comment, in which case we should resync |
| 2421 | ** to renew the check-in lock and repeat the checks for conflicts. |
| 2422 | */ |
| 2423 | |
| 2424 | DDED src/hook.c |
+1
| --- a/src/hook.c | ||
| +++ b/src/hook.c | ||
| @@ -0,0 +1 @@ | ||
| 1 | +et("hooks","[]", 0son_extract(jx.value,'$.seq')son_extract(jx.value,'$.cmd')son_extract(jx.value,'$.type')json_extract(value,'$[%d].cmd'), son_extract(value,'$[%d].type')=son_extract(jx.value,'$.cmd') " AND jsons |
| --- a/src/hook.c | |
| +++ b/src/hook.c | |
| @@ -0,0 +1 @@ | |
| --- a/src/hook.c | |
| +++ b/src/hook.c | |
| @@ -0,0 +1 @@ | |
| 1 | et("hooks","[]", 0son_extract(jx.value,'$.seq')son_extract(jx.value,'$.cmd')son_extract(jx.value,'$.type')json_extract(value,'$[%d].cmd'), son_extract(value,'$[%d].type')=son_extract(jx.value,'$.cmd') " AND jsons |
+12
| --- src/main.mk | ||
| +++ src/main.mk | ||
| @@ -66,10 +66,11 @@ | ||
| 66 | 66 | $(SRCDIR)/fuzz.c \ |
| 67 | 67 | $(SRCDIR)/glob.c \ |
| 68 | 68 | $(SRCDIR)/graph.c \ |
| 69 | 69 | $(SRCDIR)/gzip.c \ |
| 70 | 70 | $(SRCDIR)/hname.c \ |
| 71 | + $(SRCDIR)/hook.c \ | |
| 71 | 72 | $(SRCDIR)/http.c \ |
| 72 | 73 | $(SRCDIR)/http_socket.c \ |
| 73 | 74 | $(SRCDIR)/http_ssl.c \ |
| 74 | 75 | $(SRCDIR)/http_transport.c \ |
| 75 | 76 | $(SRCDIR)/import.c \ |
| @@ -313,10 +314,11 @@ | ||
| 313 | 314 | $(OBJDIR)/fuzz_.c \ |
| 314 | 315 | $(OBJDIR)/glob_.c \ |
| 315 | 316 | $(OBJDIR)/graph_.c \ |
| 316 | 317 | $(OBJDIR)/gzip_.c \ |
| 317 | 318 | $(OBJDIR)/hname_.c \ |
| 319 | + $(OBJDIR)/hook_.c \ | |
| 318 | 320 | $(OBJDIR)/http_.c \ |
| 319 | 321 | $(OBJDIR)/http_socket_.c \ |
| 320 | 322 | $(OBJDIR)/http_ssl_.c \ |
| 321 | 323 | $(OBJDIR)/http_transport_.c \ |
| 322 | 324 | $(OBJDIR)/import_.c \ |
| @@ -458,10 +460,11 @@ | ||
| 458 | 460 | $(OBJDIR)/fuzz.o \ |
| 459 | 461 | $(OBJDIR)/glob.o \ |
| 460 | 462 | $(OBJDIR)/graph.o \ |
| 461 | 463 | $(OBJDIR)/gzip.o \ |
| 462 | 464 | $(OBJDIR)/hname.o \ |
| 465 | + $(OBJDIR)/hook.o \ | |
| 463 | 466 | $(OBJDIR)/http.o \ |
| 464 | 467 | $(OBJDIR)/http_socket.o \ |
| 465 | 468 | $(OBJDIR)/http_ssl.o \ |
| 466 | 469 | $(OBJDIR)/http_transport.o \ |
| 467 | 470 | $(OBJDIR)/import.o \ |
| @@ -790,10 +793,11 @@ | ||
| 790 | 793 | $(OBJDIR)/fuzz_.c:$(OBJDIR)/fuzz.h \ |
| 791 | 794 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 792 | 795 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 793 | 796 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 794 | 797 | $(OBJDIR)/hname_.c:$(OBJDIR)/hname.h \ |
| 798 | + $(OBJDIR)/hook_.c:$(OBJDIR)/hook.h \ | |
| 795 | 799 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| 796 | 800 | $(OBJDIR)/http_socket_.c:$(OBJDIR)/http_socket.h \ |
| 797 | 801 | $(OBJDIR)/http_ssl_.c:$(OBJDIR)/http_ssl.h \ |
| 798 | 802 | $(OBJDIR)/http_transport_.c:$(OBJDIR)/http_transport.h \ |
| 799 | 803 | $(OBJDIR)/import_.c:$(OBJDIR)/import.h \ |
| @@ -1303,10 +1307,18 @@ | ||
| 1303 | 1307 | |
| 1304 | 1308 | $(OBJDIR)/hname.o: $(OBJDIR)/hname_.c $(OBJDIR)/hname.h $(SRCDIR)/config.h |
| 1305 | 1309 | $(XTCC) -o $(OBJDIR)/hname.o -c $(OBJDIR)/hname_.c |
| 1306 | 1310 | |
| 1307 | 1311 | $(OBJDIR)/hname.h: $(OBJDIR)/headers |
| 1312 | + | |
| 1313 | +$(OBJDIR)/hook_.c: $(SRCDIR)/hook.c $(OBJDIR)/translate | |
| 1314 | + $(OBJDIR)/translate $(SRCDIR)/hook.c >$@ | |
| 1315 | + | |
| 1316 | +$(OBJDIR)/hook.o: $(OBJDIR)/hook_.c $(OBJDIR)/hook.h $(SRCDIR)/config.h | |
| 1317 | + $(XTCC) -o $(OBJDIR)/hook.o -c $(OBJDIR)/hook_.c | |
| 1318 | + | |
| 1319 | +$(OBJDIR)/hook.h: $(OBJDIR)/headers | |
| 1308 | 1320 | |
| 1309 | 1321 | $(OBJDIR)/http_.c: $(SRCDIR)/http.c $(OBJDIR)/translate |
| 1310 | 1322 | $(OBJDIR)/translate $(SRCDIR)/http.c >$@ |
| 1311 | 1323 | |
| 1312 | 1324 | $(OBJDIR)/http.o: $(OBJDIR)/http_.c $(OBJDIR)/http.h $(SRCDIR)/config.h |
| 1313 | 1325 |
| --- src/main.mk | |
| +++ src/main.mk | |
| @@ -66,10 +66,11 @@ | |
| 66 | $(SRCDIR)/fuzz.c \ |
| 67 | $(SRCDIR)/glob.c \ |
| 68 | $(SRCDIR)/graph.c \ |
| 69 | $(SRCDIR)/gzip.c \ |
| 70 | $(SRCDIR)/hname.c \ |
| 71 | $(SRCDIR)/http.c \ |
| 72 | $(SRCDIR)/http_socket.c \ |
| 73 | $(SRCDIR)/http_ssl.c \ |
| 74 | $(SRCDIR)/http_transport.c \ |
| 75 | $(SRCDIR)/import.c \ |
| @@ -313,10 +314,11 @@ | |
| 313 | $(OBJDIR)/fuzz_.c \ |
| 314 | $(OBJDIR)/glob_.c \ |
| 315 | $(OBJDIR)/graph_.c \ |
| 316 | $(OBJDIR)/gzip_.c \ |
| 317 | $(OBJDIR)/hname_.c \ |
| 318 | $(OBJDIR)/http_.c \ |
| 319 | $(OBJDIR)/http_socket_.c \ |
| 320 | $(OBJDIR)/http_ssl_.c \ |
| 321 | $(OBJDIR)/http_transport_.c \ |
| 322 | $(OBJDIR)/import_.c \ |
| @@ -458,10 +460,11 @@ | |
| 458 | $(OBJDIR)/fuzz.o \ |
| 459 | $(OBJDIR)/glob.o \ |
| 460 | $(OBJDIR)/graph.o \ |
| 461 | $(OBJDIR)/gzip.o \ |
| 462 | $(OBJDIR)/hname.o \ |
| 463 | $(OBJDIR)/http.o \ |
| 464 | $(OBJDIR)/http_socket.o \ |
| 465 | $(OBJDIR)/http_ssl.o \ |
| 466 | $(OBJDIR)/http_transport.o \ |
| 467 | $(OBJDIR)/import.o \ |
| @@ -790,10 +793,11 @@ | |
| 790 | $(OBJDIR)/fuzz_.c:$(OBJDIR)/fuzz.h \ |
| 791 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 792 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 793 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 794 | $(OBJDIR)/hname_.c:$(OBJDIR)/hname.h \ |
| 795 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| 796 | $(OBJDIR)/http_socket_.c:$(OBJDIR)/http_socket.h \ |
| 797 | $(OBJDIR)/http_ssl_.c:$(OBJDIR)/http_ssl.h \ |
| 798 | $(OBJDIR)/http_transport_.c:$(OBJDIR)/http_transport.h \ |
| 799 | $(OBJDIR)/import_.c:$(OBJDIR)/import.h \ |
| @@ -1303,10 +1307,18 @@ | |
| 1303 | |
| 1304 | $(OBJDIR)/hname.o: $(OBJDIR)/hname_.c $(OBJDIR)/hname.h $(SRCDIR)/config.h |
| 1305 | $(XTCC) -o $(OBJDIR)/hname.o -c $(OBJDIR)/hname_.c |
| 1306 | |
| 1307 | $(OBJDIR)/hname.h: $(OBJDIR)/headers |
| 1308 | |
| 1309 | $(OBJDIR)/http_.c: $(SRCDIR)/http.c $(OBJDIR)/translate |
| 1310 | $(OBJDIR)/translate $(SRCDIR)/http.c >$@ |
| 1311 | |
| 1312 | $(OBJDIR)/http.o: $(OBJDIR)/http_.c $(OBJDIR)/http.h $(SRCDIR)/config.h |
| 1313 |
| --- src/main.mk | |
| +++ src/main.mk | |
| @@ -66,10 +66,11 @@ | |
| 66 | $(SRCDIR)/fuzz.c \ |
| 67 | $(SRCDIR)/glob.c \ |
| 68 | $(SRCDIR)/graph.c \ |
| 69 | $(SRCDIR)/gzip.c \ |
| 70 | $(SRCDIR)/hname.c \ |
| 71 | $(SRCDIR)/hook.c \ |
| 72 | $(SRCDIR)/http.c \ |
| 73 | $(SRCDIR)/http_socket.c \ |
| 74 | $(SRCDIR)/http_ssl.c \ |
| 75 | $(SRCDIR)/http_transport.c \ |
| 76 | $(SRCDIR)/import.c \ |
| @@ -313,10 +314,11 @@ | |
| 314 | $(OBJDIR)/fuzz_.c \ |
| 315 | $(OBJDIR)/glob_.c \ |
| 316 | $(OBJDIR)/graph_.c \ |
| 317 | $(OBJDIR)/gzip_.c \ |
| 318 | $(OBJDIR)/hname_.c \ |
| 319 | $(OBJDIR)/hook_.c \ |
| 320 | $(OBJDIR)/http_.c \ |
| 321 | $(OBJDIR)/http_socket_.c \ |
| 322 | $(OBJDIR)/http_ssl_.c \ |
| 323 | $(OBJDIR)/http_transport_.c \ |
| 324 | $(OBJDIR)/import_.c \ |
| @@ -458,10 +460,11 @@ | |
| 460 | $(OBJDIR)/fuzz.o \ |
| 461 | $(OBJDIR)/glob.o \ |
| 462 | $(OBJDIR)/graph.o \ |
| 463 | $(OBJDIR)/gzip.o \ |
| 464 | $(OBJDIR)/hname.o \ |
| 465 | $(OBJDIR)/hook.o \ |
| 466 | $(OBJDIR)/http.o \ |
| 467 | $(OBJDIR)/http_socket.o \ |
| 468 | $(OBJDIR)/http_ssl.o \ |
| 469 | $(OBJDIR)/http_transport.o \ |
| 470 | $(OBJDIR)/import.o \ |
| @@ -790,10 +793,11 @@ | |
| 793 | $(OBJDIR)/fuzz_.c:$(OBJDIR)/fuzz.h \ |
| 794 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 795 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 796 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 797 | $(OBJDIR)/hname_.c:$(OBJDIR)/hname.h \ |
| 798 | $(OBJDIR)/hook_.c:$(OBJDIR)/hook.h \ |
| 799 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| 800 | $(OBJDIR)/http_socket_.c:$(OBJDIR)/http_socket.h \ |
| 801 | $(OBJDIR)/http_ssl_.c:$(OBJDIR)/http_ssl.h \ |
| 802 | $(OBJDIR)/http_transport_.c:$(OBJDIR)/http_transport.h \ |
| 803 | $(OBJDIR)/import_.c:$(OBJDIR)/import.h \ |
| @@ -1303,10 +1307,18 @@ | |
| 1307 | |
| 1308 | $(OBJDIR)/hname.o: $(OBJDIR)/hname_.c $(OBJDIR)/hname.h $(SRCDIR)/config.h |
| 1309 | $(XTCC) -o $(OBJDIR)/hname.o -c $(OBJDIR)/hname_.c |
| 1310 | |
| 1311 | $(OBJDIR)/hname.h: $(OBJDIR)/headers |
| 1312 | |
| 1313 | $(OBJDIR)/hook_.c: $(SRCDIR)/hook.c $(OBJDIR)/translate |
| 1314 | $(OBJDIR)/translate $(SRCDIR)/hook.c >$@ |
| 1315 | |
| 1316 | $(OBJDIR)/hook.o: $(OBJDIR)/hook_.c $(OBJDIR)/hook.h $(SRCDIR)/config.h |
| 1317 | $(XTCC) -o $(OBJDIR)/hook.o -c $(OBJDIR)/hook_.c |
| 1318 | |
| 1319 | $(OBJDIR)/hook.h: $(OBJDIR)/headers |
| 1320 | |
| 1321 | $(OBJDIR)/http_.c: $(SRCDIR)/http.c $(OBJDIR)/translate |
| 1322 | $(OBJDIR)/translate $(SRCDIR)/http.c >$@ |
| 1323 | |
| 1324 | $(OBJDIR)/http.o: $(OBJDIR)/http_.c $(OBJDIR)/http.h $(SRCDIR)/config.h |
| 1325 |
+1
| --- src/makemake.tcl | ||
| +++ src/makemake.tcl | ||
| @@ -77,10 +77,11 @@ | ||
| 77 | 77 | fuzz |
| 78 | 78 | glob |
| 79 | 79 | graph |
| 80 | 80 | gzip |
| 81 | 81 | hname |
| 82 | + hook | |
| 82 | 83 | http |
| 83 | 84 | http_socket |
| 84 | 85 | http_transport |
| 85 | 86 | import |
| 86 | 87 | info |
| 87 | 88 |
| --- src/makemake.tcl | |
| +++ src/makemake.tcl | |
| @@ -77,10 +77,11 @@ | |
| 77 | fuzz |
| 78 | glob |
| 79 | graph |
| 80 | gzip |
| 81 | hname |
| 82 | http |
| 83 | http_socket |
| 84 | http_transport |
| 85 | import |
| 86 | info |
| 87 |
| --- src/makemake.tcl | |
| +++ src/makemake.tcl | |
| @@ -77,10 +77,11 @@ | |
| 77 | fuzz |
| 78 | glob |
| 79 | graph |
| 80 | gzip |
| 81 | hname |
| 82 | hook |
| 83 | http |
| 84 | http_socket |
| 85 | http_transport |
| 86 | import |
| 87 | info |
| 88 |
+1
| --- src/xfer.c | ||
| +++ src/xfer.c | ||
| @@ -1739,10 +1739,11 @@ | ||
| 1739 | 1739 | }else if( isPull ){ |
| 1740 | 1740 | create_cluster(); |
| 1741 | 1741 | send_unclustered(&xfer); |
| 1742 | 1742 | if( xfer.syncPrivate ) send_private(&xfer); |
| 1743 | 1743 | } |
| 1744 | + hook_expecting_more_artifacts(xfer.nGimmeSent?60:0); | |
| 1744 | 1745 | db_multi_exec("DROP TABLE onremote; DROP TABLE unk;"); |
| 1745 | 1746 | manifest_crosslink_end(MC_PERMIT_HOOKS); |
| 1746 | 1747 | |
| 1747 | 1748 | /* Send the server timestamp last, in case prior processing happened |
| 1748 | 1749 | ** to use up a significant fraction of our time window. |
| 1749 | 1750 |
| --- src/xfer.c | |
| +++ src/xfer.c | |
| @@ -1739,10 +1739,11 @@ | |
| 1739 | }else if( isPull ){ |
| 1740 | create_cluster(); |
| 1741 | send_unclustered(&xfer); |
| 1742 | if( xfer.syncPrivate ) send_private(&xfer); |
| 1743 | } |
| 1744 | db_multi_exec("DROP TABLE onremote; DROP TABLE unk;"); |
| 1745 | manifest_crosslink_end(MC_PERMIT_HOOKS); |
| 1746 | |
| 1747 | /* Send the server timestamp last, in case prior processing happened |
| 1748 | ** to use up a significant fraction of our time window. |
| 1749 |
| --- src/xfer.c | |
| +++ src/xfer.c | |
| @@ -1739,10 +1739,11 @@ | |
| 1739 | }else if( isPull ){ |
| 1740 | create_cluster(); |
| 1741 | send_unclustered(&xfer); |
| 1742 | if( xfer.syncPrivate ) send_private(&xfer); |
| 1743 | } |
| 1744 | hook_expecting_more_artifacts(xfer.nGimmeSent?60:0); |
| 1745 | db_multi_exec("DROP TABLE onremote; DROP TABLE unk;"); |
| 1746 | manifest_crosslink_end(MC_PERMIT_HOOKS); |
| 1747 | |
| 1748 | /* Send the server timestamp last, in case prior processing happened |
| 1749 | ** to use up a significant fraction of our time window. |
| 1750 |
+10
-4
| --- win/Makefile.dmc | ||
| +++ win/Makefile.dmc | ||
| @@ -28,13 +28,13 @@ | ||
| 28 | 28 | |
| 29 | 29 | SQLITE_OPTIONS = -DNDEBUG=1 -DSQLITE_DQS=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_TRUSTED_SCHEMA=0 |
| 30 | 30 | |
| 31 | 31 | SHELL_OPTIONS = -DNDEBUG=1 -DSQLITE_DQS=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_TRUSTED_SCHEMA=0 -Dmain=sqlite3_shell -DSQLITE_SHELL_IS_UTF8=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) -DSQLITE_SHELL_DBNAME_PROC=sqlcmd_get_dbname -DSQLITE_SHELL_INIT_PROC=sqlcmd_init_proc -Daccess=file_access -Dsystem=fossil_system -Dgetenv=fossil_getenv -Dfopen=fossil_fopen |
| 32 | 32 | |
| 33 | -SRC = add_.c ajax_.c alerts_.c allrepo_.c attach_.c backlink_.c backoffice_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c capabilities_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c cookies_.c db_.c delta_.c deltacmd_.c deltafunc_.c descendants_.c diff_.c diffcmd_.c dispatch_.c doc_.c encode_.c etag_.c event_.c export_.c extcgi_.c file_.c fileedit_.c finfo_.c foci_.c forum_.c fshell_.c fusefs_.c fuzz_.c glob_.c graph_.c gzip_.c hname_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c piechart_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c repolist_.c report_.c rss_.c schema_.c search_.c security_audit_.c setup_.c setupuser_.c sha1_.c sha1hard_.c sha3_.c shun_.c sitemap_.c skins_.c smtp_.c sqlcmd_.c stash_.c stat_.c statrep_.c style_.c sync_.c tag_.c tar_.c terminal_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c unversioned_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c webmail_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c | |
| 33 | +SRC = add_.c ajax_.c alerts_.c allrepo_.c attach_.c backlink_.c backoffice_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c capabilities_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c cookies_.c db_.c delta_.c deltacmd_.c deltafunc_.c descendants_.c diff_.c diffcmd_.c dispatch_.c doc_.c encode_.c etag_.c event_.c export_.c extcgi_.c file_.c fileedit_.c finfo_.c foci_.c forum_.c fshell_.c fusefs_.c fuzz_.c glob_.c graph_.c gzip_.c hname_.c hook_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c piechart_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c repolist_.c report_.c rss_.c schema_.c search_.c security_audit_.c setup_.c setupuser_.c sha1_.c sha1hard_.c sha3_.c shun_.c sitemap_.c skins_.c smtp_.c sqlcmd_.c stash_.c stat_.c statrep_.c style_.c sync_.c tag_.c tar_.c terminal_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c unversioned_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c webmail_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c | |
| 34 | 34 | |
| 35 | -OBJ = $(OBJDIR)\add$O $(OBJDIR)\ajax$O $(OBJDIR)\alerts$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\backlink$O $(OBJDIR)\backoffice$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\capabilities$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\cookies$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\deltafunc$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\dispatch$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\etag$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\extcgi$O $(OBJDIR)\file$O $(OBJDIR)\fileedit$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\forum$O $(OBJDIR)\fshell$O $(OBJDIR)\fusefs$O $(OBJDIR)\fuzz$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\hname$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\piechart$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\repolist$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\security_audit$O $(OBJDIR)\setup$O $(OBJDIR)\setupuser$O $(OBJDIR)\sha1$O $(OBJDIR)\sha1hard$O $(OBJDIR)\sha3$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\smtp$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\statrep$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\terminal$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\unversioned$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\webmail$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O | |
| 35 | +OBJ = $(OBJDIR)\add$O $(OBJDIR)\ajax$O $(OBJDIR)\alerts$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\backlink$O $(OBJDIR)\backoffice$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\capabilities$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\cookies$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\deltafunc$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\dispatch$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\etag$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\extcgi$O $(OBJDIR)\file$O $(OBJDIR)\fileedit$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\forum$O $(OBJDIR)\fshell$O $(OBJDIR)\fusefs$O $(OBJDIR)\fuzz$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\hname$O $(OBJDIR)\hook$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\piechart$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\repolist$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\security_audit$O $(OBJDIR)\setup$O $(OBJDIR)\setupuser$O $(OBJDIR)\sha1$O $(OBJDIR)\sha1hard$O $(OBJDIR)\sha3$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\smtp$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\statrep$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\terminal$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\unversioned$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\webmail$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O | |
| 36 | 36 | |
| 37 | 37 | |
| 38 | 38 | RC=$(DMDIR)\bin\rcc |
| 39 | 39 | RCFLAGS=-32 -w1 -I$(SRCDIR) /D__DMC__ |
| 40 | 40 | |
| @@ -49,11 +49,11 @@ | ||
| 49 | 49 | |
| 50 | 50 | $(OBJDIR)\fossil.res: $B\win\fossil.rc |
| 51 | 51 | $(RC) $(RCFLAGS) -o$@ $** |
| 52 | 52 | |
| 53 | 53 | $(OBJDIR)\link: $B\win\Makefile.dmc $(OBJDIR)\fossil.res |
| 54 | - +echo add ajax alerts allrepo attach backlink backoffice bag bisect blob branch browse builtin bundle cache capabilities captcha cgi checkin checkout clearsign clone comformat configure content cookies db delta deltacmd deltafunc descendants diff diffcmd dispatch doc encode etag event export extcgi file fileedit finfo foci forum fshell fusefs fuzz glob graph gzip hname http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path piechart pivot popen pqueue printf publish purge rebuild regexp repolist report rss schema search security_audit setup setupuser sha1 sha1hard sha3 shun sitemap skins smtp sqlcmd stash stat statrep style sync tag tar terminal th_main timeline tkt tktsetup undo unicode unversioned update url user utf8 util verify vfile webmail wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ | |
| 54 | + +echo add ajax alerts allrepo attach backlink backoffice bag bisect blob branch browse builtin bundle cache capabilities captcha cgi checkin checkout clearsign clone comformat configure content cookies db delta deltacmd deltafunc descendants diff diffcmd dispatch doc encode etag event export extcgi file fileedit finfo foci forum fshell fusefs fuzz glob graph gzip hname hook http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path piechart pivot popen pqueue printf publish purge rebuild regexp repolist report rss schema search security_audit setup setupuser sha1 sha1hard sha3 shun sitemap skins smtp sqlcmd stash stat statrep style sync tag tar terminal th_main timeline tkt tktsetup undo unicode unversioned update url user utf8 util verify vfile webmail wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ | |
| 55 | 55 | +echo fossil >> $@ |
| 56 | 56 | +echo fossil >> $@ |
| 57 | 57 | +echo $(LIBS) >> $@ |
| 58 | 58 | +echo. >> $@ |
| 59 | 59 | +echo fossil >> $@ |
| @@ -433,10 +433,16 @@ | ||
| 433 | 433 | $(OBJDIR)\hname$O : hname_.c hname.h |
| 434 | 434 | $(TCC) -o$@ -c hname_.c |
| 435 | 435 | |
| 436 | 436 | hname_.c : $(SRCDIR)\hname.c |
| 437 | 437 | +translate$E $** > $@ |
| 438 | + | |
| 439 | +$(OBJDIR)\hook$O : hook_.c hook.h | |
| 440 | + $(TCC) -o$@ -c hook_.c | |
| 441 | + | |
| 442 | +hook_.c : $(SRCDIR)\hook.c | |
| 443 | + +translate$E $** > $@ | |
| 438 | 444 | |
| 439 | 445 | $(OBJDIR)\http$O : http_.c http.h |
| 440 | 446 | $(TCC) -o$@ -c http_.c |
| 441 | 447 | |
| 442 | 448 | http_.c : $(SRCDIR)\http.c |
| @@ -981,7 +987,7 @@ | ||
| 981 | 987 | |
| 982 | 988 | zip_.c : $(SRCDIR)\zip.c |
| 983 | 989 | +translate$E $** > $@ |
| 984 | 990 | |
| 985 | 991 | headers: makeheaders$E page_index.h builtin_data.h VERSION.h |
| 986 | - +makeheaders$E add_.c:add.h ajax_.c:ajax.h alerts_.c:alerts.h allrepo_.c:allrepo.h attach_.c:attach.h backlink_.c:backlink.h backoffice_.c:backoffice.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h capabilities_.c:capabilities.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h cookies_.c:cookies.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h deltafunc_.c:deltafunc.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h dispatch_.c:dispatch.h doc_.c:doc.h encode_.c:encode.h etag_.c:etag.h event_.c:event.h export_.c:export.h extcgi_.c:extcgi.h file_.c:file.h fileedit_.c:fileedit.h finfo_.c:finfo.h foci_.c:foci.h forum_.c:forum.h fshell_.c:fshell.h fusefs_.c:fusefs.h fuzz_.c:fuzz.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h hname_.c:hname.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h piechart_.c:piechart.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h repolist_.c:repolist.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h security_audit_.c:security_audit.h setup_.c:setup.h setupuser_.c:setupuser.h sha1_.c:sha1.h sha1hard_.c:sha1hard.h sha3_.c:sha3.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h smtp_.c:smtp.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h statrep_.c:statrep.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h terminal_.c:terminal.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h unversioned_.c:unversioned.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h webmail_.c:webmail.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h | |
| 992 | + +makeheaders$E add_.c:add.h ajax_.c:ajax.h alerts_.c:alerts.h allrepo_.c:allrepo.h attach_.c:attach.h backlink_.c:backlink.h backoffice_.c:backoffice.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h capabilities_.c:capabilities.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h cookies_.c:cookies.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h deltafunc_.c:deltafunc.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h dispatch_.c:dispatch.h doc_.c:doc.h encode_.c:encode.h etag_.c:etag.h event_.c:event.h export_.c:export.h extcgi_.c:extcgi.h file_.c:file.h fileedit_.c:fileedit.h finfo_.c:finfo.h foci_.c:foci.h forum_.c:forum.h fshell_.c:fshell.h fusefs_.c:fusefs.h fuzz_.c:fuzz.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h hname_.c:hname.h hook_.c:hook.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h piechart_.c:piechart.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h repolist_.c:repolist.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h security_audit_.c:security_audit.h setup_.c:setup.h setupuser_.c:setupuser.h sha1_.c:sha1.h sha1hard_.c:sha1hard.h sha3_.c:sha3.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h smtp_.c:smtp.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h statrep_.c:statrep.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h terminal_.c:terminal.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h unversioned_.c:unversioned.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h webmail_.c:webmail.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h | |
| 987 | 993 | @copy /Y nul: headers |
| 988 | 994 |
| --- win/Makefile.dmc | |
| +++ win/Makefile.dmc | |
| @@ -28,13 +28,13 @@ | |
| 28 | |
| 29 | SQLITE_OPTIONS = -DNDEBUG=1 -DSQLITE_DQS=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_TRUSTED_SCHEMA=0 |
| 30 | |
| 31 | SHELL_OPTIONS = -DNDEBUG=1 -DSQLITE_DQS=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_TRUSTED_SCHEMA=0 -Dmain=sqlite3_shell -DSQLITE_SHELL_IS_UTF8=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) -DSQLITE_SHELL_DBNAME_PROC=sqlcmd_get_dbname -DSQLITE_SHELL_INIT_PROC=sqlcmd_init_proc -Daccess=file_access -Dsystem=fossil_system -Dgetenv=fossil_getenv -Dfopen=fossil_fopen |
| 32 | |
| 33 | SRC = add_.c ajax_.c alerts_.c allrepo_.c attach_.c backlink_.c backoffice_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c capabilities_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c cookies_.c db_.c delta_.c deltacmd_.c deltafunc_.c descendants_.c diff_.c diffcmd_.c dispatch_.c doc_.c encode_.c etag_.c event_.c export_.c extcgi_.c file_.c fileedit_.c finfo_.c foci_.c forum_.c fshell_.c fusefs_.c fuzz_.c glob_.c graph_.c gzip_.c hname_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c piechart_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c repolist_.c report_.c rss_.c schema_.c search_.c security_audit_.c setup_.c setupuser_.c sha1_.c sha1hard_.c sha3_.c shun_.c sitemap_.c skins_.c smtp_.c sqlcmd_.c stash_.c stat_.c statrep_.c style_.c sync_.c tag_.c tar_.c terminal_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c unversioned_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c webmail_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c |
| 34 | |
| 35 | OBJ = $(OBJDIR)\add$O $(OBJDIR)\ajax$O $(OBJDIR)\alerts$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\backlink$O $(OBJDIR)\backoffice$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\capabilities$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\cookies$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\deltafunc$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\dispatch$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\etag$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\extcgi$O $(OBJDIR)\file$O $(OBJDIR)\fileedit$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\forum$O $(OBJDIR)\fshell$O $(OBJDIR)\fusefs$O $(OBJDIR)\fuzz$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\hname$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\piechart$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\repolist$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\security_audit$O $(OBJDIR)\setup$O $(OBJDIR)\setupuser$O $(OBJDIR)\sha1$O $(OBJDIR)\sha1hard$O $(OBJDIR)\sha3$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\smtp$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\statrep$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\terminal$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\unversioned$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\webmail$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O |
| 36 | |
| 37 | |
| 38 | RC=$(DMDIR)\bin\rcc |
| 39 | RCFLAGS=-32 -w1 -I$(SRCDIR) /D__DMC__ |
| 40 | |
| @@ -49,11 +49,11 @@ | |
| 49 | |
| 50 | $(OBJDIR)\fossil.res: $B\win\fossil.rc |
| 51 | $(RC) $(RCFLAGS) -o$@ $** |
| 52 | |
| 53 | $(OBJDIR)\link: $B\win\Makefile.dmc $(OBJDIR)\fossil.res |
| 54 | +echo add ajax alerts allrepo attach backlink backoffice bag bisect blob branch browse builtin bundle cache capabilities captcha cgi checkin checkout clearsign clone comformat configure content cookies db delta deltacmd deltafunc descendants diff diffcmd dispatch doc encode etag event export extcgi file fileedit finfo foci forum fshell fusefs fuzz glob graph gzip hname http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path piechart pivot popen pqueue printf publish purge rebuild regexp repolist report rss schema search security_audit setup setupuser sha1 sha1hard sha3 shun sitemap skins smtp sqlcmd stash stat statrep style sync tag tar terminal th_main timeline tkt tktsetup undo unicode unversioned update url user utf8 util verify vfile webmail wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ |
| 55 | +echo fossil >> $@ |
| 56 | +echo fossil >> $@ |
| 57 | +echo $(LIBS) >> $@ |
| 58 | +echo. >> $@ |
| 59 | +echo fossil >> $@ |
| @@ -433,10 +433,16 @@ | |
| 433 | $(OBJDIR)\hname$O : hname_.c hname.h |
| 434 | $(TCC) -o$@ -c hname_.c |
| 435 | |
| 436 | hname_.c : $(SRCDIR)\hname.c |
| 437 | +translate$E $** > $@ |
| 438 | |
| 439 | $(OBJDIR)\http$O : http_.c http.h |
| 440 | $(TCC) -o$@ -c http_.c |
| 441 | |
| 442 | http_.c : $(SRCDIR)\http.c |
| @@ -981,7 +987,7 @@ | |
| 981 | |
| 982 | zip_.c : $(SRCDIR)\zip.c |
| 983 | +translate$E $** > $@ |
| 984 | |
| 985 | headers: makeheaders$E page_index.h builtin_data.h VERSION.h |
| 986 | +makeheaders$E add_.c:add.h ajax_.c:ajax.h alerts_.c:alerts.h allrepo_.c:allrepo.h attach_.c:attach.h backlink_.c:backlink.h backoffice_.c:backoffice.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h capabilities_.c:capabilities.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h cookies_.c:cookies.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h deltafunc_.c:deltafunc.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h dispatch_.c:dispatch.h doc_.c:doc.h encode_.c:encode.h etag_.c:etag.h event_.c:event.h export_.c:export.h extcgi_.c:extcgi.h file_.c:file.h fileedit_.c:fileedit.h finfo_.c:finfo.h foci_.c:foci.h forum_.c:forum.h fshell_.c:fshell.h fusefs_.c:fusefs.h fuzz_.c:fuzz.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h hname_.c:hname.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h piechart_.c:piechart.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h repolist_.c:repolist.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h security_audit_.c:security_audit.h setup_.c:setup.h setupuser_.c:setupuser.h sha1_.c:sha1.h sha1hard_.c:sha1hard.h sha3_.c:sha3.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h smtp_.c:smtp.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h statrep_.c:statrep.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h terminal_.c:terminal.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h unversioned_.c:unversioned.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h webmail_.c:webmail.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h |
| 987 | @copy /Y nul: headers |
| 988 |
| --- win/Makefile.dmc | |
| +++ win/Makefile.dmc | |
| @@ -28,13 +28,13 @@ | |
| 28 | |
| 29 | SQLITE_OPTIONS = -DNDEBUG=1 -DSQLITE_DQS=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_TRUSTED_SCHEMA=0 |
| 30 | |
| 31 | SHELL_OPTIONS = -DNDEBUG=1 -DSQLITE_DQS=0 -DSQLITE_THREADSAFE=0 -DSQLITE_DEFAULT_MEMSTATUS=0 -DSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 -DSQLITE_LIKE_DOESNT_MATCH_BLOBS -DSQLITE_OMIT_DECLTYPE -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_SHARED_CACHE -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_MAX_EXPR_DEPTH=0 -DSQLITE_USE_ALLOCA -DSQLITE_ENABLE_LOCKING_STYLE=0 -DSQLITE_DEFAULT_FILE_FORMAT=4 -DSQLITE_ENABLE_EXPLAIN_COMMENTS -DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_STMTVTAB -DSQLITE_HAVE_ZLIB -DSQLITE_INTROSPECTION_PRAGMAS -DSQLITE_ENABLE_DBPAGE_VTAB -DSQLITE_TRUSTED_SCHEMA=0 -Dmain=sqlite3_shell -DSQLITE_SHELL_IS_UTF8=1 -DSQLITE_OMIT_LOAD_EXTENSION=1 -DUSE_SYSTEM_SQLITE=$(USE_SYSTEM_SQLITE) -DSQLITE_SHELL_DBNAME_PROC=sqlcmd_get_dbname -DSQLITE_SHELL_INIT_PROC=sqlcmd_init_proc -Daccess=file_access -Dsystem=fossil_system -Dgetenv=fossil_getenv -Dfopen=fossil_fopen |
| 32 | |
| 33 | SRC = add_.c ajax_.c alerts_.c allrepo_.c attach_.c backlink_.c backoffice_.c bag_.c bisect_.c blob_.c branch_.c browse_.c builtin_.c bundle_.c cache_.c capabilities_.c captcha_.c cgi_.c checkin_.c checkout_.c clearsign_.c clone_.c comformat_.c configure_.c content_.c cookies_.c db_.c delta_.c deltacmd_.c deltafunc_.c descendants_.c diff_.c diffcmd_.c dispatch_.c doc_.c encode_.c etag_.c event_.c export_.c extcgi_.c file_.c fileedit_.c finfo_.c foci_.c forum_.c fshell_.c fusefs_.c fuzz_.c glob_.c graph_.c gzip_.c hname_.c hook_.c http_.c http_socket_.c http_ssl_.c http_transport_.c import_.c info_.c json_.c json_artifact_.c json_branch_.c json_config_.c json_diff_.c json_dir_.c json_finfo_.c json_login_.c json_query_.c json_report_.c json_status_.c json_tag_.c json_timeline_.c json_user_.c json_wiki_.c leaf_.c loadctrl_.c login_.c lookslike_.c main_.c manifest_.c markdown_.c markdown_html_.c md5_.c merge_.c merge3_.c moderate_.c name_.c path_.c piechart_.c pivot_.c popen_.c pqueue_.c printf_.c publish_.c purge_.c rebuild_.c regexp_.c repolist_.c report_.c rss_.c schema_.c search_.c security_audit_.c setup_.c setupuser_.c sha1_.c sha1hard_.c sha3_.c shun_.c sitemap_.c skins_.c smtp_.c sqlcmd_.c stash_.c stat_.c statrep_.c style_.c sync_.c tag_.c tar_.c terminal_.c th_main_.c timeline_.c tkt_.c tktsetup_.c undo_.c unicode_.c unversioned_.c update_.c url_.c user_.c utf8_.c util_.c verify_.c vfile_.c webmail_.c wiki_.c wikiformat_.c winfile_.c winhttp_.c wysiwyg_.c xfer_.c xfersetup_.c zip_.c |
| 34 | |
| 35 | OBJ = $(OBJDIR)\add$O $(OBJDIR)\ajax$O $(OBJDIR)\alerts$O $(OBJDIR)\allrepo$O $(OBJDIR)\attach$O $(OBJDIR)\backlink$O $(OBJDIR)\backoffice$O $(OBJDIR)\bag$O $(OBJDIR)\bisect$O $(OBJDIR)\blob$O $(OBJDIR)\branch$O $(OBJDIR)\browse$O $(OBJDIR)\builtin$O $(OBJDIR)\bundle$O $(OBJDIR)\cache$O $(OBJDIR)\capabilities$O $(OBJDIR)\captcha$O $(OBJDIR)\cgi$O $(OBJDIR)\checkin$O $(OBJDIR)\checkout$O $(OBJDIR)\clearsign$O $(OBJDIR)\clone$O $(OBJDIR)\comformat$O $(OBJDIR)\configure$O $(OBJDIR)\content$O $(OBJDIR)\cookies$O $(OBJDIR)\db$O $(OBJDIR)\delta$O $(OBJDIR)\deltacmd$O $(OBJDIR)\deltafunc$O $(OBJDIR)\descendants$O $(OBJDIR)\diff$O $(OBJDIR)\diffcmd$O $(OBJDIR)\dispatch$O $(OBJDIR)\doc$O $(OBJDIR)\encode$O $(OBJDIR)\etag$O $(OBJDIR)\event$O $(OBJDIR)\export$O $(OBJDIR)\extcgi$O $(OBJDIR)\file$O $(OBJDIR)\fileedit$O $(OBJDIR)\finfo$O $(OBJDIR)\foci$O $(OBJDIR)\forum$O $(OBJDIR)\fshell$O $(OBJDIR)\fusefs$O $(OBJDIR)\fuzz$O $(OBJDIR)\glob$O $(OBJDIR)\graph$O $(OBJDIR)\gzip$O $(OBJDIR)\hname$O $(OBJDIR)\hook$O $(OBJDIR)\http$O $(OBJDIR)\http_socket$O $(OBJDIR)\http_ssl$O $(OBJDIR)\http_transport$O $(OBJDIR)\import$O $(OBJDIR)\info$O $(OBJDIR)\json$O $(OBJDIR)\json_artifact$O $(OBJDIR)\json_branch$O $(OBJDIR)\json_config$O $(OBJDIR)\json_diff$O $(OBJDIR)\json_dir$O $(OBJDIR)\json_finfo$O $(OBJDIR)\json_login$O $(OBJDIR)\json_query$O $(OBJDIR)\json_report$O $(OBJDIR)\json_status$O $(OBJDIR)\json_tag$O $(OBJDIR)\json_timeline$O $(OBJDIR)\json_user$O $(OBJDIR)\json_wiki$O $(OBJDIR)\leaf$O $(OBJDIR)\loadctrl$O $(OBJDIR)\login$O $(OBJDIR)\lookslike$O $(OBJDIR)\main$O $(OBJDIR)\manifest$O $(OBJDIR)\markdown$O $(OBJDIR)\markdown_html$O $(OBJDIR)\md5$O $(OBJDIR)\merge$O $(OBJDIR)\merge3$O $(OBJDIR)\moderate$O $(OBJDIR)\name$O $(OBJDIR)\path$O $(OBJDIR)\piechart$O $(OBJDIR)\pivot$O $(OBJDIR)\popen$O $(OBJDIR)\pqueue$O $(OBJDIR)\printf$O $(OBJDIR)\publish$O $(OBJDIR)\purge$O $(OBJDIR)\rebuild$O $(OBJDIR)\regexp$O $(OBJDIR)\repolist$O $(OBJDIR)\report$O $(OBJDIR)\rss$O $(OBJDIR)\schema$O $(OBJDIR)\search$O $(OBJDIR)\security_audit$O $(OBJDIR)\setup$O $(OBJDIR)\setupuser$O $(OBJDIR)\sha1$O $(OBJDIR)\sha1hard$O $(OBJDIR)\sha3$O $(OBJDIR)\shun$O $(OBJDIR)\sitemap$O $(OBJDIR)\skins$O $(OBJDIR)\smtp$O $(OBJDIR)\sqlcmd$O $(OBJDIR)\stash$O $(OBJDIR)\stat$O $(OBJDIR)\statrep$O $(OBJDIR)\style$O $(OBJDIR)\sync$O $(OBJDIR)\tag$O $(OBJDIR)\tar$O $(OBJDIR)\terminal$O $(OBJDIR)\th_main$O $(OBJDIR)\timeline$O $(OBJDIR)\tkt$O $(OBJDIR)\tktsetup$O $(OBJDIR)\undo$O $(OBJDIR)\unicode$O $(OBJDIR)\unversioned$O $(OBJDIR)\update$O $(OBJDIR)\url$O $(OBJDIR)\user$O $(OBJDIR)\utf8$O $(OBJDIR)\util$O $(OBJDIR)\verify$O $(OBJDIR)\vfile$O $(OBJDIR)\webmail$O $(OBJDIR)\wiki$O $(OBJDIR)\wikiformat$O $(OBJDIR)\winfile$O $(OBJDIR)\winhttp$O $(OBJDIR)\wysiwyg$O $(OBJDIR)\xfer$O $(OBJDIR)\xfersetup$O $(OBJDIR)\zip$O $(OBJDIR)\shell$O $(OBJDIR)\sqlite3$O $(OBJDIR)\th$O $(OBJDIR)\th_lang$O |
| 36 | |
| 37 | |
| 38 | RC=$(DMDIR)\bin\rcc |
| 39 | RCFLAGS=-32 -w1 -I$(SRCDIR) /D__DMC__ |
| 40 | |
| @@ -49,11 +49,11 @@ | |
| 49 | |
| 50 | $(OBJDIR)\fossil.res: $B\win\fossil.rc |
| 51 | $(RC) $(RCFLAGS) -o$@ $** |
| 52 | |
| 53 | $(OBJDIR)\link: $B\win\Makefile.dmc $(OBJDIR)\fossil.res |
| 54 | +echo add ajax alerts allrepo attach backlink backoffice bag bisect blob branch browse builtin bundle cache capabilities captcha cgi checkin checkout clearsign clone comformat configure content cookies db delta deltacmd deltafunc descendants diff diffcmd dispatch doc encode etag event export extcgi file fileedit finfo foci forum fshell fusefs fuzz glob graph gzip hname hook http http_socket http_ssl http_transport import info json json_artifact json_branch json_config json_diff json_dir json_finfo json_login json_query json_report json_status json_tag json_timeline json_user json_wiki leaf loadctrl login lookslike main manifest markdown markdown_html md5 merge merge3 moderate name path piechart pivot popen pqueue printf publish purge rebuild regexp repolist report rss schema search security_audit setup setupuser sha1 sha1hard sha3 shun sitemap skins smtp sqlcmd stash stat statrep style sync tag tar terminal th_main timeline tkt tktsetup undo unicode unversioned update url user utf8 util verify vfile webmail wiki wikiformat winfile winhttp wysiwyg xfer xfersetup zip shell sqlite3 th th_lang > $@ |
| 55 | +echo fossil >> $@ |
| 56 | +echo fossil >> $@ |
| 57 | +echo $(LIBS) >> $@ |
| 58 | +echo. >> $@ |
| 59 | +echo fossil >> $@ |
| @@ -433,10 +433,16 @@ | |
| 433 | $(OBJDIR)\hname$O : hname_.c hname.h |
| 434 | $(TCC) -o$@ -c hname_.c |
| 435 | |
| 436 | hname_.c : $(SRCDIR)\hname.c |
| 437 | +translate$E $** > $@ |
| 438 | |
| 439 | $(OBJDIR)\hook$O : hook_.c hook.h |
| 440 | $(TCC) -o$@ -c hook_.c |
| 441 | |
| 442 | hook_.c : $(SRCDIR)\hook.c |
| 443 | +translate$E $** > $@ |
| 444 | |
| 445 | $(OBJDIR)\http$O : http_.c http.h |
| 446 | $(TCC) -o$@ -c http_.c |
| 447 | |
| 448 | http_.c : $(SRCDIR)\http.c |
| @@ -981,7 +987,7 @@ | |
| 987 | |
| 988 | zip_.c : $(SRCDIR)\zip.c |
| 989 | +translate$E $** > $@ |
| 990 | |
| 991 | headers: makeheaders$E page_index.h builtin_data.h VERSION.h |
| 992 | +makeheaders$E add_.c:add.h ajax_.c:ajax.h alerts_.c:alerts.h allrepo_.c:allrepo.h attach_.c:attach.h backlink_.c:backlink.h backoffice_.c:backoffice.h bag_.c:bag.h bisect_.c:bisect.h blob_.c:blob.h branch_.c:branch.h browse_.c:browse.h builtin_.c:builtin.h bundle_.c:bundle.h cache_.c:cache.h capabilities_.c:capabilities.h captcha_.c:captcha.h cgi_.c:cgi.h checkin_.c:checkin.h checkout_.c:checkout.h clearsign_.c:clearsign.h clone_.c:clone.h comformat_.c:comformat.h configure_.c:configure.h content_.c:content.h cookies_.c:cookies.h db_.c:db.h delta_.c:delta.h deltacmd_.c:deltacmd.h deltafunc_.c:deltafunc.h descendants_.c:descendants.h diff_.c:diff.h diffcmd_.c:diffcmd.h dispatch_.c:dispatch.h doc_.c:doc.h encode_.c:encode.h etag_.c:etag.h event_.c:event.h export_.c:export.h extcgi_.c:extcgi.h file_.c:file.h fileedit_.c:fileedit.h finfo_.c:finfo.h foci_.c:foci.h forum_.c:forum.h fshell_.c:fshell.h fusefs_.c:fusefs.h fuzz_.c:fuzz.h glob_.c:glob.h graph_.c:graph.h gzip_.c:gzip.h hname_.c:hname.h hook_.c:hook.h http_.c:http.h http_socket_.c:http_socket.h http_ssl_.c:http_ssl.h http_transport_.c:http_transport.h import_.c:import.h info_.c:info.h json_.c:json.h json_artifact_.c:json_artifact.h json_branch_.c:json_branch.h json_config_.c:json_config.h json_diff_.c:json_diff.h json_dir_.c:json_dir.h json_finfo_.c:json_finfo.h json_login_.c:json_login.h json_query_.c:json_query.h json_report_.c:json_report.h json_status_.c:json_status.h json_tag_.c:json_tag.h json_timeline_.c:json_timeline.h json_user_.c:json_user.h json_wiki_.c:json_wiki.h leaf_.c:leaf.h loadctrl_.c:loadctrl.h login_.c:login.h lookslike_.c:lookslike.h main_.c:main.h manifest_.c:manifest.h markdown_.c:markdown.h markdown_html_.c:markdown_html.h md5_.c:md5.h merge_.c:merge.h merge3_.c:merge3.h moderate_.c:moderate.h name_.c:name.h path_.c:path.h piechart_.c:piechart.h pivot_.c:pivot.h popen_.c:popen.h pqueue_.c:pqueue.h printf_.c:printf.h publish_.c:publish.h purge_.c:purge.h rebuild_.c:rebuild.h regexp_.c:regexp.h repolist_.c:repolist.h report_.c:report.h rss_.c:rss.h schema_.c:schema.h search_.c:search.h security_audit_.c:security_audit.h setup_.c:setup.h setupuser_.c:setupuser.h sha1_.c:sha1.h sha1hard_.c:sha1hard.h sha3_.c:sha3.h shun_.c:shun.h sitemap_.c:sitemap.h skins_.c:skins.h smtp_.c:smtp.h sqlcmd_.c:sqlcmd.h stash_.c:stash.h stat_.c:stat.h statrep_.c:statrep.h style_.c:style.h sync_.c:sync.h tag_.c:tag.h tar_.c:tar.h terminal_.c:terminal.h th_main_.c:th_main.h timeline_.c:timeline.h tkt_.c:tkt.h tktsetup_.c:tktsetup.h undo_.c:undo.h unicode_.c:unicode.h unversioned_.c:unversioned.h update_.c:update.h url_.c:url.h user_.c:user.h utf8_.c:utf8.h util_.c:util.h verify_.c:verify.h vfile_.c:vfile.h webmail_.c:webmail.h wiki_.c:wiki.h wikiformat_.c:wikiformat.h winfile_.c:winfile.h winhttp_.c:winhttp.h wysiwyg_.c:wysiwyg.h xfer_.c:xfer.h xfersetup_.c:xfersetup.h zip_.c:zip.h $(SRCDIR)\sqlite3.h $(SRCDIR)\th.h VERSION.h $(SRCDIR)\cson_amalgamation.h |
| 993 | @copy /Y nul: headers |
| 994 |
+12
| --- win/Makefile.mingw | ||
| +++ win/Makefile.mingw | ||
| @@ -478,10 +478,11 @@ | ||
| 478 | 478 | $(SRCDIR)/fuzz.c \ |
| 479 | 479 | $(SRCDIR)/glob.c \ |
| 480 | 480 | $(SRCDIR)/graph.c \ |
| 481 | 481 | $(SRCDIR)/gzip.c \ |
| 482 | 482 | $(SRCDIR)/hname.c \ |
| 483 | + $(SRCDIR)/hook.c \ | |
| 483 | 484 | $(SRCDIR)/http.c \ |
| 484 | 485 | $(SRCDIR)/http_socket.c \ |
| 485 | 486 | $(SRCDIR)/http_ssl.c \ |
| 486 | 487 | $(SRCDIR)/http_transport.c \ |
| 487 | 488 | $(SRCDIR)/import.c \ |
| @@ -725,10 +726,11 @@ | ||
| 725 | 726 | $(OBJDIR)/fuzz_.c \ |
| 726 | 727 | $(OBJDIR)/glob_.c \ |
| 727 | 728 | $(OBJDIR)/graph_.c \ |
| 728 | 729 | $(OBJDIR)/gzip_.c \ |
| 729 | 730 | $(OBJDIR)/hname_.c \ |
| 731 | + $(OBJDIR)/hook_.c \ | |
| 730 | 732 | $(OBJDIR)/http_.c \ |
| 731 | 733 | $(OBJDIR)/http_socket_.c \ |
| 732 | 734 | $(OBJDIR)/http_ssl_.c \ |
| 733 | 735 | $(OBJDIR)/http_transport_.c \ |
| 734 | 736 | $(OBJDIR)/import_.c \ |
| @@ -870,10 +872,11 @@ | ||
| 870 | 872 | $(OBJDIR)/fuzz.o \ |
| 871 | 873 | $(OBJDIR)/glob.o \ |
| 872 | 874 | $(OBJDIR)/graph.o \ |
| 873 | 875 | $(OBJDIR)/gzip.o \ |
| 874 | 876 | $(OBJDIR)/hname.o \ |
| 877 | + $(OBJDIR)/hook.o \ | |
| 875 | 878 | $(OBJDIR)/http.o \ |
| 876 | 879 | $(OBJDIR)/http_socket.o \ |
| 877 | 880 | $(OBJDIR)/http_ssl.o \ |
| 878 | 881 | $(OBJDIR)/http_transport.o \ |
| 879 | 882 | $(OBJDIR)/import.o \ |
| @@ -1227,10 +1230,11 @@ | ||
| 1227 | 1230 | $(OBJDIR)/fuzz_.c:$(OBJDIR)/fuzz.h \ |
| 1228 | 1231 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 1229 | 1232 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 1230 | 1233 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 1231 | 1234 | $(OBJDIR)/hname_.c:$(OBJDIR)/hname.h \ |
| 1235 | + $(OBJDIR)/hook_.c:$(OBJDIR)/hook.h \ | |
| 1232 | 1236 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| 1233 | 1237 | $(OBJDIR)/http_socket_.c:$(OBJDIR)/http_socket.h \ |
| 1234 | 1238 | $(OBJDIR)/http_ssl_.c:$(OBJDIR)/http_ssl.h \ |
| 1235 | 1239 | $(OBJDIR)/http_transport_.c:$(OBJDIR)/http_transport.h \ |
| 1236 | 1240 | $(OBJDIR)/import_.c:$(OBJDIR)/import.h \ |
| @@ -1742,10 +1746,18 @@ | ||
| 1742 | 1746 | |
| 1743 | 1747 | $(OBJDIR)/hname.o: $(OBJDIR)/hname_.c $(OBJDIR)/hname.h $(SRCDIR)/config.h |
| 1744 | 1748 | $(XTCC) -o $(OBJDIR)/hname.o -c $(OBJDIR)/hname_.c |
| 1745 | 1749 | |
| 1746 | 1750 | $(OBJDIR)/hname.h: $(OBJDIR)/headers |
| 1751 | + | |
| 1752 | +$(OBJDIR)/hook_.c: $(SRCDIR)/hook.c $(TRANSLATE) | |
| 1753 | + $(TRANSLATE) $(SRCDIR)/hook.c >$@ | |
| 1754 | + | |
| 1755 | +$(OBJDIR)/hook.o: $(OBJDIR)/hook_.c $(OBJDIR)/hook.h $(SRCDIR)/config.h | |
| 1756 | + $(XTCC) -o $(OBJDIR)/hook.o -c $(OBJDIR)/hook_.c | |
| 1757 | + | |
| 1758 | +$(OBJDIR)/hook.h: $(OBJDIR)/headers | |
| 1747 | 1759 | |
| 1748 | 1760 | $(OBJDIR)/http_.c: $(SRCDIR)/http.c $(TRANSLATE) |
| 1749 | 1761 | $(TRANSLATE) $(SRCDIR)/http.c >$@ |
| 1750 | 1762 | |
| 1751 | 1763 | $(OBJDIR)/http.o: $(OBJDIR)/http_.c $(OBJDIR)/http.h $(SRCDIR)/config.h |
| 1752 | 1764 |
| --- win/Makefile.mingw | |
| +++ win/Makefile.mingw | |
| @@ -478,10 +478,11 @@ | |
| 478 | $(SRCDIR)/fuzz.c \ |
| 479 | $(SRCDIR)/glob.c \ |
| 480 | $(SRCDIR)/graph.c \ |
| 481 | $(SRCDIR)/gzip.c \ |
| 482 | $(SRCDIR)/hname.c \ |
| 483 | $(SRCDIR)/http.c \ |
| 484 | $(SRCDIR)/http_socket.c \ |
| 485 | $(SRCDIR)/http_ssl.c \ |
| 486 | $(SRCDIR)/http_transport.c \ |
| 487 | $(SRCDIR)/import.c \ |
| @@ -725,10 +726,11 @@ | |
| 725 | $(OBJDIR)/fuzz_.c \ |
| 726 | $(OBJDIR)/glob_.c \ |
| 727 | $(OBJDIR)/graph_.c \ |
| 728 | $(OBJDIR)/gzip_.c \ |
| 729 | $(OBJDIR)/hname_.c \ |
| 730 | $(OBJDIR)/http_.c \ |
| 731 | $(OBJDIR)/http_socket_.c \ |
| 732 | $(OBJDIR)/http_ssl_.c \ |
| 733 | $(OBJDIR)/http_transport_.c \ |
| 734 | $(OBJDIR)/import_.c \ |
| @@ -870,10 +872,11 @@ | |
| 870 | $(OBJDIR)/fuzz.o \ |
| 871 | $(OBJDIR)/glob.o \ |
| 872 | $(OBJDIR)/graph.o \ |
| 873 | $(OBJDIR)/gzip.o \ |
| 874 | $(OBJDIR)/hname.o \ |
| 875 | $(OBJDIR)/http.o \ |
| 876 | $(OBJDIR)/http_socket.o \ |
| 877 | $(OBJDIR)/http_ssl.o \ |
| 878 | $(OBJDIR)/http_transport.o \ |
| 879 | $(OBJDIR)/import.o \ |
| @@ -1227,10 +1230,11 @@ | |
| 1227 | $(OBJDIR)/fuzz_.c:$(OBJDIR)/fuzz.h \ |
| 1228 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 1229 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 1230 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 1231 | $(OBJDIR)/hname_.c:$(OBJDIR)/hname.h \ |
| 1232 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| 1233 | $(OBJDIR)/http_socket_.c:$(OBJDIR)/http_socket.h \ |
| 1234 | $(OBJDIR)/http_ssl_.c:$(OBJDIR)/http_ssl.h \ |
| 1235 | $(OBJDIR)/http_transport_.c:$(OBJDIR)/http_transport.h \ |
| 1236 | $(OBJDIR)/import_.c:$(OBJDIR)/import.h \ |
| @@ -1742,10 +1746,18 @@ | |
| 1742 | |
| 1743 | $(OBJDIR)/hname.o: $(OBJDIR)/hname_.c $(OBJDIR)/hname.h $(SRCDIR)/config.h |
| 1744 | $(XTCC) -o $(OBJDIR)/hname.o -c $(OBJDIR)/hname_.c |
| 1745 | |
| 1746 | $(OBJDIR)/hname.h: $(OBJDIR)/headers |
| 1747 | |
| 1748 | $(OBJDIR)/http_.c: $(SRCDIR)/http.c $(TRANSLATE) |
| 1749 | $(TRANSLATE) $(SRCDIR)/http.c >$@ |
| 1750 | |
| 1751 | $(OBJDIR)/http.o: $(OBJDIR)/http_.c $(OBJDIR)/http.h $(SRCDIR)/config.h |
| 1752 |
| --- win/Makefile.mingw | |
| +++ win/Makefile.mingw | |
| @@ -478,10 +478,11 @@ | |
| 478 | $(SRCDIR)/fuzz.c \ |
| 479 | $(SRCDIR)/glob.c \ |
| 480 | $(SRCDIR)/graph.c \ |
| 481 | $(SRCDIR)/gzip.c \ |
| 482 | $(SRCDIR)/hname.c \ |
| 483 | $(SRCDIR)/hook.c \ |
| 484 | $(SRCDIR)/http.c \ |
| 485 | $(SRCDIR)/http_socket.c \ |
| 486 | $(SRCDIR)/http_ssl.c \ |
| 487 | $(SRCDIR)/http_transport.c \ |
| 488 | $(SRCDIR)/import.c \ |
| @@ -725,10 +726,11 @@ | |
| 726 | $(OBJDIR)/fuzz_.c \ |
| 727 | $(OBJDIR)/glob_.c \ |
| 728 | $(OBJDIR)/graph_.c \ |
| 729 | $(OBJDIR)/gzip_.c \ |
| 730 | $(OBJDIR)/hname_.c \ |
| 731 | $(OBJDIR)/hook_.c \ |
| 732 | $(OBJDIR)/http_.c \ |
| 733 | $(OBJDIR)/http_socket_.c \ |
| 734 | $(OBJDIR)/http_ssl_.c \ |
| 735 | $(OBJDIR)/http_transport_.c \ |
| 736 | $(OBJDIR)/import_.c \ |
| @@ -870,10 +872,11 @@ | |
| 872 | $(OBJDIR)/fuzz.o \ |
| 873 | $(OBJDIR)/glob.o \ |
| 874 | $(OBJDIR)/graph.o \ |
| 875 | $(OBJDIR)/gzip.o \ |
| 876 | $(OBJDIR)/hname.o \ |
| 877 | $(OBJDIR)/hook.o \ |
| 878 | $(OBJDIR)/http.o \ |
| 879 | $(OBJDIR)/http_socket.o \ |
| 880 | $(OBJDIR)/http_ssl.o \ |
| 881 | $(OBJDIR)/http_transport.o \ |
| 882 | $(OBJDIR)/import.o \ |
| @@ -1227,10 +1230,11 @@ | |
| 1230 | $(OBJDIR)/fuzz_.c:$(OBJDIR)/fuzz.h \ |
| 1231 | $(OBJDIR)/glob_.c:$(OBJDIR)/glob.h \ |
| 1232 | $(OBJDIR)/graph_.c:$(OBJDIR)/graph.h \ |
| 1233 | $(OBJDIR)/gzip_.c:$(OBJDIR)/gzip.h \ |
| 1234 | $(OBJDIR)/hname_.c:$(OBJDIR)/hname.h \ |
| 1235 | $(OBJDIR)/hook_.c:$(OBJDIR)/hook.h \ |
| 1236 | $(OBJDIR)/http_.c:$(OBJDIR)/http.h \ |
| 1237 | $(OBJDIR)/http_socket_.c:$(OBJDIR)/http_socket.h \ |
| 1238 | $(OBJDIR)/http_ssl_.c:$(OBJDIR)/http_ssl.h \ |
| 1239 | $(OBJDIR)/http_transport_.c:$(OBJDIR)/http_transport.h \ |
| 1240 | $(OBJDIR)/import_.c:$(OBJDIR)/import.h \ |
| @@ -1742,10 +1746,18 @@ | |
| 1746 | |
| 1747 | $(OBJDIR)/hname.o: $(OBJDIR)/hname_.c $(OBJDIR)/hname.h $(SRCDIR)/config.h |
| 1748 | $(XTCC) -o $(OBJDIR)/hname.o -c $(OBJDIR)/hname_.c |
| 1749 | |
| 1750 | $(OBJDIR)/hname.h: $(OBJDIR)/headers |
| 1751 | |
| 1752 | $(OBJDIR)/hook_.c: $(SRCDIR)/hook.c $(TRANSLATE) |
| 1753 | $(TRANSLATE) $(SRCDIR)/hook.c >$@ |
| 1754 | |
| 1755 | $(OBJDIR)/hook.o: $(OBJDIR)/hook_.c $(OBJDIR)/hook.h $(SRCDIR)/config.h |
| 1756 | $(XTCC) -o $(OBJDIR)/hook.o -c $(OBJDIR)/hook_.c |
| 1757 | |
| 1758 | $(OBJDIR)/hook.h: $(OBJDIR)/headers |
| 1759 | |
| 1760 | $(OBJDIR)/http_.c: $(SRCDIR)/http.c $(TRANSLATE) |
| 1761 | $(TRANSLATE) $(SRCDIR)/http.c >$@ |
| 1762 | |
| 1763 | $(OBJDIR)/http.o: $(OBJDIR)/http_.c $(OBJDIR)/http.h $(SRCDIR)/config.h |
| 1764 |
+10
| --- win/Makefile.msc | ||
| +++ win/Makefile.msc | ||
| @@ -400,10 +400,11 @@ | ||
| 400 | 400 | "$(OX)\fuzz_.c" \ |
| 401 | 401 | "$(OX)\glob_.c" \ |
| 402 | 402 | "$(OX)\graph_.c" \ |
| 403 | 403 | "$(OX)\gzip_.c" \ |
| 404 | 404 | "$(OX)\hname_.c" \ |
| 405 | + "$(OX)\hook_.c" \ | |
| 405 | 406 | "$(OX)\http_.c" \ |
| 406 | 407 | "$(OX)\http_socket_.c" \ |
| 407 | 408 | "$(OX)\http_ssl_.c" \ |
| 408 | 409 | "$(OX)\http_transport_.c" \ |
| 409 | 410 | "$(OX)\import_.c" \ |
| @@ -646,10 +647,11 @@ | ||
| 646 | 647 | "$(OX)\fuzz$O" \ |
| 647 | 648 | "$(OX)\glob$O" \ |
| 648 | 649 | "$(OX)\graph$O" \ |
| 649 | 650 | "$(OX)\gzip$O" \ |
| 650 | 651 | "$(OX)\hname$O" \ |
| 652 | + "$(OX)\hook$O" \ | |
| 651 | 653 | "$(OX)\http$O" \ |
| 652 | 654 | "$(OX)\http_socket$O" \ |
| 653 | 655 | "$(OX)\http_ssl$O" \ |
| 654 | 656 | "$(OX)\http_transport$O" \ |
| 655 | 657 | "$(OX)\import$O" \ |
| @@ -872,10 +874,11 @@ | ||
| 872 | 874 | echo "$(OX)\fuzz.obj" >> $@ |
| 873 | 875 | echo "$(OX)\glob.obj" >> $@ |
| 874 | 876 | echo "$(OX)\graph.obj" >> $@ |
| 875 | 877 | echo "$(OX)\gzip.obj" >> $@ |
| 876 | 878 | echo "$(OX)\hname.obj" >> $@ |
| 879 | + echo "$(OX)\hook.obj" >> $@ | |
| 877 | 880 | echo "$(OX)\http.obj" >> $@ |
| 878 | 881 | echo "$(OX)\http_socket.obj" >> $@ |
| 879 | 882 | echo "$(OX)\http_ssl.obj" >> $@ |
| 880 | 883 | echo "$(OX)\http_transport.obj" >> $@ |
| 881 | 884 | echo "$(OX)\import.obj" >> $@ |
| @@ -1493,10 +1496,16 @@ | ||
| 1493 | 1496 | "$(OX)\hname$O" : "$(OX)\hname_.c" "$(OX)\hname.h" |
| 1494 | 1497 | $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\hname_.c" |
| 1495 | 1498 | |
| 1496 | 1499 | "$(OX)\hname_.c" : "$(SRCDIR)\hname.c" |
| 1497 | 1500 | "$(OBJDIR)\translate$E" $** > $@ |
| 1501 | + | |
| 1502 | +"$(OX)\hook$O" : "$(OX)\hook_.c" "$(OX)\hook.h" | |
| 1503 | + $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\hook_.c" | |
| 1504 | + | |
| 1505 | +"$(OX)\hook_.c" : "$(SRCDIR)\hook.c" | |
| 1506 | + "$(OBJDIR)\translate$E" $** > $@ | |
| 1498 | 1507 | |
| 1499 | 1508 | "$(OX)\http$O" : "$(OX)\http_.c" "$(OX)\http.h" |
| 1500 | 1509 | $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\http_.c" |
| 1501 | 1510 | |
| 1502 | 1511 | "$(OX)\http_.c" : "$(SRCDIR)\http.c" |
| @@ -2096,10 +2105,11 @@ | ||
| 2096 | 2105 | "$(OX)\fuzz_.c":"$(OX)\fuzz.h" \ |
| 2097 | 2106 | "$(OX)\glob_.c":"$(OX)\glob.h" \ |
| 2098 | 2107 | "$(OX)\graph_.c":"$(OX)\graph.h" \ |
| 2099 | 2108 | "$(OX)\gzip_.c":"$(OX)\gzip.h" \ |
| 2100 | 2109 | "$(OX)\hname_.c":"$(OX)\hname.h" \ |
| 2110 | + "$(OX)\hook_.c":"$(OX)\hook.h" \ | |
| 2101 | 2111 | "$(OX)\http_.c":"$(OX)\http.h" \ |
| 2102 | 2112 | "$(OX)\http_socket_.c":"$(OX)\http_socket.h" \ |
| 2103 | 2113 | "$(OX)\http_ssl_.c":"$(OX)\http_ssl.h" \ |
| 2104 | 2114 | "$(OX)\http_transport_.c":"$(OX)\http_transport.h" \ |
| 2105 | 2115 | "$(OX)\import_.c":"$(OX)\import.h" \ |
| 2106 | 2116 | |
| 2107 | 2117 | ADDED www/hooks.md |
| --- win/Makefile.msc | |
| +++ win/Makefile.msc | |
| @@ -400,10 +400,11 @@ | |
| 400 | "$(OX)\fuzz_.c" \ |
| 401 | "$(OX)\glob_.c" \ |
| 402 | "$(OX)\graph_.c" \ |
| 403 | "$(OX)\gzip_.c" \ |
| 404 | "$(OX)\hname_.c" \ |
| 405 | "$(OX)\http_.c" \ |
| 406 | "$(OX)\http_socket_.c" \ |
| 407 | "$(OX)\http_ssl_.c" \ |
| 408 | "$(OX)\http_transport_.c" \ |
| 409 | "$(OX)\import_.c" \ |
| @@ -646,10 +647,11 @@ | |
| 646 | "$(OX)\fuzz$O" \ |
| 647 | "$(OX)\glob$O" \ |
| 648 | "$(OX)\graph$O" \ |
| 649 | "$(OX)\gzip$O" \ |
| 650 | "$(OX)\hname$O" \ |
| 651 | "$(OX)\http$O" \ |
| 652 | "$(OX)\http_socket$O" \ |
| 653 | "$(OX)\http_ssl$O" \ |
| 654 | "$(OX)\http_transport$O" \ |
| 655 | "$(OX)\import$O" \ |
| @@ -872,10 +874,11 @@ | |
| 872 | echo "$(OX)\fuzz.obj" >> $@ |
| 873 | echo "$(OX)\glob.obj" >> $@ |
| 874 | echo "$(OX)\graph.obj" >> $@ |
| 875 | echo "$(OX)\gzip.obj" >> $@ |
| 876 | echo "$(OX)\hname.obj" >> $@ |
| 877 | echo "$(OX)\http.obj" >> $@ |
| 878 | echo "$(OX)\http_socket.obj" >> $@ |
| 879 | echo "$(OX)\http_ssl.obj" >> $@ |
| 880 | echo "$(OX)\http_transport.obj" >> $@ |
| 881 | echo "$(OX)\import.obj" >> $@ |
| @@ -1493,10 +1496,16 @@ | |
| 1493 | "$(OX)\hname$O" : "$(OX)\hname_.c" "$(OX)\hname.h" |
| 1494 | $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\hname_.c" |
| 1495 | |
| 1496 | "$(OX)\hname_.c" : "$(SRCDIR)\hname.c" |
| 1497 | "$(OBJDIR)\translate$E" $** > $@ |
| 1498 | |
| 1499 | "$(OX)\http$O" : "$(OX)\http_.c" "$(OX)\http.h" |
| 1500 | $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\http_.c" |
| 1501 | |
| 1502 | "$(OX)\http_.c" : "$(SRCDIR)\http.c" |
| @@ -2096,10 +2105,11 @@ | |
| 2096 | "$(OX)\fuzz_.c":"$(OX)\fuzz.h" \ |
| 2097 | "$(OX)\glob_.c":"$(OX)\glob.h" \ |
| 2098 | "$(OX)\graph_.c":"$(OX)\graph.h" \ |
| 2099 | "$(OX)\gzip_.c":"$(OX)\gzip.h" \ |
| 2100 | "$(OX)\hname_.c":"$(OX)\hname.h" \ |
| 2101 | "$(OX)\http_.c":"$(OX)\http.h" \ |
| 2102 | "$(OX)\http_socket_.c":"$(OX)\http_socket.h" \ |
| 2103 | "$(OX)\http_ssl_.c":"$(OX)\http_ssl.h" \ |
| 2104 | "$(OX)\http_transport_.c":"$(OX)\http_transport.h" \ |
| 2105 | "$(OX)\import_.c":"$(OX)\import.h" \ |
| 2106 | |
| 2107 | DDED www/hooks.md |
| --- win/Makefile.msc | |
| +++ win/Makefile.msc | |
| @@ -400,10 +400,11 @@ | |
| 400 | "$(OX)\fuzz_.c" \ |
| 401 | "$(OX)\glob_.c" \ |
| 402 | "$(OX)\graph_.c" \ |
| 403 | "$(OX)\gzip_.c" \ |
| 404 | "$(OX)\hname_.c" \ |
| 405 | "$(OX)\hook_.c" \ |
| 406 | "$(OX)\http_.c" \ |
| 407 | "$(OX)\http_socket_.c" \ |
| 408 | "$(OX)\http_ssl_.c" \ |
| 409 | "$(OX)\http_transport_.c" \ |
| 410 | "$(OX)\import_.c" \ |
| @@ -646,10 +647,11 @@ | |
| 647 | "$(OX)\fuzz$O" \ |
| 648 | "$(OX)\glob$O" \ |
| 649 | "$(OX)\graph$O" \ |
| 650 | "$(OX)\gzip$O" \ |
| 651 | "$(OX)\hname$O" \ |
| 652 | "$(OX)\hook$O" \ |
| 653 | "$(OX)\http$O" \ |
| 654 | "$(OX)\http_socket$O" \ |
| 655 | "$(OX)\http_ssl$O" \ |
| 656 | "$(OX)\http_transport$O" \ |
| 657 | "$(OX)\import$O" \ |
| @@ -872,10 +874,11 @@ | |
| 874 | echo "$(OX)\fuzz.obj" >> $@ |
| 875 | echo "$(OX)\glob.obj" >> $@ |
| 876 | echo "$(OX)\graph.obj" >> $@ |
| 877 | echo "$(OX)\gzip.obj" >> $@ |
| 878 | echo "$(OX)\hname.obj" >> $@ |
| 879 | echo "$(OX)\hook.obj" >> $@ |
| 880 | echo "$(OX)\http.obj" >> $@ |
| 881 | echo "$(OX)\http_socket.obj" >> $@ |
| 882 | echo "$(OX)\http_ssl.obj" >> $@ |
| 883 | echo "$(OX)\http_transport.obj" >> $@ |
| 884 | echo "$(OX)\import.obj" >> $@ |
| @@ -1493,10 +1496,16 @@ | |
| 1496 | "$(OX)\hname$O" : "$(OX)\hname_.c" "$(OX)\hname.h" |
| 1497 | $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\hname_.c" |
| 1498 | |
| 1499 | "$(OX)\hname_.c" : "$(SRCDIR)\hname.c" |
| 1500 | "$(OBJDIR)\translate$E" $** > $@ |
| 1501 | |
| 1502 | "$(OX)\hook$O" : "$(OX)\hook_.c" "$(OX)\hook.h" |
| 1503 | $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\hook_.c" |
| 1504 | |
| 1505 | "$(OX)\hook_.c" : "$(SRCDIR)\hook.c" |
| 1506 | "$(OBJDIR)\translate$E" $** > $@ |
| 1507 | |
| 1508 | "$(OX)\http$O" : "$(OX)\http_.c" "$(OX)\http.h" |
| 1509 | $(TCC) /Fo$@ /Fd$(@D)\ -c "$(OX)\http_.c" |
| 1510 | |
| 1511 | "$(OX)\http_.c" : "$(SRCDIR)\http.c" |
| @@ -2096,10 +2105,11 @@ | |
| 2105 | "$(OX)\fuzz_.c":"$(OX)\fuzz.h" \ |
| 2106 | "$(OX)\glob_.c":"$(OX)\glob.h" \ |
| 2107 | "$(OX)\graph_.c":"$(OX)\graph.h" \ |
| 2108 | "$(OX)\gzip_.c":"$(OX)\gzip.h" \ |
| 2109 | "$(OX)\hname_.c":"$(OX)\hname.h" \ |
| 2110 | "$(OX)\hook_.c":"$(OX)\hook.h" \ |
| 2111 | "$(OX)\http_.c":"$(OX)\http.h" \ |
| 2112 | "$(OX)\http_socket_.c":"$(OX)\http_socket.h" \ |
| 2113 | "$(OX)\http_ssl_.c":"$(OX)\http_ssl.h" \ |
| 2114 | "$(OX)\http_transport_.c":"$(OX)\http_transport.h" \ |
| 2115 | "$(OX)\import_.c":"$(OX)\import.h" \ |
| 2116 | |
| 2117 | DDED www/hooks.md |
+122
| --- a/www/hooks.md | ||
| +++ b/www/hooks.md | ||
| @@ -0,0 +1,122 @@ | ||
| 1 | +# Hooks | |
| 2 | + | |
| 3 | +Hooks are short scripts that Fossil runs at defined points of processing. | |
| 4 | +Administrators can use hooks to help enforce policy or connect Fossil to | |
| 5 | +a continuous integration (CI) system. | |
| 6 | + | |
| 7 | +## Interim Documentation. | |
| 8 | + | |
| 9 | + * This is a work-in-progress. The interface is in flux. | |
| 10 | + For the time being, the documentation as a list of | |
| 11 | + bullet points. We hope to transform this into a proper document | |
| 12 | + later, after things settle down. | |
| 13 | + | |
| 14 | + * Contributions and suggestions to the hook system and/or the | |
| 15 | + documentation are welcomed. | |
| 16 | + | |
| 17 | +## General Notes. | |
| 18 | + | |
| 19 | + * Each hooks has a "type", a "sequence", and a "command". The command | |
| 20 | + is a shell command that runs at the appropriate time. The type | |
| 21 | + is currently one of "after-receive", "before-commit", "commit-msg", | |
| 22 | + or "disabled". The sequence is an arbitrary integer. | |
| 23 | + | |
| 24 | + * There can be multiple hooks of the same type. When that is the | |
| 25 | + case, the hooks are run in order of ascending sequence. | |
| 26 | + | |
| 27 | + * Use the "fossil hook" command to create, edit, and delete hooks. | |
| 28 | + | |
| 29 | + * Use the "fossil hook test" command to test new hooks. | |
| 30 | + | |
| 31 | +## Hook Scripts | |
| 32 | + | |
| 33 | + * All scripts are expected to run relatively quickly. If a long-running | |
| 34 | + process is started by a hook, it should be run in the background so | |
| 35 | + that the original script can return. | |
| 36 | + | |
| 37 | + * The "%F" sequence inside the script is translated into the | |
| 38 | + name of the fossil executable. | |
| 39 | + | |
| 40 | + * The "%R" sequence in the script is translated into the name of | |
| 41 | + the repository. | |
| 42 | + | |
| 43 | + * The "%As, | |
| 44 | + the meaning of which depends on the hook type. The auxiliary filename | |
| 45 | + might be an empty string. Take care to use appropriate quoting! | |
| 46 | + | |
| 47 | +## Disabled Hooks | |
| 48 | + | |
| 49 | + * Hooks with type "disabled" never run. They are a place-holder for | |
| 50 | + scripts that might be converted to some other hook-type later. | |
| 51 | + For example, the command "fossil hook edit --type disabled ID" | |
| 52 | + can be used to temporarily disable the hook named ID, and then | |
| 53 | + "fossil hook edit --type after-receive ID" can be used to reenable | |
| 54 | + it later. | |
| 55 | + | |
| 56 | +## After-Receive Hooks | |
| 57 | + | |
| 58 | + * The "after-receive" hook is run by [the backoffice](./backoffice.md) | |
| 59 | + whenever new artifacts are received into the repository. The artifacts | |
| 60 | + have already been committed and so there is nothing that the | |
| 61 | + after-receive hook can do to block them. | |
| 62 | + | |
| 63 | + * The after-receive hooks are intended to be run on a server to start | |
| 64 | + up a background testing or CI process. But they can also be run | |
| 65 | + on the client side. The key point is that after-receive hooks are | |
| 66 | + invoked by backoffice, so backoffice must be running in order to | |
| 67 | + fire after-receive hooks. | |
| 68 | + | |
| 69 | + * The exit code from the after-receive script is ignored. | |
| 70 | + | |
| 71 | + * The standard input to the after-receive hook is a list of | |
| 72 | + new artifacts, one per line. The first token on each line is the | |
| 73 | + hash of the new artifact. After the hash is a human-readable text | |
| 74 | + description of what the artifact represents. | |
| 75 | + | |
| 76 | + * Sometimes the same artifact can represent two or more things. | |
| 77 | + For example, the same artifact might represent two or more files | |
| 78 | + in the check-out (assuming the files hold identical content). In | |
| 79 | + that case, the text description that is input to the after-receive | |
| 80 | + hook only shows one of the possible uses for the artifact. | |
| 81 | + | |
| 82 | + * If two or more pushes occur against a repository at about the same | |
| 83 | + time, then the set of artifacts added by both pushes might be | |
| 84 | + combined into a single after-receive callback. | |
| 85 | + | |
| 86 | + * Fossil holds a write transaction on the repository while the | |
| 87 | + after-receive hook is running. If the script needs to access the | |
| 88 | + database, then the database will need to be in WAL mode so that | |
| 89 | + readers can co-exist with the writer. Or the script might just | |
| 90 | + launch a background process that waits until the hook script finishes | |
| 91 | + and the transaction commits before it tries to access the repository | |
| 92 | + database. | |
| 93 | + | |
| 94 | + * A push might not deliver all of the artifacts for a checkin. If | |
| 95 | + Fossil knows that a /xfer HTTP request is incomplete, it will defer | |
| 96 | + running the after-receive push for 60 seconds, or until a complete | |
| 97 | + /xfer reqest is received. This helps to prevent after-receive hooks | |
| 98 | + from running when incomplete checkins exist in the repository, but | |
| 99 | + it does not provide hard guarantees, as there is no way to do that | |
| 100 | + in a distributed system. | |
| 101 | + | |
| 102 | + * The list of artifacts delivered to standard input of the | |
| 103 | + after-receive hook will not contain more than 24-hours worth | |
| 104 | + of artifacts. If the backoffice has been shut down for a while | |
| 105 | + such that after-receive hooks have not been running, and more | |
| 106 | + than 24-hours of changes have accumulated since the last run | |
| 107 | + of an after-receive hook, then only the most recent 24-hours | |
| 108 | + is included in the input. | |
| 109 | + | |
| 110 | +## Before-Commit Hooks | |
| 111 | + | |
| 112 | + * Before-commit hooks run during the "fossil commit" command before | |
| 113 | + the user is prompted for the check-in comment. Fossil holds | |
| 114 | + a write-transaction on the repository when the before-commit | |
| 115 | + hook is running, so the repository needs to be in WAL mode if the | |
| 116 | + script needs to access the repository. | |
| 117 | + | |
| 118 | + * The %A substitution is the name of a "commit description file" that | |
| 119 | + shows the details of the commit in progress. To see what a | |
| 120 | + "commit description file" looks like, set a before-commit hook | |
| 121 | + with a commandsessing. | |
| 122 | +Administrators can use hooks to help enforce p |
| --- a/www/hooks.md | |
| +++ b/www/hooks.md | |
| @@ -0,0 +1,122 @@ | |
| --- a/www/hooks.md | |
| +++ b/www/hooks.md | |
| @@ -0,0 +1,122 @@ | |
| 1 | # Hooks |
| 2 | |
| 3 | Hooks are short scripts that Fossil runs at defined points of processing. |
| 4 | Administrators can use hooks to help enforce policy or connect Fossil to |
| 5 | a continuous integration (CI) system. |
| 6 | |
| 7 | ## Interim Documentation. |
| 8 | |
| 9 | * This is a work-in-progress. The interface is in flux. |
| 10 | For the time being, the documentation as a list of |
| 11 | bullet points. We hope to transform this into a proper document |
| 12 | later, after things settle down. |
| 13 | |
| 14 | * Contributions and suggestions to the hook system and/or the |
| 15 | documentation are welcomed. |
| 16 | |
| 17 | ## General Notes. |
| 18 | |
| 19 | * Each hooks has a "type", a "sequence", and a "command". The command |
| 20 | is a shell command that runs at the appropriate time. The type |
| 21 | is currently one of "after-receive", "before-commit", "commit-msg", |
| 22 | or "disabled". The sequence is an arbitrary integer. |
| 23 | |
| 24 | * There can be multiple hooks of the same type. When that is the |
| 25 | case, the hooks are run in order of ascending sequence. |
| 26 | |
| 27 | * Use the "fossil hook" command to create, edit, and delete hooks. |
| 28 | |
| 29 | * Use the "fossil hook test" command to test new hooks. |
| 30 | |
| 31 | ## Hook Scripts |
| 32 | |
| 33 | * All scripts are expected to run relatively quickly. If a long-running |
| 34 | process is started by a hook, it should be run in the background so |
| 35 | that the original script can return. |
| 36 | |
| 37 | * The "%F" sequence inside the script is translated into the |
| 38 | name of the fossil executable. |
| 39 | |
| 40 | * The "%R" sequence in the script is translated into the name of |
| 41 | the repository. |
| 42 | |
| 43 | * The "%As, |
| 44 | the meaning of which depends on the hook type. The auxiliary filename |
| 45 | might be an empty string. Take care to use appropriate quoting! |
| 46 | |
| 47 | ## Disabled Hooks |
| 48 | |
| 49 | * Hooks with type "disabled" never run. They are a place-holder for |
| 50 | scripts that might be converted to some other hook-type later. |
| 51 | For example, the command "fossil hook edit --type disabled ID" |
| 52 | can be used to temporarily disable the hook named ID, and then |
| 53 | "fossil hook edit --type after-receive ID" can be used to reenable |
| 54 | it later. |
| 55 | |
| 56 | ## After-Receive Hooks |
| 57 | |
| 58 | * The "after-receive" hook is run by [the backoffice](./backoffice.md) |
| 59 | whenever new artifacts are received into the repository. The artifacts |
| 60 | have already been committed and so there is nothing that the |
| 61 | after-receive hook can do to block them. |
| 62 | |
| 63 | * The after-receive hooks are intended to be run on a server to start |
| 64 | up a background testing or CI process. But they can also be run |
| 65 | on the client side. The key point is that after-receive hooks are |
| 66 | invoked by backoffice, so backoffice must be running in order to |
| 67 | fire after-receive hooks. |
| 68 | |
| 69 | * The exit code from the after-receive script is ignored. |
| 70 | |
| 71 | * The standard input to the after-receive hook is a list of |
| 72 | new artifacts, one per line. The first token on each line is the |
| 73 | hash of the new artifact. After the hash is a human-readable text |
| 74 | description of what the artifact represents. |
| 75 | |
| 76 | * Sometimes the same artifact can represent two or more things. |
| 77 | For example, the same artifact might represent two or more files |
| 78 | in the check-out (assuming the files hold identical content). In |
| 79 | that case, the text description that is input to the after-receive |
| 80 | hook only shows one of the possible uses for the artifact. |
| 81 | |
| 82 | * If two or more pushes occur against a repository at about the same |
| 83 | time, then the set of artifacts added by both pushes might be |
| 84 | combined into a single after-receive callback. |
| 85 | |
| 86 | * Fossil holds a write transaction on the repository while the |
| 87 | after-receive hook is running. If the script needs to access the |
| 88 | database, then the database will need to be in WAL mode so that |
| 89 | readers can co-exist with the writer. Or the script might just |
| 90 | launch a background process that waits until the hook script finishes |
| 91 | and the transaction commits before it tries to access the repository |
| 92 | database. |
| 93 | |
| 94 | * A push might not deliver all of the artifacts for a checkin. If |
| 95 | Fossil knows that a /xfer HTTP request is incomplete, it will defer |
| 96 | running the after-receive push for 60 seconds, or until a complete |
| 97 | /xfer reqest is received. This helps to prevent after-receive hooks |
| 98 | from running when incomplete checkins exist in the repository, but |
| 99 | it does not provide hard guarantees, as there is no way to do that |
| 100 | in a distributed system. |
| 101 | |
| 102 | * The list of artifacts delivered to standard input of the |
| 103 | after-receive hook will not contain more than 24-hours worth |
| 104 | of artifacts. If the backoffice has been shut down for a while |
| 105 | such that after-receive hooks have not been running, and more |
| 106 | than 24-hours of changes have accumulated since the last run |
| 107 | of an after-receive hook, then only the most recent 24-hours |
| 108 | is included in the input. |
| 109 | |
| 110 | ## Before-Commit Hooks |
| 111 | |
| 112 | * Before-commit hooks run during the "fossil commit" command before |
| 113 | the user is prompted for the check-in comment. Fossil holds |
| 114 | a write-transaction on the repository when the before-commit |
| 115 | hook is running, so the repository needs to be in WAL mode if the |
| 116 | script needs to access the repository. |
| 117 | |
| 118 | * The %A substitution is the name of a "commit description file" that |
| 119 | shows the details of the commit in progress. To see what a |
| 120 | "commit description file" looks like, set a before-commit hook |
| 121 | with a commandsessing. |
| 122 | Administrators can use hooks to help enforce p |