#------------------------------------------------------------------------------
# Rake Tasks
#------------------------------------------------------------------------------
-#task :default
+task :default => [:build]
desc "Build the AFM release binary"
task :build do
#include <ncurses.h>
+#include <stdbool.h>
+
+bool Running = true;
+
+void handle_input(char ch) {
+ if(ch == 'q')
+ Running = false;
+}
int main(int argc, char** argv) {
initscr();
- printw("Hello World !!!");
- refresh();
- getch();
+ raw();
+ keypad(stdscr, TRUE);
+ noecho();
+ printw("Hello, World! Please Press 'q' to quit.");
+ while(Running) {
+ refresh();
+ handle_input(getch());
+ }
endwin();
return 0;
}