import-gpg/src/state-helper.ts

13 lines
329 B
TypeScript
Raw Normal View History

import * as core from '@actions/core';
2020-05-03 20:46:05 +02:00
export const IsPost = !!process.env['STATE_isPost'];
export const gpgPrivateKey = process.env['STATE_gpgPrivateKey'] || '';
export function setGpgPrivateKey(gpgPrivateKey: string) {
core.saveState('gpgPrivateKey', gpgPrivateKey);
}
2020-05-03 20:46:05 +02:00
if (!IsPost) {
core.saveState('isPost', 'true');
2020-05-03 20:46:05 +02:00
}