2020-08-18 23:40:31 +08:00
|
|
|
import * as core from '@actions/core';
|
|
|
|
|
|
|
|
export const IsPost = !!process.env['STATE_isPost'];
|
2021-04-24 04:08:40 +08:00
|
|
|
export const IsDebug = !!process.env['STATE_isDebug'];
|
2020-08-18 23:40:31 +08:00
|
|
|
export const builderName = process.env['STATE_builderName'] || '';
|
2021-04-24 04:08:40 +08:00
|
|
|
export const containerName = process.env['STATE_containerName'] || '';
|
|
|
|
|
|
|
|
export function setDebug(debug: string) {
|
|
|
|
core.saveState('isDebug', debug);
|
|
|
|
}
|
2020-08-18 23:40:31 +08:00
|
|
|
|
|
|
|
export function setBuilderName(builderName: string) {
|
|
|
|
core.saveState('builderName', builderName);
|
|
|
|
}
|
|
|
|
|
2021-04-24 04:08:40 +08:00
|
|
|
export function setContainerName(containerName: string) {
|
|
|
|
core.saveState('containerName', containerName);
|
|
|
|
}
|
|
|
|
|
2020-08-18 23:40:31 +08:00
|
|
|
if (!IsPost) {
|
|
|
|
core.saveState('isPost', 'true');
|
|
|
|
}
|