This is a huge patch for Swmo, Sxmo over Sway.
It is Dwm backward compatible so dwm users should not expect regressions.
If you install all dependencies, you then can toggle between Sway and Dwm using a new config entry. It will reboot the phone.
This commit also contains:
* Make the modemmonitor bullet proof
* various other smaller fixes
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
As we rely on the terminal name to use the contextual menu, we used the
st target directly, preventing to use the taillog command in terminal
mode.
Add an optional TERMNAME env variable to manage this smoothly.
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
As we now rely on sxmo_terminal.sh and the TERMCMD env variable, we then
can simplify things.
In the sxmo dwm context, TERMCMD="st -e" so sxmo_terminal.sh will run
the command in st.
In the ssh context, we dont have TERMCMD so sxmo_terminal.sh will just
run the command
In a tmux context, we can set TERMCMD="tmux split-window" with
set-environment -g TERMCMD "tmux split-window"
so sxmo_terminal.sh will run the command in a splited window.
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
When you number of conversation start to grow, it rapidly take some
seconds for the menu to open itself. The [ -d "folder" ] test really is
uneficient.
This simplify this part as we now ask sxmo_contacts to only list texted
contacts.
We then simplify the sxmo_modemtext that was already using SSH related
behaviors.
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
* Draft files are assigned to each number:
Stored here ".local/share/modem/+33666666666/draft.txt"
We automatically edit this single file, making crash or unexpected
edition issue to leave intact saved draft.
* Simplification of some logics
Having a known draft file instead of using a TEXT var simplify lots
of things
* EDITOR is not run in a subshell
Some editors as kakoune got issues with that. Futhermore, it will be
usefull for some other development as making all menu ssh mode
compatible
* Remove modem check
As we now got draft, why do we care if modem is up or down ?
* Display the contact name instead of it number in the conversation
Or use "Unknown Number (+337798676)"
* Unify display message notif adding possibilities to bypass the
main menu
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
This allow the "Reply" appmenu shortcut to open a new compose message
directly.
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
This reverts commit 3bb3fb6094.
We cannot use this special less argument as it is not busybox less
compatible.
I add busybox aliases to not reproduce the error in the future.
Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
Breaking change. Make sure you send an email to the mailing list
telling users to move their
$XDG_CONFIG_HOME/{modem,notifications} files/folders to
$XDG_DATA_HOME
Signed-off-by: Anjandev Momi <anjan@momi.ca>
DRAFT_DIR is also used in the main loop so this prevent logging to sterr
ls: cannot access '/home/foobar/.config/sxmo/modem/draft': No such file or directory
Signed-off-by: Reed Wade <reedwade@misterbanal.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
The dialer only included recent callers, but there was no way to access
the full contact list (contacts.tsv). I added a "more contacts" options
that calls sxmo_contacts --all, providing an alphabetically sorted list
of all your contacts. It also works for the texting menu.
This is a cleaned up version of an earlier patch by Maarten van Gompel.
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
This allow userscripts to send sms using the sxmo way so we now can
create our own sms clients.
Signed-off-by: Reed Wade <reedwade@misterbanal.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
Text messages which fail to send will now automatically postpone
(maintainer note: I incorporated a minor shellcheck fix)
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
Ensure contacts from modem and contacts lists are all fully qualified phone numbers (starting with + and carrying a country prefix). This effectively filters out older/incompatible entries.
Note prefix stripping was unreliable because any +1XX number would break things.
The advice should be to always dial with +1 / international prefixes and store
contacts in your contacts.tsv with international codes; this way we avoid any
duplicate errors since we can be assured things in mmcli always come back w/
international prefixing automatically.