git Branch management
marclallen
Posts: 53 Bronze 3
Hi!
I'm not entirely clear on the best way to handle branches using SC.
Once I'm linked, can I just manipulate the repository from behind the scenes and then refresh? Or do I need to unlink, relink every time I change my working branch?
Ideally, branching would be built into the UI so I could, at a minimum, switch branches.
I'm not entirely clear on the best way to handle branches using SC.
Once I'm linked, can I just manipulate the repository from behind the scenes and then refresh? Or do I need to unlink, relink every time I change my working branch?
Ideally, branching would be built into the UI so I could, at a minimum, switch branches.
Tagged:
Answers
I haven't been using Redgate SQL Source Control for the last couple of years (we've been using Visual Studio and Database projects) but I am now looking at Redgate SQL Source Control again as I prefer the 'connected' method of development.
I kind of agree with the following statement made by the original poster.
"Ideally, branching would be built into the UI so I could, at a minimum, switch branches".
Is this something that you guys are considering?
I saw a video where Kendra uses sublime merge for handling conflicts, I was wondering what the redgate teams use for creating/switching branches (excluding the command line)?
cheers
Ben
such as
- no annoying conflicts on the .dbproj file
- no re-keying from SSMS to Visual Studio (don't have to keep jumping around between IDEs)
- much nicer interface
- schema comparison less buggy
- you can see other people's changes more easily
visual studio has improved massively in the last 2 years tho.The pros/cons of each is what i'm currently researching (including the pros/cons between the redgate and microsoft build/release plug-ins in Azure DevOps).
But one small advantage of Visual Studio is that it has the branch management gui.
cheers
Ben
Product Manager
Redgate Software
I don't think i would need/want the database to change after each switch of branch though, I could get the database & branch in the position I want using the 'Commit' & 'Get Latest' tabs within RedGate Sql Source Control.
What I would ideally be after is this screen which pops up when you click the arrow next to your current branch.
Have it appear when you click the branch label in Redgate Sql Source Control
Hope that makes sense. I've only been using git for ~7 months so i'm no expert !
What is the specific reason you wouldn't want it to auto-sync your DB with the state of the new branch?
Adding branch switching is something we may consider, although this would be most likely in the context of an integration with SQL Clone.
Product Manager
Redgate Software
"This should work as expect today except that you'll need to type the git checkout commands manually (it would be great if you could try to switch branches and let us know if the end result in the Get Latest screen is as you would expect)." Typing the git commands manually is what I was I hoping the RedGate UI could do for me! I like having as few applications open as poss, others in my team dont want to use the command line at all.
What is the specific reason you wouldn't want it to auto-sync your DB with the state of the new branch?
We use shared databases environments at the moment. We have laptops with 250gb hard disks but our DWH databases are much bigger and we haven't looked at making smaller copies because its a bit of a spaghetti architecture.
Also, if there is a lot of context switching then you may have a branch you haven't touched for a week or so and its nice to have the control to put things back manually and refresh your memory of what you were doing.
cheers, Ben
so, i'm putting the full list below for my own notes
1. Visual Studio db projects can have duplicate object definitions
2. I think you can't (easily) see the SQL definitions in dacpacs but you can in SCA nu-get packages (unconfirmed!)
Product Manager
Redgate Software