GithubHelp home page GithubHelp logo

leto / jitterbug Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fcuny/jitterbug

1.0 2.0 0.0 4.38 MB

Cross Language Continuous Integration for Git

Home Page: http://lumberjaph.net/jitterbug/

Perl 84.50% CSS 9.69% JavaScript 0.88% Shell 4.93%

jitterbug's Introduction

Jitterbug : Cross Language Continuous integration for Git

What is Jitterbug?

Jitterbug is written in Perl 5 and depends on various CPAN modules, such as Moose, Dancer, DBIx::Class and others.

Installing Jitterbug

# You can also use Makefile.PL, but you will then have to manually 
perl Build.PL
# perl Makefile.PL

# install missing dependencies
./Build installdeps

# you can also use cpanm
# cpanm --installdeps .

# Look at config.yaml or example.yaml for how to configure your Jitterbug instance
$EDITOR config.yaml

# start the jitterbug Dancer app, which by default binds to port 3000
perl jitterbug.pl

# If you need to start it on a different port use -p
perl jitterbug.pl -p 3001

In another terminal, deploy a DBIx::Class schema ( which is SQLite by default, change the values in config.yml to tweak) :

perl scripts/jitterbug_db --config config.yml --deploy

Now add a post-receive hook to your github project that hits the /hook/ URL on the server that the jitterbug Dancer app is running on, i.e.

http://example.com:3001/hook/

Now you must start the builder, which actually clones a new git repo for each task (this could be network-intensive) and actually runs the build and test commands for each project.

perl scripts/builder.pl -c config.yml

Now, when you commit to a project that has a Jitterbug post-receive hook, the builder check periodically for a new task and build and test your projects!

Configuring Jitterbug

Take a look at example.yml, which uses all the advanced features of Jitterbug. The easiest thing is to copy this file and tweak it to your needs.

Most of the configuration changes that you will make are in the "jitterbug" and "plugins" config keys. Under the "jitterbug" key we have the keys "reports", "build", "build_process", "options", "branches" and "projects". Both the "reports" and "build" keys take a "dir" key, such as:

jitterbug:
reports:
    dir: /tmp/jitterbug
build:
    dir: /tmp/build

This means that reports should be stored in /tmp/jitterbug and build directories will be stored in /tmp/build.

The "build_process" section has the most options, which may be overwhelming at first. Most of them are related to how emails will be formatted. The first three config keys are the most important:

build_process: builder: ./scripts/capsule.sh builder_variables: "DEBUG=1" reuse_repo: 1

The "builder" key is a path to a script that detects the language and type of test suite and then builds and tests a repo. Unless Jitterbug doesn't know how to autodetect and run the tests in your repo (please tell us!), you won't have to change this config key.

The "build_variables" keys is for setting environment variabels in the builder process. Here, we set the environmanet variable DEBUG to a value of 1.

The "reuse_repo" key tells Jitterbug whether it should reuse Git repos, i.e. not clone them again and again. If you have large git repos, this config key can be a life saver to minimize bandwidth and the time to build + test a commit. If this is a true value, repos will be cached in the "build" directory specified above.

The rest of the options in this section are related to email notifications. The keys "on_failure" and "on_pass" list the name of a Perl class that handles emails. You probably won't need to change this.

The config key "on_failure_subject_prefix" can be used to tweak the subject lines of emails that Jitterbug sends. By default, they will begin with "[jitterbug] FAIL". Similarly, there is a "on_pass_subject_prefix" which defaults to "[jitterbug] PASS".

jitterbug's People

Contributors

leto avatar fcuny avatar xsawyerx avatar

Stargazers

 avatar

Watchers

Robert Buels avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.