MCPcopy Create free account
hub / github.com/remotemobprogramming/mob / startJoinMobSession

Function startJoinMobSession

mob.go:766–776  ·  view source on GitHub ↗
(configuration config.Configuration)

Source from the content-addressed store, hash-verified

764}
765
766func startJoinMobSession(configuration config.Configuration) {
767 baseBranch, currentWipBranch := determineBranches(gitCurrentBranch(), gitBranches(), configuration)
768
769 say.Info("joining existing session from " + currentWipBranch.remote(configuration).String())
770 if currentWipBranch.hasLocalBranch() && doBranchesDiverge(baseBranch.remote(configuration).Name, currentWipBranch.Name) {
771 say.Warning("Careful, your wip branch (" + currentWipBranch.Name + ") diverges from your main branch (" + baseBranch.remote(configuration).Name + ") !")
772 }
773
774 git("checkout", "-B", currentWipBranch.Name, currentWipBranch.remote(configuration).Name)
775 git("branch", "--set-upstream-to="+currentWipBranch.remote(configuration).Name, currentWipBranch.Name)
776}
777
778func startNewMobSession(configuration config.Configuration) {
779 currentBaseBranch, currentWipBranch := determineBranches(gitCurrentBranch(), gitBranches(), configuration)

Callers 1

startFunction · 0.85

Calls 10

InfoFunction · 0.92
WarningFunction · 0.92
determineBranchesFunction · 0.85
gitCurrentBranchFunction · 0.85
gitBranchesFunction · 0.85
doBranchesDivergeFunction · 0.85
gitFunction · 0.85
StringMethod · 0.80
remoteMethod · 0.80
hasLocalBranchMethod · 0.80

Tested by

no test coverage detected