How does merging branches affect content in Github workflow?

How does merging branches affect content in Github workflow?

victorcngo
Shopify Partner
2 0 0
hello there! i'd need some assistance about github shopify workflow. here's the story: my shopify project has got two branches (/main which is connected to the client store, and /develop which is our work branch connected to a testing store)
 
my client has started to fill the content (adding products, customizing the store with sections and blocks we've created for the theme customizer), so the json files located in templates folder should have changed accordingly on /main branch (edited)
 
 
thing is, i still need to commit some changes (nothing related to content) from develop to main, and my json files are not up to date with the /main (edited)
 
by merging /develop to /main with a pull request, i'm afraid to overwrite the content that my client has entered! (edited)
 
i've created the PR and looks like i'm able to merge with no conflict, and no commit in any json file. what should i expect?
Reply 1 (1)

PaulNewton
Shopify Partner
7722 678 1627

Really only way to know is hands on just gotta make a dev shop and try to purposefully break a theme/repo.

 

Basically if you merged a PR there should be conflicts stopping the merge before any overwrites happen where ever the two branches are out of sync in commits lines.

 

Develop is out of date from main, not main is out of date from develop.

Part of the problem is that merchants are an oblivious committer  to this so /main is not /main in a purely developer sense: Someone is commiting directly to production/deploy with no other abstraction branches or layers in between.

 

As a process before merging backup the repo/branches/export-admin-themes.

To /develop pull down any upstream changes from origin , /main.

Treating main like a staging/deploy branch where the merchant has merged their own /dev repo into main.

git pull origin main

Then again maybe more backups.

Then push the now sync'd merged updated /dev branch to main.

 

 

Contact paull.newton+shopifyforum@gmail.com for the solutions you need


Save time & money ,Ask Questions The Smart Way


Problem Solved? ✔Accept and Like solutions to help future merchants

Answers powered by coffee Thank Paul with a Coffee for more answers or donate to eff.org