Skip to content

Commit

Permalink
check if ext specified
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenHodgson committed Oct 31, 2024
1 parent 02a8c0b commit 2e7399b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30554,7 +30554,7 @@ const main = async () => {
}
let projectPath = core.getInput(`project-path`, { required: true });
core.info(`projectPath: "${projectPath}"`);
if (!projectPath.endsWith(`**/*.sln`)) {
if (!projectPath.endsWith(`.sln`)) {
projectPath = path.join(projectPath, `**/*.sln`);
}
let buildPath = projectPath;
Expand Down Expand Up @@ -30657,7 +30657,7 @@ main();
async function getCertificatePath(projectPath) {
let certificatePath = core.getInput(`certificate-path`) || `${projectPath}/**/*.pfx`;
core.info(`certificatePath: "${certificatePath}"`);
if (!certificatePath.endsWith(`**/*.pfx`)) {
if (!certificatePath.endsWith(`.pfx`)) {
certificatePath = path.join(certificatePath, `**/*.pfx`);
}
if (certificatePath.includes(`*`)) {
Expand Down
2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const main = async () => {
if (process.platform !== `win32`) { throw new Error(`This action can only run on Windows runner.`); }
let projectPath = core.getInput(`project-path`, { required: true });
core.info(`projectPath: "${projectPath}"`);
if (!projectPath.endsWith(`**/*.sln`)) {
if (!projectPath.endsWith(`.sln`)) {
projectPath = path.join(projectPath, `**/*.sln`);
}
let buildPath = projectPath;
Expand Down Expand Up @@ -120,7 +120,7 @@ main();
async function getCertificatePath(projectPath: string): Promise<string> {
let certificatePath = core.getInput(`certificate-path`) || `${projectPath}/**/*.pfx`;
core.info(`certificatePath: "${certificatePath}"`);
if (!certificatePath.endsWith(`**/*.pfx`)) {
if (!certificatePath.endsWith(`.pfx`)) {
certificatePath = path.join(certificatePath, `**/*.pfx`);
}
if (certificatePath.includes(`*`)) {
Expand Down

0 comments on commit 2e7399b

Please sign in to comment.