Skip to content

Commit df6aeaf

Browse files
committed
add create_tar to common-tools
1 parent d86e211 commit df6aeaf

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ Release/
3737
/common-tools/linux/extract_iso/extract_iso
3838
/common-tools/linux/convert_bin/convert_bin
3939
/common-tools/linux/create_zip/create_zip
40+
/common-tools/linux/create_tar/create_tar
4041

4142
# Rewritten Software Ports
4243
rewritten-software-ports/linux/LoaderMDO/LoaderMDO
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#include <iostream>
2+
#include <string>
3+
4+
using namespace std;
5+
6+
int main() {
7+
8+
// inputFolder for selecting which Folder should be used for the creation of the TAR archive.
9+
std::string inputFolder;
10+
std::cout << "Navigate to the Path of the input Folder!" << std::endl;
11+
std::cin >> inputFolder;
12+
13+
std::string outputTAR;
14+
std::cout << "Give me the Output directory for the TAR archive" << std::endl;
15+
std::cin >> outputTAR;
16+
17+
std::string tarCommand = "tar -cf \"" + outputTAR + "\" -C \"" + inputFolder + "\" .";
18+
19+
// Execute final TAR converter command.
20+
system(tarCommand.c_str());
21+
22+
return 0;
23+
24+
}

0 commit comments

Comments
 (0)