-
-
Notifications
You must be signed in to change notification settings - Fork 228
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Added travis.yml * Adjust config * Add deployment * Build PR different than master branch * test new config * 1.0.1 * wip * Should hopefully work
- Loading branch information
1 parent
4d7e25f
commit 13f21eb
Showing
6 changed files
with
101 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
dist: trusty | ||
sudo: false | ||
|
||
language: node_js | ||
node_js: | ||
- "10" | ||
|
||
before_deploy: | ||
- git config --global user.email "[email protected]" | ||
- git config --global user.name "UnchartedBull" | ||
- git config --global push.default matching | ||
- git config credential.helper "store --file=.git/credentials" | ||
- echo "https://${GITHUB_API_KEY}:@github.com" > .git/credentials | ||
- mv $TRAVIS_BUILD_DIR/package/*armv7l.deb $TRAVIS_BUILD_DIR/OctoDash_$(git describe --tags $(git rev-list --tags --max-count=1))_armv7l.deb | ||
- mv $TRAVIS_BUILD_DIR/package/*arm64.deb $TRAVIS_BUILD_DIR/OctoDash_$(git describe --tags $(git rev-list --tags --max-count=1))_arm64.deb | ||
|
||
cache: | ||
directories: | ||
- ./node_modules | ||
|
||
install: | ||
- npm install | ||
|
||
jobs: | ||
include: | ||
- stage: lint | ||
name: "Linting Angular Application ..." | ||
script: ng lint | ||
- stage: build | ||
if: type = pull_request | ||
name: "Building Angular Application ..." | ||
script: npm run ng:build | ||
- stage: build | ||
if: type = push | ||
name: "Packaging Electron App ..." | ||
script: npm run pack | ||
- stage: deploy | ||
if: type = push | ||
name: "Deploying the GitHub Releases ..." | ||
deploy: | ||
provider: script | ||
skip_cleanup: true | ||
script: .travis/bump_version.sh | ||
on: | ||
branch: master | ||
tags: false | ||
deploy: | ||
provider: releases | ||
api_key: $GITHUB_TOKEN | ||
skip_cleanup: true | ||
draft: true | ||
file_glob: true | ||
file: | ||
- "OctoDash_*_armv7l.deb" | ||
- "OctoDash_*_arm64.deb" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#!/bin/sh | ||
|
||
make_version() { | ||
git checkout -- . | ||
git status | ||
COMMIT=$(git log -1 --pretty=%B) | ||
VERSION_BUMP="patch" | ||
if [[ $COMMIT == *"version:major"* ]]; then | ||
VERSION_BUMP="major" | ||
fi | ||
if [[ $COMMIT == *"version:minor"* ]]; then | ||
VERSION_BUMP="minor" | ||
fi | ||
echo "commit message: "$COMMIT | ||
echo "will execute npm version "$VERSION_BUMP | ||
npm version $VERSION_BUMP -m "bump version to %s [skip ci]" | ||
} | ||
|
||
upload_files() { | ||
git push origin HEAD:$TRAVIS_BRANCH | ||
git push --tags | ||
} | ||
|
||
make_version | ||
upload_files |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"extends": "./tsconfig.json", | ||
"compilerOptions": { | ||
"outDir": "./out-tsc/spec", | ||
"types": [ | ||
"jasmine", | ||
"node" | ||
] | ||
}, | ||
"files": [ | ||
"src/test.ts", | ||
"src/polyfills.ts" | ||
], | ||
"include": [ | ||
"src/**/*.spec.ts", | ||
"src/**/*.d.ts" | ||
] | ||
} |