Skip to content

Commit

Permalink
Fix workdir (#224)
Browse files Browse the repository at this point in the history
  • Loading branch information
crazy-max committed Jun 24, 2020
1 parent 044b9d4 commit 8708f57
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
@@ -1,5 +1,9 @@
# Changelog

## 2.1.1 (2020/06/24)

* Fix workdir (#224)

## 2.1.0 (2020/06/15)

* Implement (optional) semver parsing of version (#213)
Expand Down
6 changes: 3 additions & 3 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions src/main.ts
Expand Up @@ -10,15 +10,15 @@ async function run(): Promise<void> {
const workdir = core.getInput('workdir') || '.';
const goreleaser = await installer.getGoReleaser(version);

const commit = await git.getShortCommit();
const tag = await git.getTag();
const isTagDirty = await git.isTagDirty(tag);

if (workdir && workdir !== '.') {
core.info(`📂 Using ${workdir} as working directory...`);
process.chdir(workdir);
}

const commit = await git.getShortCommit();
const tag = await git.getTag();
const isTagDirty = await git.isTagDirty(tag);

let snapshot = '';
if (args.split(' ').indexOf('release') > -1) {
if (isTagDirty) {
Expand Down

0 comments on commit 8708f57

Please sign in to comment.