Feat: better screen formating & better project resstructure

This commit is contained in:
AfonsoCMSousa
2026-08-05 13:40:42 +01:00
parent 7a4394feb6
commit f80dafd03d
14 changed files with 277 additions and 170 deletions
+9 -14
View File
@@ -20,28 +20,23 @@ typedef struct {
void kmain(void) {
user current_user = {.user_name = "admin", .user_hostname = "soraos", .user_id = 0};
__clear_screen();
clear_screen();
printf("SoraOS Kernel Initialized\n");
printf("\tWelcome to SoraOS\n");
printf("\tKernel Version %s\n", __KERNEL_VERSION);
printf("\tCompiled on: %s at %s\n\n", __DATE__, __TIME__);
// TODO: CLI IDEA
int _count = printf("%s@%s:>", current_user.user_name, current_user.user_hostname);
scursor(_count, text_pos.line);
while (1) {
// TODO: CLI IDEA
printf("%s@%s:$ ", current_user.user_name, current_user.user_hostname);
// TODO: Enable user input handling
char input_buffer[256] = {0};
scanf("%s", input_buffer);
printf("You entered: %s\n", input_buffer);
// TODO: Enable user input handling
char input_buffer[256] = {0};
scanf("%s", input_buffer);
printf("echo: %s\n", input_buffer);
}
int num1, num2;
printf("Enter num1: ");
scanf("%d", &num1);
printf("Enter num2: ");
scanf("%d", &num2);
printf("You entered: %d and %d\n", num1, num2);
// Infinite loop
while (1) {
__asm__ volatile("hlt");