Skip to content

Commit

Permalink
Merge pull request #258 from fraz3alpha/tidy-up-bundling-process
Browse files Browse the repository at this point in the history
Tidy up bundling process
  • Loading branch information
fraz3alpha authored Feb 16, 2020
2 parents 2823fc7 + f76c12f commit f5306e8
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,17 @@ before_install:
- gem install bundler

script:
# Run the tests against the Javascript libraries we have writte
- bash -c "cd ./browser-extensions/common/js && npm run test-with-coverage"
# Only build the staging website if the github token is available, which means
# that it will only happen for PRs from our own repo, not forks.
- 'if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then if [ "$RUNNING_CHALLENGES_GITHUB_TOKEN" != "" ]; then bash ./build/website/build-staging.sh; fi; fi'
- 'if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then bash ./build/website/build.sh; fi'
- './build/extension-chrome/build.sh'
- './build/extension-firefox/build.sh'
# Moving the test until after the build to start with, so that I can defer having to work out how
# not to bundle the coverage data into the extension zip files.
# Perhaps we should actually be testing the bundled code, rather than that in the repo, not sure.
# Run the tests against the Javascript libraries we have written
- bash -c "cd ./browser-extensions/common/js && npm run test-with-coverage"

# branch whitelist.
# For GitHub Pages - if we push code to master the built code goes to gh-pages
Expand Down
3 changes: 3 additions & 0 deletions build/extension-chrome/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,6 @@ cd ${TMP_BUILD_DIR}
# zip -r extension.zip js/ html/ images/ css/ manifest.json
web-ext lint
web-ext build

# Print the size of the built extension
ls -l web-ext-artifacts/running_challenges-*.zip
3 changes: 3 additions & 0 deletions build/extension-firefox/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,6 @@ for i in patches/firefox/*.patch; do patch -p0 --directory "${TMP_BUILD_DIR}" <
cd ${TMP_BUILD_DIR}
web-ext lint
web-ext build

# Print the size of the built extension
ls -l web-ext-artifacts/running_challenges-*.zip

0 comments on commit f5306e8

Please sign in to comment.