diff --git a/index.js b/index.js index 5f1ec8d..03065eb 100644 --- a/index.js +++ b/index.js @@ -1,4 +1,5 @@ const core = require("@actions/core"); +const exec = require("@actions/exec") const fs = require("fs"); const github = require("@actions/github"); const io = require("@actions/io"); @@ -163,6 +164,13 @@ async function run() { } catch (e) { core.setFailed(e.message); } + + // Run Nextflow so it downloads its dependencies + try { + const nf_exit_code = await exec.exec("nextflow", ["help"]) + } catch (e) { + core.warning("Nextflow appears to have installed correctly, but an error was thrown while running it.") + } } run(); diff --git a/package-lock.json b/package-lock.json index faf89ee..1dcc0e5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,6 +10,7 @@ "license": "ISC", "dependencies": { "@actions/core": "^1.8.2", + "@actions/exec": "^1.1.1", "@actions/github": "^5.0.3", "@actions/tool-cache": "^2.0.1", "async-retry": "^1.3.3", diff --git a/package.json b/package.json index 8686df6..b242a84 100644 --- a/package.json +++ b/package.json @@ -11,6 +11,7 @@ "license": "ISC", "dependencies": { "@actions/core": "^1.8.2", + "@actions/exec": "^1.1.1", "@actions/github": "^5.0.3", "@actions/tool-cache": "^2.0.1", "async-retry": "^1.3.3",