set git user
This commit is contained in:
parent
8eca834494
commit
b8ad07e55e
|
@ -24,8 +24,7 @@ COPY package*.json ./
|
||||||
# Install dependencies
|
# Install dependencies
|
||||||
RUN apt-get update
|
RUN apt-get update
|
||||||
RUN apt-get -y install git
|
RUN apt-get -y install git
|
||||||
RUN git config --global user.name "Bump Version"
|
|
||||||
RUN git config --global user.email "gh-action-bump-version@users.noreply.github.com"
|
|
||||||
RUN npm ci
|
RUN npm ci
|
||||||
|
|
||||||
|
|
||||||
|
|
4
index.js
4
index.js
|
@ -27,6 +27,10 @@ Toolkit.run(async tools => {
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const current = pkg.version.toString()
|
const current = pkg.version.toString()
|
||||||
|
// set git user
|
||||||
|
await tools.runInWorkspace('git', ['config', 'user.name', '"Bump Version"'])
|
||||||
|
await tools.runInWorkspace('git', ['config', 'user.email', '"gh-action-bump-version@users.noreply.github.com"'])
|
||||||
|
|
||||||
await tools.runInWorkspace('git', ['checkout', 'master'])
|
await tools.runInWorkspace('git', ['checkout', 'master'])
|
||||||
await tools.runInWorkspace('npm',
|
await tools.runInWorkspace('npm',
|
||||||
['version', '--allow-same-version=true', '--git-tag-version=false', current])
|
['version', '--allow-same-version=true', '--git-tag-version=false', current])
|
||||||
|
|
Loading…
Reference in New Issue