mirror of
https://github.com/goreleaser/goreleaser-action
synced 2026-06-30 01:19:43 +00:00
Allow to run GoReleaser from a subdirectory (#45)
This commit is contained in:
@@ -8,8 +8,14 @@ export async function run(silent?: boolean) {
|
||||
const version = core.getInput('version') || 'latest';
|
||||
const args = core.getInput('args');
|
||||
const key = core.getInput('key');
|
||||
const workdir = core.getInput('workdir') || '.';
|
||||
const goreleaser = await installer.getGoReleaser(version);
|
||||
|
||||
if (workdir && workdir !== '.') {
|
||||
console.log(`📂 Using ${workdir} as working directory...`)
|
||||
process.chdir(workdir);
|
||||
}
|
||||
|
||||
let snapshot = '';
|
||||
if (!process.env.GITHUB_REF || !process.env.GITHUB_REF.startsWith('refs/tags/')) {
|
||||
console.log(`⚠️ No tag found. Snapshot forced`);
|
||||
|
||||
Reference in New Issue
Block a user