mirror of
https://github.com/peaceiris/actions-hugo.git
synced 2025-06-07 09:35:28 +08:00
Replaced bool values with strings (#2)
This commit is contained in:
parent
a11750b1de
commit
9182f4160b
@ -1,13 +1,13 @@
|
|||||||
export default function getURL(
|
export default function getURL(
|
||||||
os: string,
|
os: string,
|
||||||
arch: string,
|
arch: string,
|
||||||
extended: boolean,
|
extended: string,
|
||||||
withdeploy: boolean,
|
withdeploy: string,
|
||||||
version: string
|
version: string
|
||||||
): string {
|
): string {
|
||||||
|
|
||||||
const extendedStr = (extended: boolean): string => {
|
const extendedStr = (extended: string): string => {
|
||||||
if (extended) {
|
if (extended === 'true') {
|
||||||
return 'extended_';
|
return 'extended_';
|
||||||
} else {
|
} else {
|
||||||
return '';
|
return '';
|
||||||
@ -16,8 +16,8 @@ export default function getURL(
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const deployStr = (deploy: boolean): string => {
|
const deployStr = (deploy: string): string => {
|
||||||
if (deploy) {
|
if (deploy === 'true') {
|
||||||
return 'withdeploy_';
|
return 'withdeploy_';
|
||||||
} else {
|
} else {
|
||||||
return '';
|
return '';
|
||||||
|
@ -44,10 +44,10 @@ export async function createBinDir(workDir: string): Promise<string> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export async function installer(version: string): Promise<void> {
|
export async function installer(version: string): Promise<void> {
|
||||||
const extended: boolean = core.getInput('extended');
|
const extended: string = core.getInput('extended');
|
||||||
core.debug(`Hugo extended: ${extended}`);
|
core.debug(`Hugo extended: ${extended}`);
|
||||||
|
|
||||||
const withDeploy: boolean = core.getInput('withDeploy');
|
const withDeploy: string = core.getInput('withDeploy');
|
||||||
core.debug(`Hugo withDeploy: ${withDeploy}`);
|
core.debug(`Hugo withDeploy: ${withDeploy}`);
|
||||||
|
|
||||||
const osName: string = getOS(process.platform);
|
const osName: string = getOS(process.platform);
|
||||||
|
Loading…
Reference in New Issue
Block a user