Skip to content

Commit

Permalink
Add multi arg compat for script
Browse files Browse the repository at this point in the history
  • Loading branch information
Slackadays committed Oct 18, 2024
1 parent aa3c852 commit 0dc1e33
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/cb/src/actions/script.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,12 @@ void script() {
stopIndicator();
fprintf(stderr, "%s", formatColors("[success][inverse] โœ” [noinverse] Removed script[blank]\n").data());
} else {
for (size_t i = 0; i < copying.items.size(); i++) {
copying.buffer += copying.items.at(i).string();
if (i != copying.items.size() - 1) copying.buffer += " ";
}
fs::remove(path.metadata.script);
writeToFile(path.metadata.script, copying.items.at(0).string());
writeToFile(path.metadata.script, copying.buffer);
fs::permissions(path.metadata.script, fs::perms::owner_exec, fs::perm_options::add);
if (output_silent || confirmation_silent) return;
stopIndicator();
Expand Down

0 comments on commit 0dc1e33

Please sign in to comment.