Skip to content

Commit

Permalink
Make workingDir property internal and only expose the .git directory
Browse files Browse the repository at this point in the history
Closes #103
  • Loading branch information
LunNova authored and magneticflux- committed Mar 29, 2023
1 parent 2e3b850 commit d01c1c9
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/main/java/org/shipkit/changelog/GenerateChangelogTask.java
Original file line number Diff line number Diff line change
Expand Up @@ -139,11 +139,22 @@ public void setOutputFile(File outputFile) {
this.outputFile = outputFile;
}

@InputDirectory
@Internal
public File getWorkingDir() {
return workingDir;
}

@InputDirectory
@PathSensitive(PathSensitivity.RELATIVE)
public File getGitDir() {
if (workingDir == null) {
return null;
}
else {
return new File(workingDir, ".git");
}
}

public void setWorkingDir(File workingDir) {
this.workingDir = workingDir;
}
Expand Down

0 comments on commit d01c1c9

Please sign in to comment.