View | Details | Raw Unified | Return to bug 224374
Collapse All | Expand All

(-)b/mail/mutt/Makefile (-6 / +4 lines)
Lines 2-9 Link Here
2
# $FreeBSD$
2
# $FreeBSD$
3
3
4
PORTNAME=	mutt
4
PORTNAME=	mutt
5
PORTVERSION=	1.9.1
5
PORTVERSION=	1.9.2
6
PORTREVISION?=	1
6
PORTREVISION?=	0
7
CATEGORIES+=	mail ipv6
7
CATEGORIES+=	mail ipv6
8
MASTER_SITES=	ftp://ftp.mutt.org/pub/mutt/ \
8
MASTER_SITES=	ftp://ftp.mutt.org/pub/mutt/ \
9
		ftp://ftp.fu-berlin.de/pub/unix/mail/mutt/ \
9
		ftp://ftp.fu-berlin.de/pub/unix/mail/mutt/ \
Lines 17-26 EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX} Link Here
17
17
18
PATCH_SITES+=	http://www.mutt.org.ua/download/mutt-${VVV_PATCH_VERSION}/:vvv \
18
PATCH_SITES+=	http://www.mutt.org.ua/download/mutt-${VVV_PATCH_VERSION}/:vvv \
19
		http://www2.mutt.org.ua/download/mutt-${VVV_PATCH_VERSION}/:vvv \
19
		http://www2.mutt.org.ua/download/mutt-${VVV_PATCH_VERSION}/:vvv \
20
		https://github.com/aschrab/mutt/compare/dev-base...feature/:ats \
21
		http://vc.org.ua/mutt/:vc
20
		http://vc.org.ua/mutt/:vc
22
PATCH_DIST_STRIP=	-p1
21
PATCH_DIST_STRIP=	-p1
23
PATCHFILES=	date-conditional.diff:ats
24
22
25
MAINTAINER?=	dereks@lifeofadishwasher.com
23
MAINTAINER?=	dereks@lifeofadishwasher.com
26
COMMENT?=	Small but powerful text based program for read/writing e-mail
24
COMMENT?=	Small but powerful text based program for read/writing e-mail
Lines 204-211 DOCS_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-doc-ref Link Here
204
.include <bsd.port.options.mk>
202
.include <bsd.port.options.mk>
205
203
206
# un/comment as each VERSION is created for PORTVERSION
204
# un/comment as each VERSION is created for PORTVERSION
207
#VVV_PATCH_VERSION=	1.8.3
205
VVV_PATCH_VERSION=	1.9.1
208
GREETING_PATCH_VERSION=	1.9.0
206
GREETING_PATCH_VERSION=	1.9.1
209
207
210
.if !defined(VVV_PATCH_VERSION)
208
.if !defined(VVV_PATCH_VERSION)
211
VVV_PATCH_VERSION=	${PORTVERSION}
209
VVV_PATCH_VERSION=	${PORTVERSION}
(-)b/mail/mutt/distinfo (-7 / +5 lines)
Lines 1-10 Link Here
1
TIMESTAMP = 1506285098
1
TIMESTAMP = 1513396241
2
SHA256 (mutt/mutt-1.9.1.tar.gz) = 749b83a96373c6e2101ebe8c4b9a651735e02c478edb750750a5146a15d91bb1
2
SHA256 (mutt/mutt-1.9.2.tar.gz) = a2e152a352bbf02d222d54074199d9c53821c19f700c4cb85f78fa85faed7896
3
SIZE (mutt/mutt-1.9.1.tar.gz) = 4193868
3
SIZE (mutt/mutt-1.9.2.tar.gz) = 4195627
4
SHA256 (mutt/date-conditional.diff) = 8936c5fe7a2a62a68f2a8d001c7a6dddf138c48186a338482b6639507ba9133e
4
SHA256 (mutt/mutt-1.9.1.vc.greeting) = b4ac804c24a07c7eb8330ebfdc94cdbf6fd7a4671badfb32fb611df09c008317
5
SIZE (mutt/date-conditional.diff) = 2023
5
SIZE (mutt/mutt-1.9.1.vc.greeting) = 4534
6
SHA256 (mutt/mutt-1.9.0.vc.greeting) = b4ac804c24a07c7eb8330ebfdc94cdbf6fd7a4671badfb32fb611df09c008317
7
SIZE (mutt/mutt-1.9.0.vc.greeting) = 4534
8
SHA256 (mutt/patch-1.9.1.vvv.nntp.gz) = f7098b713dfcbb2a4a6e5edaf536eb99be6d92fad073d5d3ac436b0191c7c892
6
SHA256 (mutt/patch-1.9.1.vvv.nntp.gz) = f7098b713dfcbb2a4a6e5edaf536eb99be6d92fad073d5d3ac436b0191c7c892
9
SIZE (mutt/patch-1.9.1.vvv.nntp.gz) = 60687
7
SIZE (mutt/patch-1.9.1.vvv.nntp.gz) = 60687
10
SHA256 (mutt/patch-1.9.1.vvv.initials.gz) = 4673ca438fb673dfee09c6b8b8f9e8e78af06056f1b515c6030b0533dae847e5
8
SHA256 (mutt/patch-1.9.1.vvv.initials.gz) = 4673ca438fb673dfee09c6b8b8f9e8e78af06056f1b515c6030b0533dae847e5
(-)b/mail/mutt/files/patch-date-conditional (-1 / +97 lines)
Added Link Here
0
- 
1
--- PATCHES.orig	2017-12-03 03:10:17 UTC
2
+++ PATCHES
3
@@ -0,0 +1 @@
4
+patch-1.5.0.ats.date_conditional.1
5
--- hdrline.c.orig	2017-12-03 03:10:17 UTC
6
+++ hdrline.c
7
@@ -428,6 +428,53 @@ hdr_format_str (char *dest,
8
 	const char *cp;
9
 	struct tm *tm; 
10
 	time_t T;
11
+	int i = 0, invert = 0;
12
+
13
+	if (optional && (op == '[' || op == '(')) {
14
+	  char *is;
15
+	  T = time(NULL);
16
+	  T -= (op == '(') ? hdr->received : hdr->date_sent;
17
+
18
+	  is = (char *)prefix;
19
+	  if( *is == '>' ) {
20
+	    invert = 1;
21
+	    ++is;
22
+	  }
23
+
24
+	  while( *is && *is != '?' ) {
25
+	    int t = strtol (is, &is, 10);
26
+	    switch (*(is++)) {
27
+	      case '?':
28
+		break;
29
+	      case 'y':
30
+		t *= 365 * 24 * 60 * 60;
31
+		break;
32
+	      case 'M':
33
+		t *= 30 * 24 * 60 * 60;
34
+		break;
35
+	      case 'w':
36
+		t *= 7 * 24 * 60 * 60;
37
+		break;
38
+	      case 'd':
39
+		t *= 24 * 60 * 60;
40
+		break;
41
+	      case 'h':
42
+		t *= 60 * 60;
43
+		break;
44
+	      case 'm':
45
+		t *= 60;
46
+		break;
47
+	    }
48
+	    i += t;
49
+	  }
50
+
51
+	  if (i < 0)
52
+	    i *= -1;
53
+
54
+	  if( (T > i || T < -1*i) ^ invert )
55
+	    optional = 0;
56
+	  break;
57
+	}
58
 
59
 	p = dest;
60
 
61
--- muttlib.c.orig	2017-12-03 03:10:17 UTC
62
+++ muttlib.c
63
@@ -1335,7 +1335,16 @@ void mutt_FormatString (char *dest,		/* 
64
       if (*src == '?')
65
       {
66
 	flags |= MUTT_FORMAT_OPTIONAL;
67
-	src++;
68
+	ch = *(++src); /* save the character to switch on */
69
+	cp = prefix;
70
+	++src;
71
+	count = 0;
72
+	while (count < sizeof (prefix) && *src != '?')
73
+	{
74
+	  *cp++ = *src++;
75
+	  count++;
76
+	}
77
+	*cp = 0;
78
       }
79
       else
80
       {
81
@@ -1351,12 +1360,12 @@ void mutt_FormatString (char *dest,		/* 
82
 	  count++;
83
 	}
84
 	*cp = 0;
85
-      }
86
 
87
-      if (!*src)
88
-	break; /* bad format */
89
+	if (!*src)
90
+	  break; /* bad format */
91
 
92
-      ch = *src++; /* save the character to switch on */
93
+	ch = *src++; /* save the character to switch on */
94
+      }
95
 
96
       if (flags & MUTT_FORMAT_OPTIONAL)
97
       {

Return to bug 224374