1352 Commits

Author SHA1 Message Date
Peter John Hartman
ea07c11d61 sxmo_contacts: use existing vars
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2023-01-22 15:17:00 -08:00
Peter John Hartman
8bd1feb1cf give keyboard time to open
Sometimes the menu would open before keyboard in sxmo_menu_with_kb.sh.
Reproduce: from main menu, click texts.  A small pause is sufficient.
This is bad since then menu overlaps keyboard and you can't type esc
or numbers.

Signed-off-by: Anjandev Momi <anjan@momi.ca>
2023-01-22 15:15:25 -08:00
Stacy Harper
375bf69803 allow to open named numbers with spaces
This strip the "logfile" suffix cause it is a pain to strip and pretty
much useless for this menu anyway
2023-01-22 20:36:15 +01:00
Peter John Hartman
79f4132b32 call hooks: minor cleanup
The comments were wrong, and mute_ring was sending CONTACTNAME, which
was also wrong.
2023-01-19 19:43:33 -06:00
Peter John Hartman
7772091bfa minor fixup to missed call message
This fixes a bug with the hook (from a previous commit)
2023-01-19 19:38:09 -06:00
ArenM
f4e8a38eb4 Use superd for modemmonitor
Superd handles cleaning up any child processes we start, that logic can
be removed from this script. Using superd should also make this more
reliable, and provide better logging facilities.

Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
2023-01-19 19:37:00 -06:00
noneofyourbusiness
5d9bc00912 replace 'pn' with 'pnc'
Signed-off-by: noneofyourbusiness <noneofyourbusiness@kolabnow.ch>
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2023-01-13 20:36:58 -08:00
Peter John Hartman
ad5102f6e1 fixup: Add contextual menu on missed call
Small fixup for c5fea64dda
2023-01-09 06:11:50 -06:00
Stacy Harper
c5fea64dda Add contextual menu on missed call window to call or sms back
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2023-01-07 02:12:16 -08:00
Stacy Harper
55f79e98b9 allow WPA connection without passphrase 2023-01-06 10:30:20 +01:00
Stacy Harper
4405e35141 Rename deprecated swaymsg "dpms" to "power"
ref: https://github.com/swaywm/sway/pull/7083
2023-01-06 10:28:08 +01:00
Stacy Harper
f436475c23 Drop busybox aliases
As discussed with Aren over and over again, there is no easy, and fast enough
way to alias those in a smart way.

Cause this is causing issues on other distros than Alpine, we drop them
completly.

I think we should find a way to check those in the CI tests to
keep an eye on non busybox api usages contributors may try to use.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
2023-01-03 07:15:17 -06:00
Peter John Hartman
f950fda54c sendsms: send group / mms id to sxmo_hook_sendsms
This brings sendsms into comformity with sms hook.  This information is
useful in sendsms hook, e.g., if I want to copy out my sent sms/mms to
a logfile or another application (as I do with my received sms), via the
hook.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-18 09:08:24 +01:00
ArenM
4f7efe0163 networks: remove call to status bar
This is handled by the networkmonitor

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-18 09:08:23 +01:00
ArenM
80bdd6ba97 networkmonitor: handle unavailable state and log unknown states
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-18 09:08:22 +01:00
Zach DeCook
081225481e modem audio: don't mute mic at call end
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-18 09:08:22 +01:00
Joshua Murphy
c34ee328ec Fix monitor for fajita
This patch supersedes my previous patch for fixing just the scale value.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-18 08:47:30 +01:00
Joshua Murphy
437258d34c Increase scale for fajita and enchilada
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-18 08:47:30 +01:00
HexagonWin
968edf20fd Fix volume keys for lge,hammerhead
The current values are not working as of kernel 5.19, so we update the
values.

Signed-off-by: HexagonWin <hexagonwin@disroot.org>
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-17 13:11:56 +01:00
Stacy Harper
088feda2c8 Cleanup sxmo_timer.sh 2022-12-17 11:25:30 +01:00
hazardchem
faba6af2eb sxmo_timer.sh: added stopwatch function
Added selection for stopwatch in timer

Signed-off-by: hazardchem <pthom44@live.com.au>
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-17 11:25:24 +01:00
ArenM
ffc7e5fa8a contactmenu: add option to show formatted number
I sometimes use the contacts menu to look up a number, when filling out
contact information on paper for example. Having the number formatted
makes it much easier to read.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-17 11:13:40 +01:00
ArenM
7a643cfa66 contactmenu: fix indentation
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-17 11:13:40 +01:00
xengineering
341381fa5c Fix scale for samsung,gt510
The currently used scale is far too big. This commit decreases it from
2.0 to 1.5 which looks good on the device.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-17 11:04:28 +01:00
Dominic Martinez
a9d11d6e62 fix screen rotation on some devices
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-17 11:03:02 +01:00
Stacy Harper
7baa2d08a0 Rely on pulseaudio instead of pipewire if installed
SDM845 devices need pulseaudio instead of pipewire for calls to work.

https://gitlab.com/postmarketOS/pmaports/-/issues/1821
2022-12-17 10:43:18 +01:00
Stacy Harper
08fe32d492 Shellcheck fixes 2022-12-17 10:34:45 +01:00
ArenM
329f3bfda9 Make sure there is a cron job to run before blocking suspend
This fixes an bug where the system is prevented from suspending by a
stuck "Waiting for cronjob" mutex.

The wakeup_active count doesn't provide information about system
wakeups, so track the amount of time spent in suspend instead. Also make
sxmo_hook_mnc.sh responsible for deciding if the system has time to
suspend before the next cron job. This makes the suspend code a bit
cleaner.

There are two bugs that can cause the mutex to get stuck:

Bug one: The kernel allows multiple applications to request multiple
wakeup times, if anything else does we will get stuck.

Bug two: /sys/class/wakeup/wakeupN/active_count does not count the
number of times the device woke the system from suspend. It counts the
number of times the device prevented the system from suspending.

Periodically the kernel syncs the system clock to the rtc. When doing
this the rtc subsystem takes a wakelock to prevent the system from
suspending until the time has been updated, which increments
active_count. If this happens while resuming we get stuck.

This is a kernel stack trace I captured of this happening while resuming:
    wakeup_source_activate+0
    pm_stay_awake+68
    rtc_set_time+212
    sync_hw_clock+436
    process_one_work+520
    worker_thread+120
    kthread+276
    ret_from_fork+16

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-12-17 10:23:22 +01:00
Stacy Harper
386acc76e1 Replace wob options with ini file
As wob 0.14 get rid of arguments in favor of ini file.

This hardcode a low width value cause we still cannot use percent value.
We should try to find a better solutions to solve this problem !

Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
2022-12-15 09:33:23 -06:00
ArenM
b3c933b5d2 rename mmsd.service to mmsd-tng.service
The service file mmsd ships is named mmsd-tng, by using the same name it
makes it easier for distros that need to integrate with systemd.

Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
2022-12-15 09:31:12 -06:00
ArenM
380a81299f Add basic tests for the appmenu
My main motivation for writing this was as a regression test for my
recent patch "appmenu: require exact match with picked"
https://lists.sr.ht/~mil/sxmo-devel/patches/32362

Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-12-05 11:56:02 -08:00
Jochen Sprickerhof
69fb14a291 Add fallback XDG_DATA_DIRS
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-12-05 11:46:46 -08:00
Tzafrir Cohen
c113099ea5 dash: Avoid empty shift
Dash gives an error if you try to shift with no positional parameters.

$ bash -c 'shift; echo b'
b
$ dash -c 'shift; echo b'
dash: 1: shift: can't shift that many

Signed-off-by: Tzafrir Cohen <tzafrir@debian.org>
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-12-05 11:46:44 -08:00
Tzafrir Cohen
d79b985804 bashism fixes
Several places where dash behaves differently than bash:
* read in dash has to have a variable.
* use command -v as type is not POSIX

Signed-off-by: Tzafrir Cohen <tzafrir@debian.org>
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-12-05 11:46:43 -08:00
Tzafrir Cohen
4a15176782 GNU find: -mindepth should come before -exec
Fixes: find: warning: you have specified the global option -mindepth
after the argument -exec, but global options are not positional, i.e.,
 -mindepth affects tests specified before it as well as those specified
after it.  Please specify global options before other arguments.

Originally busybox find was used and it probably does not give this
warning.

Signed-off-by: Tzafrir Cohen <tzafrir@debian.org>
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-12-05 11:46:42 -08:00
Diego Valcarce
9a31200c13 Add device profile for 'samsung,a3u-eur'
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-12-05 11:36:02 -08:00
Philipp Schmitt
97734923c2 polaris: add device profile
Signed-off-by: Philipp Schmitt <philipp@schmitt.co>
Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-12-05 11:34:31 -08:00
Maarten van Gompel
c0e64920c5 improve detection of active app_id and title for xwayland apps
In sway, tools like feh didn't have their context menu pop up because
the app wasn't identified properly (empty app_id).

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-11-26 09:57:02 +01:00
Stacy Harper
8164bdf331 Fix shellchecks 2022-11-15 13:41:55 +01:00
Stacy Harper
a2405f6d57 Fix shellspec 2022-11-15 13:41:55 +01:00
medsouz
4380117f2d Update Pinephone Pro power button to match new devicetree
The current configuration is based on an old devicetree provided with Tow-Boot.

Most (if not all) distributions will be packaging a newer version with a changed gpio name for the power button.

For more information check this issue on PostmarketOS: https://gitlab.com/postmarketOS/pmaports/-/merge_requests/3628#note_1164572571

Signed-off-by: Anjandev Momi <anjan@momi.ca>
2022-11-13 23:54:19 -08:00
Anjandev Momi
a92dc42968 poco f1: add vibration file path
Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-11-07 21:06:00 +01:00
Peter John Hartman
ad3b182177 bluetoothtoggle: include debian
as per user request, not tested.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-11-07 21:02:50 +01:00
Zach DeCook
825fce5159 Bluetooth Menu: Show device type icons
watch appears twice in this list because we're waiting on upstream bluez to merge the class detection for it

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-11-07 20:57:27 +01:00
Peter John Hartman
a0b91310ad modemaudio: error checking
This moves the dbus calls to cleaner functions and adds some
error checking/warnings on failures.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-11-07 20:49:29 +01:00
ArenM
8926890d05 Check for eg25-manager command instead of SXMO_EG25
eg25-manger should only be installed on systems that have a eg25 modem.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-11-07 20:09:24 +01:00
Peter John Hartman
aea5a73f51 notification: another fixup to devices without led
Oops, found a small bug where it didn't update statusbar if you clicked
on the message.  So this one should be good to go.

In re this:
377744c95b

There were two problems with that patch:

1. The check for SXMO_NO_LED never worked so every device was getting
   it.
2. The change to notificationwrite broke notificationwrite so no popups
were happening.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
2022-11-07 20:01:33 +01:00
Maarten van Gompel
1eb30701c3 alsamicismuted not implemented and led to 'Not implemented' appearing in status bar: write to stderr instead
I kept getting 'Not implemented' in my status bar, output from
sxmo_status.sh, which was caused by sxmo_audio.sh and a alsamicismuted()
outputting "Not implemented" to stdout, effectively obscuring most of
the tiny status bar. I redirected the output to stderr..

Ideally of course we should fix the function, but this will have to do
in the meantime.

Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
2022-11-05 07:42:58 -05:00
ArenM
2e84d9ce9a remove usb/bind & usb/unbind from SXMO_SYS_FILES
I believe these were used in the early days of sxmo to reset the
connection to the modem. eg25-manager now handles this.

Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
2022-11-05 07:42:58 -05:00
ArenM
95c3ce8262 remove sxmo_superd_signal.sh
It used to be used to update the clock on the desktop widget, but that's
been replaced with sxmo_aligned_sleep.

Signed-off-by: Peter John Hartman <peterjohnhartman@gmail.com>
2022-11-05 07:42:58 -05:00