diff --git a/packages/flowershow/upgrade.sh b/packages/flowershow/upgrade.sh new file mode 100755 index 000000000..b4b3a86a0 --- /dev/null +++ b/packages/flowershow/upgrade.sh @@ -0,0 +1,28 @@ +# upgrade an existing standard nextjs site + +npx degit flowershow/flowershow/templates/default --force + +# files that we should keep the original (probably) +git checkout README.md +git checkout .gitignore + +# stuff that shouldn't be there +rm .env.example +rm -Rf tests +rm netlify.toml +rm netlify.toml +# data seems to be exampleData +rm -Rf data +rm -Rf components/TempCallout.jsx + +# set up custom components +rm -Rf components/custom + +# set up assets +mkdir -p content/assets +rm public/assets +ln -s content/assets public/assets + +# notes +echo "You may need to hand merge the following files:" +echo "pacakge.json, package-lock.json" diff --git a/site/content/docs/upgrade.md b/site/content/docs/upgrade.md new file mode 100644 index 000000000..78c247613 --- /dev/null +++ b/site/content/docs/upgrade.md @@ -0,0 +1,15 @@ +--- +title: Upgrading Flowershow and a Flowershow Site +--- + +For a simple site you can just upgrade Flowershow and republish. + +For a "custom" site i.e. where you are using Flowershow as a NextJS template you will need to do more. + +## Upgrading a NextJS site built with Flowershow + +See `packages/flowershow/upgrade.sh` in the Flowershow github repo. + +You will probably have to do some custom merging. + +See also https://github.com/flowershow/flowershow/issues/111