From 8da442f411a7fe0d9a5521ac6e95e20c7923caf1 Mon Sep 17 00:00:00 2001 From: Jack Humbert Date: Wed, 17 May 2017 20:27:07 -0400 Subject: update travis script --- util/travis_compiled_push.sh | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'util/travis_compiled_push.sh') diff --git a/util/travis_compiled_push.sh b/util/travis_compiled_push.sh index 58334cb1f6..718daaa295 100644 --- a/util/travis_compiled_push.sh +++ b/util/travis_compiled_push.sh @@ -33,18 +33,19 @@ if [[ "$TRAVIS_COMMIT_MESSAGE" != *"[skip build]"* ]] ; then make ergodox-ez AUTOGEN=true - find . -name ".build" | xargs rm -rf cd .. git clone https://$GH_TOKEN@github.com/jackhumbert/qmk.fm.git cd qmk.fm - git submodule update --init --recursive + #git submodule update --init --recursive #rm -rf keyboard #rm -rf keyboards - yes | cp -rf ../qmk_firmware/keyboards . + #yes | cp -rf ../qmk_firmware/keyboards . #mkdir keyboards/ergodox_ez/ - cp ../qmk_firmware/util/ergodox_ez.html keyboards/ergodox_ez/index.html - cp ../qmk_firmware/readme.md qmk_readme.md - ./generate.sh + #cp ../qmk_firmware/util/ergodox_ez.html keyboards/ergodox_ez/index.html + #cp ../qmk_firmware/readme.md qmk_readme.md + #./generate.sh + rm -f _compiled/*.hex + for file in ../qmk_firmware/keyboards/*/keymaps/*/*.hex; do mv -v "$file" "_compiled/${file##*/}"; done git add -A git commit -m "generated from qmk/qmk_firmware@${rev}" -- cgit v1.2.3 From 71feac57175f5a3d09e96cc579f5d5c3477adb7b Mon Sep 17 00:00:00 2001 From: Jack Humbert Date: Sun, 28 May 2017 16:16:56 -0400 Subject: ignore docs, fix tag/hex pushing --- util/travis_compiled_push.sh | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'util/travis_compiled_push.sh') diff --git a/util/travis_compiled_push.sh b/util/travis_compiled_push.sh index 718daaa295..dcf408a2e9 100644 --- a/util/travis_compiled_push.sh +++ b/util/travis_compiled_push.sh @@ -7,6 +7,14 @@ rev=$(git rev-parse --short HEAD) git config --global user.name "Travis CI" git config --global user.email "jack.humb+travis.ci@gmail.com" +openssl aes-256-cbc -K $encrypted_b0ee987fd0fc_key -iv $encrypted_b0ee987fd0fc_iv -in util/qmk_firmware.enc -out qmk_firmware -d +openssl aes-256-cbc -K $encrypted_b0ee987fd0fc_key -iv $encrypted_b0ee987fd0fc_iv -in util/qmk.fm.enc -out qmk.fm -d +chmod 600 qmk_firmware +chmod 600 qmk.fm +eval `ssh-agent -s` +ssh-add qmk_firmware +ssh-add qmk.fm + if [[ "$TRAVIS_BRANCH" == "master" && "$TRAVIS_PULL_REQUEST" == "false" ]] ; then increment_version () @@ -17,14 +25,14 @@ increment_version () echo -e "${new// /.}" } -NEFM=$(git diff --name-only -n 1 ${TRAVIS_COMMIT_RANGE} | grep -Ev '^(keyboards/)' | wc -l) +NEFM=$(git diff --name-only -n 1 ${TRAVIS_COMMIT_RANGE} | grep -Ev '^(keyboards/)' | grep -Ev '^(docs/)' | wc -l) if [[ $NEFM -gt 0 ]] ; then echo "Essential files modified." git fetch --tags lasttag=$(git tag | grep -Ev '\-' | xargs -I@ git log --format=format:"%ai @%n" -1 @ | sort -V | awk '{print $4}' | tail -1) newtag=$(increment_version $lasttag) git tag $newtag - git push --tags -q https://$GH_TOKEN@github.com/qmk/qmk_firmware + git push --tags else echo "No essential files modified." fi @@ -34,7 +42,7 @@ if [[ "$TRAVIS_COMMIT_MESSAGE" != *"[skip build]"* ]] ; then make ergodox-ez AUTOGEN=true cd .. - git clone https://$GH_TOKEN@github.com/jackhumbert/qmk.fm.git + git clone git@github.com:qmk/qmk.fm.git cd qmk.fm #git submodule update --init --recursive #rm -rf keyboard -- cgit v1.2.3 From ae6b803ad61d647febbfe806d795b8b757fce074 Mon Sep 17 00:00:00 2001 From: Jack Humbert Date: Mon, 29 May 2017 10:54:46 -0400 Subject: more than one en-file, and actually ignore docs --- util/travis_compiled_push.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'util/travis_compiled_push.sh') diff --git a/util/travis_compiled_push.sh b/util/travis_compiled_push.sh index dcf408a2e9..a5bbe70ece 100644 --- a/util/travis_compiled_push.sh +++ b/util/travis_compiled_push.sh @@ -7,12 +7,10 @@ rev=$(git rev-parse --short HEAD) git config --global user.name "Travis CI" git config --global user.email "jack.humb+travis.ci@gmail.com" -openssl aes-256-cbc -K $encrypted_b0ee987fd0fc_key -iv $encrypted_b0ee987fd0fc_iv -in util/qmk_firmware.enc -out qmk_firmware -d -openssl aes-256-cbc -K $encrypted_b0ee987fd0fc_key -iv $encrypted_b0ee987fd0fc_iv -in util/qmk.fm.enc -out qmk.fm -d -chmod 600 qmk_firmware +chmod 600 id_rsa_qmk_firmware chmod 600 qmk.fm eval `ssh-agent -s` -ssh-add qmk_firmware +ssh-add id_rsa_qmk_firmware ssh-add qmk.fm if [[ "$TRAVIS_BRANCH" == "master" && "$TRAVIS_PULL_REQUEST" == "false" ]] ; then -- cgit v1.2.3 From 44832127d72e66e422a40e2bebc27e14236807c3 Mon Sep 17 00:00:00 2001 From: Jack Humbert Date: Mon, 29 May 2017 12:14:49 -0400 Subject: push to git url --- util/travis_compiled_push.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'util/travis_compiled_push.sh') diff --git a/util/travis_compiled_push.sh b/util/travis_compiled_push.sh index a5bbe70ece..a2fc2b1941 100644 --- a/util/travis_compiled_push.sh +++ b/util/travis_compiled_push.sh @@ -30,7 +30,7 @@ if [[ $NEFM -gt 0 ]] ; then lasttag=$(git tag | grep -Ev '\-' | xargs -I@ git log --format=format:"%ai @%n" -1 @ | sort -V | awk '{print $4}' | tail -1) newtag=$(increment_version $lasttag) git tag $newtag - git push --tags + git push --tags git@github.com:qmk/qmk_firmware.git else echo "No essential files modified." fi @@ -55,7 +55,7 @@ if [[ "$TRAVIS_COMMIT_MESSAGE" != *"[skip build]"* ]] ; then git add -A git commit -m "generated from qmk/qmk_firmware@${rev}" - git push + git push git@github.com:qmk/qmk.fm.git master fi -- cgit v1.2.3 From 0c351fa98bff6a2e9d3ff30cc19d6b0782b85a62 Mon Sep 17 00:00:00 2001 From: Jack Humbert Date: Mon, 29 May 2017 12:49:25 -0400 Subject: no master needed on push maybe --- util/travis_compiled_push.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'util/travis_compiled_push.sh') diff --git a/util/travis_compiled_push.sh b/util/travis_compiled_push.sh index a2fc2b1941..853795369f 100644 --- a/util/travis_compiled_push.sh +++ b/util/travis_compiled_push.sh @@ -55,7 +55,7 @@ if [[ "$TRAVIS_COMMIT_MESSAGE" != *"[skip build]"* ]] ; then git add -A git commit -m "generated from qmk/qmk_firmware@${rev}" - git push git@github.com:qmk/qmk.fm.git master + git push git@github.com:qmk/qmk.fm.git fi -- cgit v1.2.3 From 7eccbfe73764dbac0c33065394a8b86c4952eabf Mon Sep 17 00:00:00 2001 From: Jack Humbert Date: Tue, 30 May 2017 11:46:25 -0400 Subject: exclude PRs --- util/travis_compiled_push.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'util/travis_compiled_push.sh') diff --git a/util/travis_compiled_push.sh b/util/travis_compiled_push.sh index 853795369f..2f5f74f93e 100644 --- a/util/travis_compiled_push.sh +++ b/util/travis_compiled_push.sh @@ -4,16 +4,18 @@ set -o errexit -o nounset rev=$(git rev-parse --short HEAD) +if [[ "$TRAVIS_BRANCH" == "master" && "$TRAVIS_PULL_REQUEST" == "false" ]] ; then + git config --global user.name "Travis CI" git config --global user.email "jack.humb+travis.ci@gmail.com" +openssl aes-256-cbc -K $encrypted_b0ee987fd0fc_key -iv $encrypted_b0ee987fd0fc_iv -in secrets.tar.enc -out secrets.tar -d +tar xvf secrets.tar + chmod 600 id_rsa_qmk_firmware chmod 600 qmk.fm eval `ssh-agent -s` ssh-add id_rsa_qmk_firmware -ssh-add qmk.fm - -if [[ "$TRAVIS_BRANCH" == "master" && "$TRAVIS_PULL_REQUEST" == "false" ]] ; then increment_version () { @@ -42,6 +44,7 @@ if [[ "$TRAVIS_COMMIT_MESSAGE" != *"[skip build]"* ]] ; then cd .. git clone git@github.com:qmk/qmk.fm.git cd qmk.fm + ssh-add ../qmk_firmware/qmk.fm #git submodule update --init --recursive #rm -rf keyboard #rm -rf keyboards -- cgit v1.2.3 From 9ecfc2329295b572bc4c5a6f4569f6d0fc2840aa Mon Sep 17 00:00:00 2001 From: Jack Humbert Date: Tue, 30 May 2017 12:49:26 -0400 Subject: make qmk bot do the hard work --- util/travis_compiled_push.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'util/travis_compiled_push.sh') diff --git a/util/travis_compiled_push.sh b/util/travis_compiled_push.sh index 2f5f74f93e..4e08be1206 100644 --- a/util/travis_compiled_push.sh +++ b/util/travis_compiled_push.sh @@ -6,8 +6,8 @@ rev=$(git rev-parse --short HEAD) if [[ "$TRAVIS_BRANCH" == "master" && "$TRAVIS_PULL_REQUEST" == "false" ]] ; then -git config --global user.name "Travis CI" -git config --global user.email "jack.humb+travis.ci@gmail.com" +git config --global user.name "QMK Bot" +git config --global user.email "hello@qmk.fm" openssl aes-256-cbc -K $encrypted_b0ee987fd0fc_key -iv $encrypted_b0ee987fd0fc_iv -in secrets.tar.enc -out secrets.tar -d tar xvf secrets.tar -- cgit v1.2.3