sup 1.4 → 1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CONTRIBUTORS +2 -2
- data/History.txt +21 -0
- data/Manifest.txt +10 -0
- data/README.md +1 -1
- data/bin/sup-sync +1 -2
- data/contrib/nix/.gitignore +1 -0
- data/contrib/nix/Gemfile.lock +17 -17
- data/contrib/nix/gem-install-shell.nix +1 -1
- data/contrib/nix/gemset.nix +28 -28
- data/contrib/nix/ruby2.4-Gemfile.lock +1 -1
- data/contrib/nix/ruby2.4-gemset.nix +2 -2
- data/contrib/nix/ruby2.5-Gemfile.lock +1 -1
- data/contrib/nix/ruby2.5-gemset.nix +2 -2
- data/contrib/nix/ruby2.6-Gemfile.lock +1 -1
- data/contrib/nix/ruby2.6-gemset.nix +2 -2
- data/contrib/nix/ruby2.7-Gemfile.lock +1 -1
- data/contrib/nix/ruby2.7-gemset.nix +2 -2
- data/contrib/nix/ruby3.0-Gemfile.lock +1 -1
- data/contrib/nix/ruby3.0-gemset.nix +2 -2
- data/contrib/nix/ruby3.1-Gemfile.lock +1 -1
- data/contrib/nix/ruby3.1-gemset.nix +2 -2
- data/contrib/nix/ruby3.2-Gemfile.lock +1 -1
- data/contrib/nix/ruby3.2-gemset.nix +2 -2
- data/contrib/nix/ruby3.3-shell.nix +1 -1
- data/contrib/nix/ruby3.4-shell.nix +1 -1
- data/contrib/nix/ruby4.0-shell.nix +2 -1
- data/contrib/nix/test-all-rubies.sh +2 -1
- data/contrib/screenshot-generator/.gitignore +1 -0
- data/contrib/screenshot-generator/default.nix +253 -0
- data/contrib/screenshot-generator/scenes.yaml +51 -0
- data/contrib/screenshot-generator/shoot.rb +127 -0
- data/contrib/screenshot-generator/sup-is-plain-text-applied.msg +83 -0
- data/contrib/screenshot-generator/sup-is-plain-text.msg +78 -0
- data/lib/sup/buffer.rb +13 -3
- data/lib/sup/draft.rb +0 -4
- data/lib/sup/index.rb +7 -1
- data/lib/sup/maildir.rb +21 -16
- data/lib/sup/mbox.rb +0 -10
- data/lib/sup/message.rb +5 -19
- data/lib/sup/message_chunks.rb +1 -1
- data/lib/sup/modes/edit_message_mode.rb +52 -4
- data/lib/sup/modes/thread_index_mode.rb +28 -27
- data/lib/sup/person.rb +0 -6
- data/lib/sup/poll.rb +1 -4
- data/lib/sup/sent.rb +5 -4
- data/lib/sup/source.rb +0 -47
- data/lib/sup/util.rb +2 -2
- data/lib/sup/version.rb +1 -1
- data/test/dummy_source.rb +0 -4
- data/test/fixtures/folded-from-header.eml +8 -0
- data/test/fixtures/rfc2047-header-encoding.eml +1 -0
- data/test/fixtures/text-attachments-with-charset.eml +7 -0
- data/test/integration/test_index.rb +62 -0
- data/test/test_header_parsing.rb +9 -9
- data/test/test_message.rb +21 -3
- data/test/unit/test_index.rb +27 -3
- data/test/unit/test_line_cursor_mode.rb +6 -0
- data/test/unit/test_maildir.rb +21 -0
- metadata +15 -4
- data/man/sup-psych-ify-config-files.1 +0 -76
data/test/unit/test_index.rb
CHANGED
|
@@ -32,34 +32,58 @@ class TestIndex < Minitest::Test
|
|
|
32
32
|
parsed = with_fake_time do
|
|
33
33
|
Redwood::Index.parse_query "after:yesterday"
|
|
34
34
|
end
|
|
35
|
-
|
|
35
|
+
expected_date_qobj = Xapian::Query.new(
|
|
36
36
|
Xapian::Query::OP_VALUE_RANGE,
|
|
37
37
|
Redwood::Index::DATE_VALUENO,
|
|
38
38
|
Xapian.sortable_serialise(Time.utc(2000, 1, 1).to_i),
|
|
39
39
|
Xapian.sortable_serialise(2**32),
|
|
40
40
|
)
|
|
41
|
+
expected_qobj = Xapian::Query.new(
|
|
42
|
+
0.0,
|
|
43
|
+
Xapian::Query.new(
|
|
44
|
+
Xapian::Query::OP_AND,
|
|
45
|
+
expected_date_qobj,
|
|
46
|
+
Xapian::Query.new("Kmail"),
|
|
47
|
+
),
|
|
48
|
+
)
|
|
41
49
|
assert_equal expected_qobj.description, parsed[:qobj].description
|
|
42
50
|
|
|
43
51
|
parsed = with_fake_time do
|
|
44
52
|
Redwood::Index.parse_query "before:yesterday"
|
|
45
53
|
end
|
|
46
|
-
|
|
54
|
+
expected_date_qobj = Xapian::Query.new(
|
|
47
55
|
Xapian::Query::OP_VALUE_RANGE,
|
|
48
56
|
Redwood::Index::DATE_VALUENO,
|
|
49
57
|
Xapian.sortable_serialise(0),
|
|
50
58
|
Xapian.sortable_serialise(Time.utc(2000, 1, 1).to_i),
|
|
51
59
|
)
|
|
60
|
+
expected_qobj = Xapian::Query.new(
|
|
61
|
+
0.0,
|
|
62
|
+
Xapian::Query.new(
|
|
63
|
+
Xapian::Query::OP_AND,
|
|
64
|
+
expected_date_qobj,
|
|
65
|
+
Xapian::Query.new("Kmail"),
|
|
66
|
+
),
|
|
67
|
+
)
|
|
52
68
|
assert_equal expected_qobj.description, parsed[:qobj].description
|
|
53
69
|
|
|
54
70
|
parsed = with_fake_time do
|
|
55
71
|
Redwood::Index.parse_query "during:yesterday"
|
|
56
72
|
end
|
|
57
|
-
|
|
73
|
+
expected_date_qobj = Xapian::Query.new(
|
|
58
74
|
Xapian::Query::OP_VALUE_RANGE,
|
|
59
75
|
Redwood::Index::DATE_VALUENO,
|
|
60
76
|
Xapian.sortable_serialise(Time.utc(1999, 12, 31).to_i),
|
|
61
77
|
Xapian.sortable_serialise(Time.utc(2000, 1, 1).to_i),
|
|
62
78
|
)
|
|
79
|
+
expected_qobj = Xapian::Query.new(
|
|
80
|
+
0.0,
|
|
81
|
+
Xapian::Query.new(
|
|
82
|
+
Xapian::Query::OP_AND,
|
|
83
|
+
expected_date_qobj,
|
|
84
|
+
Xapian::Query.new("Kmail"),
|
|
85
|
+
),
|
|
86
|
+
)
|
|
63
87
|
assert_equal expected_qobj.description, parsed[:qobj].description
|
|
64
88
|
end
|
|
65
89
|
end
|
|
@@ -10,6 +10,9 @@ class TestLineCursorMode < Minitest::Test
|
|
|
10
10
|
:load_more_threads_when_scrolling => true,
|
|
11
11
|
:continuous_scroll => false,
|
|
12
12
|
}
|
|
13
|
+
@out = File.open File::NULL, "w"
|
|
14
|
+
@inp = File.open File::NULL, "r"
|
|
15
|
+
@screen = Ncurses.newterm "dumb", @out, @inp
|
|
13
16
|
Redwood::BufferManager.init
|
|
14
17
|
@modes_to_cleanup = []
|
|
15
18
|
@lines = []
|
|
@@ -20,6 +23,9 @@ class TestLineCursorMode < Minitest::Test
|
|
|
20
23
|
def teardown
|
|
21
24
|
@modes_to_cleanup.each { |mode| mode.cleanup }
|
|
22
25
|
Redwood::BufferManager.deinstantiate!
|
|
26
|
+
Ncurses.delscreen @screen
|
|
27
|
+
@inp.close
|
|
28
|
+
@out.close
|
|
23
29
|
$config = nil
|
|
24
30
|
end
|
|
25
31
|
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
require 'test_helper'
|
|
2
|
+
require 'sup'
|
|
3
|
+
require 'sup/maildir'
|
|
4
|
+
|
|
5
|
+
module Redwood
|
|
6
|
+
|
|
7
|
+
class TestMaildir < Minitest::Test
|
|
8
|
+
def test_flag_parsing
|
|
9
|
+
maildir = Maildir.new "maildir:/nowhere"
|
|
10
|
+
labels = maildir.labels? "asdf:2,S"
|
|
11
|
+
assert_equal [], labels
|
|
12
|
+
labels = maildir.labels? "asdf:2,"
|
|
13
|
+
assert_equal [:unread], labels
|
|
14
|
+
labels = maildir.labels? "asdf:2,DFPRST"
|
|
15
|
+
assert_equal [:deleted, :starred, :forwarded, :replied, :draft], labels
|
|
16
|
+
labels = maildir.labels? "asdf:2,DFPRT"
|
|
17
|
+
assert_equal [:unread, :deleted, :starred, :forwarded, :replied, :draft], labels
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: sup
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: '1.
|
|
4
|
+
version: '1.5'
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- William Morgan
|
|
@@ -10,7 +10,7 @@ authors:
|
|
|
10
10
|
- Matthieu Rakotojaona
|
|
11
11
|
bindir: bin
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date: 2026-
|
|
13
|
+
date: 2026-11-19 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: ncursesw
|
|
@@ -317,7 +317,6 @@ extra_rdoc_files:
|
|
|
317
317
|
- man/sup-config.1
|
|
318
318
|
- man/sup-dump.1
|
|
319
319
|
- man/sup-import-dump.1
|
|
320
|
-
- man/sup-psych-ify-config-files.1
|
|
321
320
|
- man/sup-recover-sources.1
|
|
322
321
|
- man/sup-sync-back-maildir.1
|
|
323
322
|
- man/sup-sync.1
|
|
@@ -349,6 +348,7 @@ files:
|
|
|
349
348
|
- contrib/colorpicker.rb
|
|
350
349
|
- contrib/completion/_sup.bash
|
|
351
350
|
- contrib/completion/_sup.zsh
|
|
351
|
+
- contrib/nix/.gitignore
|
|
352
352
|
- contrib/nix/Gemfile
|
|
353
353
|
- contrib/nix/Gemfile.lock
|
|
354
354
|
- contrib/nix/README
|
|
@@ -379,6 +379,12 @@ files:
|
|
|
379
379
|
- contrib/nix/ruby3.4-shell.nix
|
|
380
380
|
- contrib/nix/ruby4.0-shell.nix
|
|
381
381
|
- contrib/nix/test-all-rubies.sh
|
|
382
|
+
- contrib/screenshot-generator/.gitignore
|
|
383
|
+
- contrib/screenshot-generator/default.nix
|
|
384
|
+
- contrib/screenshot-generator/scenes.yaml
|
|
385
|
+
- contrib/screenshot-generator/shoot.rb
|
|
386
|
+
- contrib/screenshot-generator/sup-is-plain-text-applied.msg
|
|
387
|
+
- contrib/screenshot-generator/sup-is-plain-text.msg
|
|
382
388
|
- devel/console.sh
|
|
383
389
|
- devel/count-loc.sh
|
|
384
390
|
- devel/load-index.rb
|
|
@@ -459,7 +465,6 @@ files:
|
|
|
459
465
|
- man/sup-config.1
|
|
460
466
|
- man/sup-dump.1
|
|
461
467
|
- man/sup-import-dump.1
|
|
462
|
-
- man/sup-psych-ify-config-files.1
|
|
463
468
|
- man/sup-recover-sources.1
|
|
464
469
|
- man/sup-sync-back-maildir.1
|
|
465
470
|
- man/sup-sync.1
|
|
@@ -474,6 +479,7 @@ files:
|
|
|
474
479
|
- test/fixtures/contacts.txt
|
|
475
480
|
- test/fixtures/embedded-message-rfc6532.eml
|
|
476
481
|
- test/fixtures/embedded-message.eml
|
|
482
|
+
- test/fixtures/folded-from-header.eml
|
|
477
483
|
- test/fixtures/invalid-date.eml
|
|
478
484
|
- test/fixtures/mailing-list-header.eml
|
|
479
485
|
- test/fixtures/malicious-attachment-names.eml
|
|
@@ -501,6 +507,7 @@ files:
|
|
|
501
507
|
- test/gnupg_test_home/secring.gpg
|
|
502
508
|
- test/gnupg_test_home/sup-test-2@foo.bar.asc
|
|
503
509
|
- test/integration/test_draft.rb
|
|
510
|
+
- test/integration/test_index.rb
|
|
504
511
|
- test/integration/test_maildir.rb
|
|
505
512
|
- test/integration/test_mbox.rb
|
|
506
513
|
- test/integration/test_sup-add.rb
|
|
@@ -518,6 +525,7 @@ files:
|
|
|
518
525
|
- test/unit/test_index.rb
|
|
519
526
|
- test/unit/test_line_cursor_mode.rb
|
|
520
527
|
- test/unit/test_locale_fiddler.rb
|
|
528
|
+
- test/unit/test_maildir.rb
|
|
521
529
|
- test/unit/test_person.rb
|
|
522
530
|
- test/unit/test_rmail_message.rb
|
|
523
531
|
- test/unit/util/test_query.rb
|
|
@@ -562,6 +570,7 @@ test_files:
|
|
|
562
570
|
- test/fixtures/contacts.txt
|
|
563
571
|
- test/fixtures/embedded-message-rfc6532.eml
|
|
564
572
|
- test/fixtures/embedded-message.eml
|
|
573
|
+
- test/fixtures/folded-from-header.eml
|
|
565
574
|
- test/fixtures/invalid-date.eml
|
|
566
575
|
- test/fixtures/mailing-list-header.eml
|
|
567
576
|
- test/fixtures/malicious-attachment-names.eml
|
|
@@ -589,6 +598,7 @@ test_files:
|
|
|
589
598
|
- test/gnupg_test_home/secring.gpg
|
|
590
599
|
- test/gnupg_test_home/sup-test-2@foo.bar.asc
|
|
591
600
|
- test/integration/test_draft.rb
|
|
601
|
+
- test/integration/test_index.rb
|
|
592
602
|
- test/integration/test_maildir.rb
|
|
593
603
|
- test/integration/test_mbox.rb
|
|
594
604
|
- test/integration/test_sup-add.rb
|
|
@@ -606,6 +616,7 @@ test_files:
|
|
|
606
616
|
- test/unit/test_index.rb
|
|
607
617
|
- test/unit/test_line_cursor_mode.rb
|
|
608
618
|
- test/unit/test_locale_fiddler.rb
|
|
619
|
+
- test/unit/test_maildir.rb
|
|
609
620
|
- test/unit/test_person.rb
|
|
610
621
|
- test/unit/test_rmail_message.rb
|
|
611
622
|
- test/unit/util/test_query.rb
|
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
.\" Automatically generated by Pandoc 3.1.11.1
|
|
2
|
-
.\"
|
|
3
|
-
.TH "SUP\-SYNC" "1" "September 3, 2014" "Sup User Manual" ""
|
|
4
|
-
.SH NAME
|
|
5
|
-
sup\-psych\-ify\-config\-files \- migrate Sup configuration
|
|
6
|
-
.SH SYNOPSIS
|
|
7
|
-
sup\-psych\-ify\-config\-files
|
|
8
|
-
.SH DESCRIPTION
|
|
9
|
-
\f[B]YAML migration is deprecated by Ruby 2.1 and newer.\f[R]
|
|
10
|
-
.PP
|
|
11
|
-
If sup\-psych\-ify\-config\-files is executed by Ruby <= 2.0 it migrates
|
|
12
|
-
the \f[I]$HOME/.sup/sources.yaml\f[R] configuration file by reading it
|
|
13
|
-
with the SYCK YAML parser and emitting the results with the Psych YAML
|
|
14
|
-
emitter.
|
|
15
|
-
.PP
|
|
16
|
-
Read more on the Sup wiki
|
|
17
|
-
.PP
|
|
18
|
-
https://github.com/sup\-heliotrope/sup/wiki/Migration\-0.13\-to\-0.14
|
|
19
|
-
.SH FILES
|
|
20
|
-
.TP
|
|
21
|
-
$HOME/.sup/config.yaml
|
|
22
|
-
Sup configuration file
|
|
23
|
-
.TP
|
|
24
|
-
$HOME/.sup/sources.yaml
|
|
25
|
-
Configuration file for Sup mail sources
|
|
26
|
-
.SH SEE ALSO
|
|
27
|
-
sup(1), sup\-add(1), sup\-config(1), sup\-dump(1)
|
|
28
|
-
.SH REPORTING BUGS
|
|
29
|
-
You are welcome to submit bug reports to the Sup issue tracker, located
|
|
30
|
-
at
|
|
31
|
-
.PP
|
|
32
|
-
\c
|
|
33
|
-
.UR https://github.com/sup-heliotrope/sup/issues
|
|
34
|
-
.UE \c
|
|
35
|
-
.SH CONTACT INFORMATION
|
|
36
|
-
.TP
|
|
37
|
-
The Sup web page:
|
|
38
|
-
\c
|
|
39
|
-
.UR https://sup-heliotrope.github.io/
|
|
40
|
-
.UE \c
|
|
41
|
-
.TP
|
|
42
|
-
Code repository:
|
|
43
|
-
\c
|
|
44
|
-
.UR https://github.com/sup-heliotrope/sup/
|
|
45
|
-
.UE \c
|
|
46
|
-
.TP
|
|
47
|
-
Sup Wiki:
|
|
48
|
-
\c
|
|
49
|
-
.UR https://github.com/sup-heliotrope/sup/wiki/
|
|
50
|
-
.UE \c
|
|
51
|
-
.TP
|
|
52
|
-
Mailing list:
|
|
53
|
-
supmua\[at]googlegroups.com
|
|
54
|
-
.RS
|
|
55
|
-
.PP
|
|
56
|
-
supmua+subscribe\[at]googlegroups.com
|
|
57
|
-
.PP
|
|
58
|
-
Archives: \c
|
|
59
|
-
.UR https://groups.google.com/d/forum/supmua/
|
|
60
|
-
.UE \c
|
|
61
|
-
.RE
|
|
62
|
-
.SH COPYRIGHT
|
|
63
|
-
Copyright © 2006\-2009 William Morgan \c
|
|
64
|
-
.MT mworgan-sup@masanjin.net
|
|
65
|
-
.ME \c
|
|
66
|
-
.PP
|
|
67
|
-
Copyright \[at] 2013\-2014 Sup developers
|
|
68
|
-
.PP
|
|
69
|
-
Permission is granted to copy and distribute this manual under the terms
|
|
70
|
-
of the GNU General Public License; either version 2 or (at your option)
|
|
71
|
-
any later version.
|
|
72
|
-
.SH AUTHORS
|
|
73
|
-
Sup was originally written by William Morgan \c
|
|
74
|
-
.MT wmorgan-sup@masanjin.net
|
|
75
|
-
.ME \c
|
|
76
|
-
\ and is now developed and maintained by the Sup developers.
|