sub:添加自动补全文件路径库。
This commit is contained in:
parent
444db54ce8
commit
de4437a7ca
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -1,3 +1,6 @@
|
|||||||
[submodule "ofen"]
|
[submodule "ofen"]
|
||||||
path = ofen
|
path = ofen
|
||||||
url = https://www.sinxmiao.cn/taynpg/ofen
|
url = https://www.sinxmiao.cn/taynpg/ofen
|
||||||
|
[submodule "filecomplete"]
|
||||||
|
path = filecomplete
|
||||||
|
url = https://www.sinxmiao.cn/taynpg/filecomplete
|
||||||
|
5
.vscode/settings.json
vendored
5
.vscode/settings.json
vendored
@ -21,7 +21,7 @@
|
|||||||
],
|
],
|
||||||
"visualizerFile": "${workspaceRoot}/.vscode/qt5.natvis",
|
"visualizerFile": "${workspaceRoot}/.vscode/qt5.natvis",
|
||||||
"args": [
|
"args": [
|
||||||
"-n", "0"
|
"-n", "2"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"cmake.environment": {
|
"cmake.environment": {
|
||||||
@ -145,5 +145,6 @@
|
|||||||
"text_encoding": "cpp",
|
"text_encoding": "cpp",
|
||||||
"*.in": "cpp"
|
"*.in": "cpp"
|
||||||
},
|
},
|
||||||
"makefile.configureOnOpen": false
|
"makefile.configureOnOpen": false,
|
||||||
|
"C_Cpp.default.configurationProvider": "ms-vscode.cmake-tools"
|
||||||
}
|
}
|
@ -30,6 +30,7 @@ add_subdirectory(net)
|
|||||||
add_subdirectory(util)
|
add_subdirectory(util)
|
||||||
add_subdirectory(server)
|
add_subdirectory(server)
|
||||||
add_subdirectory(client)
|
add_subdirectory(client)
|
||||||
|
add_subdirectory(filecomplete)
|
||||||
|
|
||||||
string(TIMESTAMP VERSION_BUILD_DATE "%Y-%m-%d %H:%M")
|
string(TIMESTAMP VERSION_BUILD_DATE "%Y-%m-%d %H:%M")
|
||||||
execute_process(
|
execute_process(
|
||||||
|
@ -8,7 +8,7 @@ if (MSVC)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_executable(tsc main.cpp client.h client.cpp config.h config.cpp)
|
add_executable(tsc main.cpp client.h client.cpp config.h config.cpp)
|
||||||
target_link_libraries(tsc PRIVATE trans_net trans_util)
|
target_link_libraries(tsc PRIVATE trans_net trans_util filecomplete)
|
||||||
if (UNIX)
|
if (UNIX)
|
||||||
target_link_libraries(tsc PRIVATE pthread)
|
target_link_libraries(tsc PRIVATE pthread)
|
||||||
endif()
|
endif()
|
||||||
|
@ -67,16 +67,17 @@ void CClient::run(const std::string& ip, const std::string& port)
|
|||||||
delete bf;
|
delete bf;
|
||||||
|
|
||||||
logger_->warn("SupportCmd:Get|Up|Down|Cancel|Update");
|
logger_->warn("SupportCmd:Get|Up|Down|Cancel|Update");
|
||||||
char line[512]{};
|
fc_append('|');
|
||||||
while (std::cin.getline(line, 512)) {
|
|
||||||
|
|
||||||
|
while (1) {
|
||||||
|
char* readline = fc_readline();
|
||||||
if (!th_run_) {
|
if (!th_run_) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
std::string cmd_input(readline);
|
||||||
std::string cmd_input(line);
|
fc_free(readline);
|
||||||
|
std::cout << "" << std::endl;
|
||||||
cmd_input = ofen::COfStr::trim(cmd_input);
|
cmd_input = ofen::COfStr::trim(cmd_input);
|
||||||
|
|
||||||
if (cmd_input == "end") {
|
if (cmd_input == "end") {
|
||||||
th_run_ = false;
|
th_run_ = false;
|
||||||
std::this_thread::sleep_for(std::chrono::milliseconds(10));
|
std::this_thread::sleep_for(std::chrono::milliseconds(10));
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
#include <string>
|
#include <string>
|
||||||
#include <util.h>
|
#include <util.h>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
#include <filecomplete.h>
|
||||||
|
|
||||||
using namespace ofen;
|
using namespace ofen;
|
||||||
struct DownClientInfo {
|
struct DownClientInfo {
|
||||||
|
1
filecomplete
Submodule
1
filecomplete
Submodule
@ -0,0 +1 @@
|
|||||||
|
Subproject commit bbd0d6a2471443e7d019f65207a072c1294b6fd7
|
Loading…
x
Reference in New Issue
Block a user