aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--.chezmoiremove1
-rw-r--r--dot_config/msmtp/config2
-rw-r--r--dot_config/sway/config6
-rw-r--r--dot_config/systemd/user/kanshi.service14
-rw-r--r--dot_config/systemd/user/ssh-agent.service.d/override.conf8
-rw-r--r--dot_config/systemd/user/sway-session-pre.target18
-rw-r--r--dot_config/systemd/user/sway-session.target20
-rw-r--r--dot_config/systemd/user/swaybg-random.service5
-rw-r--r--dot_config/systemd/user/swayidle.service14
-rw-r--r--dot_config/systemd/user/wayland-session-pre.target18
-rw-r--r--dot_config/systemd/user/wayland-session.target18
-rw-r--r--dot_config/systemd/user/wayland-session.target.wants/symlink_kanshi.service1
-rw-r--r--dot_config/systemd/user/wayland-session.target.wants/symlink_swaybg-random.service (renamed from dot_config/systemd/user/default.target.wants/symlink_swaybg-random.service)0
-rw-r--r--dot_config/systemd/user/wayland-session.target.wants/symlink_swayidle.service1
-rw-r--r--dot_emacs10
-rw-r--r--dot_mbsyncrc.tmpl30
-rw-r--r--dot_zshrc.tmpl2
17 files changed, 142 insertions, 26 deletions
diff --git a/.chezmoiremove b/.chezmoiremove
index c4b76e5..fd1ff69 100644
--- a/.chezmoiremove
+++ b/.chezmoiremove
@@ -8,6 +8,7 @@
.screenlayout/zeta-work.sh
bin/mutt
.config/systemd/user/borgmatic@tosh.service.wants/backup-email@mail.cs.mcgill.ca.service
+.config/systemd/user/default.target.wants/swaybg-random.service
.config/neomutt/news.rc
.xkb
afs
diff --git a/dot_config/msmtp/config b/dot_config/msmtp/config
index b30868b..cae5650 100644
--- a/dot_config/msmtp/config
+++ b/dot_config/msmtp/config
@@ -9,6 +9,6 @@ user kavanagh.ryan@uqam.ca
from kavanagh.ryan@uqam.ca
tls_certcheck on
auth xoauth2
-passwordeval /home/rak/bin/mutt_oauth2.py --encryption-pipe='cat' --decryption-pipe='cat' -t ~/.config/neomutt/accounts/kavanagh.ryan.uqam.ca/xoauth2-token
+passwordeval /home/rak/bin/mutt_oauth2.py --encryption-pipe='cat' --decryption-pipe='cat' -t $XDG_STATE_HOME/xoauth2-tokens/kavanagh.ryan.uqam.ca
port 587
tls_trust_file /etc/ssl/certs/ca-certificates.crt
diff --git a/dot_config/sway/config b/dot_config/sway/config
index 562f48a..80c392e 100644
--- a/dot_config/sway/config
+++ b/dot_config/sway/config
@@ -28,10 +28,6 @@ for_window [con_mark=$alphamark] opacity set $trans
include /etc/sway/config-vars.d/*
### Idle configuration
-exec swayidle -w \
- timeout 180 $lock \
- timeout 240 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \
- before-sleep $lock
for_window [app_id="dspdfviewer"] inhibit_idle focus
### Input configuration
@@ -196,5 +192,5 @@ exec_always pkill kanshi; exec kanshi
font pango:Iosevka Regular 8
-include /etc/sway/config.d/*
+include /etc/sway/config.d/50-systemd-user.conf
include ~/.config/sway/config.d/*
diff --git a/dot_config/systemd/user/kanshi.service b/dot_config/systemd/user/kanshi.service
new file mode 100644
index 0000000..381b9e4
--- /dev/null
+++ b/dot_config/systemd/user/kanshi.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=Dynamic output configuration
+Documentation=man:kanshi(1)
+PartOf=wayland-session.target
+Requires=wayland-session.target
+After=wayland-session.target
+
+[Service]
+Type=simple
+ExecStart=/usr/bin/kanshi
+Restart=always
+
+[Install]
+WantedBy=wayland-session.target
diff --git a/dot_config/systemd/user/ssh-agent.service.d/override.conf b/dot_config/systemd/user/ssh-agent.service.d/override.conf
index acb0fb7..a3b6435 100644
--- a/dot_config/systemd/user/ssh-agent.service.d/override.conf
+++ b/dot_config/systemd/user/ssh-agent.service.d/override.conf
@@ -1,3 +1,11 @@
+[Unit]
+Description=OpenSSH Agent
+Documentation=man:ssh-agent(1)
+Before=basic.target
+ConditionPathExists=/etc/X11/Xsession.options
+Wants=dbus.socket
+After=dbus.socket
+
[Service]
ExecStart=
ExecStart=/home/rak/.local/lib/openssh/agent-launch start
diff --git a/dot_config/systemd/user/sway-session-pre.target b/dot_config/systemd/user/sway-session-pre.target
new file mode 100644
index 0000000..3215544
--- /dev/null
+++ b/dot_config/systemd/user/sway-session-pre.target
@@ -0,0 +1,18 @@
+# SPDX-License-Identifier: LGPL-2.1+
+#
+# This file is inspired from systemd's `graphical-session-pre.target`
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Session services which should run early before the sway session is brought up
+Documentation=man:systemd.special(7)
+Requires=basic.target
+Before=sway-session.target
+RefuseManualStart=yes
+StopWhenUnneeded=yes
+BindsTo=wayland-session-pre.target
+After=wayland-session-pre.target
diff --git a/dot_config/systemd/user/sway-session.target b/dot_config/systemd/user/sway-session.target
index 56029b8..4637f0f 100644
--- a/dot_config/systemd/user/sway-session.target
+++ b/dot_config/systemd/user/sway-session.target
@@ -1,6 +1,18 @@
+# SPDX-License-Identifier: LGPL-2.1+
+#
+# This file is inspired from systemd's `graphical-session.target`
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
[Unit]
-Description=Sway session
+Description=Current sway user session
Documentation=man:systemd.special(7)
-BindsTo=graphical-session.target
-Wants=graphical-session-pre.target
-After=graphical-session-pre.target
+Requires=basic.target
+#RefuseManualStart=yes
+StopWhenUnneeded=yes
+BindsTo=wayland-session.target
+Wants=wayland-session-pre.target
+After=wayland-session-pre.target
diff --git a/dot_config/systemd/user/swaybg-random.service b/dot_config/systemd/user/swaybg-random.service
index 37cd49d..06d7c29 100644
--- a/dot_config/systemd/user/swaybg-random.service
+++ b/dot_config/systemd/user/swaybg-random.service
@@ -1,12 +1,11 @@
[Unit]
-Description=randomize background
+Description=Randomize Wayland background
[Service]
Type=exec
Restart=always
RuntimeMaxSec=1h
-
ExecStart=/home/rak/bin/swaybg-random
[Install]
-WantedBy=default.target
+WantedBy=wayland-session.target
diff --git a/dot_config/systemd/user/swayidle.service b/dot_config/systemd/user/swayidle.service
new file mode 100644
index 0000000..536eaf9
--- /dev/null
+++ b/dot_config/systemd/user/swayidle.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=Idle manager for Wayland
+Documentation=man:swayidle(1)
+PartOf=wayland-session.target
+Requires=wayland-session.target
+After=wayland-session.target
+
+[Service]
+Type=simple
+ExecStart=/usr/bin/swayidle -w
+Restart=always
+
+[Install]
+WantedBy=wayland-session.target
diff --git a/dot_config/systemd/user/wayland-session-pre.target b/dot_config/systemd/user/wayland-session-pre.target
new file mode 100644
index 0000000..e4057ed
--- /dev/null
+++ b/dot_config/systemd/user/wayland-session-pre.target
@@ -0,0 +1,18 @@
+# SPDX-License-Identifier: LGPL-2.1+
+#
+# This file is inspired from systemd's `graphical-session-pre.target`
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Session services which should run early before the wayland session is brought up
+Documentation=man:systemd.special(7)
+Requires=basic.target
+Before=wayland-session.target
+RefuseManualStart=yes
+StopWhenUnneeded=yes
+BindsTo=graphical-session-pre.target
+After=graphical-session-pre.target
diff --git a/dot_config/systemd/user/wayland-session.target b/dot_config/systemd/user/wayland-session.target
new file mode 100644
index 0000000..f4cc2b7
--- /dev/null
+++ b/dot_config/systemd/user/wayland-session.target
@@ -0,0 +1,18 @@
+# SPDX-License-Identifier: LGPL-2.1+
+#
+# This file is inspired from systemd's `graphical-session.target`
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Current wayland user session
+Documentation=man:systemd.special(7)
+Requires=basic.target
+RefuseManualStart=yes
+StopWhenUnneeded=yes
+BindsTo=graphical-session.target
+Wants=graphical-session-pre.target
+After=graphical-session-pre.target
diff --git a/dot_config/systemd/user/wayland-session.target.wants/symlink_kanshi.service b/dot_config/systemd/user/wayland-session.target.wants/symlink_kanshi.service
new file mode 100644
index 0000000..7d5903e
--- /dev/null
+++ b/dot_config/systemd/user/wayland-session.target.wants/symlink_kanshi.service
@@ -0,0 +1 @@
+/home/rak/.config/systemd/user/kanshi.service
diff --git a/dot_config/systemd/user/default.target.wants/symlink_swaybg-random.service b/dot_config/systemd/user/wayland-session.target.wants/symlink_swaybg-random.service
index 2ebb1f9..2ebb1f9 100644
--- a/dot_config/systemd/user/default.target.wants/symlink_swaybg-random.service
+++ b/dot_config/systemd/user/wayland-session.target.wants/symlink_swaybg-random.service
diff --git a/dot_config/systemd/user/wayland-session.target.wants/symlink_swayidle.service b/dot_config/systemd/user/wayland-session.target.wants/symlink_swayidle.service
new file mode 100644
index 0000000..a53991f
--- /dev/null
+++ b/dot_config/systemd/user/wayland-session.target.wants/symlink_swayidle.service
@@ -0,0 +1 @@
+/home/rak/.config/systemd/user/swayidle.service
diff --git a/dot_emacs b/dot_emacs
index 2296451..b6d199e 100644
--- a/dot_emacs
+++ b/dot_emacs
@@ -52,14 +52,6 @@
(moe-dark)
(moe-theme-powerline)))
-(defun single-lines-only ()
- "Replace multiple blank lines with a single one"
- (interactive)
- (goto-char (point-min))
- (while (re-search-forward "\\(^\\s-*$\\)\n" nil t)
- (replace-match "\n")
- (forward-char 1)))
-
(use-package ace-window
:ensure t
:custom
@@ -1113,7 +1105,7 @@ If not, issue a warning."
(use-package simple
:custom
(column-mode-number t)
- (visual-line-fringe-idicators (left-curly-arrow right-curly-arrow)))
+ (visual-line-fringe-indicators '(left-curly-arrow right-curly-arrow)))
(use-package smerge-mode
:commands smerge-mode
diff --git a/dot_mbsyncrc.tmpl b/dot_mbsyncrc.tmpl
index 12b4950..1bfd928 100644
--- a/dot_mbsyncrc.tmpl
+++ b/dot_mbsyncrc.tmpl
@@ -1,21 +1,21 @@
IMAPAccount UQAM
Host outlook.office365.com
User kavanagh.ryan@uqam.ca
-PassCmd "mutt_oauth2.py --encryption-pipe='cat' --decryption-pipe='cat' ~/.config/neomutt/accounts/kavanagh.ryan.uqam.ca/xoauth2-token"
+PassCmd "mutt_oauth2.py --encryption-pipe='cat' --decryption-pipe='cat' $XDG_STATE_HOME/xoauth2-tokens/kavanagh.ryan.uqam.ca"
AuthMechs XOAUTH2
TLSType IMAPS
IMAPAccount queensu
Host outlook.office365.com
User 9rak@queensu.ca
-PassCmd "~/bin/mutt_oauth2.py --client-id="08162f7c-0fd2-4200-a84a-f25a4db0b584" --client-secret="TxRBilcHdC6WGBee]fs?QR:SJ8nI[g82" --encryption-pipe="cat" --decryption-pipe="cat" ~/.config/neomutt/accounts/9rak.queensu.ca/xoauth2-token"
+PassCmd "~/bin/mutt_oauth2.py --client-id="08162f7c-0fd2-4200-a84a-f25a4db0b584" --client-secret="TxRBilcHdC6WGBee]fs?QR:SJ8nI[g82" --encryption-pipe="cat" --decryption-pipe="cat" $XDG_STATE_HOME/xoauth2-tokens/9rak.queensu.ca"
AuthMechs XOAUTH2
TLSType IMAPS
IMAPAccount mcgill
Host outlook.office365.com
User ryan.kavanagh@mail.mcgill.ca
-PassCmd "~/bin/mutt_oauth2.py --client-id="08162f7c-0fd2-4200-a84a-f25a4db0b584" --client-secret="TxRBilcHdC6WGBee]fs?QR:SJ8nI[g82" --encryption-pipe="cat" --decryption-pipe="cat" ~/.config/neomutt/accounts/ryan.kavanagh.mail.mcgill.ca/xoauth2-token"
+PassCmd "~/bin/mutt_oauth2.py --client-id="08162f7c-0fd2-4200-a84a-f25a4db0b584" --client-secret="TxRBilcHdC6WGBee]fs?QR:SJ8nI[g82" --encryption-pipe="cat" --decryption-pipe="cat" $XDG_STATE_HOME/xoauth2-tokens/ryan.kavanagh.mail.mcgill.ca"
AuthMechs XOAUTH2
TLSType IMAPS
@@ -33,6 +33,13 @@ Pass {{ .password.gmail }}
AuthMechs PLAIN
TLSType IMAPS
+IMAPAccount ryan.a.kavanagh.gmail.com
+Host imap.gmail.com
+User ryan.a.kavanagh@gmail.com
+PassCmd "~/bin/mutt_oauth2.py --encryption-pipe=cat --decryption-pipe=cat $XDG_STATE_HOME/xoauth2-tokens/ryan.a.kavanagh.gmail.com"
+AuthMechs XOAUTH2
+TLSType IMAPS
+
IMAPAccount rak
Host hades.rak.ac
User rak
@@ -58,6 +65,9 @@ Account rak
IMAPStore gmail-remote
Account gmail
+IMAPStore ryan.a.kavanagh.gmail.com
+Account ryan.a.kavanagh.gmail.com
+
MaildirStore uqam-maildir
Subfolders Verbatim
Path ~/Maildir/UQAM/
@@ -88,6 +98,11 @@ Subfolders Verbatim
Path ~/Maildir/gmail/
Inbox ~/Maildir/gmail/INBOX
+MaildirStore archive
+Subfolders Verbatim
+Path ~/Maildir/Archive/
+Inbox ~/Maildir/Archive/INBOX
+
Channel uqam-inbox
Far :uqam-remote:
Near :uqam-maildir:
@@ -110,6 +125,7 @@ Near :queensu-maildir:
Create Both
Patterns * !Calendar !Calendar/* !Contacts !"Conversation History" !"Deleted Items" !"Flux RSS" !Journal !Notes !Outbox
Expunge Both
+Remove Both
Sync All
Channel mcgill
@@ -189,6 +205,14 @@ Expunge Near
Pattern * !INBOX !"[Google Mail]/Sent Mail" !"[Google Mail]/Drafts" !"[Google Mail]/Bin" !"[Google Mail]/All Mail"
Sync Pull
+Channel archive-to-gmail
+Far :ryan.a.kavanagh.gmail.com:
+Near :archive:
+Create Both
+Expunge Both
+Pattern * !"[Gmail]/All Mail" !"[Gmail]/Important" !"[Gmail]/Spam" !"[Gmail]/Starred" !"[Gmail]/Trash"
+Sync All
+
Group inboxes
Channel gmail-inbox
Channel rak-inbox
diff --git a/dot_zshrc.tmpl b/dot_zshrc.tmpl
index 2c62630..312ad0e 100644
--- a/dot_zshrc.tmpl
+++ b/dot_zshrc.tmpl
@@ -587,7 +587,7 @@ NO_verbose \
# GPG / SSH AGENT
if command -v keychain > /dev/null && test -d ~/.ssh/keys/{{ .chezmoi.hostname }}; then
- keychain {{ if (eq .chezmoi.os "linux") -}} --systemd {{- end }} --inherit any ~/.ssh/keys/{{ .chezmoi.hostname }}/id_*[^p][^u][^b]
+ keychain --inherit any ~/.ssh/keys/{{ .chezmoi.hostname }}/id_*[^p][^u][^b]
[ -z "$HOSTNAME" ] && HOSTNAME=`uname -n`
[ -f $HOME/.keychain/$HOSTNAME-sh ] &&
. $HOME/.keychain/$HOSTNAME-sh