Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Report version number in output #19

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions anypiajs/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ set(CMAKE_VERBOSE_MAKEFILE on)

project(anypiajs)

project(anypiajs VERSION "2020.1")
project(anypiajs DESCRIPTION "The current version of the Social Security Detailed Calculator is 2020.1, which was released on December 31, 2019. It updates the 2019.2 version with the new economic information from the automatic adjustments announced on October 10, 2019.")

configure_file(anypiajsConfig.h.in
include_directories(${PROJECT_BINARY_BIN}))

if(CMAKE_SYSTEM_NAME STREQUAL Emscripten)
# CMake's Emscripten settings search for everything under
# the toolchain prefix, this breaks Boost find_package.
Expand Down
7 changes: 7 additions & 0 deletions anypiajs/PiaCalOutput.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,16 @@
#include "bendpia.h"
#include "WageInd.h"

#include "anypiajsConfig.h"

#include <vector>
#include <iostream>

using namespace json;




std::string PiaCalOutput::GetPIAMethodType(const PiaMethod* pMethod)
{
std::string strType;
Expand Down Expand Up @@ -377,4 +381,7 @@ void PiaCalOutput::AddWageBenefit(json::JSON& parent, const WageInd * pWageInd,
parent["PIAEligibility"] = piaEligibility;
parent["PIAAfterWindwfall"] = piaAfterWindfall;
parent["NoncoveredPosion"] = noncoveredPension;
parent["projectname"] = PROJECT_NAME;
parent["projectversion"] = PROJECT_VER;
parent["projectdescription"] = PROJECT_DESC;
}
11 changes: 11 additions & 0 deletions anypiajs/anypiajsConfig.h.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#ifndef INCLUDE_GUARD
#define INCLUDE_GUARD

#define PROJECT_NAME "@PROJECT_NAME@"
#define PROJECT_VER "@PROJECT_VERSION@"
#define PROJECT_DESC "@PROJECT_DESCRIPTION@"
#define PROJECT_VER_MAJOR "@PROJECT_VERSION_MAJOR@"
#define PROJECT_VER_MINOR "@PROJECT_VERSION_MINOR@"
#define PTOJECT_VER_PATCH "@PROJECT_VERSION_PATCH@"

#endif // INCLUDE_GUARD