Comments (11)
It's definitely not abandoned; 10 unattended issues should be weighed against my daily use of this library for several years now, and its use by others. :)
from alert.
If I might say, I was able to make it work with the following changes at alert-log-notify
(when (fboundp 'log4e:deflogger)
(log4e:deflogger "alert" "%t [%l] %m" "%H:%M:%S")
(when (functionp 'alert--log-set-level)
(alert--log-set-level alert-log-level))
;; HACK: Enable logging here?
(alert--log-enable-logging)
(alert--log-info mes)
)
Two things with this: the *Alert*
buffer name is called *log4e-alert*
and alert-log-message
must be nil
when alert-default-style
is 'log
unless double logging is okay. I just read up on log4e
and a rookie so I really don't know. But an official fix for this would ease my mind as well.
from alert.
my daily use of this library for several years now, and its use by others. :)
I am looking for a reliable persistent notifications inside emacs. Persistent in the sense that the notification won't disappear till I really payed attention to it.
For instance, if a new message arrived in my slack buffer the notification should be on till I visited that buffer. This is how jabber notifications work. emacs-slack builds on alert
and its notifications are far from being useful at the moment.
libnotify
is currently broken (#28), so in linux I cannot get persistent notifications working outside emacs either.
from alert.
Sounds like some bugs need fixing. The behavior you describe is exactly how alert should be working for you: alerts persist until you visit the buffer that raised them, so long as you don't have them configured to automatically disappear (which is the default).
from alert.
Assuming 'fringe
or 'mode-line
works, if the current buffer or minibuffer is the that invokes (alert "I love cats" :style 'fringe)
; the fringe alert is immediately removed by alert-remove-on-command
thus making it appear that nothing happened. Ditto with mode-line
My workaround is to use delay it a little bit
(run-at-time 0 nil (lambda () (alert "I love cats" :style 'fringe)))
.
Just noting
from alert.
I'm also being confused by the correct way to configure this.
First of all, I have alert-log-messages
set to t
but no *Alerts*
buffer is being created. Second of all, the log4e logging seems to be buggy by default.
As been mentioned earlier, I need to execute alert--log-enable-logging
sequence before the alert--log-open-log
works.
EDIT: Forgot to mention, that alert--log-enable-logging
seems to be initialized lazily, so I need to create a dummy alert before calling the alert--log-enable-logging
function.
from alert.
Perhaps alert-log-notify
should do
(when (fboundp 'log4e:deflogger)
(log4e:deflogger "alert" "%t [%l] %m" "%H:%M:%S")
(alert--log-enable-logging)
(when (functionp 'alert--log-set-level)
(alert--log-set-level alert-log-level)))
?
My init.el workaround is to
(use-package alert
:defer t
:config
(alert-log-notify nil)
(alert--log-enable-logging))
from alert.
I installed the stable package and I didn't have any troubles with the message style, but it was missing the 'mode-line' style, which I wanted. I installed the latest unstable version, and none of the styles seems to work. (I'll probably actually just define my own style that modifies the mode-line to say what I want rather than just changing the colour, but I thought it was worth mentioning the difference between the two versions.)
from alert.
@vincentjgoh Thanks for the note, I'll look into it soon.
from alert.
First of all, I have alert-log-messages set to t but no Alerts buffer is being created. Second of all, the log4e logging seems to be buggy by default.
IMO the the documentation needs to be updated because *Alerts*
is only used when log4e
is not available:
But log4e
is a dependency of alert
. So most users need to use alert--log-open-log
instead.
I was also confused by the fact that the log4e
based logging function are defined at runtime. And the first message gets lost. See: Ensure log4e logging is enabled when using default log4e functions
from alert.
I just stumbled across this issue when trying to figure out why I couldn't find an *Alerts*
buffer. Thanks @juergenhoetzel, for the info; that's what I needed. It would be helpful to have this clearly documented somewhere.
from alert.
Related Issues (20)
- tmux-specific alert styles HOT 1
- [FR] Add severity "emoji icons"
- Minor mode to allow users to override the builtin `notifications-notify` command with `alert`?
- Add a windows desktop style desktop notification
- Subtitle property?
- `alert-log-messages` and packages.
- post-command-hook alert-remove-on-command should not act during eval-expression
- Race Condition On mode-line Prevents (Meaningful) Restore
- alert broken using growl on Windows
- alert won't notify via notify-send HOT 2
- not working with Chinese or Emoji when style is osx-notifier HOT 1
- not working well with notifier style HOT 1
- :persistent doesn't work with libnotify HOT 5
- Support sounds
- Enhancement request: use https://github.com/KDE/snoretoast instead
- Feature request: ability to change app name
- Use `notifications-notify`, not `notify-send` command? HOT 1
- Parameter `:style` is not handled correctly HOT 2
- invalid-function: log4e:deflogger HOT 2
- alert-fade-time not working with osx-notifier
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from alert.