mirror of
https://github.com/actions/setup-java.git
synced 2025-04-20 01:46:46 +00:00
Features/installer (#1)
* Initial attempt * Clean up * Extract right directory * Log whats happening * Read correct directory * Full path * Allow java to be found in cache * Add tests
This commit is contained in:
parent
62b9fcdfde
commit
46ca045b4e
6 changed files with 407 additions and 7 deletions
|
@ -16,10 +16,18 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|||
};
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const core = __importStar(require("@actions/core"));
|
||||
const installer = __importStar(require("./installer"));
|
||||
function run() {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
const myInput = core.getInput('myInput');
|
||||
core.debug(`Hello ${myInput}`);
|
||||
try {
|
||||
const version = core.getInput('version', { required: true });
|
||||
const arch = core.getInput('architecture', { required: true });
|
||||
const jdkFile = core.getInput('jdkFile', { required: true });
|
||||
yield installer.getJava(version, arch, jdkFile);
|
||||
}
|
||||
catch (error) {
|
||||
core.setFailed(error.message);
|
||||
}
|
||||
});
|
||||
}
|
||||
run();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue