创建项目
This commit is contained in:
commit
d8cccfca22
9
CMakeLists.txt
Normal file
9
CMakeLists.txt
Normal file
@ -0,0 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.30)
|
||||
project(sdktools)
|
||||
|
||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/bin)
|
||||
set(CMAKE_CXX_STANDARD 20)
|
||||
|
||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -static-libgcc -static-libstdc++")
|
||||
|
||||
add_executable(sdktools main.cpp)
|
20
main.cpp
Normal file
20
main.cpp
Normal file
@ -0,0 +1,20 @@
|
||||
#include <iostream>
|
||||
|
||||
using namespace std;
|
||||
int main() {
|
||||
while (true) {
|
||||
string command;
|
||||
cout << ">>>";
|
||||
getline(cin, command);
|
||||
|
||||
if (command == "list"){
|
||||
cout << "list" <<endl;
|
||||
}
|
||||
else if (command == "exit") {
|
||||
return 0;
|
||||
}
|
||||
else {
|
||||
printf("未知的指令\"%s\",请使用\"help\"获取更多帮助\n",command.c_str());
|
||||
}
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user