()
| 4 | import { optionalInt, optionalProtocol, optionalString, optionalBoolean, optionalStringArray, optionalLogLevel, optionalSecurity } from "./parse"; |
| 5 | |
| 6 | async function runDeployment() { |
| 7 | try { |
| 8 | const args: IFtpDeployArguments = { |
| 9 | server: core.getInput("server", { required: true }), |
| 10 | username: core.getInput("username", { required: true }), |
| 11 | password: core.getInput("password", { required: true }), |
| 12 | port: optionalInt("port", core.getInput("port")), |
| 13 | protocol: optionalProtocol("protocol", core.getInput("protocol")), |
| 14 | "local-dir": optionalString(core.getInput("local-dir")), |
| 15 | "server-dir": optionalString(core.getInput("server-dir")), |
| 16 | "state-name": optionalString(core.getInput("state-name")), |
| 17 | "dry-run": optionalBoolean("dry-run", core.getInput("dry-run")), |
| 18 | "dangerous-clean-slate": optionalBoolean("dangerous-clean-slate", core.getInput("dangerous-clean-slate")), |
| 19 | "exclude": optionalStringArray("exclude", core.getMultilineInput("exclude")), |
| 20 | "log-level": optionalLogLevel("log-level", core.getInput("log-level")), |
| 21 | "security": optionalSecurity("security", core.getInput("security")), |
| 22 | "timeout": optionalInt("timeout", core.getInput("timeout")) |
| 23 | }; |
| 24 | |
| 25 | await deploy(args); |
| 26 | } |
| 27 | catch (error: any) { |
| 28 | core.setFailed(error); |
| 29 | } |
| 30 | } |
| 31 | |
| 32 | runDeployment(); |
no test coverage detected