added C++ based nuke tool to nuke dirs/files
This commit is contained in:
parent
887fa8cdaf
commit
ab4fb231e5
5 changed files with 24 additions and 11 deletions
14
nuke.cpp
Normal file
14
nuke.cpp
Normal file
|
@ -0,0 +1,14 @@
|
|||
#include<filesystem>
|
||||
#include<iostream>
|
||||
using namespace std;
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
for(int i=1;i<argc;i++){
|
||||
if(!filesystem::exists(argv[i]))
|
||||
{
|
||||
cerr<<"error, no such file or directory";
|
||||
return 1;
|
||||
}
|
||||
filesystem::remove_all(argv[i]);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue