Git Workflow with Capistrano

I am trying to use a good git workflow using capistrano. I found some good articles , but I either do not fully understand what they are offering (probably), or they are missing.

Here is what I had in mind so far, but I was catching up when merging back into the main branch (i.e. before moving on to the scene? After?) And tried to connect it to capistrano for deployments:

  • Make sure you are aware of all the changes made on the remote main branch by other developers
    • git checkout master
    • git pull
  • Create a new branch that relates to the specific error you are trying to fix
    • git checkout -b bug-fix-branch
  • Make changes
    • git status
    • git add .
    • git commit -m "Friendly message about the commit"

So this is usually the place where I get stuck. At the moment, I have a master branch , which is healthy, and a new bug-chip-branch , which contains my (unverified - except for unit tests) changes.

( cap staging deploy), ( , , )? ( , production.rb )? git-deployment, , , , .

? , , git, , .

Help!

+5
1

, , , "" , . gem 'capistrano-ext', ( , , , ). capistrano-ext , , , "", set :branch, "staging", . :

#after commiting on bug-fix branch
git checkout staging # => tracks staging on origin
git merge bug-fix-branch # => bring new code in
git push origin staging # => capsitrano acts locally, it needs the code to get from origin
cap staging deploy # => wasnt that easy?

, git

  • master-edge code,
  • - , ( )
  • - ( )

EDIT: , .

, . prod , . , prod , prod , HEAD prod, , , , . , , , , , , ( , , , ). , , - prod . pro git.org .

+3

All Articles