@@ -2323,6 +2323,12 @@ require('orgmode').setup({
2323
2323
if not vim.tbl_isempty(result) then
2324
2324
require('orgmode.notifications.notification_popup'):new({ content = result })
2325
2325
end
2326
+
2327
+ -- Example: if you use Snacks, you can do something like this (THis is not implemented)
2328
+ Snacks.notifier.notify(table.concat(result, '\n'), vim.log.levels.INFO, {
2329
+ title = 'Orgmode',
2330
+ ft = 'org'
2331
+ })
2326
2332
end,
2327
2333
cron_notifier = function(tasks)
2328
2334
for _, task in ipairs(tasks) do
@@ -2332,12 +2338,18 @@ require('orgmode').setup({
2332
2338
2333
2339
-- Linux
2334
2340
if vim.fn.executable('notify-send') == 1 then
2335
- vim.loop.spawn('notify-send', { args = { string.format('%s\n%s\n%s', title, subtitle, date) }})
2341
+ vim.system({
2342
+ 'notify-send',
2343
+ '--icon=/path/to/orgmode/assets/nvim-orgmode-small.png',
2344
+ '--app-name=orgmode',
2345
+ title,
2346
+ string.format('%s\n%s', subtitle, date),
2347
+ })
2336
2348
end
2337
2349
2338
2350
-- MacOS
2339
2351
if vim.fn.executable('terminal-notifier') == 1 then
2340
- vim.loop.spawn( 'terminal-notifier', { args = { '-title', title, '-subtitle', subtitle, '-message', date } })
2352
+ vim.system({ 'terminal-notifier', '-title', title, '-subtitle', subtitle, '-message', date })
2341
2353
end
2342
2354
end
2343
2355
end
0 commit comments