Linux command
fossil-commit 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Commit with message
fossil commit -m "[message]"
Commit interactively
fossil commit
Commit specific files
fossil commit [file1] [file2] -m "[message]"
Commit to new branch
fossil commit --branch [branch_name] -m "[message]"
Amend last commit
fossil amend [checkin] -m "[new message]"
说明
fossil commit records changes in the working copy to the repository, creating a new check-in with the specified comment. All files previously added or modified are included in the commit. The command opens an editor for the commit message if -m is not provided. Unlike Git, Fossil uses autosync by default, potentially pushing changes to configured remotes immediately after commit. Commits can create new branches, add tags, and include metadata like timestamps and user information. The --private option creates commits that won't be pushed to public repositories.
参数
- -m, --comment _text_
- Commit message.
- --branch _name_
- Create new branch.
- --tag _name_
- Add tag.
- --private
- Make commit private.
- --allow-empty
- Allow empty commit.
- --close
- Close branch after commit.
FAQ
What is the fossil-commit command used for?
fossil commit records changes in the working copy to the repository, creating a new check-in with the specified comment. All files previously added or modified are included in the commit. The command opens an editor for the commit message if -m is not provided. Unlike Git, Fossil uses autosync by default, potentially pushing changes to configured remotes immediately after commit. Commits can create new branches, add tags, and include metadata like timestamps and user information. The --private option creates commits that won't be pushed to public repositories.
How do I run a basic fossil-commit example?
Run `fossil commit -m "[message]"` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -m, --comment _text_ do in fossil-commit?
Commit message.