-
Notifications
You must be signed in to change notification settings - Fork 596
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow merging when migrating from
z
(#33)
If the user passes the `--merge` flag to the `migrate` subcommand, all duplicate entries will have their ranks and epochs updated: the rank will be the sum of the stored rank and the newly-parsed rank, while the epoch will be the maximum of the stored epoch and the newly-parsed epoch. This allows one to import from the `z` database even after having used `zoxide` for any amount of time. This also permits a user who has already sourced the init script to import their old database without needing to do something like `rm ~/.zo && zoxide migrate ~/.z`.
- Loading branch information
Showing
2 changed files
with
23 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters