mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-08-06 22:08:41 +00:00
accept / command line arguments on windows
This commit is contained in:
@@ -98,9 +98,10 @@ cmd_line_from_string_list(Arena *arena, String8List command_line)
|
|||||||
next = node->next;
|
next = node->next;
|
||||||
String8 option_name = node->string;
|
String8 option_name = node->string;
|
||||||
|
|
||||||
// NOTE(rjf): Look at -- or - at the start of an argument to determine if it's
|
// NOTE(rjf): Look at --, -, or / (only on Windows) at the start of an
|
||||||
// a flag option. All arguments after a single "--" (with no trailing string
|
// argument to determine if it's a flag option. All arguments after a
|
||||||
// on the command line will be considered as input files.
|
// single "--" (with no trailing string on the command line will be
|
||||||
|
// considered as input files.
|
||||||
B32 is_option = 1;
|
B32 is_option = 1;
|
||||||
if(after_passthrough_option == 0)
|
if(after_passthrough_option == 0)
|
||||||
{
|
{
|
||||||
@@ -117,6 +118,11 @@ cmd_line_from_string_list(Arena *arena, String8List command_line)
|
|||||||
{
|
{
|
||||||
option_name = str8_skip(option_name, 1);
|
option_name = str8_skip(option_name, 1);
|
||||||
}
|
}
|
||||||
|
else if(operating_system_from_context() == OperatingSystem_Windows &&
|
||||||
|
str8_match(str8_prefix(node->string, 1), str8_lit("/"), 0))
|
||||||
|
{
|
||||||
|
option_name = str8_skip(option_name, 1);
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
is_option = 0;
|
is_option = 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user