@@ -3,20 +3,18 @@ class Offlineimap < Formula
33
44 desc "Synchronizes emails between two repositories"
55 homepage "https://github.com/OfflineIMAP/offlineimap3"
6- url "https://github.com/OfflineIMAP/offlineimap3/archive/refs/tags/v8.0.0 .tar.gz"
7- sha256 "5d40c163ca2fbf89658116e29f8fa75050d0c34c29619019eee1a84c90fcab32 "
6+ url "https://github.com/OfflineIMAP/offlineimap3/archive/refs/tags/v8.0.1 .tar.gz"
7+ sha256 "82ce54136465ea1cce62f4e961e8c155ac3eee2149fa812763629448902d7d69 "
88 license "GPL-2.0-or-later"
9- revision 3
109 head "https://github.com/OfflineIMAP/offlineimap3.git" , branch : "master"
1110
1211 bottle do
13- rebuild 3
14- sha256 cellar : :any_skip_relocation , arm64_tahoe : "3b2f3a0fd3ac8f2633e4787ba3e6874a38113a2762f720557999abe906c754db"
15- sha256 cellar : :any_skip_relocation , arm64_sequoia : "fe87903fa864769f72337b116bbd9e14f3ee79614a811b0a85cbc6ab8d2edd19"
16- sha256 cellar : :any_skip_relocation , arm64_sonoma : "f1a28a3ca108dae4e0bc04832cda86fc8c808d4e171e0df6e8bb900e132570f6"
17- sha256 cellar : :any_skip_relocation , sonoma : "eea4147c9b8aec69ccc1974caf0d08677cc370e98e690bc917405b7706256777"
18- sha256 cellar : :any_skip_relocation , arm64_linux : "9b94a7824487d05f8565187c89317a0e703e1cf686ec74bfbbafaeac93818dca"
19- sha256 cellar : :any_skip_relocation , x86_64_linux : "9125706c6663f9878214df3a4943178b9c83617e48627d962532c547a229b4dc"
12+ sha256 cellar : :any_skip_relocation , arm64_tahoe : "f251f42c4fa68a9fbc3f3b8778f96d5b64753cd5f9c1ca0c3d8ed563239f3acf"
13+ sha256 cellar : :any_skip_relocation , arm64_sequoia : "f251f42c4fa68a9fbc3f3b8778f96d5b64753cd5f9c1ca0c3d8ed563239f3acf"
14+ sha256 cellar : :any_skip_relocation , arm64_sonoma : "f251f42c4fa68a9fbc3f3b8778f96d5b64753cd5f9c1ca0c3d8ed563239f3acf"
15+ sha256 cellar : :any_skip_relocation , sonoma : "965d0ae92184e0f04e1739fef4fff253affbced651c03646b777d0b360d4c869"
16+ sha256 cellar : :any_skip_relocation , arm64_linux : "965d0ae92184e0f04e1739fef4fff253affbced651c03646b777d0b360d4c869"
17+ sha256 cellar : :any_skip_relocation , x86_64_linux : "965d0ae92184e0f04e1739fef4fff253affbced651c03646b777d0b360d4c869"
2018 end
2119
2220 depends_on "certifi"
@@ -26,21 +24,11 @@ class Offlineimap < Formula
2624
2725 pypi_packages exclude_packages : "certifi"
2826
29- resource "decorator" do
30- url "https://files.pythonhosted.org/packages/66/0c/8d907af351aa16b42caae42f9d6aa37b900c67308052d10fdce809f8d952/decorator-5.1.1.tar.gz"
31- sha256 "637996211036b6385ef91435e4fae22989472f9d571faba8927ba8253acbc330"
32- end
33-
3427 resource "distro" do
3528 url "https://files.pythonhosted.org/packages/fc/f8/98eea607f65de6527f8a2e8885fc8015d3e6f5775df186e443e0964a11c3/distro-1.9.0.tar.gz"
3629 sha256 "2fa77c6fd8940f116ee1d6b94a2f90b13b5ea8d019b98bc8bafdcabcdd9bdbed"
3730 end
3831
39- resource "gssapi" do
40- url "https://files.pythonhosted.org/packages/04/2f/fcffb772a00e658f608e657791484e3111a19a722b464e893fef35f35097/gssapi-1.9.0.tar.gz"
41- sha256 "f468fac8f3f5fca8f4d1ca19e3cd4d2e10bd91074e7285464b22715d13548afe"
42- end
43-
4432 resource "imaplib2" do
4533 url "https://files.pythonhosted.org/packages/e4/1a/4ccb857f4832d2836a8c996f18fa7bcad19bfdf1a375dfa12e29dbe0e44a/imaplib2-3.6.tar.gz"
4634 sha256 "96cb485b31868a242cb98d5c5dc67b39b22a6359f30316de536060488e581e5b"
@@ -52,11 +40,6 @@ class Offlineimap < Formula
5240 end
5341 end
5442
55- resource "portalocker" do
56- url "https://files.pythonhosted.org/packages/ed/d3/c6c64067759e87af98cc668c1cc75171347d0f1577fab7ca3749134e3cd4/portalocker-2.10.1.tar.gz"
57- sha256 "ef1bf844e878ab08aee7e40184156e1151f228f103aa5c6bd0724cc330960f8f"
58- end
59-
6043 resource "rfc6555" do
6144 url "https://files.pythonhosted.org/packages/f6/4b/24f953c3682c134e4d0f83c7be5ede44c6c653f7d2c0b06ebb3b117f005a/rfc6555-0.1.0.tar.gz"
6245 sha256 "123905b8f68e2bec0c15f321998a262b27e2eaadea29a28bd270021ada411b67"
@@ -67,32 +50,6 @@ class Offlineimap < Formula
6750 sha256 "8d7eaa5a82a1cac232164990f04874c594c9453ec55eef02eab885aa02fc17a2"
6851 end
6952
70- # Fix compatibility with Python 3.11+.
71- patch do
72- url "https://github.com/OfflineIMAP/offlineimap3/commit/7cd32cf834b34a3d4675b29bebcd32dc1e5ef128.patch?full_index=1"
73- sha256 "ffddf6f43398ee13a761c78bece1b4262f9a46cc678966da6af2705ee0fbf1ba"
74- end
75-
76- # Support python 3.12
77- patch do
78- url "https://github.com/OfflineIMAP/offlineimap3/commit/b0c75495db9e1b2b2879e7b0500a885df937bc66.patch?full_index=1"
79- sha256 "6f22557b8d3bfabc9923e76ade72ac1d671c313b751980493f7f05619f57a8f9"
80- end
81-
82- patch do
83- url "https://github.com/OfflineIMAP/offlineimap3/commit/a1951559299b297492b8454850fcfe6eb9822a38.patch?full_index=1"
84- sha256 "64065e061d5efb1a416d43e9f6b776732d9b3b358ffcedafee76ca75abd782da"
85- end
86-
87- patch do
88- url "https://github.com/OfflineIMAP/offlineimap3/commit/4601f50d98cffcb182fddb04f8a78c795004bc73.patch?full_index=1"
89- sha256 "a38595f54fa70d3cdb44aec2f858c256265421171a8ec331a34cbe6041072954"
90- end
91-
92- # Fix warnings with Python 3.12+.
93- # Adapted from: https://github.com/OfflineIMAP/offlineimap3/commit/489ff3bdb1fbd9b483b094f24936e7161f30a754
94- patch :DATA
95-
9653 def install
9754 virtualenv_install_with_resources
9855
@@ -123,103 +80,3 @@ def caveats
12380 system bin /"offlineimap" , "--version"
12481 end
12582end
126-
127- __END__
128- diff --git a/offlineimap/folder/Base.py b/offlineimap/folder/Base.py
129- index f871d6f..e798fb7 100644
130- --- a/offlineimap/folder/Base.py
131- +++ b/offlineimap/folder/Base.py
132- @@ -24,7 +24,6 @@ from sys import exc_info
133-
134- from email import policy
135- from email.parser import BytesParser
136- -from email.generator import BytesGenerator
137- from email.utils import parsedate_tz, mktime_tz
138-
139- from offlineimap import threadutil
140- @@ -249,7 +248,7 @@ class BaseFolder:
141- basename = self.name.replace('/', '.')
142- # Replace with literal 'dot' if final path name is '.' as '.' is
143- # an invalid file name.
144- - basename = re.sub('(^|\/)\.$', '\\1dot', basename)
145- + basename = re.sub(r'(^|\/)\.$', '\\1dot', basename)
146- return basename
147-
148- def check_uidvalidity(self):
149- @@ -866,7 +865,7 @@ class BaseFolder:
150- """
151- msg_header = re.split(b'[\r]?\n[\r]?\n', raw_msg_bytes)[0]
152- try:
153- - msg_id = re.search(b"\nmessage-id:[\s]+(<[A-Za-z0-9!#$%&'*+-/=?^_`{}|~.@ ]+>)",
154- + msg_id = re.search(br"\nmessage-id:[\s]+(<[A-Za-z0-9!#$%&'*+-/=?^_`{}|~.@ ]+>)",
155- msg_header, re.IGNORECASE).group(1)
156- except AttributeError:
157- # No match - Likely not following RFC rules. Try and find anything
158- diff --git a/offlineimap/folder/Gmail.py b/offlineimap/folder/Gmail.py
159- index 544931a..c71720a 100644
160- --- a/offlineimap/folder/Gmail.py
161- +++ b/offlineimap/folder/Gmail.py
162- @@ -75,7 +75,7 @@ class GmailFolder(IMAPFolder):
163-
164- # Embed the labels into the message headers
165- if self.synclabels:
166- - m = re.search('X-GM-LABELS\s*[(](.*)[)]', data[0])
167- + m = re.search(r'X-GM-LABELS\s*[(](.*)[)]', data[0])
168- if m:
169- labels = set([imaputil.dequote(lb) for lb in imaputil.imapsplit(m.group(1))])
170- else:
171- diff --git a/offlineimap/folder/IMAP.py b/offlineimap/folder/IMAP.py
172- index c9318c2..a2883a0 100644
173- --- a/offlineimap/folder/IMAP.py
174- +++ b/offlineimap/folder/IMAP.py
175- @@ -509,14 +509,14 @@ class IMAPFolder(BaseFolder):
176- item = [x.decode('utf-8') for x in item]
177-
178- # Walk just tuples.
179- - if re.search("(?:^|\\r|\\n)%s:\s*%s(?:\\r|\\n)" %
180- + if re.search(r"(?:^|\\r|\\n)%s:\s*%s(?:\\r|\\n)" %
181- (headername, headervalue),
182- item[1], flags=re.IGNORECASE):
183- found = item[0]
184- elif found is not None:
185- if isinstance(item, bytes):
186- item = item.decode('utf-8')
187- - uid = re.search("UID\s+(\d+)", item, flags=re.IGNORECASE)
188- + uid = re.search(r"UID\s+(\d+)", item, flags=re.IGNORECASE)
189- if uid:
190- return int(uid.group(1))
191- else:
192- @@ -526,7 +526,7 @@ class IMAPFolder(BaseFolder):
193- # ')'
194- # and item[0] stored in "found" is like:
195- # '1694 (UID 1694 RFC822.HEADER {1294}'
196- - uid = re.search("\d+\s+\(UID\s+(\d+)", found,
197- + uid = re.search(r"\d+\s+\(UID\s+(\d+)", found,
198- flags=re.IGNORECASE)
199- if uid:
200- return int(uid.group(1))
201- diff --git a/offlineimap/folder/Maildir.py b/offlineimap/folder/Maildir.py
202- index f319b66..198927f 100644
203- --- a/offlineimap/folder/Maildir.py
204- +++ b/offlineimap/folder/Maildir.py
205- @@ -28,9 +28,9 @@ from .Base import BaseFolder
206- from email.errors import NoBoundaryInMultipartDefect
207-
208- # Find the UID in a message filename
209- -re_uidmatch = re.compile(',U=(\d+)')
210- +re_uidmatch = re.compile(r',U=(\d+)')
211- # Find a numeric timestamp in a string (filename prefix)
212- -re_timestampmatch = re.compile('(\d+)')
213- +re_timestampmatch = re.compile(r'(\d+)')
214-
215- timehash = {}
216- timelock = Lock()
217- @@ -61,7 +61,7 @@ class MaildirFolder(BaseFolder):
218- "Account " + self.accountname, "maildir-windows-compatible", False)
219- self.infosep = '!' if self.wincompatible else ':'
220- """infosep is the separator between maildir name and flag appendix"""
221- - self.re_flagmatch = re.compile('%s2,(\w*)' % self.infosep)
222- + self.re_flagmatch = re.compile(r'%s2,(\w*)' % self.infosep)
223- # self.ui is set in BaseFolder.init()
224- # Everything up to the first comma or colon (or ! if Windows):
225- self.re_prefixmatch = re.compile('([^' + self.infosep + ',]*)')
0 commit comments