Skip to content

Commit ba07b1e

Browse files
authored
Move send message action into a subdirectory (#32)
Resolves #12
1 parent 924e1b2 commit ba07b1e

File tree

9 files changed

+4376
-4409
lines changed

9 files changed

+4376
-4409
lines changed

.github/workflows/local-test.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
run: |
2424
echo "::set-output name=value::${{ env.ZULIP_API_KEY != '' }}"
2525
- name: Send a stream message
26-
uses: ./
26+
uses: ./send-message
2727
with:
2828
email: 'it-bot@github-actions-test.zulipchat.com'
2929
api-key: ${{ secrets.ZULIP_API_KEY }}
@@ -34,7 +34,7 @@ jobs:
3434
content: 'I come not, friends, to steal away your hearts.'
3535
if: ${{ steps.enable_integration_tests.outputs.value == 'true' }}
3636
- name: Send a private message
37-
uses: ./
37+
uses: ./send-message
3838
with:
3939
email: 'it-bot@github-actions-test.zulipchat.com'
4040
api-key: ${{ secrets.ZULIP_API_KEY }}
@@ -53,7 +53,7 @@ jobs:
5353
- name: Package
5454
run: npm run package
5555
- name: Missing API key and password
56-
uses: ./
56+
uses: ./send-message
5757
with:
5858
email: 'it-bot@github-actions-test.zulipchat.com'
5959
organization-url: 'https://github-actions-test.zulipchat.com'
@@ -63,7 +63,7 @@ jobs:
6363
content: 'I come not, friends, to steal away your hearts.'
6464
continue-on-error: true
6565
- name: Wrong organization URL
66-
uses: ./
66+
uses: ./send-message
6767
with:
6868
email: 'it-bot@github-actions-test.zulipchat.com'
6969
api-key: ${{ secrets.ZULIP_API_KEY }}

.github/workflows/release.yml

Lines changed: 0 additions & 38 deletions
This file was deleted.

README.md

Lines changed: 4 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -1,68 +1,9 @@
1-
# Zulip Send Message Action
1+
# Zulip GitHub Actions
22

33
[![GitHub Action badge](https://github.com/zulip/github-actions-zulip/workflows/test-local/badge.svg)](https://github.com/zulip/github-actions-zulip/actions?query=workflow%3Atest-local)
44

5-
This action sends a message to [Zulip](https://zulip.com/).
5+
This is a collection of GitHub Actions to interact with [Zulip](https://zulip.com/).
66

7-
## Inputs
7+
## Actions
88

9-
### `api-key`
10-
11-
**Required** [API key](https://zulip.com/api/api-keys) used to interact with the Zulip API. You can get an API key through Zulip's web interface.
12-
13-
### `email`
14-
15-
**Required** Email address of the user who owns the API key mentioned above.
16-
17-
### `organization-url`
18-
19-
**Required** Zulip organization canonical URL.
20-
21-
### `to`
22-
23-
**Required** For stream messages, either the name or integer ID of the stream.
24-
For private messages, either a list containing integer user IDs or a list containing string email addresses.
25-
26-
### `type`
27-
28-
**Required** The type of message to be sent. `private` for a private message and `stream` for a stream message.
29-
Must be one of: `private`, `stream`.
30-
31-
### `topic`
32-
33-
**Optional** The topic of the message. Only required for stream messages (`type="stream"`), ignored otherwise.
34-
Maximum length of 60 characters.
35-
36-
### `content`
37-
38-
**Required** The content of the message. Maximum message size of 10000 bytes.
39-
Format your message using [Zulip Markdown](https://zulip.com/help/format-your-message-using-markdown).
40-
41-
## Example usage
42-
43-
**Send a stream message**
44-
```yml
45-
- name: Send a stream message
46-
uses: zulip/github-actions-zulip@v0.2.0
47-
with:
48-
api-key: 'abcd1234'
49-
email: 'username@example.com'
50-
organization-url: 'https://org.zulipchat.com'
51-
to: 'social'
52-
type: 'stream'
53-
topic: 'Castle'
54-
content: 'I come not, friends, to steal away your hearts.'
55-
```
56-
57-
**Send a private message**
58-
```yml
59-
- name: Send a private message
60-
uses: zulip/github-actions-zulip@v0.2.0
61-
with:
62-
api-key: 'abcd1234'
63-
email: 'username@example.com'
64-
organization-url: 'https://org.zulipchat.com'
65-
to: '9' # user_id
66-
type: 'private'
67-
content: 'With mirth and laughter let old wrinkles come.'
68-
```
9+
- [Sends a message to Zulip](./send-message/README.md)

0 commit comments

Comments
 (0)