Fix terminal exec parameter when running command in a terminal as all terminals using the option '-e' by convention
This commit is contained in:
parent
8d1075eb2c
commit
1649fb95e1
@ -810,11 +810,11 @@ bool wofi_mod_control(void) {
|
|||||||
|
|
||||||
void wofi_term_run(const char* cmd) {
|
void wofi_term_run(const char* cmd) {
|
||||||
if(terminal != NULL) {
|
if(terminal != NULL) {
|
||||||
execlp(terminal, terminal, "--", cmd, NULL);
|
execlp(terminal, terminal, "-e", cmd, NULL);
|
||||||
}
|
}
|
||||||
size_t term_count = sizeof(terminals) / sizeof(char*);
|
size_t term_count = sizeof(terminals) / sizeof(char*);
|
||||||
for(size_t count = 0; count < term_count; ++count) {
|
for(size_t count = 0; count < term_count; ++count) {
|
||||||
execlp(terminals[count], terminals[count], "--", cmd, NULL);
|
execlp(terminals[count], terminals[count], "-e", cmd, NULL);
|
||||||
}
|
}
|
||||||
fprintf(stderr, "No terminal emulator found please set term in config or use --term\n");
|
fprintf(stderr, "No terminal emulator found please set term in config or use --term\n");
|
||||||
exit(1);
|
exit(1);
|
||||||
|
Loading…
Reference in New Issue
Block a user