diff --git a/.gitignore b/.gitignore index 54a30bb..98f73e9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1 @@ -uwufetch -res/* \ No newline at end of file +uwufetch \ No newline at end of file diff --git a/README.md b/README.md index 2c343f0..8d34a89 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,9 @@ To uninstall: cd uwufetch make uninstall ``` +## Images + +[IMAGES.md](https://github.com/TheDarkBug/uwufetch/tree/main/res/IMAGES.md) ## License This program is provided under the [GPL-3.0 License](https://github.com/TheDarkBug/uwufetch/LICENSE). diff --git a/res/IMAGES.md b/res/IMAGES.md new file mode 100644 index 0000000..f816447 --- /dev/null +++ b/res/IMAGES.md @@ -0,0 +1,24 @@ +# Image logos + +Int this directory, all the images for the logos, are stored. +If you want to remove *your* image from this repository contact me on [reddit](https://www.reddit.com/user/TheDarkBug). + +## Credits + +image Nyarch Linuwu by u/Ishaan_P ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lxfg9j/someone_posted_uwuntu_so_i_made_nyarch/)) +image Nyartix Linuwu by u/akzcake ([original post](https://www.reddit.com/r/linuxmasterrace/comments/ly6wd1/nyartix/)) +image Debinyan by u/Ishaan_P ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lxqip4/debinyan/)) +image Endowo Os by u/zuru2003 ([original post](https://www.reddit.com/r/linuxmasterrace/comments/ly9zed/endowo_os/)) +image Fedowa by u/iD3nis124 ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lxjp3s/saw_nyarch_and_had_to_do_fedowa/)) +image GentOwO by u/Abbix57 ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lyeija/gentowo/)) +image Myanjawo by u/matrixrunner ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lxx9h7/myanjawo_also_in_wallpaper/)) +image Miwint by u/iD3nis124 ([original post](https://www.reddit.com/r/linuxmasterrace/comments/ly8oy0/seen_a_lot_of_people_asking_for_mint_so_here_it_is/)) +image KDE Uwon by u/muff2 ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lxt82v/kde_uwon/)) +image NwnixOS by u/ant-artica ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lzdwl4/nixowos/)) +image OwOsuse by u/VortexAcherontic ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lyhgxp/my_better_attempt_on_owosuse/)) +image Pop UwUs by u/Mochimo786 ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lxz3xu/pop_uwus/)) +image Slawkyware by u/theldus ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lyt6xi/slawckyware/)) +image Sowus by u/welpelp ([original post](https://www.reddit.com/r/linuxmasterrace/comments/ly9il3/continuing_the_trend_i_made_sowus_my_first/)) +image Tuwu by u/Annual-Examination96 ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lz2i32/tuwu/)) +image Uwuntu by u/Chicki2D ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lwsnul/uwuntu/)) +image Owoid by u/Satoqz ([original post](https://www.reddit.com/r/linuxmasterrace/comments/lxnjwd/my_boyfriend_decided_to_create_owoid/)) \ No newline at end of file diff --git a/res/artix.png b/res/artix.png new file mode 100644 index 0000000..851e61c Binary files /dev/null and b/res/artix.png differ diff --git a/res/debian.png b/res/debian.png new file mode 100644 index 0000000..47973a0 Binary files /dev/null and b/res/debian.png differ diff --git a/res/endeavour.png b/res/endeavour.png new file mode 100644 index 0000000..08aa9fb Binary files /dev/null and b/res/endeavour.png differ diff --git a/res/fedora.png b/res/fedora.png new file mode 100644 index 0000000..cfa767f Binary files /dev/null and b/res/fedora.png differ diff --git a/res/gentoo.png b/res/gentoo.png new file mode 100644 index 0000000..c673a0b Binary files /dev/null and b/res/gentoo.png differ diff --git a/res/manjaro.png b/res/manjaro.png new file mode 100644 index 0000000..d3f867b Binary files /dev/null and b/res/manjaro.png differ diff --git a/res/mint.png b/res/mint.png new file mode 100644 index 0000000..6e15dcb Binary files /dev/null and b/res/mint.png differ diff --git a/res/neon.png b/res/neon.png new file mode 100644 index 0000000..94c1f04 Binary files /dev/null and b/res/neon.png differ diff --git a/res/nixos.png b/res/nixos.png new file mode 100644 index 0000000..f7123a9 Binary files /dev/null and b/res/nixos.png differ diff --git a/res/opensuse.png b/res/opensuse.png new file mode 100644 index 0000000..631c608 Binary files /dev/null and b/res/opensuse.png differ diff --git a/res/pop_os.png b/res/pop_os.png new file mode 100644 index 0000000..9a51f10 Binary files /dev/null and b/res/pop_os.png differ diff --git a/res/slackware.png b/res/slackware.png new file mode 100644 index 0000000..0971275 Binary files /dev/null and b/res/slackware.png differ diff --git a/res/solus.png b/res/solus.png new file mode 100644 index 0000000..cf35873 Binary files /dev/null and b/res/solus.png differ diff --git a/res/tux.png b/res/tux.png new file mode 100644 index 0000000..3d24244 Binary files /dev/null and b/res/tux.png differ diff --git a/res/ubuntu.png b/res/ubuntu.png new file mode 100644 index 0000000..4068ade Binary files /dev/null and b/res/ubuntu.png differ diff --git a/res/void.png b/res/void.png new file mode 100644 index 0000000..3702aa7 Binary files /dev/null and b/res/void.png differ diff --git a/uwufetch.c b/uwufetch.c index ecdd19e..7bacdfb 100644 --- a/uwufetch.c +++ b/uwufetch.c @@ -31,28 +31,30 @@ void print_image(); void usage(char*); int main(int argc, char *argv[]) { - int opt = 0; + int opt = 0, a_i_flag = 0; get_info(); //sprintf(version_name, "%s", "debian"); // a debug thing - while((opt = getopt(argc, argv, "a:hi")) != -1) { + while((opt = getopt(argc, argv, "ad:hi")) != -1) { switch(opt) { case 'a': - if (optarg) sprintf(version_name, "%s", optarg); - if (opt != 'i') print_ascii(); + a_i_flag = 0; break; - case 'i': + case 'd': if (optarg) sprintf(version_name, "%s", optarg); - if (opt != 'a') print_image(); break; case 'h': usage(argv[0]); return 0; + case 'i': + a_i_flag = 1; + break; default: break; } } - if (argc == 1) print_ascii(); + if (argc == 1 || a_i_flag == 0) print_ascii(); + else if (a_i_flag) print_image(); print_info(); } @@ -92,7 +94,7 @@ int pkgman() { // this is just a function that returns the total of installed pa } void print_info() { // print collected info - printf("\033[8A\033[17C %s%s%s@%s\n", NORMAL, BOLD, user, host); + printf("\033[9A\033[17C %s%s%s@%s\n", NORMAL, BOLD, user, host); printf("\033[17C %s%sOWOS %s%s\n", NORMAL, BOLD, NORMAL, version_name); printf("\033[17C %s%sKERNEL %s%s %s\n", NORMAL, BOLD, NORMAL, sys_var.release, sys_var.machine); printf("\033[17C %s%sCPUWU %s%s\n", NORMAL, BOLD, NORMAL, cpu_model); @@ -132,7 +134,7 @@ void get_info() { // get all necessary info void print_ascii() { // prints logo (as ascii art) of the given system. distributions listed alphabetically. if (strcmp(version_name, "arch") == 0) { sprintf(version_name, "%s", "Nyarch Linuwu"); - printf( "\033[8C%s/\\\n" + printf( "\033[1E\033[8C%s/\\\n" " / \\\n" " /\\ \\\n" " / > w <\\\n" @@ -141,7 +143,7 @@ void print_ascii() { // prints logo (as ascii art) of the given system. distribu " /_-'' ''-_\\\n\n", BLUE); } else if (strcmp(version_name, "artix") == 0) { sprintf(version_name, "%s", "Nyartix Linuwu"); - printf( "\033[8C%s/\\\n" + printf( "\033[1E\033[8C%s/\\\n" " / \\\n" " /`'.,\\\n" " /\u2022 w \u2022 \\\n" @@ -150,7 +152,7 @@ void print_ascii() { // prints logo (as ascii art) of the given system. distribu " /.,'` `'.\\\n\n", BLUE); } else if (strcmp(version_name, "debian") == 0) { sprintf(version_name, "%s", "Debinyan"); - printf( "\033[6C%s______\n" + printf( "\033[1E\033[6C%s______\n" " / ___ \\\n" " | / OwO |\n" " | \\____-\n" @@ -158,7 +160,7 @@ void print_ascii() { // prints logo (as ascii art) of the given system. distribu " --_\n\n\n", RED); } else if (strcmp(version_name, "fedora") == 0) { sprintf(version_name, "%s", "Fedowoa"); - printf( "\033[8C%s_____\n" + printf( "\033[1E\033[8C%s_____\n" " / __)%s\\\n" " %s> %s| / %s<%s\\ \\\n" " __%s_| %sw%s|_%s_/ /\n" @@ -168,7 +170,7 @@ void print_ascii() { // prints logo (as ascii art) of the given system. distribu " %s\\%s(_____/\n", BLUE, CYAN, WHITE, BLUE, WHITE, CYAN, BLUE, CYAN, BLUE, CYAN, BLUE, CYAN, BLUE, CYAN, BLUE, CYAN, BLUE); } else if (strcmp(version_name, "gentoo") == 0) { sprintf(version_name, "%s", "GentOwO"); - printf( "%s _-----_\n" + printf( "\033[1E\033[3C%s_-----_\n" " ( \\\n" " \\ OwO \\\n" "%s \\ )\n" @@ -177,7 +179,7 @@ void print_ascii() { // prints logo (as ascii art) of the given system. distribu " \\____-\n\n", MAGENTA, WHITE); } else if (strcmp(version_name, "manjaro") == 0) { sprintf(version_name, "%s", "Myanjawo"); - printf( " \u25b3 \u25b3 \u25e0\u25e0\u25e0\u25e0\n" + printf( "\033[0E\033[1C\u25b3 \u25b3 \u25e0\u25e0\u25e0\u25e0\n" " \e[0;42m \e[0m \e[0;42m \e[0m\n" " \e[0;42m \e[0m\e[0;42m\e[1;30m > w < \e[0m\e[0;42m \e[0m \e[0;42m \e[0m\n" " \e[0;42m \e[0m \e[0;42m \e[0m\n"