Skip to content

Commit

Permalink
feat: support jdk 8-12 during build
Browse files Browse the repository at this point in the history
  • Loading branch information
sfat committed Aug 21, 2019
1 parent aa46958 commit d691032
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 10 deletions.
54 changes: 46 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,65 @@ notifications:
email: false
language: node_js
node_js:
- "10"
- "8"
- "6"

cache:
directories:
- node_modules

before_install:
# Install a later version of sbt-extras to support SBT >=1.0
- curl -Ls https://git.io/sbt > ~/bin/sbt
- chmod a+x ~/bin/sbt
# install jdk is needed for JDK10+
- wget https://github.com/sormuras/bach/raw/master/install-jdk.sh

script:
- npm test
- npm run test-system
jobs:
include:
- stage: Node versions
node_js: 6
env: JDK=9
script:
- source install-jdk.sh --feature $JDK
- ln -sf /etc/ssl/certs/java/cacerts $JAVA_HOME/lib/security/cacerts
- java -version
- npm test
- npm run test-system
-
node_js: 8
env: JDK=10
script:
- source install-jdk.sh --feature $JDK
- ln -sf /etc/ssl/certs/java/cacerts $JAVA_HOME/lib/security/cacerts
- java -version
- npm test
- npm run test-system
-
node_js: 10
env: JDK=11
script:
- source install-jdk.sh --feature $JDK
- ln -sf /etc/ssl/certs/java/cacerts $JAVA_HOME/lib/security/cacerts
- npm test
- npm run test-system
- stage: Old and newer Java versions
env: JDK=8
script:
- jdk_switcher use openjdk8
- java -version
- npm test
- npm run test-system
-
env: JDK=12
script:
- source install-jdk.sh --feature $JDK
- ln -sf /etc/ssl/certs/java/cacerts $JAVA_HOME/lib/security/cacerts
- java -version
- npm test
- npm run test-system
- stage: npm release
if: branch = master
node_js: "8" # This *has* to be the "build leader"
script: skip
after_success:
- npx semantic-release
branches:
only:
- master
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,9 @@ Snyk helps you find, fix and monitor for known vulnerabilities in your dependenc
## Snyk SBT CLI Plugin

This plugin provides dependency metadata for SBT projects that use `sbt` and have a `build.sbt` file.

## Compability

`snyk-sbt-plugin` has been tested against jdk 8-12.

`jdk13` is not currently supported (See this [comment](https://github.com/snyk/snyk-sbt-plugin/pull/61#issuecomment-521356342) for more details)
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
"prepare": "npm run build",
"test": "npm run lint && npm run build && npm run test-functional",
"test-functional": "tap -Rspec ./test/functional/*.test.[tj]s",
"test-system": "tap -Rspec --timeout=600 ./test/system/*.test.[tj]s",
"test-system-windows": "tap -Rspec --timeout=600 ./test/system-windows/*.test.[tj]s"
"test-system": "tap -Rspec --timeout=700 ./test/system/*.test.[tj]s",
"test-system-windows": "tap -Rspec --timeout=700 ./test/system-windows/*.test.[tj]s"
},
"author": "snyk.io",
"license": "Apache-2.0",
Expand Down

0 comments on commit d691032

Please sign in to comment.