You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Posting as an issue, but it's more of a discussion of strategy.
I thought this a little more about how to best incorporate improvements on functions and make sure all is working before merging into main. I suggest the following branching strategy for refactoring functions (thanks to AI for organizing my early morning thoughts):
Main Refactor Branch (function_refactor):
All refactoring work will be done in the function_refactor branch.
This branch will act as the main branch for function refactoring tasks.
When creating a new branch for refactoring a specific function, always branch from function_refactor.
Specific Function Refactor Branches:
Each function refactor should have its own branch, which will stem from function_refactor.
The naming convention for these branches will be functionname_refactor. For example, if refactoring a function called sncm.LL, the branch should be called sncm.LL_refactor.
Example:
function_refactor → base branch for refactoring.
sncm.LL_refactor → branch specifically for refactoring the sncm.LL function.
bino.LL_refactor → branch for refactoring the bino.LL function.
Workflow:
Step 1: Create the base branch function_refactor (already created).
Step 2: For each function that needs refactoring, create a new branch named functionname_refactor.
Step 3: After completing the refactor for a specific function, open a pull request from the specific *_refactor branch to function_refactor.
Step 4: Once all refactoring work for individual functions is merged into function_refactor, it can be merged into the main branch by "Squash" method.
Ok thanks for this -- it's an intuitive workflow and it makes sense to me. I probably should have been more specific when naming my function refactor branch as 'myfeature_function_refactor'.
No problem. I'm also learning a lot about branch management. Trying to minimize convolution for me and all.
I just pushed new changes to function_refactor trying out git merge --no-ff . No PR for those changes, so seeing what works best. I like PRs better to make everyone aware of what happened.
Posting as an issue, but it's more of a discussion of strategy.
I thought this a little more about how to best incorporate improvements on functions and make sure all is working before merging into
main
. I suggest the following branching strategy for refactoring functions (thanks to AI for organizing my early morning thoughts):Main Refactor Branch (
function_refactor
):function_refactor
branch.function_refactor
.Specific Function Refactor Branches:
function_refactor
.functionname_refactor
. For example, if refactoring a function calledsncm.LL
, the branch should be calledsncm.LL_refactor
.Example:
function_refactor
→ base branch for refactoring.sncm.LL_refactor
→ branch specifically for refactoring thesncm.LL
function.bino.LL_refactor
→ branch for refactoring thebino.LL
function.Workflow:
function_refactor
(already created).functionname_refactor
.*_refactor
branch tofunction_refactor
.function_refactor
, it can be merged into themain
branch by "Squash" method.See A successful Git branching model for more details on this model.
This method helps keep each function's refactoring isolated, making it easier to review, test, and merge individual changes.
Related to #7 and #4
The text was updated successfully, but these errors were encountered: