Skip to content

blakemcbride/Bld

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BLD - Build System

Build systems such as Maven and Gradle are great build systems if you are building a simple, standard application. You follow their conventions, and building is automatic! But, if you want to build something complex or non-standard, things get really complex really fast. Sometimes, the simplest variation over their standard configuration can be inordinately complex or require all sorts of plugins. Worse yet, if the build process is complex enough, you find that parts of your application are now embedded in your build process. Thus, Maven essentially becomes part of your application.

BLD is a build system that is simple to use and simple to create custom processes. It was extracted from the KISS open-source, full-stack, Java-based web development framework available at https://github.com/blakemcbride/kiss. BLD is as simple as Maven when building applications that are simple to build. But with BLD, it is far easier to add custom build processes to your application.

BLD is smart, so it doesn't perform functions that are already done. Your build program specifies all the needed steps, but BLD only actually executes the steps necessary.

BLD is portable to Linux, macOS, Windows, and other systems.

The sample tasks that come with BLD mimic Maven's structure, so things will look familiar. Currently, BLD has only been used for Java applications. But there is no reason it couldn't be used with other languages.

BLD includes the following files:

  • builder/Tasks.java - the application-specific build procedures (or tasks)
  • builder/BuildUtils.java - the generic utilities needed to build
  • bld - the program that drives the process (Linux, macOS, etc.)
  • bld.cmd - the Windows version of bld
  • builder/commons-compress-1.20.jar - needed to extract jar files

Usage

All interactions with the system are through the bld script (or bld.cmd in the case of Windows). Except for Windows, you will normally need to execute the bld program with a leading ./

The only file you should have to edit is the Tasks.java file.

The following commands are supported:

  • bld help - print a help message
  • bld list-tasks - print a list of valid tasks
  • bld build - build the application
  • bld run [argument]... - run the application
  • bld jar - build an application jar file
  • bld javadoc - build javadoc files
  • bld libs - download foreign jar files (normally done by other tasks)
  • bld clean - remove the built files
  • bld realclean - remove the built files and downloaded jar files
  • bld ideclean - realclean + remove the IDE files

Default Structure

With BLD, you can structure your system any way you like. However, the way it comes out of the box is as follows:

  • src/main/java - the source root of your source code
  • libs - the directory for your local and foreign jar files
  • target/classes - the compiled classes
  • target/javadoc - the javadoc files
  • app.jar - the application jar file
  • builder - the bld system files

Requirements

  • Java 8 or later

You do not need to build the system. The system builds itself anytime something changes.

Installation

There is an installation script (install or install.cmd) that can be used to install bld into your application.

About

Build System

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published