-1

What's the difference between trunk and branch in jenkins?

BenMorel
  • 30,280
  • 40
  • 163
  • 285
user1624173
  • 55
  • 1
  • 1
  • 6
  • Could you elaborate on your question? Are you referring to the source code of Jenkins itself? Or a feature within Jenkins or a Jenkins plugin? – ngm Feb 14 '13 at 08:46
  • No, No I am not referring to the source code of jenkins, Actually i am a newbie to the jenkins. I am not getting any idea about branch and trunk in jenkins. – user1624173 Feb 14 '13 at 09:48
  • @ngm can you please suggest some link or help me to understand these terms. – user1624173 Feb 14 '13 at 09:49

1 Answers1

2

It sounds like you're just interested in the terms trunk and branch in general in relation to source control. Trunk generally refers to the "main" version of source for a piece of software, and a branch is a (usually temporary) diversion from this main line, usually to work on a feature which is then merged back in to the trunk.

The details depend on which version control system you are using, but here's a description in relation to SVN:

Trunk would be the main body of development, originating from the start of the project until the present.

Branch will be a copy of code derived from a certain point in the trunk that is used for applying major changes to the code while preserving the integrity of the code in the trunk. If the major changes work according to plan, they are usually merged back into the trunk.

As it relates to Jenkins, you're probably interested in which version of the software the continuous integration process should be building. I'd suggest more often than not it will be the trunk, as this is the canonical version, and the one most likely to be the candidate for release. But you might have branches for legacy version, etc, which might need building too. But it will depend of course on the process for any given company/project.

Community
  • 1
  • 1
ngm
  • 6,897
  • 1
  • 49
  • 60