2020-01-18 08:38:21 +00:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
|
|
|
|
*
|
2021-04-22 08:24:48 +00:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-01-18 08:38:21 +00:00
|
|
|
*/
|
|
|
|
|
2020-08-05 17:35:13 +00:00
|
|
|
#include <LibCore/ArgsParser.h>
|
2019-06-01 10:10:35 +00:00
|
|
|
#include <stdio.h>
|
2020-02-18 09:46:06 +00:00
|
|
|
#include <unistd.h>
|
2019-06-01 10:10:35 +00:00
|
|
|
|
|
|
|
int main(int argc, char** argv)
|
|
|
|
{
|
2020-02-18 09:46:06 +00:00
|
|
|
if (pledge("stdio", nullptr) < 0) {
|
|
|
|
perror("pledge");
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
|
2020-08-05 17:35:13 +00:00
|
|
|
const char* string = "yes";
|
|
|
|
|
|
|
|
Core::ArgsParser args_parser;
|
|
|
|
args_parser.add_positional_argument(string, "String to output (defaults to 'yes')", "string", Core::ArgsParser::Required::No);
|
|
|
|
args_parser.parse(argc, argv);
|
|
|
|
|
|
|
|
for (;;)
|
|
|
|
puts(string);
|
2019-06-01 10:10:35 +00:00
|
|
|
return 0;
|
|
|
|
}
|