madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

calendar: remove trailing newlines of output
authorAlphonse Mariya <alphonse.mariya@hotmail.com>
Thu, 14 Dec 2017 23:33:20 +0000 (00:33 +0100)
committerAlphonse Mariya <alphonse.mariya@hotmail.com>
Fri, 15 Dec 2017 00:07:56 +0000 (01:07 +0100)
widget/calendar.lua

index 2dda8908afdec255ffc54d14b01e688e0a958ba2..4f927b38b81bc7265b1f0425320bc002b1ed156e 100644 (file)
@@ -62,7 +62,7 @@ function calendar.show(t_out, inc_offset, scr)
     helpers.async(f, function(ws)
         local fg, bg = calendar.notification_preset.fg, calendar.notification_preset.bg
         calendar.notification_preset.text = ws:gsub("%c%[%d+[m]?%s?%d+%c%[%d+[m]?",
-        markup.bold(markup.color(bg, fg, os.date("%e")))):gsub("\n*$", "")
+        markup.bold(markup.color(bg, fg, os.date("%e")))):gsub("[\n%s]*$", "")
 
         local widget_focused = true