From 181646f61d8c89b8ca77981212f2d3dab374677c Mon Sep 17 00:00:00 2001 From: Shawn Cicoria Date: Mon, 14 May 2018 20:50:15 -0400 Subject: [PATCH 1/6] fix travis build --- .travis.yml | 46 +++++++++++++++++++++++++++++++--------------- package.json | 5 +---- 2 files changed, 32 insertions(+), 19 deletions(-) diff --git a/.travis.yml b/.travis.yml index b0ab1e58a..1f0696ed5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,20 +3,36 @@ node_js: - '9' - '8' - '7' - install: - - npm install - +- npm install deploy: - - provider: script - skip_cleanup: true - script: sh .travis/pu.sh - on: - branch: master - tags: false - - provider: npm - email: "liliankasem@gmail.com" - api_key: $NPM_TOKEN - on: - branch: master - tags: false +- provider: script + skip_cleanup: true + script: sh .travis/pu.sh + on: + branch: master + tags: false + node: 8 + repo: Azure-Samples/react-aad-msal +- provider: npm + email: github@cicoria.com + api_key: + secure: JGnaSdWwGa2Bh8kezygMsNz9vau3Z/T8SvgAtlnFZIu0mqBfZNjC0oJEM2FH26D73Nj4kb6BOSmZ3blhNeQCZw/KfNimwd4hDJY/bUPyxQNtsejU+wdronuxBL7DFiCBT9GV1clBZNrwWe2R+4w2zLRp48/F7BLBd++4VLy/nVvthBFPuR78g/Il35GYBgwN/BTy1hP4ToY8v5ZeTfpFytZ/QhPjOLTp6QIL8eRcxH0uX7+ivYmG43/vocx3uknMhv637Z5kIU/LtCrRmlnIWUdLC8TfX/R0itP2ZkffrXDSqk5mFlu3DjAG+Nmfx86iKKrniiXePrmXX8V50gSb0BDUXJ/tDdfJtIxfyNXtxZuQjt/dDS4cEsALrHNEbTDfjILBYN1BhOM5H5pks2/7qHhNtu00QkV1CRXbgnxOSiQe86IasYsupJsuUPdEpQFXKZ4EpLWj0I06MIb7xTqZQPDuwq9jtObBtG/qlCDXB0j4amSXMAdVMAoG/IIl3sl+IfHDqcFDNpA7l1e//jhvPt1DqHOalCd+7NsVrFfOmijNKyOBgRThXTCLblFk1yhUBYF9WjW/JnaiuHAqB96fUcwRoNa0pMeuzDdaIdABxuRDc5FHqSQQQzR43h2pPMRrhRtJmcQLO08s/YZKq9o4L8ceNUYtph79v78T7MyfxJo= + on: + branch: master + tags: false + node: 8 + repo: Azure-Samples/react-aad-msal +- provider: releases + api_key: + secure: o2qIYtsYuo5r8M/gkU9teD45/cp7uc9SP6sdmSKZlbxeh7gpv8q42QYNebBNaELBXepa2H+oCq3yh4GlhJbQ1glj+n+Ccr6fUosaPE9M0aJ3ECjI6twgX+As2g30Xj0UIiysORD8zGCKAuSecPkydE+/a/GXtA3TxReeDWVmPVrLnkx//sP00+S/hdRK8ocbARFRBU3VKltC6vs+zuBK8ggX8Ab71uBSiuceGdvgWEjy18zTeiJ2a2Ws9geSRgJjA1cW1tFhygIDfuePHkX9q0jvo9e7oxyMFX2iXSBfoyrT/AiuppzyG8IJZA/O1eLnhHWxRzRkQ7kJ4E90c2gRGOmo2CSqeUgv3eRuv183aWfPj0UvgqG/6lRUGF1QCyDU6yn/99T3XE8Uc7DkJGiFsUL/g1nP2FMqRRpkQLRsQFcdNxf8nO/ZzMXBI67Kryzm7clSg7qzQ8mz9xbqtvVAeflvDiGXnC5yMg1W/Ri40X/NsntSSLAn38MTs7qMpYVfnZrIiWm7jFRIkM023l9hLu5kOPWQQxoZTk6wZWbZkw3Q7yExmcTfA2LLJYqzSrQGRj8zO7RcqsSLGwOslr8a25d7mSIoUHZWMef0b1VNq9r5xEWhBJeA1V/zwRMWMuPzSomdG0A7oQEVvipayboeKQ8iPskJrvXG6YNqT2apfwo= + file_glob: true + file: dist/* + on: + branch: master + tags: false + node: 8 + repo: Azure-Samples/react-aad-msal +env: + global: + secure: TljZCsFri7z/qySGC6p0JAoiLG/0IfAfwao1KxSKKblgUl6Q7yTGxet+W+6XPorMPRqZNlKtUqPKTZoWtRj7jJykjJXqqMF2SywuJq0+ldYPGWDA47cmpQcZ0tRCnrar+Fd+Ti5eItYbzaK7Wiy3eQWQYm5//9aOzTJe0gqImEV17lxmpcf/YlUSZE7YZbMu9Xxe6JqY7EQ6g3mWB7LXdgIRoMT6bbHneTsmBQDJjbMhH9yGpNY9aMN0mrN7m7uBLtBATzvJWUM3nNbokje5VxwJEr7Q13QeTIBUPOPJkGPlS1rcN3Fl86z4IyXZC+uVfeP0fBZFMpAbcgNceeHv3hnwnmx8ysPO00Js2ln/5jfVLuAqKfPjJ3Vdhvsz5mYgPyvi03v19+IM5SVvWT/Y8do1btdICkF+s0erMh1MWGwP94CI4DSJaM+lbKEJSO6oPZMubzTyZkDgu54plC/Y4gyVNKRetK1mkJ7lMwkHsZz/oLjqWFgc2QKe/H2o5ypaIqQm7zH5qWjtn5nGt3+9D9Xc6+OrK/scWTWpgnoOM33Bh/K4BP/sO3imcx9Lqs98ENSQJdhsBHno6MyBjPbVy4GPShhcYAh7Q4cyeH5lV4k0kDnuDo8Y/0gGxOK5QR1s+7uRHHWA9NCHwrUJiXygIrPFGFEWMUtAmx1kY+BOcDg= diff --git a/package.json b/package.json index fd21f9b47..3953186fc 100644 --- a/package.json +++ b/package.json @@ -85,10 +85,7 @@ "start-dev": "npm install && npm run build-dev && npm --prefix ./sample run start", "build": "npm run lint && tsc", "build-dev": "tsc", - "test": "node scripts/test.js --env=jsdom", - "prepublishOnly": "npm install && npm run build", - "version": "npm run build && git add .", - "postversion": "git push && git push --tags" + "test": "node scripts/test.js --env=jsdom" }, "devDependencies": { "@types/jest": "^22.2.3", From 335a90c56f24a7b7f2a0dafdf262eaee4a94827e Mon Sep 17 00:00:00 2001 From: Shawn Cicoria Date: Mon, 14 May 2018 21:11:49 -0400 Subject: [PATCH 2/6] 0.3.8 --- package-lock.json | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package-lock.json b/package-lock.json index a6face23a..7ecb91735 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "react-aad-msal", - "version": "0.3.7", + "version": "0.3.8", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 3953186fc..4b42fb50a 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-aad-msal", - "version": "0.3.7", + "version": "0.3.8", "description": "A react component that integrates with Azure AD (v2, MSAL).", "private": false, "license": "MIT", From e955ac25b2bbdba611cd7b271b7b5672460d26d3 Mon Sep 17 00:00:00 2001 From: Shawn Cicoria Date: Mon, 14 May 2018 21:11:54 -0400 Subject: [PATCH 3/6] 0.3.9 --- package-lock.json | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package-lock.json b/package-lock.json index 7ecb91735..0efc46055 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "react-aad-msal", - "version": "0.3.8", + "version": "0.3.9", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 4b42fb50a..23113908c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-aad-msal", - "version": "0.3.8", + "version": "0.3.9", "description": "A react component that integrates with Azure AD (v2, MSAL).", "private": false, "license": "MIT", From 599279ea64eb73b9bf4162bb78d2dcb653098853 Mon Sep 17 00:00:00 2001 From: Shawn Cicoria Date: Tue, 15 May 2018 09:35:53 -0400 Subject: [PATCH 4/6] update script and travis build --- .travis.yml | 60 +++++++++++++++++++++++++-------------------------- .travis/pu.sh | 12 ++++++----- package.json | 2 +- 3 files changed, 37 insertions(+), 37 deletions(-) diff --git a/.travis.yml b/.travis.yml index 1f0696ed5..ead00f711 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,38 +1,36 @@ language: node_js node_js: -- '9' -- '8' -- '7' + - '9' + - '8' + - '7' install: -- npm install + - npm install deploy: -- provider: script - skip_cleanup: true - script: sh .travis/pu.sh - on: - branch: master - tags: false - node: 8 - repo: Azure-Samples/react-aad-msal -- provider: npm - email: github@cicoria.com - api_key: - secure: JGnaSdWwGa2Bh8kezygMsNz9vau3Z/T8SvgAtlnFZIu0mqBfZNjC0oJEM2FH26D73Nj4kb6BOSmZ3blhNeQCZw/KfNimwd4hDJY/bUPyxQNtsejU+wdronuxBL7DFiCBT9GV1clBZNrwWe2R+4w2zLRp48/F7BLBd++4VLy/nVvthBFPuR78g/Il35GYBgwN/BTy1hP4ToY8v5ZeTfpFytZ/QhPjOLTp6QIL8eRcxH0uX7+ivYmG43/vocx3uknMhv637Z5kIU/LtCrRmlnIWUdLC8TfX/R0itP2ZkffrXDSqk5mFlu3DjAG+Nmfx86iKKrniiXePrmXX8V50gSb0BDUXJ/tDdfJtIxfyNXtxZuQjt/dDS4cEsALrHNEbTDfjILBYN1BhOM5H5pks2/7qHhNtu00QkV1CRXbgnxOSiQe86IasYsupJsuUPdEpQFXKZ4EpLWj0I06MIb7xTqZQPDuwq9jtObBtG/qlCDXB0j4amSXMAdVMAoG/IIl3sl+IfHDqcFDNpA7l1e//jhvPt1DqHOalCd+7NsVrFfOmijNKyOBgRThXTCLblFk1yhUBYF9WjW/JnaiuHAqB96fUcwRoNa0pMeuzDdaIdABxuRDc5FHqSQQQzR43h2pPMRrhRtJmcQLO08s/YZKq9o4L8ceNUYtph79v78T7MyfxJo= - on: - branch: master - tags: false - node: 8 - repo: Azure-Samples/react-aad-msal -- provider: releases - api_key: - secure: o2qIYtsYuo5r8M/gkU9teD45/cp7uc9SP6sdmSKZlbxeh7gpv8q42QYNebBNaELBXepa2H+oCq3yh4GlhJbQ1glj+n+Ccr6fUosaPE9M0aJ3ECjI6twgX+As2g30Xj0UIiysORD8zGCKAuSecPkydE+/a/GXtA3TxReeDWVmPVrLnkx//sP00+S/hdRK8ocbARFRBU3VKltC6vs+zuBK8ggX8Ab71uBSiuceGdvgWEjy18zTeiJ2a2Ws9geSRgJjA1cW1tFhygIDfuePHkX9q0jvo9e7oxyMFX2iXSBfoyrT/AiuppzyG8IJZA/O1eLnhHWxRzRkQ7kJ4E90c2gRGOmo2CSqeUgv3eRuv183aWfPj0UvgqG/6lRUGF1QCyDU6yn/99T3XE8Uc7DkJGiFsUL/g1nP2FMqRRpkQLRsQFcdNxf8nO/ZzMXBI67Kryzm7clSg7qzQ8mz9xbqtvVAeflvDiGXnC5yMg1W/Ri40X/NsntSSLAn38MTs7qMpYVfnZrIiWm7jFRIkM023l9hLu5kOPWQQxoZTk6wZWbZkw3Q7yExmcTfA2LLJYqzSrQGRj8zO7RcqsSLGwOslr8a25d7mSIoUHZWMef0b1VNq9r5xEWhBJeA1V/zwRMWMuPzSomdG0A7oQEVvipayboeKQ8iPskJrvXG6YNqT2apfwo= - file_glob: true - file: dist/* - on: - branch: master - tags: false - node: 8 - repo: Azure-Samples/react-aad-msal + - provider: script + skip_cleanup: true + script: sh .travis/pu.sh + on: + tags: false + node: 8 + repo: Azure-Samples/react-aad-msal + # - provider: npm + # email: github@cicoria.com + # api_key: + # secure: JGnaSdWwGa2Bh8kezygMsNz9vau3Z/T8SvgAtlnFZIu0mqBfZNjC0oJEM2FH26D73Nj4kb6BOSmZ3blhNeQCZw/KfNimwd4hDJY/bUPyxQNtsejU+wdronuxBL7DFiCBT9GV1clBZNrwWe2R+4w2zLRp48/F7BLBd++4VLy/nVvthBFPuR78g/Il35GYBgwN/BTy1hP4ToY8v5ZeTfpFytZ/QhPjOLTp6QIL8eRcxH0uX7+ivYmG43/vocx3uknMhv637Z5kIU/LtCrRmlnIWUdLC8TfX/R0itP2ZkffrXDSqk5mFlu3DjAG+Nmfx86iKKrniiXePrmXX8V50gSb0BDUXJ/tDdfJtIxfyNXtxZuQjt/dDS4cEsALrHNEbTDfjILBYN1BhOM5H5pks2/7qHhNtu00QkV1CRXbgnxOSiQe86IasYsupJsuUPdEpQFXKZ4EpLWj0I06MIb7xTqZQPDuwq9jtObBtG/qlCDXB0j4amSXMAdVMAoG/IIl3sl+IfHDqcFDNpA7l1e//jhvPt1DqHOalCd+7NsVrFfOmijNKyOBgRThXTCLblFk1yhUBYF9WjW/JnaiuHAqB96fUcwRoNa0pMeuzDdaIdABxuRDc5FHqSQQQzR43h2pPMRrhRtJmcQLO08s/YZKq9o4L8ceNUYtph79v78T7MyfxJo= + # on: + # branch: master + # tags: false + # node: 8 + # repo: Azure-Samples/react-aad-msal + - provider: releases + api_key: + secure: o2qIYtsYuo5r8M/gkU9teD45/cp7uc9SP6sdmSKZlbxeh7gpv8q42QYNebBNaELBXepa2H+oCq3yh4GlhJbQ1glj+n+Ccr6fUosaPE9M0aJ3ECjI6twgX+As2g30Xj0UIiysORD8zGCKAuSecPkydE+/a/GXtA3TxReeDWVmPVrLnkx//sP00+S/hdRK8ocbARFRBU3VKltC6vs+zuBK8ggX8Ab71uBSiuceGdvgWEjy18zTeiJ2a2Ws9geSRgJjA1cW1tFhygIDfuePHkX9q0jvo9e7oxyMFX2iXSBfoyrT/AiuppzyG8IJZA/O1eLnhHWxRzRkQ7kJ4E90c2gRGOmo2CSqeUgv3eRuv183aWfPj0UvgqG/6lRUGF1QCyDU6yn/99T3XE8Uc7DkJGiFsUL/g1nP2FMqRRpkQLRsQFcdNxf8nO/ZzMXBI67Kryzm7clSg7qzQ8mz9xbqtvVAeflvDiGXnC5yMg1W/Ri40X/NsntSSLAn38MTs7qMpYVfnZrIiWm7jFRIkM023l9hLu5kOPWQQxoZTk6wZWbZkw3Q7yExmcTfA2LLJYqzSrQGRj8zO7RcqsSLGwOslr8a25d7mSIoUHZWMef0b1VNq9r5xEWhBJeA1V/zwRMWMuPzSomdG0A7oQEVvipayboeKQ8iPskJrvXG6YNqT2apfwo= + file_glob: true + file: dist/* + on: + tags: true + node: 8 + repo: Azure-Samples/react-aad-msal env: global: secure: TljZCsFri7z/qySGC6p0JAoiLG/0IfAfwao1KxSKKblgUl6Q7yTGxet+W+6XPorMPRqZNlKtUqPKTZoWtRj7jJykjJXqqMF2SywuJq0+ldYPGWDA47cmpQcZ0tRCnrar+Fd+Ti5eItYbzaK7Wiy3eQWQYm5//9aOzTJe0gqImEV17lxmpcf/YlUSZE7YZbMu9Xxe6JqY7EQ6g3mWB7LXdgIRoMT6bbHneTsmBQDJjbMhH9yGpNY9aMN0mrN7m7uBLtBATzvJWUM3nNbokje5VxwJEr7Q13QeTIBUPOPJkGPlS1rcN3Fl86z4IyXZC+uVfeP0fBZFMpAbcgNceeHv3hnwnmx8ysPO00Js2ln/5jfVLuAqKfPjJ3Vdhvsz5mYgPyvi03v19+IM5SVvWT/Y8do1btdICkF+s0erMh1MWGwP94CI4DSJaM+lbKEJSO6oPZMubzTyZkDgu54plC/Y4gyVNKRetK1mkJ7lMwkHsZz/oLjqWFgc2QKe/H2o5ypaIqQm7zH5qWjtn5nGt3+9D9Xc6+OrK/scWTWpgnoOM33Bh/K4BP/sO3imcx9Lqs98ENSQJdhsBHno6MyBjPbVy4GPShhcYAh7Q4cyeH5lV4k0kDnuDo8Y/0gGxOK5QR1s+7uRHHWA9NCHwrUJiXygIrPFGFEWMUtAmx1kY+BOcDg= diff --git a/.travis/pu.sh b/.travis/pu.sh index 0fe8d4a69..82b0feecd 100644 --- a/.travis/pu.sh +++ b/.travis/pu.sh @@ -6,8 +6,8 @@ setup_git() { # Set the user name and email to match the API token holder # This will make sure the git commits will have the correct photo # and the user gets the credit for a checkin - git config --global user.email "liliankasem@gmail.com" - git config --global user.name "liliankasem" + git config --global user.email "github@cicoria.com" + git config --global user.name "Mr.Robot" git config --global push.default matching # Get the credentials from a file @@ -34,12 +34,14 @@ make_version() { upload_files() { # This make sure the current work area is pushed to the tip of the current branch - git push origin HEAD:$TRAVIS_BRANCH + # git push origin HEAD:$TRAVIS_BRANCH # This pushes the new tag - git push --tags + git push --tags --dry-run } - +echo "####### the env is..." +env +echo "####### end env" setup_git make_version upload_files \ No newline at end of file diff --git a/package.json b/package.json index 23113908c..db7521e64 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-aad-msal", - "version": "0.3.9", + "version": "0.3.13", "description": "A react component that integrates with Azure AD (v2, MSAL).", "private": false, "license": "MIT", From ea2f8df2bb1539ec2a3a2099f482460be95d6ff5 Mon Sep 17 00:00:00 2001 From: Shawn Cicoria Date: Tue, 15 May 2018 10:10:45 -0400 Subject: [PATCH 5/6] try travis update --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index ead00f711..4d75d5bb2 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,6 +6,8 @@ node_js: install: - npm install deploy: + - provider: script + script: sh echo "### this is the env "; env | sort - provider: script skip_cleanup: true script: sh .travis/pu.sh From df1f6664eb810601f1597243143692d54e65e591 Mon Sep 17 00:00:00 2001 From: Shawn Cicoria Date: Tue, 15 May 2018 11:09:32 -0400 Subject: [PATCH 6/6] fixing build when push vs pr --- .travis.yml | 4 ++-- .travis/pu.sh | 16 ++++++++++++++-- package.json | 2 +- 3 files changed, 17 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 4d75d5bb2..17ad618b0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,14 +7,14 @@ install: - npm install deploy: - provider: script - script: sh echo "### this is the env "; env | sort + script: env | sort - provider: script skip_cleanup: true script: sh .travis/pu.sh on: tags: false node: 8 - repo: Azure-Samples/react-aad-msal + repo: Azure-Samples/react-aad-msal" # - provider: npm # email: github@cicoria.com # api_key: diff --git a/.travis/pu.sh b/.travis/pu.sh index 82b0feecd..72cdb8d47 100644 --- a/.travis/pu.sh +++ b/.travis/pu.sh @@ -39,9 +39,21 @@ upload_files() { # This pushes the new tag git push --tags --dry-run } + +check_release() { + if [ "${TRAVIS_PULL_REQUEST}" != "false" ]; then + echo "this IS a PR to deploy" + echo "script will continue..." + else + echo "this is NOT a PR" + exit(0) + fi +} + echo "####### the env is..." -env +env | sort | grep TRAVIS echo "####### end env" +check_release setup_git make_version -upload_files \ No newline at end of file +upload_files diff --git a/package.json b/package.json index db7521e64..0764f3a03 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-aad-msal", - "version": "0.3.13", + "version": "0.3.15", "description": "A react component that integrates with Azure AD (v2, MSAL).", "private": false, "license": "MIT",