Skip to content
This repository has been archived by the owner on Feb 5, 2022. It is now read-only.

Best approach for upgrading a template? #132

Open
niftylettuce opened this issue Sep 18, 2019 · 16 comments
Open

Best approach for upgrading a template? #132

niftylettuce opened this issue Sep 18, 2019 · 16 comments

Comments

@niftylettuce
Copy link

Let's say someone upgrades to a newer version of a CLI of Sao, e.g. lad (see https://github.com/ladjs/lad) via npm install -g lad@latest. They then want to upgrade their template. What would be the best approach? Just a git clone and then apply the diff between template directory and the user's project dir?

@egoist
Copy link
Member

egoist commented Sep 18, 2019

For an already generated project it's hard to upgrade automatically since you may have changed many files 🤔

@niftylettuce
Copy link
Author

It would be incredible for sao to have a package (possibly one even built-in) that lets you do this by plugging the package into your CLI.

@niftylettuce
Copy link
Author

This would be the BEST feature for Sao by far compared to ANY other template/scaffolding too.

@niftylettuce
Copy link
Author

Also would gladly donate to you to help build something like this 😄

@niftylettuce
Copy link
Author

I found your Patreon, now a supporter.

@egoist
Copy link
Member

egoist commented Sep 18, 2019

Thanks, I'll take a look at the react-native solution, this is definitely a missing feature for every scaffolding tool.

@niftylettuce
Copy link
Author

Let me know!

@shaunwarman
Copy link

Codemods would work well. JSCodeShift is a solid tool. Good example usage with jest.

@niftylettuce
Copy link
Author

Would be awesome to have this 🙌

@niftylettuce
Copy link
Author

I am awarding a $200 bug bounty for this issue.

@egoist
Copy link
Member

egoist commented May 17, 2020

I will create a website like https://react-native-community.github.io/upgrade-helper to show the diffs between two versions of a generator

@niftylettuce
Copy link
Author

@egoist Hey! I also shared this with @shaunwarman - but I think having a CLI tool like this would be great:

https://github.com/willmendesneto/update-yeoman-generator/blob/9946691c89a70a5916b929c7c2f38b26a9536445/lib/run.js

@egoist
Copy link
Member

egoist commented May 17, 2020

Yes, a separate CLI tool like that is also planned.

@egoist egoist mentioned this issue May 18, 2020
6 tasks
@niftylettuce
Copy link
Author

Any update here @egoist ?

@shaunwarman
Copy link

Checking in again @egoist , I should have bandwidth to dive in and help, but unsure if you have some ideas / todos for this new CLI tool

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants