X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/f2fb4f6fdadc1b09877e5ef6bd75e06a668a4080..724eaa3ad77cab7f229c405d046dcebeab6552ab:/asyncshell.lua diff --git a/asyncshell.lua b/asyncshell.lua index c05fb6b..51885e8 100644 --- a/asyncshell.lua +++ b/asyncshell.lua @@ -13,6 +13,8 @@ -- ...synchronously -- wwidget.text = asyncshell.demand('wscript -Kiev', 5):read("*l") or "Error" +-- This makes things faster, but puts weight on sysload and is more cpu demanding. + local spawn = require('awful.util').spawn asyncshell = {} @@ -39,7 +41,7 @@ function asyncshell.request(command, callback) local tmpfname = asyncshell.file_template .. id asyncshell.request_table[id] = {callback = callback} local req = - string.format("bash -c '%s > %s; " .. + string.format("sh -c '%s > %s; " .. 'echo "asyncshell.deliver(%s)" | ' .. "awesome-client' 2> /dev/null", string.gsub(command, "'", "'\\''"), tmpfname,