| 1 | /** |
| 2 | * \file src/opustags.cc |
| 3 | * \brief Main function for opustags. |
| 4 | * |
| 5 | * See opustags.h for the program's documentation. |
| 6 | */ |
| 7 | |
| 8 | #include <opustags.h>cxx . . $ `<file>/src/opustags.h`/ |
| 9 | |
| 10 | #include <locale.h> |
| 11 | |
| 12 | /** |
| 13 | * Main function of the opustags binary. |
| 14 | * |
| 15 | * Does practically nothing but call the cli module. |
| 16 | */ |
| 17 | int maincxx . . $ main(afcd3168fc1188a4).(int argc, char** argv) { |
| 18 | try { |
| 19 | setlocale(LC_ALLcxx . . $ `<external>/3736975272097309885/locale.h:41:9`!, ""); |
| 20 | otcxx . . $ ot/::optionscxx . . $ ot/options# opt = otcxx . . $ ot/::parse_optionscxx . . $ ot/parse_options(be20433a3686cf7a).(argc, argv, stdincxx . . $ `<external>/232824719582829767/stdio.h:153:9`!); |
| 21 | otcxx . . $ ot/::runcxx . . $ ot/run(47bf986496f380f8).(opt); |
| 22 | return 0; |
| 23 | } catch (const otcxx . . $ ot/::statuscxx . . $ ot/status#& rc) { |
| 24 | if (!rc.messagecxx . . $ ot/status#message..emptycxx . . $ std/__cxx11/basic_string#empty(3482b152b9333168).()) |
| 25 | fprintf(stderrcxx . . $ `<external>/232824719582829767/stdio.h:155:9`!, "error: %s\n", rc.messagecxx . . $ ot/status#message..c_strcxx . . $ std/__cxx11/basic_string#c_str(8e614c7de0b1573e).()); |
| 26 | return rc == otcxx . . $ ot/::stcxx . . $ ot/st#::bad_argumentscxx . . $ ot/st#bad_arguments. ? 2 : 1; |
| 27 | } |
| 28 | } |