Skip to content

Commit

Permalink
prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
nelsonleblanc-rl committed Nov 11, 2024
1 parent c51ad0a commit df36dcb
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions packages/@cdktf/commons/src/gradle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@ import { logger } from "./logging";
import { exec } from "./util";

export function isGradleProject(workingDirectory: string): boolean {
const buildGradlePath = path.join(workingDirectory, "build.gradle" || "build.gradle.kts");
const buildGradlePath = path.join(
workingDirectory,
"build.gradle" || "build.gradle.kts"
);

try {
fs.accessSync(buildGradlePath, fs.constants.R_OK | fs.constants.W_OK);
Expand Down Expand Up @@ -151,7 +154,10 @@ export async function getGradlePackageVersion(packageName: string) {
}

export async function getGradlePackageVersionFromBuild(packageName: string) {
const buildGradlePath = path.join(process.cwd(), "build.gradle" || "build.gradle.kts");
const buildGradlePath = path.join(
process.cwd(),
"build.gradle" || "build.gradle.kts"
);
const buildGradleContents = await fs.readFile(buildGradlePath, "utf-8");
const buildLines = buildGradleContents.split(/\r\n|\r|\n/);

Expand Down

0 comments on commit df36dcb

Please sign in to comment.