Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Further cleanup of the documentation for "fossil commit". Deprecate the "--mimetype" option as it is unimplemented (on the display side). Deemphasize unimportant and seldom used aspects of the commit command in order to bring more focus onto the important and often used parts. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA3-256: |
1ec8deef8a7705013edf1e7b9ee57bf5 |
| User & Date: | drh 2025-03-18 13:01:50.645 |
Context
|
2025-03-18
| ||
| 13:15 | Comment improvements on the "fossil commit" code. Tighten the restrictions on creating delta manifests such that the --delta option will only override the absence of the seen-delta-manifest setting, but no longer overrides the forbid-delta-manifest setting either on the host or on the sync host. check-in: 52a2be128c user: drh tags: trunk | |
| 13:01 | Further cleanup of the documentation for "fossil commit". Deprecate the "--mimetype" option as it is unimplemented (on the display side). Deemphasize unimportant and seldom used aspects of the commit command in order to bring more focus onto the important and often used parts. check-in: 1ec8deef8a user: drh tags: trunk | |
| 12:31 | Omit the --bgcolor and --branchcolor options from the documentation of "fossil commit". The options still work, but their use is discouraged. Removing them from the official documentation will reduce the temptation to use them. Also: The --no-warnings flag implies --allow-suspect-comment. check-in: 5c8de3496d user: drh tags: trunk | |
Changes
Changes to src/checkin.c.
| ︙ | ︙ | |||
2352 2353 2354 2355 2356 2357 2358 | /* ** COMMAND: ci# ** COMMAND: commit ** ** Usage: %fossil commit ?OPTIONS? ?FILE...? ** or: %fossil ci ?OPTIONS? ?FILE...? ** | | > > > > | | < | | | > | < < < | < < < < < < < < < < < < < < < < < < | < > | | > > | | | < | > | > | | < | < < < < | 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 |
/*
** COMMAND: ci#
** COMMAND: commit
**
** Usage: %fossil commit ?OPTIONS? ?FILE...?
** or: %fossil ci ?OPTIONS? ?FILE...?
**
** Create a new check-in containing all of the changes in the current
** check-out. All changes are committed unless some subset of files
** is specified on the command line, in which case only the named files
** become part of the new check-in.
**
** You will be prompted to enter a check-in comment unless the comment
** has been specified on the command-line using "-m" or "-M". The
** text editor used is determined by the "editor" setting, or by the
** "VISUAL" or "EDITOR" environment variables. Commit message text is
** interpreted as fossil-wiki format. Potentially misformatted check-in
** comment text is detected and reported unless the --allow-suspect-comment
** option is used.
**
** The --branch option followed by a branch name causes the new
** check-in to be placed in a newly-created branch with name specified.
**
** A check-in is not permitted to fork unless the --allow-fork option
** appears. An empty check-in (i.e. with nothing changed) is not
** allowed unless the --allow-empty option appears. A check-in may not
** be older than its ancestor unless the --allow-older option appears.
** If any files in the check-in appear to contain unresolved merge
** conflicts, the check-in will not be allowed unless the
** --allow-conflict option is present. In addition, the entire
** check-in process may be aborted if a file contains content that
** appears to be binary, Unicode text, or text with CR/LF line endings
** unless the interactive user chooses to proceed. If there is no
** interactive user or these warnings should be skipped for some other
** reason, the --no-warnings option may be used. A check-in is not
** allowed against a closed leaf.
**
** The --private option creates a private check-in that is never synced.
** Children of private check-ins are automatically private.
**
** The --tag option applies the symbolic tag name to the check-in.
** The --tag option can be repeated to assign multiple tags to a check-in.
** For example: "... --tag release --tag version-1.2.3 ..."
**
** Options:
** --allow-conflict Allow unresolved merge conflicts
** --allow-empty Allow a commit with no changes
** --allow-fork Allow the commit to fork
** --allow-older Allow a commit older than its ancestor
** --allow-suspect-comment Allow check-in comments that might be misformed
** --baseline Use a baseline manifest in the commit process
** --branch NEW-BRANCH-NAME Check in to this new branch
** --close Close the branch being committed
** --date-override DATETIME Make DATETIME the time of the check-in.
** Useful when importing historical check-ins
** from another version control system.
** --delta Use a delta manifest in the commit process
** --hash Verify file status using hashing rather
** than relying on filesystem mtimes
** --if-changes Make this command a silent no-op if there
** are no changes
** --ignore-clock-skew If a clock skew is detected, ignore it and
** behave as if the user had entered 'yes' to
** the question of whether to proceed despite
** the skew.
** --ignore-oversize Do not warn the user about oversized files
** --integrate Close all merged-in branches
** -m|--comment COMMENT-TEXT Use COMMENT-TEXT as the check-in comment
** -M|--message-file FILE Read the check-in comment from FILE
** -n|--dry-run Do not actually create a new check-in. Just
** show what would have happened. For debugging.
** -v|--verbose Show a diff in the commit message prompt
** --no-prompt This option disables prompting the user for
** input and assumes an answer of 'No' for every
** question.
** --no-warnings Omit all warnings about file contents
** --no-verify Do not run before-commit hooks
** --nosign Do not attempt to sign this commit with gpg
** --nosync Do not auto-sync prior to committing
** --override-lock Allow a check-in even though parent is locked
** --private Never sync the resulting check-in and make
** all descendants private too.
** --proxy PROXY Use PROXY as http proxy during sync operation
** --tag TAG-NAME Add TAG-NAME to the check-in. May be repeated.
** --trace Debug tracing
** --user-override USER Record USER as the login that created the
** new check-in, rather that the current user.
**
** See also: [[branch]], [[changes]], [[update]], [[extras]], [[sync]]
*/
void commit_cmd(void){
int hasChanges; /* True if unsaved changes exist */
int vid; /* blob-id of parent version */
int nrid; /* blob-id of a modified file */
|
| ︙ | ︙ | |||
2548 2549 2550 2551 2552 2553 2554 |
noPrompt = find_option("no-prompt", 0, 0)!=0;
noWarningFlag = find_option("no-warnings", 0, 0)!=0;
noVerify = find_option("no-verify",0,0)!=0;
bTrace = find_option("trace",0,0)!=0;
sCiInfo.zBranch = find_option("branch","b",1);
/* NB: the --bgcolor and --branchcolor flags still work, but are
| | > > < | 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 |
noPrompt = find_option("no-prompt", 0, 0)!=0;
noWarningFlag = find_option("no-warnings", 0, 0)!=0;
noVerify = find_option("no-verify",0,0)!=0;
bTrace = find_option("trace",0,0)!=0;
sCiInfo.zBranch = find_option("branch","b",1);
/* NB: the --bgcolor and --branchcolor flags still work, but are
** now undocumented, to discourage their use. --mimetype has never
** been used for anything, so also leave it undocumented */
sCiInfo.zColor = find_option("bgcolor",0,1); /* Deprecated, undocumented*/
sCiInfo.zBrClr = find_option("branchcolor",0,1); /* Deprecated, undocumented*/
sCiInfo.zMimetype = find_option("mimetype",0,1); /* Deprecated, undocumented*/
sCiInfo.closeFlag = find_option("close",0,0)!=0;
sCiInfo.integrateFlag = find_option("integrate",0,0)!=0;
sCiInfo.verboseFlag = find_option("verbose", "v", 0)!=0;
while( (zTag = find_option("tag",0,1))!=0 ){
if( zTag[0]==0 ) continue;
sCiInfo.azTag = fossil_realloc((void*)sCiInfo.azTag,
sizeof(char*)*(nTag+2));
sCiInfo.azTag[nTag++] = zTag;
sCiInfo.azTag[nTag] = 0;
|
| ︙ | ︙ |
Changes to www/fileformat.wiki.
| ︙ | ︙ | |||
171 172 173 174 175 176 177 | is optional. The file format might be extended with new permission letters in the future. The optional 4th argument is the name of the same file as it existed in the parent check-in. If the name of the file is unchanged from its parent, then the 4th argument is omitted. A manifest has zero or one <b>N</b> cards. The <b>N</b> card specifies the mimetype for the text in the comment of the <b>C</b> card. If the <b>N</b> card is omitted, a default mimetype | | > > > | 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 | is optional. The file format might be extended with new permission letters in the future. The optional 4th argument is the name of the same file as it existed in the parent check-in. If the name of the file is unchanged from its parent, then the 4th argument is omitted. A manifest has zero or one <b>N</b> cards. The <b>N</b> card specifies the mimetype for the text in the comment of the <b>C</b> card. If the <b>N</b> card is omitted, a default mimetype is used. Note that the <b>N</b> card has never actually been used by any Fossil implementation. The implementation has always interpreted check-in comments according to the [/wiki_rules|Fossil Wiki formatting rules]. There are no current plans to ever change that. A manifest has zero or one <b>P</b> cards. Most manifests have one <b>P</b> card. The <b>P</b> card has a varying number of arguments that define other manifests from which the current manifest is derived. Each argument is a lowercase hexadecimal artifact hash of a predecessor manifest. All arguments to the <b>P</b> card must be unique within that card. |
| ︙ | ︙ |