mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-25 13:58:15 -05:00
7c2d84df1c
There are three open pull requests adding this functionality: - https://github.com/google/gmail-oauth2-tools/pull/17 (October 2019) - https://github.com/google/gmail-oauth2-tools/pull/26 (May 2020) - https://github.com/google/gmail-oauth2-tools/pull/37 (May 2021) (The patch here is identical to #26, so I just closed this one.) Meanwhile, the most recent commit to the upstream repository was in May 2019: that was the commit that first added `sendgmail`. This commit adjusts Guix's `sendgmail`, following Postel's advice, to make the command "liberal in its receiving behavior" (RFC 760): it always accepts email addresses with any domain name, as in #26, and it accepts (and ignores) the `-gsuite` flag used in #17. * gnu/packages/patches/sendgmail-remove-domain-restriction.patch: New file. This is the patch from #26. * gnu/packages/patches/sendgmail-accept-ignored-gsuite-flag.patch: New file, based on #17. * gnu/local.mk (dist_patch_DATA): Add the new patches. * gnu/packages/mail.scm (sendgmail)[source]: Apply the new patches. Increment the "revision" argument to `git-version` from 0 to 1. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
39 lines
1.3 KiB
Diff
39 lines
1.3 KiB
Diff
From 854490dc4a8a6a661b4750730c3ff749519f6e36 Mon Sep 17 00:00:00 2001
|
|
From: Philip McGrath <philip@philipmcgrath.com>
|
|
Date: Sun, 14 Nov 2021 10:14:24 -0500
|
|
Subject: [PATCH] sendgmail: accept and ignore a "-gsuite" flag
|
|
|
|
Accepting a "-gsuite" flag provides compatability with
|
|
https://github.com/Flameeyes/gmail-oauth2-tools/commit/eabb456
|
|
so users do not have to change their scripts or config files.
|
|
|
|
Full hash of original: eabb45608ff4ce04045ff4ea92d05450e789ac81
|
|
|
|
Related to https://github.com/google/gmail-oauth2-tools/pull/17
|
|
---
|
|
go/sendgmail/main.go | 2 ++
|
|
1 file changed, 2 insertions(+)
|
|
|
|
diff --git a/go/sendgmail/main.go b/go/sendgmail/main.go
|
|
index 405aa1b..5cfd0c1 100644
|
|
--- a/go/sendgmail/main.go
|
|
+++ b/go/sendgmail/main.go
|
|
@@ -40,6 +40,7 @@ var (
|
|
setUp bool
|
|
dummyF string
|
|
dummyI bool
|
|
+ gsuite bool
|
|
)
|
|
|
|
func init() {
|
|
@@ -47,6 +48,7 @@ func init() {
|
|
flag.BoolVar(&setUp, "setup", false, "If true, sendgmail sets up the sender's OAuth2 token and then exits.")
|
|
flag.StringVar(&dummyF, "f", "", "Dummy flag for compatibility with sendmail.")
|
|
flag.BoolVar(&dummyI, "i", true, "Dummy flag for compatibility with sendmail.")
|
|
+ flag.BoolVar(&gsuite, "gsuite", true, "Dummy flag for compatibility with other forks of sendgmail.")
|
|
}
|
|
|
|
func main() {
|
|
--
|
|
2.32.0
|
|
|