9
9
#include < iostream>
10
10
#include < vector>
11
11
12
- static bool copyFolder (const char * source, const char * destination) {
12
+ [[gnu::unused]] static bool copyFolder (const char * source, const char * destination) {
13
13
DIR* dir = opendir (source);
14
14
if (dir == nullptr ) {
15
15
printf (" Failed to open source directory\n " );
@@ -75,7 +75,7 @@ static bool copyFolder(const char* source, const char* destination) {
75
75
return true ;
76
76
}
77
77
78
- static std::string replaceLastPathComponent (const std::string& path, const std::string& newComponent) {
78
+ [[gnu::unused]] static std::string replaceLastPathComponent (const std::string& path, const std::string& newComponent) {
79
79
size_t lastSlashIndex = path.find_last_of (' /' );
80
80
if (lastSlashIndex != std::string::npos) {
81
81
std::string newPath = path.substr (0 , lastSlashIndex + 1 ) + newComponent;
@@ -85,7 +85,7 @@ static std::string replaceLastPathComponent(const std::string& path, const std::
85
85
}
86
86
87
87
// Helper function to get the last path component
88
- static std::string getLastPathComponent (const std::string& path) {
88
+ [[gnu::unused]] static std::string getLastPathComponent (const std::string& path) {
89
89
size_t lastSlashIndex = path.find_last_of (' /' );
90
90
if (lastSlashIndex != std::string::npos) {
91
91
return path.substr (lastSlashIndex + 1 );
@@ -94,7 +94,7 @@ static std::string getLastPathComponent(const std::string& path) {
94
94
}
95
95
96
96
// Helper function to replace the first path component with a new component
97
- static std::string replaceFirstPathComponent (const std::string& path, const std::string& destinationPath) {
97
+ [[gnu::unused]] static std::string replaceFirstPathComponent (const std::string& path, const std::string& destinationPath) {
98
98
std::string fileName = getLastPathComponent (path);
99
99
std::string newPath = destinationPath + " /" + fileName;
100
100
return newPath;
0 commit comments