diff options
| author | Evsyukov Denis Anatolyevich <[email protected]> | 2020-01-09 15:28:07 +0300 |
|---|---|---|
| committer | Evsyukov Denis Anatolyevich <[email protected]> | 2020-01-09 15:28:07 +0300 |
| commit | df81d3d62297a4f0cffbf8ff4acc368ee2896b9a (patch) | |
| tree | 55a795b4df8659aa5e9937988456a4ea16d9e687 /src/main.cpp | |
| parent | First commit (diff) | |
| download | t-df81d3d62297a4f0cffbf8ff4acc368ee2896b9a.tar.xz t-df81d3d62297a4f0cffbf8ff4acc368ee2896b9a.zip | |
Added sha256 functions
Diffstat (limited to 'src/main.cpp')
| -rw-r--r-- | src/main.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/main.cpp b/src/main.cpp index be82bf1..b5f6099 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -4,6 +4,7 @@ #include "cxxopts.hpp" #include "functions.hpp" +#include "sha256/sha256.h" using namespace std; @@ -34,13 +35,14 @@ int main(int argc, char *argv[]) { exit(0); } if (result.count("positional")) { - std::cout << "Positional = {" << std::endl; std::string str; auto &v = result["positional"].as<std::vector<std::string>>(); for (const auto &s : v) { str += s + " "; } - std::cout << "\"" << trim(str) << "\"" << std::endl << "}" << std::endl; + str = trim(str); + + cout << "sha256('" << str << "'): " << sha256(str) << endl; } std::string taskdir; if (result.count("taskdir")) { |