CLI Reference
hf
hf [OPTIONS] <SUBCOMMAND>
Options
-v
,--verbose
Subcommands
daemon
Daemon management commandsrepository
Repository management commandsgui
Open the GUI in the browsermerge
Finish your WIP and merge it into trunkdiff
Diff current WIP with trunkdelete
Delete the given WIPconflicts
Conflicts related commandsgithub
Github related commandsswitch
Switch to a different WIPpull
Pull the latest changes from trunk into your WIPtitle
Set or show the title of the current WIPlist
List all WIPscreate
Create a new WIPduplicate
Duplicate an existing WIPstatus
Show the current WIP statusversion
Print version informationrevert
Revert an entire WIPdiscard
Discard all changes in the specified file (e.g. "main.rs") by restoring that file to the version from trunk. Danger: this will delete all the changes you made to the specified filereview
Code review related commandshide
Keep a file local (don't upload this file's changes, and don't make it part of your WIPs)
hf daemon
Daemon management commands
hf daemon <SUBCOMMAND>
Subcommands
ping
Detect whether daemon is running (just answers 'pong')
hf daemon ping
Detect whether daemon is running (just answers 'pong')
hf daemon ping
hf repository
Repository management commands
hf repository <SUBCOMMAND>
Subcommands
hf repository add
Add a repository
hf repository add [OPTIONS] [DIR]
Args
[DIR]
Repository directory to add, without this parameter it uses the current directory
Options
--no-init-check
hf repository remove
Remove a repository
hf repository remove [DIR]
Args
[DIR]
Repository directory to remove, without this parameter it uses the current directory
hf repository list
List currently watched repositories
hf repository list
hf gui
Open the GUI in the browser
hf gui
hf merge
Finish your WIP and merge it into trunk
hf merge [OPTIONS] [DESCRIPTION]
Args
[DESCRIPTION]
Description of the commit. Default: the WIP's title
Options
--ignore-review
Merge to trunk directly even if there's an open review (instead of merging that pull request)
hf diff
Diff current WIP with trunk
hf diff [WIP_ID]
Args
[WIP_ID]
Show diff for this WIP (default: current WIP)
hf delete
Delete the given WIP
hf delete [WIP_ID]
Args
[WIP_ID]
The id of WIP to delete
hf conflicts
Conflicts related commands
hf conflicts <SUBCOMMAND>
Subcommands
list
List detected conflictsrun
Run conflict detection nowmerge-check
Check if current WIP can be merged into trunk without conflictsshow
Show conflicts with specified conflict numberclear
Clear saved conflicts list
hf conflicts list
List detected conflicts
hf conflicts list
hf conflicts run
Run conflict detection now
hf conflicts run
hf conflicts merge-check
Check if current WIP can be merged into trunk without conflicts
hf conflicts merge-check
hf conflicts show
Show conflicts with specified conflict number
hf conflicts show [NUMBER]
Args
[NUMBER]
hf conflicts clear
Clear saved conflicts list
hf conflicts clear
hf github
Github related commands
hf github <SUBCOMMAND>
Subcommands
auth
Authenticate with the GitHub apptest
Tests the GitHub integration by listing the open pull requests of your repository
hf github auth
Authenticate with the GitHub app
hf github auth
hf github test
Tests the GitHub integration by listing the open pull requests of your repository
hf github test
hf switch
Switch to a different WIP
hf switch [WIP_ID]
Args
[WIP_ID]
The id of WIP to switch to (e.g. GT-100)
hf pull
Pull the latest changes from trunk into your WIP
hf pull [OPTIONS] [ALL|WIP_ID]
Args
[ALL|WIP_ID]
Pull changes into this WIP (default: current WIP), or 'all' for all WIPs
Options
-w
,--write-conflicts
Write all conflicting changes to your files marked by special conflict markers
hf title
Set or show the title of the current WIP
hf title [OPTIONS] [NEW_TITLE]
Args
[NEW_TITLE]
New title for WIP, if empty, will print the current title
Options
-e
,--edit
Edit title in the editor
hf list
List all WIPs
hf list <SUBCOMMAND>
Subcommands
all
Also display other people's WIPs
hf list all
Also display other people's WIPs
hf list all
hf create
Create a new WIP
hf create [NEW_TITLE]
Args
[NEW_TITLE]
Title for the newly created WIP
hf duplicate
Duplicate an existing WIP
hf duplicate [WIP_ID]
Args
[WIP_ID]
The WIP that the new WIP should be based off of (default: current WIP)
hf status
Show the current WIP status
hf status [WIP_ID]
Args
[WIP_ID]
Show status for this WIP (default: current WIP)
hf version
Print version information
hf version
hf revert
Revert an entire WIP
hf revert [WIP_ID]
Args
[WIP_ID]
Revert a merged WIP (e.g. "EM-123") by creating a new WIP with the inverted changes
hf discard
Discard all changes in the specified file (e.g. "main.rs") by restoring that file to the version from trunk. Danger: this will delete all the changes you made to the specified file
hf discard [FILE_PATH]
Args
[FILE_PATH]
hf review
Code review related commands
hf review <SUBCOMMAND>
Subcommands
create
Create a code review (pull request) for the current WIPupdate
Update the code review (pull request) with the latest changes of the current WIP, so the reviewers can see themmerge
Finish the review and merge the WIP into trunk
hf review create
Create a code review (pull request) for the current WIP
hf review create [DESCRIPTION]
Args
[DESCRIPTION]
Description of the commit. Default: the WIP title
hf review update
Update the code review (pull request) with the latest changes of the current WIP, so the reviewers can see them
hf review update [DESCRIPTION]
Args
[DESCRIPTION]
Description of the commit. Default: the WIP title
hf review merge
Finish the review and merge the WIP into trunk
hf review merge [DESCRIPTION]
Args
[DESCRIPTION]
hf hide
Keep a file local (don't upload this file's changes, and don't make it part of your WIPs)
hf hide <SUBCOMMAND> [FILENAME]
Args
[FILENAME]
The file to hide so changes are not uploaded or included in your WIPs
Subcommands
hf hide clear
hf hide clear [OPTIONS] [FILENAME]
Args
[FILENAME]
Options
-a
,--all
hf hide list
hf hide list