mirror of
https://github.com/mitchellkrogza/nginx-ultimate-bad-bot-blocker.git
synced 2025-09-10 06:15:06 +00:00
Some changes to Travis and Modify/Commit Script
This commit is contained in:
parent
669a9d8332
commit
6a91d8a63f
2 changed files with 3 additions and 8 deletions
32
travisCI/modify-files-and-commit.sh
Executable file
32
travisCI/modify-files-and-commit.sh
Executable file
|
@ -0,0 +1,32 @@
|
|||
#!/bin/bash
|
||||
YEAR=$(date +"%Y")
|
||||
MONTH=$(date +"%m")
|
||||
cd $TRAVIS_BUILD_DIR
|
||||
|
||||
#Remove Remotes Added by TravisCI
|
||||
git remote rm origin
|
||||
|
||||
#Add Remote with Secure Key
|
||||
git remote add origin https://${GH_TOKEN}@github.com/${TRAVIS_REPO_SLUG}.git
|
||||
|
||||
#List Remotes ONLY DURING testing - do not do this on live repo / possible key leak
|
||||
#git remote -v
|
||||
|
||||
# Set Git Variables
|
||||
git config --global user.email "${GIT_EMAIL}"
|
||||
git config --global user.name "${GIT_NAME}"
|
||||
git config --global push.default simple
|
||||
|
||||
# Make sure we have master branch checked out in Git
|
||||
git checkout master
|
||||
|
||||
# Modify our file and make sure Travis is owner
|
||||
sudo $TRAVIS_BUILD_DIR/travisCI/modify-globalblacklist.sh
|
||||
sudo $TRAVIS_BUILD_DIR/travisCI/modify-readme.sh
|
||||
#sudo chown -R travis:travis $TRAVIS_BUILD_DIR/*
|
||||
|
||||
# Add the modified files and commit
|
||||
git add -A
|
||||
git commit -am "V3.$YEAR.$MONTH.$TRAVIS_BUILD_NUMBER [ci skip]"
|
||||
|
||||
# Travis now moves to the before_deploy: section of .travis.yml
|
Loading…
Add table
Add a link
Reference in a new issue