update to 1.1
This commit is contained in:
13
src/main.cpp
13
src/main.cpp
@@ -3,12 +3,16 @@
|
|||||||
|
|
||||||
#include "IO.h"
|
#include "IO.h"
|
||||||
|
|
||||||
|
#define ASSEMBLEUR_VERSION "1.1"
|
||||||
|
|
||||||
int main(int argc, char** argv) {
|
int main(int argc, char** argv) {
|
||||||
|
|
||||||
argparse::ArgumentParser program("Assembleur");
|
argparse::ArgumentParser program("Assembleur", ASSEMBLEUR_VERSION);
|
||||||
|
|
||||||
std::string inputFileName;
|
std::string inputFileName;
|
||||||
program.add_argument("file").help("The assembly file to compile").store_into(inputFileName);
|
program.add_argument("file")
|
||||||
|
.help("The assembly file to compile")
|
||||||
|
.store_into(inputFileName);
|
||||||
|
|
||||||
std::string outputFileName;
|
std::string outputFileName;
|
||||||
program.add_argument("-o", "--output")
|
program.add_argument("-o", "--output")
|
||||||
@@ -33,10 +37,7 @@ int main(int argc, char** argv) {
|
|||||||
.store_into(header);
|
.store_into(header);
|
||||||
|
|
||||||
bool reverse;
|
bool reverse;
|
||||||
program.add_argument("-r", "--reversed")
|
program.add_argument("-r", "--reversed").help("inverse bit orders").flag().store_into(reverse);
|
||||||
.help("inverse bit orders")
|
|
||||||
.flag()
|
|
||||||
.store_into(reverse);
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
program.parse_args(argc, argv);
|
program.parse_args(argc, argv);
|
||||||
|
|||||||
Reference in New Issue
Block a user