diff options
Diffstat (limited to 'shell/commands.adb')
-rw-r--r-- | shell/commands.adb | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/shell/commands.adb b/shell/commands.adb new file mode 100644 index 0000000..d7971ce --- /dev/null +++ b/shell/commands.adb @@ -0,0 +1,35 @@ +-- +-- $Id$ +-- + +with Ada.Text_IO; use Ada.Text_IO; + +package body Commands is + + function Prompt return String is begin + return "RTEMS> "; + end Prompt; + + function C_Prompt return chars_ptr is + begin + return New_String (Prompt); + end C_Prompt; + + function Command_Test_Arguments + (ArgC : Argument_Count_Type; + ArgV : Argument_Vector_Type) + return int + is + Arguments : Argument_Array (1 .. ArgC); + Count : Argument_Count_Type := 1; + begin + Arguments := Argument_Vector_Package.Value (ArgV, ArgC); + loop + exit when Count > ArgC; + Put_Line (Value (Arguments (Count))); + Count := Count + 1; + end loop; + return 0; + end Command_Test_Arguments; + +end Commands; |