Skip to content

Commit

Permalink
Merge pull request #99300 from akien-mga/revert-pr98895
Browse files Browse the repository at this point in the history
Revert "Warn on unknown command line arguments"
  • Loading branch information
akien-mga authored Nov 16, 2024
2 parents 6c05ec3 + 4d4407c commit 5efd124
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions main/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1801,13 +1801,6 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph
} else if (arg == "--" || arg == "++") {
adding_user_args = true;
} else {
if (!FileAccess::exists(arg) && !DirAccess::exists(arg)) {
// Warn if the argument isn't recognized by Godot *and* the file/folder
// specified by a positional argument doesn't exist.
// This allows projects to read file or folder paths as a positional argument
// without printing a warning, as this scenario can't make use of user command line arguments.
WARN_PRINT(vformat("Unknown command line argument \"%s\". User arguments should be passed after a -- or ++ separator, e.g. \"-- %s\".", arg, arg));
}
main_args.push_back(arg);
}

Expand Down

0 comments on commit 5efd124

Please sign in to comment.