telex 0.1.0 → 0.1.1
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/CHANGELOG.md +9 -0
- data/README.md +6 -2
- data/config/routes.rb +4 -2
- data/lib/telex/engine.rb +6 -0
- data/lib/telex/version.rb +1 -1
- data/lib/telex.rb +5 -0
- metadata +2 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 7d996298da2a8f90a268e03eea91bd280a6bb0abe473a9feb61ffefd1d30d089
|
|
4
|
+
data.tar.gz: dc2b3b106851f1919422b9b5c4d7d5e3a6841ad19b1e6092ab24967c3317c046
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 245d45bf33cbb9e695574f564bacd79faeebf090e1cfbd28f74e66680aeb41540209301f98d9372e02e0f3f26c486f89adc26d35fe2886d0d8a7f2c194a0b24b
|
|
7
|
+
data.tar.gz: 75897e2acdd17b0b4017a2dc840ecbc770a20d17014399b81939bd15c8dc9283027c8f5801920a2470db8b537f7f8f8e6010b40ec0ba2b8d46afe75f615732c9
|
data/CHANGELOG.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 0.1.1 (2026-10-07)
|
|
4
|
+
|
|
5
|
+
- An app that does not load Action Mailbox boots again in production. Telex then only sends: the ingress and its route are left out.
|
|
6
|
+
|
|
7
|
+
## 0.1.0 (2026-10-07)
|
|
8
|
+
|
|
9
|
+
- First release: the `:lettermint` delivery method for Action Mailer and the Lettermint ingress for Action Mailbox.
|
data/README.md
CHANGED
|
@@ -11,9 +11,11 @@ Each app has its own Lettermint project: its own API token, logs, webhook and re
|
|
|
11
11
|
|
|
12
12
|
```ruby
|
|
13
13
|
# Gemfile
|
|
14
|
-
gem "telex"
|
|
14
|
+
gem "telex"
|
|
15
15
|
```
|
|
16
16
|
|
|
17
|
+
Or `gem "telex", github: "boxprod/telex"` to follow `main` between releases.
|
|
18
|
+
|
|
17
19
|
```yaml
|
|
18
20
|
# bin/rails credentials:edit
|
|
19
21
|
lettermint:
|
|
@@ -34,7 +36,7 @@ The sending domain must be verified in the Lettermint project (SPF, DKIM, return
|
|
|
34
36
|
|
|
35
37
|
### Receiving
|
|
36
38
|
|
|
37
|
-
Install Action Mailbox if the app does not have it yet (it needs Active Storage):
|
|
39
|
+
Install Action Mailbox if the app does not have it yet (it needs Active Storage). Without it, Telex only sends:
|
|
38
40
|
|
|
39
41
|
```sh
|
|
40
42
|
bin/rails action_mailbox:install db:migrate
|
|
@@ -99,3 +101,5 @@ bundle install
|
|
|
99
101
|
bin/rails db:migrate
|
|
100
102
|
bin/rails test
|
|
101
103
|
```
|
|
104
|
+
|
|
105
|
+
To release, bump `lib/telex/version.rb`, commit, then `bundle exec rake release`: it tags, pushes the tag and pushes the gem to RubyGems, asking for a one-time code.
|
data/config/routes.rb
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
Rails.application.routes.draw do
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
if Telex.receiving?
|
|
3
|
+
scope "/rails/action_mailbox", module: "action_mailbox/ingresses" do
|
|
4
|
+
post "/lettermint/inbound_emails" => "lettermint/inbound_emails#create", as: :rails_lettermint_inbound_emails
|
|
5
|
+
end
|
|
4
6
|
end
|
|
5
7
|
end
|
data/lib/telex/engine.rb
CHANGED
|
@@ -8,5 +8,11 @@ module Telex
|
|
|
8
8
|
add_delivery_method :lettermint, Mail::SMTP, Telex::SMTP_SETTINGS.merge(password: Telex.api_token)
|
|
9
9
|
end
|
|
10
10
|
end
|
|
11
|
+
|
|
12
|
+
# An app that only sends does not load Action Mailbox: the ingress is left out, or eager
|
|
13
|
+
# loading it would stop the app from booting.
|
|
14
|
+
initializer "telex.without_action_mailbox", before: :set_autoload_paths do
|
|
15
|
+
Rails.autoloaders.main.ignore(root.join("app/controllers/action_mailbox")) unless Telex.receiving?
|
|
16
|
+
end
|
|
11
17
|
end
|
|
12
18
|
end
|
data/lib/telex/version.rb
CHANGED
data/lib/telex.rb
CHANGED
|
@@ -25,6 +25,11 @@ module Telex
|
|
|
25
25
|
Rails.application.credentials.dig(:lettermint, :webhook_secret) || ENV["LETTERMINT_WEBHOOK_SECRET"]
|
|
26
26
|
end
|
|
27
27
|
|
|
28
|
+
# Whether the app loads Action Mailbox, without which Telex only sends.
|
|
29
|
+
def receiving?
|
|
30
|
+
defined?(ActionMailbox::Engine) ? true : false
|
|
31
|
+
end
|
|
32
|
+
|
|
28
33
|
# Replaced in tests; anything that answers #fetch(url) with the message's source.
|
|
29
34
|
attr_writer :download
|
|
30
35
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: telex
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- B.O.X
|
|
@@ -29,6 +29,7 @@ executables: []
|
|
|
29
29
|
extensions: []
|
|
30
30
|
extra_rdoc_files: []
|
|
31
31
|
files:
|
|
32
|
+
- CHANGELOG.md
|
|
32
33
|
- MIT-LICENSE
|
|
33
34
|
- README.md
|
|
34
35
|
- Rakefile
|