Skip to content

Migrating a pre-existing dotfiles repository #2330

Closed Answered by twpayne
britter asked this question in Q&A
Discussion options

You must be logged in to vote

Does this make sense?

Yes, your proposed series of steps sound very reasonable. git should detect the renames and so you'll maintain per-file history.

Anything else I need to initialize in the chezmoi repository that would normally be initialized by chezmoi init?

No, nothing else is needed. chezmoi init just creates an empty git repo.

Another approach that you might want to consider if you want to do an incremental migration is to use .chezmoiroot and chezmoi add --follow. .chezmoiroot allows you to keep the chezmoi-managed files separate from your link-script managed files (in your case this only matters for the licenses directory and README.md as chezmoi ignores everything beginning…

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@britter
Comment options

Answer selected by britter
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants