Create a minimal interactive shell

This commit is contained in:
2024-02-22 21:29:25 +01:00
parent bfb15f2d4a
commit 160a97930e
43 changed files with 1192 additions and 3264 deletions

16
shell/main.cpp Normal file
View File

@ -0,0 +1,16 @@
#include <cstdlib>
#include <unistd.h>
#include "elna/interactive.hpp"
int main()
{
if (!elna::enable_raw_mode())
{
std::perror("tcsetattr");
return EXIT_FAILURE;
}
std::atexit(elna::disable_raw_mode);
elna::loop();
return EXIT_SUCCESS;
}