-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #49 from BU-Tools/release/v3.0
Release/v3.0
- Loading branch information
Showing
9 changed files
with
129 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#ifndef __VERSION_TRACKER_HH__ | ||
#define __VERSION_TRACKER_HH__ 1 | ||
|
||
#include <vector> | ||
#include <string> | ||
#include <stdint.h> | ||
class VersionTracker { | ||
public: | ||
VersionTracker(){ | ||
sVersion = "Not Initialized"; | ||
repositoryURI = "Not Initialized"; | ||
}; | ||
VersionTracker(std::vector<uint32_t> nVer, | ||
std::string sVer, | ||
std::string repoURI): | ||
nVersion(nVer), | ||
sVersion(sVer), | ||
repositoryURI(repoURI){ | ||
}; | ||
std::vector<uint32_t> GetNumericVer(){return nVersion;}; | ||
std::string GetHumanVer() {return sVersion;}; | ||
std::string GetRepositoryURI(){return repositoryURI;}; | ||
private: | ||
std::vector<uint32_t> nVersion; | ||
std::string sVersion; | ||
std::string repositoryURI; | ||
}; | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
GIT_VERSION="$(shell git describe --dirty --always --tags )" | ||
GIT_HASH=$(shell git rev-parse --verify HEAD | awk 'BEGIN{line="";comma=""}{for (i=0;i<length($$0);i+=8){line =line comma " 0x" substr($$0,i,8);comma=","}}END{print line}') | ||
GIT_REPO="$(shell git ls-remote --get-url)" | ||
|
||
VERSION_FILE=src/BUTool/Version.cc | ||
|
||
define VERSION_BODY | ||
#include <BUTool/DeviceFactory.hh> | ||
|
||
VersionTracker const BUTool::DeviceFactory::BUToolVersion = VersionTracker({$(GIT_HASH)}, | ||
$(GIT_VERSION), | ||
$(GIT_REPO)); | ||
endef | ||
export VERSION_BODY | ||
|
||
$(VERSION_FILE): | ||
@echo "$$VERSION_BODY">$(VERSION_FILE) | ||
|
||
clean_version: | ||
@rm -f $(VERSION_FILE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters