Gnu printf interprets these to be arguments instead of a format string
which breaks sending mms.
Also ATTACHMENTS_ARG was being overwritten make_attachments_arg causing
messages to not have the description included, only the attachment.
Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
The lsof / grep call is broken and causes the script to crash when
adding or removing a recipient.
Lsof also doesn't have a stable output format, and the format is
different between the busybox and gnu versions, so we shouldn't be
trying to parse the output of it.
Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
autosuspend calls the presuspend check when the kernel locks are clear,
and it hasn't been called recently. If we always call it, there's a risk
that running all checks could take too long and we'll fail to suspend
often.
Successfully exiting means that there is nothing going on, so the system is
free to suspend within a reasonable timeframe (something like < 10 seconds).
All the checks currently use the (default) delay wait mechanism, but I
would like to try to write others. For example `playerctl -F` could be
used when playerctl is blocking suspend. Unfortunately managing spawned
jobs and race conditions is harder than it seems at first glance.
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
This revision changes things to refer to shell script for hooks not
manpages. I think manpages will just introduce problems. Instead, the
proposal is to have each hook include its own documentation in comments
at the start of it, and refer the viewer back to the section in the
sxmo(7) manpage where that hook is discussed.
This is unfinished but pushing it.
Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
This is basically a conversion of USERGUIDE.md. Pushing this now for
comment on the structure. The idea is to have each of our hooks as
its own man page (e.g., sxmo_hook_sms(1) and so on). And then we'd
also have "bigger" scripts have their own man pages, e.g.,
sxmo_files(1), sxmo_rtcwake(1), sxmo_notifications(1).
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
Watch was spitting out no such file or directory errors, that I think
were caused by a race between updating the status bar, and removing
items.
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
Never happend before but it is definitely possible that the 30s duration
could expire if the following trigger take longer than 20s. By example
in case of network issue.
The goal of this default duration is to avoid stucked wake
locks, even if this could theorically not happen anyway. So let's use a
big value to avoid causing troubles.
A mpv instance is a inhibit idle for the WM. It means that we
should not rely on sxmo_idle.sh to start and stop the periodic wake lock
checker.
Instead we should just periodically run them.
This file was not bumped on new version. This can cause issue, by
example with our recent font change.
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
This implements simple hooks when we enable / disable callaudio. The
"hack" in our current code is pretty specific to pinephone, and I think
that users might also want to, e.g., bump volume when receiving phone
call, or otherwise tweak some sound settings.
The user probably missed the wake up anyway. Sticking the message just
is confusing.
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
Mostly a cleanup. We now have sxmo_wakeup.sh so the hook should bear
that name somehow (although sxmo_hook_suspendblockers might fit too)
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
There is already a single blink when the screen is turned off, and then
we wait for 5 seconds instead of the normal 2 before starting the
repeating blink. This replaces that with a single call to start the
repeating blink.
Also remove comments about dangling blinks, as they're always used now.
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
If you have a lot of wifi networks, its very annoying to have to scroll
to the bottom or swipe up to close (swiping up might activate a
different network).
Maybe we give more of a gap between top of screen and menus?
Signed-off-by: Willow Barraco <contact@willowbarraco.fr>