Skip to content

Can degit handle template upgrading? #351

@martin-braun

Description

@martin-braun

degit peeks my interest, because I can provide a git repository as template with no headache. I very much adore the fact that the user doesn't have to download the entire repository this way, but what about upgrading my template?

Say I bumped a lot of dependencies in my template. I might also changed the ground structure of my project scaffold slightly.

After a while a user decides to upgrade the template to get the latest nitty-gritty that my template offers. Ideally their way of doing this is just calling degit again. The hard part is that it must not overwrite files that have been changed, but produce the same merge-conflict output that git itself would give if I would try to pull from the upstream with rebase.

Since degit stores the previous download of the template with its hash in the user directory, it would use the old version to compare the files. It would also maintain a local database to know what template-hash the current project is using.

Have there ever been any thoughts about this? Are there plans or even existing solutions to the problem?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions