buildnumberinc

command module
v0.0.0-...-7ae2af4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 22, 2019 License: MIT Imports: 12 Imported by: 0

README

BuildNumberInc

BuildNumberInc is an application to auto-increment the build number of a C/C++ project

Note

This repository is archived because I have no use for this application any more.

Usage

Add the executable and the arguments to the pre-build step of your IDE.

If the build number is declared as a #define no flags are needed. If the build number is declared as a const use the -c flag. If you want to use only LF (and not CRLF) as line endings in the source file use -r flag. If you want to see the changed build number add the -v flag.

Example
Atollic TrueSTUDIO for ARM

In project properties -> C/C++ Build -> Settings -> Build Steps -> Pre-build steps -> Command

for a #define set:

<path_to_BuildNumberInc.exe>\BuildNumberInc.exe -v <path_to_file>\version.h SW_VER_BUILD

for a const set:

<path_to_BuildNumberInc.exe>\BuildNumberInc.exe -c -v <path_to_file>\version.h verBuildNo_0
Test file (version.h)
#ifndef VERSION_H
#define VERSION_H

#define SW_VER_MAJOR	1
#define SW_VER_MINOR	8
#define SW_VER_BUILD	28		// build number

namespace YourNamespace {

    const unsigned int verBuildNo_0 = 14; // a comment
    const uint16_t verBuildNo_1 = 27; // another comment

} // namespace

#endif // VERSION_H

Building the package

BuildNumberInc is a simple package so, if you have Go installed and added to your path, just type go build in the source directory.

License

BuildNumberInc is released under the MIT License.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL