Answer the question
In order to leave comments, you need to log in
Git (BitBucket) + JIRA + PhpStorm - Work Plan?
Hello!
I'm getting started with git and I have a few questions.
Can you please tell me how to organize work with the code of several people?
Let's say JIRA got ahead of one big task and several small subtasks for it.
To do this, one developer creates a new branch, then works on tasks, for each subtask there is a separate commit.
And what should be next, how should the unification go?
1. After completion, does he push the entire new branch, or does he merge with master and push the master?
2. When does a developer delete a branch of their own code?
Further, it is clear that after that the developer declares a pull request and the administrator accepts it, right? Well, after all the others request a new version
With phpStorm, the following situation arose: if you initially push the branch and then merge it with the master, then the IDE in the 'push' window again offers to send all commits from the branch but already to the master.
How to solve this dilemma?
Answer the question
In order to leave comments, you need to log in
No no no. You don't think there at all.
Each feature is in a separate branch and preferably there is only one commit in it, updates are made amend, this will make it easy to pull your commits with a cherry pick instead of a merge, which is especially convenient when there are several stable releases.
Accordingly, the developer pushes everything to his repository, makes a pull request. Then the build is assembled by merging the main repository and a branch from the developer's turnip. If everything is OK, then we accept the pull request. Further, the development branches do not interfere with anyone, they can lie down. The main rap is relatively clean.
I hope I explained it clearly, we did a very large project with a bunch of versions and apobobo proved to be very good.
I usually work like this:
If one person is working on a task, then usually a separate branch from the master is created in the local repository, and the developer works there. If there are changes in the master, rebase commits from the master to a new branch will help (if you need the changes made to the master). Then, a rebase of commits from the new branch to master is simply done, and that same local branch is simply deleted as unnecessary. In the commit tree, everything will look as if everything was done in the master.
If more than one person is working on the task, then just push a new branch and work according to the same scheme, periodically synchronizing the changes. Again, upon completion of the work, the commits are rebase on the master and the branch (local and on the server) is deleted.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question