Giter Club home page Giter Club logo

abt's Introduction

Advanced Build Tool - abt

Advanced Build Tool is a shell scripts that simplify packages builds from a version control system or a local directory.

Overview

Abt is developed to build a distribution packages directly from a version control system. The latest version is integrated with docker so only functional docker is required to start build packages.

Features

  • Supported packaging systems: rpm, deb
  • Version control systems integration: git, svn
  • Build a project from arbitrary branch or tag
  • Build flow customization for a particular project

Modular functions design allows easy implementation of other packaging systems or additional features.

Description

The default build work flow provides the following stages:

  • checkout a project and optional required modules from a version control system
  • prepare build environment: install required packages which specified in rpm spec or deb control file
  • perform package(s) build
  • publish packages to a repository. directory repos in home of the user is configured by default

Getting started

While ready to use abt packages are provided at release page and can be installed on a host or VM, the recommended way is to use prepared docker images.

  1. Install and configure docker with non-root access for the user which will build packages. Please refer to appropriate for your OS documentation. Verify installation:
    docker run --rm -it hello-world
  2. Download abt.docker script and put it to appropriate location. As an instance:
    mkdir ~/bin
    curl -o ~/bin/abt.docker https://raw.githubusercontent.com/sergevs/abt/master/Docker/abt.docker
    chmod +x ~/bin/abt.docker
  3. In the order to build rpm packages it's required to define %packager macro, like that ( replace "Your name" an "your email" appropriately ):
    echo "%packager Your name <your email>" >> ~/.rpmmacros
  4. Ready to build packages. Verify to build abt itself:
    ~/bin/abt.docker sergevs42/centos7.x86_64-abt -v 3.1.2 sergevs/abt
    find ~/DockerBuild/repos 

Customization

It's possible to customize build behavior via various ways.

  1. DADD_OPTS environment variable allow to supply additional options to container build environment. As an instance you can provide additional repositories.
    export DADD_OPTS='-v<path to yum.repo>:/etc/yum.repos.d/additional.repo'
  2. ~/.abtrc allows to customize various aspects of abt
  3. Customize abt.docker script according to your needs

Options

See also:

abt.docker

Usage: Docker/abt.docker <docker image> -v <version> [OPTIONS] <vcs module path>

Supported images are:
NAME                                DESCRIPTION                                     STARS     OFFICIAL   AUTOMATED
sergevs42/centos6.x86_64-abt        abt ( https://github.com/sergevs/abt ) ima...   0                    [OK]
sergevs42/centos7.x86_64-abt        abt ( https://github.com/sergevs/abt ) ima...   0                    [OK]
sergevs42/debian8.amd64-abt         abt ( https://github.com/sergevs/abt ) ima...   0                    [OK]
sergevs42/debian9.amd64-abt         abt ( https://github.com/sergevs/abt ) ima...   0                    [OK]
sergevs42/debian7.amd64-abt         abt ( https://github.com/sergevs/abt ) ima...   0                    [OK]

And help for a particular image:

abt.docker sergevs42/debian8.amd64-abt -h

### Docker home is /home/builder/. ###

### user init ###

INFO: setting up container hostname to debian8.amd64-abt
Usage: abt -v <version> [OPTIONS] <vcs module path>

Options:
           [-a <release> ]
           [-b <trunk|branch|tag> ] 
           [-c <abt filename> ] 
           [-d <debug level> ]
           [-e <change log entry> ]
           [-h ]
           [-l <enable logging> ]
           [-n <vcs revision> ]
           [-o <build from spec file> ]
           [-m 0|1|<mock config> ]  0 - don't use mock, 1 - use mock, <mock config> - config file without arch and cfg extension
           [-p <rpmbuild  options> ]
           [-P rpm|deb ] package type to build
           [-r <repository> ]
           [-s <skip stages> ] 
           [-t <config type> ]
           [-u <vcs base URL> ]
           [-v <version>]
           [-A "module alias"]
           [-D "rpm macros"]
           [-C <full path to additional configuration file> (overrides /etc/abt/abtrc and ~/.abtrc)
           [-S <save build environment>]
           [-V [svn|git] version control system]

Default stages are:
Stage   1 => vcsPrepare
Stage   2 => pkgInitEnv
Stage  45 => debInstallDeps
Stage  50 => debBuild
Stage  70 => debRepoCopy
Stage  90 => cleanUp

Known projects ready to build

abt's People

Contributors

sergevs avatar newsgate avatar

Watchers

James Cloos avatar  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.