peach-ruby 0.4.0 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +34 -3
- data/lib/peach/stream/response.rb +6 -0
- data/lib/peach/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1c436683fd63ce4146bae46abd33f6a3b526763827e0346fc078047f45ceb83a
|
4
|
+
data.tar.gz: 510884541687f39b105f3f99ddd5c1dd58a9749b730462b40ab2f46082f92e50
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e89f352088cd473f27aea558b6f9ffbab323cc5995de4466ee9982b407a82e1c3266243776a96b731879c7b5b8169e94b99ac7d5e87e1d0979e6031c1fdfa214
|
7
|
+
data.tar.gz: 623041f06dd194ac1a18b067ae49165a8c81453bdf91f5684480161ad04f5f8f1e90728684107309c487563ebace0aa1fb998462bc1e01ceafebecafd0ea14aa
|
data/README.md
CHANGED
@@ -45,10 +45,41 @@ Peach::TemplateMessage.deliver('wat_1234abcd', { foo: 'bar' }, contact)
|
|
45
45
|
|
46
46
|
## Development
|
47
47
|
|
48
|
-
|
48
|
+
### Install dependencies
|
49
49
|
|
50
|
-
|
50
|
+
```bash
|
51
|
+
bin/setup
|
52
|
+
```
|
53
|
+
|
54
|
+
### Run tests
|
55
|
+
|
56
|
+
```bash
|
57
|
+
bundle exec rake spec
|
58
|
+
```
|
59
|
+
|
60
|
+
### Use the interactive prompt
|
61
|
+
|
62
|
+
```bash
|
63
|
+
bin/console
|
64
|
+
```
|
65
|
+
|
66
|
+
### Install gem locally
|
67
|
+
|
68
|
+
```bash
|
69
|
+
bundle exec rake install
|
70
|
+
```
|
71
|
+
|
72
|
+
### Release a new version
|
73
|
+
|
74
|
+
We use the [rubygems/release-gem@v1](https://github.com/rubygems/release-gem) action, which creates the tags and pushes the `.gem` file to [rubygems.org](https://rubygems.org) for us.
|
75
|
+
|
76
|
+
What we need to do then is:
|
77
|
+
1. Update version number in `version.rb`
|
78
|
+
2. Run `bundle install` to update `Gemfile.lock` with the new gem version
|
79
|
+
3. Add and commit changes and create a Pull Request
|
80
|
+
|
81
|
+
The GitHub Action then should ideally take care of the rest.
|
51
82
|
|
52
83
|
## Contributing
|
53
84
|
|
54
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
85
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/trypeach-io/peach-ruby.
|
@@ -42,6 +42,12 @@ module Peach
|
|
42
42
|
{ prompt: prompt }
|
43
43
|
end
|
44
44
|
|
45
|
+
def send_template_message(system_name, data: {})
|
46
|
+
template_message = { system_name: system_name }
|
47
|
+
template_message[:data] = data unless data.empty?
|
48
|
+
{ template_message: template_message }
|
49
|
+
end
|
50
|
+
|
45
51
|
def handoff(user_id: nil, group_id: nil, text: nil)
|
46
52
|
handoff = {}
|
47
53
|
handoff[:message] = { text: text } if text
|
data/lib/peach/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: peach-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peach Developers
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-06-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: debug
|