fix: move setup_git into greenkeeper
MODIFY
src/generators/app.ts
src/generators/app.ts
@@ -294,7 +294,7 @@ class App extends Generator {
// if (this.semantic_release) {
// this.fs.copyTpl(this.templatePath('scripts/release'), this.destinationPath('.circleci/release'), this)
// }
- this.fs.copyTpl(this.templatePath('scripts/setup_git'), this.destinationPath('.circleci/setup_git'), this)
+ // this.fs.copyTpl(this.templatePath('scripts/setup_git'), this.destinationPath('.circleci/setup_git'), this)
this.fs.copyTpl(this.templatePath('README.md.ejs'), this.destinationPath('README.md'), this)
this.fs.copyTpl(this.templatePath('circle.yml.ejs'), this.destinationPath('.circleci/config.yml'), this)
this.fs.copyTpl(this.templatePath('appveyor.yml.ejs'), this.destinationPath('appveyor.yml'), this)

MODIFY
templates/appveyor.yml.ejs
templates/appveyor.yml.ejs
@@ -6,10 +6,6 @@ cache:
install:
- ps: Install-Product node $env:nodejs_version x64
- - git submodule sync
- - git submodule update --init --recursive
- - git config --global user.email "anycli@example.com"
- - git config --global user.name "anycli"
- yarn add -D nyc@11 @anycli/nyc-config@0
test_script:
<%_ if (type === 'single' || type === 'multi') { _%>

MODIFY
templates/circle.yml.ejs
templates/circle.yml.ejs
@@ -23,7 +23,6 @@ jobs:
steps:
- checkout
- attach_workspace: {at: node_modules}
- - run: .circleci/setup_git
<%_ if (mocha) { _%>
- run: |
mkdir -p reports
@@ -85,7 +84,6 @@ jobs:
- attach_workspace: {at: node_modules}
- run: |
export PATH=/usr/local/share/.config/yarn/global/node_modules/.bin:$PATH
- .circleci/setup_git
yarn global add @anycli/semantic-release@1 semantic-release@12
semantic-release -e @anycli/semantic-release
<%_ } _%>

MODIFY
templates/scripts/greenkeeper
templates/scripts/greenkeeper
@@ -10,6 +10,12 @@ if [[ "$CIRCLE_BRANCH" != greenkeeper/* ]]; then
exit 0
fi
+if [[ ! -z "$GIT_EMAIL" ]] & [[ ! -z "$GIT_USERNAME" ]]; then
+ git config --global push.default simple
+ git config --global user.email "$GIT_EMAIL"
+ git config --global user.name "$GIT_USERNAME"
+fi
+
if [[ ! -x "$(command -v greenkeeper-lockfile-update)" ]]; then
yarn global add greenkeeper-lockfile@1
fi

fix: move setup_git into greenkeeper