You've already forked dynamic-badges-action
🔧 Use camel case
This commit is contained in:
20
action.yml
20
action.yml
@@ -7,10 +7,10 @@ inputs:
|
||||
auth:
|
||||
description: 'Your secret with the gist scope'
|
||||
required: true
|
||||
gist-id:
|
||||
gistID:
|
||||
description: 'The ID of the gist to use'
|
||||
required: true
|
||||
badge-name:
|
||||
filename:
|
||||
description: 'The *.json filename of the badge data'
|
||||
required: true
|
||||
label:
|
||||
@@ -19,34 +19,34 @@ inputs:
|
||||
message:
|
||||
description: 'The right text of the badge'
|
||||
required: true
|
||||
label-color:
|
||||
labelColor:
|
||||
description: 'The left color of the badge'
|
||||
required: false
|
||||
color:
|
||||
description: 'The right color of the badge'
|
||||
required: false
|
||||
is-error:
|
||||
isError:
|
||||
description: 'The color will be red and cannot be overridden'
|
||||
required: false
|
||||
named-logo:
|
||||
namedLogo:
|
||||
description: 'A logo name from simpleicons.org'
|
||||
required: false
|
||||
logo-svg:
|
||||
logoSvg:
|
||||
description: 'An svg-string to be used as logo'
|
||||
required: false
|
||||
logo-color:
|
||||
logoColor:
|
||||
description: 'The color for the logo'
|
||||
required: false
|
||||
logo-width:
|
||||
logoWidth:
|
||||
description: 'The space allocated for the logo'
|
||||
required: false
|
||||
logo-position:
|
||||
logoPosition:
|
||||
description: 'The position of the logo'
|
||||
required: false
|
||||
style:
|
||||
description: 'The style like "flat" or "social"'
|
||||
required: false
|
||||
cache-seconds:
|
||||
cacheSeconds:
|
||||
description: 'The cache lifetime in seconds (must be greater than 300)'
|
||||
required: false
|
||||
runs:
|
||||
|
||||
20
index.js
20
index.js
@@ -8,16 +8,16 @@ try {
|
||||
message: core.getInput('message')
|
||||
};
|
||||
|
||||
const labelColor = core.getInput('label-color');
|
||||
const labelColor = core.getInput('labelColor');
|
||||
const color = core.getInput('color');
|
||||
const isError = core.getInput('is-error');
|
||||
const namedLogo = core.getInput('named-logo');
|
||||
const logoSvg = core.getInput('logo-svg');
|
||||
const logoColor = core.getInput('logo-color');
|
||||
const logoWidth = core.getInput('logo-width');
|
||||
const logoPosition = core.getInput('logo-position');
|
||||
const isError = core.getInput('isError');
|
||||
const namedLogo = core.getInput('namedLogo');
|
||||
const logoSvg = core.getInput('logoSvg');
|
||||
const logoColor = core.getInput('logoColor');
|
||||
const logoWidth = core.getInput('logoWidth');
|
||||
const logoPosition = core.getInput('logoPosition');
|
||||
const style = core.getInput('style');
|
||||
const cacheSeconds = core.getInput('cache-seconds');
|
||||
const cacheSeconds = core.getInput('cacheSeconds');
|
||||
|
||||
|
||||
if (labelColor != '') {
|
||||
@@ -61,7 +61,7 @@ try {
|
||||
}
|
||||
|
||||
let data = {files: {}};
|
||||
data.files[core.getInput('badge-name')] = {
|
||||
data.files[core.getInput('filename')] = {
|
||||
content: JSON.stringify(description)
|
||||
};
|
||||
data = JSON.stringify(data);
|
||||
@@ -69,7 +69,7 @@ try {
|
||||
const req = http.request(
|
||||
{
|
||||
host: 'api.github.com',
|
||||
path: '/gists/' + core.getInput('gist-id'),
|
||||
path: '/gists/' + core.getInput('gistID'),
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
|
||||
Reference in New Issue
Block a user