【问题标题】:notify-send not working from cron通知发送不能从 cron 工作
【发布时间】:2017-05-22 11:05:50
【问题描述】:

* * * * * export DISPLAY=:0.0 && usr/bin/notify-send "Hello world!"

我将上述命令添加到 crontab 中,notify-send 是从终端工作,但不是从 cron。还检查了日志,它每分钟都在工作,但没有显示通知。

【问题讨论】:

    标签: notifications cron ubuntu-14.04 crontab


    【解决方案1】:

    不知道为什么,但这有效。而是直接调用 notify-send 将其添加到脚本中。

    * * * * * export DISPLAY=:0.0 && /bin/sh /home/notifyCustom.sh
    

    【讨论】:

      猜你喜欢
      • 2014-07-29
      • 2015-09-24
      • 1970-01-01
      • 2023-04-04
      • 2014-08-17
      • 2019-05-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多