2020-08-15 12:45:36 +00:00
|
|
|
import * as core from '@actions/core';
|
|
|
|
|
|
|
|
export const IsPost = !!process.env['STATE_isPost'];
|
|
|
|
export const registry = process.env['STATE_registry'] || '';
|
|
|
|
export const logout = /true/i.test(process.env['STATE_logout'] || '');
|
|
|
|
|
|
|
|
export function setRegistry(registry: string) {
|
|
|
|
core.saveState('registry', registry);
|
|
|
|
}
|
|
|
|
|
2021-06-22 08:39:55 +00:00
|
|
|
export function setLogout(logout: boolean) {
|
2020-08-15 12:45:36 +00:00
|
|
|
core.saveState('logout', logout);
|
|
|
|
}
|
|
|
|
|
|
|
|
if (!IsPost) {
|
|
|
|
core.saveState('isPost', 'true');
|
|
|
|
}
|