James Kuszmaul | b13e13f | 2023-11-22 20:44:04 -0800 | [diff] [blame^] | 1 | // Copyright (c) FIRST and other WPILib contributors. |
| 2 | // Open Source Software; you can modify and/or share it under the terms of |
| 3 | // the WPILib BSD license file in the root directory of this project. |
| 4 | |
| 5 | #include <string_view> |
| 6 | |
| 7 | #ifndef RUNNING_SYSID_TESTS |
| 8 | |
| 9 | void Application(std::string_view saveDir); |
| 10 | |
| 11 | #ifdef _WIN32 |
| 12 | int __stdcall WinMain(void* hInstance, void* hPrevInstance, char* pCmdLine, |
| 13 | int nCmdShow) { |
| 14 | int argc = __argc; |
| 15 | char** argv = __argv; |
| 16 | #else |
| 17 | int main(int argc, char** argv) { |
| 18 | #endif |
| 19 | std::string_view saveDir; |
| 20 | if (argc == 2) { |
| 21 | saveDir = argv[1]; |
| 22 | } |
| 23 | |
| 24 | Application(saveDir); |
| 25 | |
| 26 | return 0; |
| 27 | } |
| 28 | |
| 29 | #endif |