commit 2e82682318b0c7cda2ec798236e71c9048902ebf
parent 51f30fdd519ec62e63c060682219aed06e03de66
Author: vx_clutch <[email protected]>
Date: Tue, 11 Nov 2025 08:21:56 -0500
wip
Diffstat:
| M | main.c | | | 23 | +++++++++++------------ |
1 file changed, 11 insertions(+), 12 deletions(-)
diff --git a/main.c b/main.c
@@ -30,6 +30,7 @@ void usage(int status)
printf(" or: %s [options]\n\n", PROGRAM_NAME);
fputs(" -s enable shell creation mode\n", stdout);
fputs(" -S enable shell creation mode as a full project\n", stdout);
+ fputs(" -i ignore estruct.h and prompt for all\n", stdout);
fputs(" --help display this help and exit\n", stdout);
fputs(" --version output version information and exit\n", stdout);
@@ -38,8 +39,8 @@ void usage(int status)
int main(int argc, char **argv)
{
- int S = 0;
- int mode = -1;
+ int i = 0;
+ int shell_mode = 0;
char *package = NULL;
if (argc < 2)
@@ -56,14 +57,12 @@ int main(int argc, char **argv)
version();
exit(EXIT_SUCCESS);
}
- else if (strcmp(argv[i], "-s") == 0) {
- S = 1;
- mode = SINGLE;
- }
- else if (strcmp(argv[i], "-S") == 0) {
- S = 1;
- mode = FULL;
- }
+ else if (strcmp(argv[i], "-s") == 0)
+ shell_mode = SINGLE;
+ else if (strcmp(argv[i], "-S") == 0)
+ shell_mode = FULL;
+ else if (strcmp(argv[i], "-i") == 0)
+ i = 1;
else
die("unknown option");
}
@@ -74,8 +73,8 @@ int main(int argc, char **argv)
if (!package)
die("no package name provided");
- if (S == SINGLE || S == FULL)
- makeshell(package, mode);
+ if (shell_mode)
+ makeshell(package, shell_mode);
else
makeproj(package);