-
Notifications
You must be signed in to change notification settings - Fork 2
/
action.yaml
110 lines (106 loc) · 3.89 KB
/
action.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
name: "Post to Medium Action"
description: "Automatically push HTML or Markdown to Medium"
author: "Brend-Smits"
inputs:
integration_token:
description: "Medium's Integration Token. Token can be retrieved at medium.com, settings section, under 'Integration Token.'"
required: true
content:
description: "Content to add in the post, can be either HTML or Markdown. Use either this parameter, or the file parameter."
required: false
content_format:
description: "The format of the content field. There are two valid values, html, and markdown."
required: true
file:
description: "Absolute path to the file to use as content, can be either HTML or Markdown. Use either this parameter, or the content parameter."
required: false
publish_status:
description: "Post's status. Valid values are 'draft', 'public', or 'unlisted'."
required: false
default: "draft"
notify_followers:
description: "Whether to notify followers that the user has published."
required: false
default: "false"
license:
description: "Post's license. Valid values are 'all-rights-reserved', 'cc-40-by', 'cc-40-by-sa', 'cc-40-by-nd', 'cc-40-by-nc', 'cc-40-by-nc-nd', 'cc-40-by-nc-sa', 'cc-40-zero', 'public-domain'."
required: false
default: "all-rights-reserved"
publication_name:
description: "The name of the publication the post is being created under. Either PublicationName of PublicationId should be set."
required: false
default: ""
publication_id:
description: "The id of the publication the post is being created under. If you do not know the Id, use PublicationName."
required: false
default: ""
canonical_url:
description: "The canonical URL of the post. If canonicalUrl was not specified in the creation of the post, this field will not be present."
required: false
default: ""
tags:
description: "The post’s tags. Provide a comma separated string without spaces."
required: true
default: ""
title:
description: "The post's title."
required: true
default: ""
parse_frontmatter:
description: "Should the action read and delete frontmatter in a markdown file. Frontmatter should start with --- and end with ---. Should be on the top of the page. When parsing frontmatter, only markdown is supported and settings will be overwritten if specified in the frontmatter."
required: false
default: "false"
outputs:
id:
description: "ID of the Medium post."
author_id:
description: "Author ID of the post creator."
canonical_url:
description: "Canonical URL of the post."
license:
description: "License of the post, can be empty at times."
license_url:
description: "License url of the post, Medium uses this under the hood."
publication_id:
description: "Id of the publication which the post is created under."
publication_status:
description: "Publication status of the post."
title:
description: "Title of the post."
tags:
description: "Tags of the post, comma separated."
url:
description: "URL to the Medium post."
runs:
using: "docker"
image: "docker://ghcr.io/philips-software/post-to-medium-action:v0.6.0"
args:
- "--integration-token"
- ${{ inputs.integration_token }}
- "--title"
- ${{ inputs.title }}
- "--tags"
- ${{ inputs.tags }}
- "--canonical-url"
- ${{ inputs.canonical_url }}
- "--publish-status"
- ${{ inputs.publish_status }}
- "--license"
- ${{ inputs.license }}
- "--publication-id"
- ${{ inputs.publication_id }}
- "--publication-name"
- ${{ inputs.publication_name }}
- "--notify-followers"
- ${{ inputs.notify_followers }}
- "--content-format"
- ${{ inputs.content_format }}
- "--content"
- ${{ inputs.content }}
- "--file"
- ${{ inputs.file }}
- "--parse-frontmatter"
- ${{ inputs.parse_frontmatter }}
branding:
icon: "book"
color: "blue"