mirror of
https://github.com/kidfromjupiter/nearby.git
synced 2026-09-16 15:36:12 -04:00
Move the increment rename tag (x) from before the first dot to before the last dot.
PiperOrigin-RevId: 477849732
This commit is contained in:
committed by
Copybara-Service
parent
8f681dece0
commit
646c3e5020
@@ -156,8 +156,8 @@ std::string CreateOutputFileWithRename(absl::string_view path) {
|
||||
|
||||
int count = 0;
|
||||
|
||||
// Locate the first dot
|
||||
auto first = file_name.find_first_of('.', 0);
|
||||
// Locate the last dot
|
||||
auto first = file_name.find_last_of('.');
|
||||
|
||||
if (first == std::string::npos) {
|
||||
first = file_name.size();
|
||||
|
||||
@@ -38,7 +38,7 @@ constexpr absl::string_view kOneIterationNoDotsFileName(
|
||||
"/incrementfiletesttxt (1)");
|
||||
constexpr absl::string_view kMultipleDotsFileName("/increment.file.test.txt");
|
||||
constexpr absl::string_view kOneIterationMultipleDotsFileName(
|
||||
"/increment (1).file.test.txt");
|
||||
"/increment.file.test (1).txt");
|
||||
constexpr absl::string_view kImmediateEscape("../");
|
||||
constexpr absl::string_view kLongEscapeBackSlash("..\\test\\..\\..\\test");
|
||||
constexpr absl::string_view kTwoLevelFolder("/test/test");
|
||||
|
||||
Reference in New Issue
Block a user