Skip to content

Commit

Permalink
feat: add commit input
Browse files Browse the repository at this point in the history
  • Loading branch information
EndBug committed Dec 3, 2021
1 parent 041b3a0 commit 018fe62
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 2 deletions.
3 changes: 3 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ inputs:
description: How the action should behave when the targeted branch is missing
required: false
default: throw
commit:
description: Additional arguments for the git commit command
required: false
committer_name:
description: The name of the custom committer you want to use
required: false
Expand Down
2 changes: 1 addition & 1 deletion lib/index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ core.info(`Running in ${baseDir}`)
core.info('> Creating commit...')
await git.commit(
getInput('message'),
undefined,
matchGitArgs(getInput('commit') || ''),
(err, data?: CommitSummary) => {
if (data) {
setOutput('committed', 'true')
Expand Down
1 change: 1 addition & 0 deletions src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ interface InputTypes {
author_email: string
branch: string
branch_mode: 'throw' | 'create'
commit: string | undefined
committer_name: string
committer_email: string
cwd: string
Expand Down

0 comments on commit 018fe62

Please sign in to comment.