Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

Commit

Permalink
Update build artifact path and add C++ standard library headers
Browse files Browse the repository at this point in the history
  • Loading branch information
langningchen committed Dec 23, 2023
1 parent 0f6ae16 commit f39ef11
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cmake-single-platform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ jobs:
uses: actions/upload-artifact@v2
with:
name: build
path: ${{github.workspace}}\build\MultiRename.exe
path: ${{github.workspace}}\build\Release\MultiRename.exe
42 changes: 41 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,46 @@
"ctime": "cpp",
"ratio": "cpp",
"iomanip": "cpp",
"sstream": "cpp"
"sstream": "cpp",
"any": "cpp",
"barrier": "cpp",
"bitset": "cpp",
"cfenv": "cpp",
"charconv": "cpp",
"chrono": "cpp",
"cinttypes": "cpp",
"complex": "cpp",
"condition_variable": "cpp",
"coroutine": "cpp",
"csetjmp": "cpp",
"csignal": "cpp",
"cstring": "cpp",
"cuchar": "cpp",
"forward_list": "cpp",
"list": "cpp",
"map": "cpp",
"unordered_set": "cpp",
"expected": "cpp",
"regex": "cpp",
"source_location": "cpp",
"format": "cpp",
"fstream": "cpp",
"future": "cpp",
"latch": "cpp",
"mutex": "cpp",
"ranges": "cpp",
"scoped_allocator": "cpp",
"semaphore": "cpp",
"shared_mutex": "cpp",
"span": "cpp",
"spanstream": "cpp",
"stacktrace": "cpp",
"stdfloat": "cpp",
"stop_token": "cpp",
"syncstream": "cpp",
"thread": "cpp",
"typeindex": "cpp",
"valarray": "cpp",
"variant": "cpp"
}
}
8 changes: 4 additions & 4 deletions main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -365,17 +365,17 @@ std::string ProceedRename(const FILE_INFO &File)
int a = std::stoi(Addison) - 1;
int b = std::stoi(Addison.substr(Addison.find('~') + 1)) - 1;
if (a < 0)
a = Value.length() + a + 1;
a = (int)Value.length() + a + 1;
else if (a == 0)
a = 1;
else if (a > (int)Value.length())
a = Value.length();
a = (int)Value.length();
if (b < 0)
b = Value.length() + b + 1;
b = (int)Value.length() + b + 1;
else if (b == 0)
b = 1;
else if (b > (int)Value.length())
b = Value.length();
b = (int)Value.length();
if (a > b)
std::swap(a, b);
Value = Value.substr(a, b - a + 1);
Expand Down

0 comments on commit f39ef11

Please sign in to comment.