aboutsummaryrefslogtreecommitdiffstats
path: root/config/templates.go
diff options
context:
space:
mode:
authorBence Ferdinandy <bence@ferdinandy.com>2024-07-01 21:43:35 +0200
committerRobin Jarry <robin@jarry.cc>2024-08-03 17:42:11 +0200
commit1d4eafb011f46966848d55f381160e846d0d50c8 (patch)
tree95ac8c80255dd65892c1b321047a60c2fc4e8e38 /config/templates.go
parent9d8d74d9bf438c337ac0d6eed1b5dede5cc0ceb2 (diff)
downloadaerc-1d4eafb011f46966848d55f381160e846d0d50c8.tar.gz
templates: add {{.AccountFrom}} template
Add template variable to access the current account's From address. Implements: https://todo.sr.ht/~rjarry/aerc/150 Changelog-added: New `{{.AccountFrom}}` template variable. Signed-off-by: Bence Ferdinandy <bence@ferdinandy.com> Tested-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to 'config/templates.go')
-rw-r--r--config/templates.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/config/templates.go b/config/templates.go
index 4000b1fc..14da731b 100644
--- a/config/templates.go
+++ b/config/templates.go
@@ -66,6 +66,7 @@ var (
func (d *dummyData) Account() string { return "work" }
func (d *dummyData) AccountBackend() string { return "maildir" }
+func (d *dummyData) AccountFrom() *mail.Address { return nil }
func (d *dummyData) Signature() string { return "" }
func (d *dummyData) Folder() string { return "INBOX" }
func (d *dummyData) To() []*mail.Address { return []*mail.Address{&addr1} }