48

I have been using open source projects for a while and been developing upon the open source applications and every so often I come across the words 'Nightly Build' and I have always been curious as to what it actually means. Does it literally mean the projects are done purely as side projects (usually at night after everyone has finished their day jobs) and there's no true contributor/dedicated development team or is it more complex than that?

  • 10
    Google failed you? joelonsoftware.com/articles/fog0000000023.html was pretty high on the list. Please update your question to identify specific things missing from this blog posting. – S.Lott Mar 9 '11 at 21:31
  • 1
    @S.Lott the link that you provide is quite long, it's good to have a shorter version or more straightforward answer here in stack-overflow. For those who wanted to know more about the topic can go to the link that you had provided. – Andrew Lam Oct 10 '17 at 6:17
66

No, it means that every night, everything that has been checked into source control is built. That build is a "nightly build".

  • 12
    Typically there is a machine running a script that will automatically pull all changes from the version control system, compile (build) all the code, and then post it somewhere to download or (if its a website or service) publish it to a test system and start it running. Another name this falls under is Continuous Integration System, although that may imply that a build is done the moment any commit to the VCS is performed. – CodexArcanum Mar 9 '11 at 21:29
  • 3
    It should also increment the version and stamp everything with the correct version number. Nothing is more frustrating than dealing with random builds from programmers that are built from stale code and wrong version numbers. A nightly build gives everyone a build and a version number they can trust. – jqa Mar 10 '11 at 1:40
33

Generally it means an automated build that is done once a day, typically after the end of the day for most of the developers. For projects with developers in multiple time zones it's generally a compromise time. The idea is that everyone who is going to check in code "today" has done so, and the automated build will make sure that everything compiles, and hopefully run the unit tests and any other automated tests etc that exist, then produce a final installer/executable etc.

13

It means a build that is performed at the end of each day of development. If you use a continuous integration server, it will generally be configured to build the code and run the unit tests on every check in. At the end of each day you may want to run more extensive tests, regression test and integration tests for example, which take too long to run on each check in and these would be triggered after the nightly build. If you have a full continuously delivery pipeline the nightly build may also be used to deploy the built code to environments for user testing.

6

The term is frequently used for large projects where a complete rebuild of the finished product from source takes too long for the individual developer to do this as a part of their normal development cycle.

Instead a complete rebuild is done automatically during the night so the build computer have 8-10-12 hours to do the build and have it ready for the developers coming in the next morning, so they can continue working on their individual tiny bit on top of the new version.

These days, it is frequent that the project includes a lot of tests ensuring the correct operation of the code, as well as generate and publish documentation from the source (like javadoc).

0

Nightly builds are good thing, they provide immediate feed back to developers if they broke the build. Having a nightly build means that the software is stable and likely to build for new users. Software that is not built regularly is difficult to release.

Quoted from: https://chess.eecs.berkeley.edu/softdevel/nightly.htm

  • 4
    this reads more like a comment, see How to Answer – gnat Nov 22 '14 at 10:09
  • reminds me of my exam days, that's how we used to start the answer of the questions. 😂😜 – ssi-anik Oct 31 '17 at 4:54
  • This explains what a nightly build is for, but it doesn't explain what a nightly build is. – Bryan Oakley Nov 3 '17 at 12:56

protected by gnat Nov 22 '14 at 10:08

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.