You can update your project from the starter-kit (merge a tagged release)
This guide explains a safe, repeatable workflow for fetching a specific tagged release from the starter-kit (for example v0.1.0 - Latest) and merging it into your project.
Assumption: you started your project from the starter-kit and added the starter-kit repo as the upstream remote:
git remote -v
origin https://github.com/you/your-app.git (fetch)
upstream https://github.com/devsbuddy/laravel-react-starter-kit.git (fetch)- Commit or stash all local changes on your project. Never merge while you have uncommitted work.
- Create a backup branch (optional but recommended):
git checkout main
git checkout -b backup-before-update-$(date +%Y%m%d)
git push origin HEAD
# switch back to your working branch, e.g. main
git checkout main- Make sure your local
main(or primary branch) is up-to-date with your remoteorigin:
git pull origin mainBelow are two safe options. Use Option A if your project shares history with the starter-kit (the usual case when you used the repo as a template). Use Option B if you prefer to create a temporary branch and test the merge before applying it to your main branch.
- Fetch tags from upstream:
git fetch upstream --tags- Verify the tag exists locally:
git tag --list | grep v0.1.0- Ensure you are on your local
main(or your app's primary branch):
git checkout main
git pull origin main- Merge the tag into
main:
git merge --no-ff v0.1.0 -m "Merge upstream v0.1.0"- If Git performs a fast-forward merge it will simply move your branch pointer.
- If there are conflicts, Git will stop and you must resolve them. See Resolving conflicts below.
- Run project update steps (see Post-merge checklist). Then push the result to your origin:
git push origin main- Fetch tags:
git fetch upstream --tags- Create a temporary branch from your up-to-date
main:
git checkout main
git pull origin main
git checkout -b upstream-merge-v0.1.0- Merge the tag into the temporary branch:
git merge --no-ff v0.1.0 -m "Merge upstream v0.1.0 (test)"-
Resolve conflicts if any (see below). Run your tests and local checks.
-
If everything looks good, switch back to
mainand merge the temporary branch:
git checkout main
git merge --no-ff upstream-merge-v0.1.0 -m "Apply upstream v0.1.0 merge"
git push origin main- Delete the temporary branch locally and remotely (optional):
git branch -d upstream-merge-v0.1.0
# if you pushed it upstream and want to delete on remote:
# git push origin --delete upstream-merge-v0.1.0If Git reports conflicts during the merge:
- Open each conflicted file and look for conflict markers
<<<<<<<,=======,>>>>>>>. - Decide how to reconcile changes: keep your version, take upstream changes, or combine them.
- After resolving all files:
git add <resolved-files>
git commit --no-edit- Re-run your local checks/tests and the Post-merge checklist.
Tip: If the conflicts are numerous and complex, consider doing a git merge --abort and performing a manual three-way merge approach, or use a visual merge tool (VSCode, Meld, Beyond Compare, etc.).
- Composer dependencies — If the starter-kit changed
composer.json:
composer install
composer dump-autoload- Node packages / build — If
package.jsonor frontend assets changed:
# if you use npm
npm install
npm run dev
# or yarn/pnpm equivalents- Migrations — If the update added or changed migrations:
php artisan migrate
# If migrations are destructive, inspect them first or run in a safe environment-
Config / env — Check
config/*and.env.examplefor new keys. Merge them into your.envcarefully. -
Clear caches:
php artisan config:clear
php artisan cache:clear
php artisan view:clear
php artisan route:clear- Run tests & manual QA — Run your test suite and smoke-test the app locally.
If your repository and the starter-kit do not share common commit history (Git will warn about unrelated histories), merging a tag may fail. In that case:
- Consider copying the specific files you need from the starter-kit release into your project manually.
- Or use
git format-patch/git amfrom the upstream to apply a sequence of commits.
# 1. Fetch upstream tags
git fetch upstream --tags
# 2. Test-first approach
git checkout main && git pull origin main
git checkout -b upstream-merge-v0.1.0
git merge --no-ff v0.1.0 -m "Merge upstream v0.1.0 (test)"
# resolve conflicts, run tests, then
git checkout main
git merge --no-ff upstream-merge-v0.1.0
git push origin main
# 3. Direct merge approach
git checkout main && git pull origin main
git merge --no-ff v0.1.0 -m "Merge upstream v0.1.0"
# resolve conflicts, run post-merge tasks, then
git push origin main