From 361206f1851f2f0ef438c211eef2e542326c74f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20V=C3=A1zquez=20Blanco?= Date: Mon, 17 Jun 2024 10:09:58 +0200 Subject: [PATCH] Fix bug in regex expressions --- dist/index.js | 2 +- package-lock.json | 4 ++-- package.json | 2 +- src/installer.test.ts | 1 - src/setup-ghidra.ts | 2 +- 5 files changed, 5 insertions(+), 6 deletions(-) diff --git a/dist/index.js b/dist/index.js index 7cc2b3a..9278ab3 100644 --- a/dist/index.js +++ b/dist/index.js @@ -35867,7 +35867,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true })); const core = __importStar(__nccwpck_require__(2186)); const github_helper = __importStar(__nccwpck_require__(6932)); const installer = __importStar(__nccwpck_require__(2574)); -const regexVersion = new RegExp("^\d+(\.\d+)*(\.\d+)*$"); +const regexVersion = new RegExp("^\\d+(\\.\\d+)*(\\.\\d+)*$"); const regexSha256sum = new RegExp("^[da-fA-F]{64}$"); function paramCheck(paramVersion, paramSha256sum, paramDownloadUrl) { // Validate version parameter diff --git a/package-lock.json b/package-lock.json index 363a077..bfc326d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "setup-ghidra", - "version": "2.0.1", + "version": "2.0.2", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "setup-ghidra", - "version": "2.0.1", + "version": "2.0.2", "license": "MIT", "dependencies": { "@actions/core": "^1.10.1", diff --git a/package.json b/package.json index 1653aa0..c3ec0d3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "setup-ghidra", - "version": "2.0.1", + "version": "2.0.2", "description": "This action sets up a Ghidra environment for use in actions.", "main": "index.js", "scripts": { diff --git a/src/installer.test.ts b/src/installer.test.ts index 346bf38..9f0456e 100644 --- a/src/installer.test.ts +++ b/src/installer.test.ts @@ -1,6 +1,5 @@ import path = require("path"); import io = require("@actions/io"); -import { Octokit } from "@octokit/rest"; import * as github_helper from "./github_helper"; import * as installer from "./installer"; import * as fs from "fs"; diff --git a/src/setup-ghidra.ts b/src/setup-ghidra.ts index bf76f6c..5da744b 100644 --- a/src/setup-ghidra.ts +++ b/src/setup-ghidra.ts @@ -2,7 +2,7 @@ import * as core from "@actions/core"; import * as github_helper from "./github_helper"; import * as installer from "./installer"; -const regexVersion = new RegExp("^\d+(\.\d+)*(\.\d+)*$"); +const regexVersion = new RegExp("^\\d+(\\.\\d+)*(\\.\\d+)*$"); const regexSha256sum = new RegExp("^[da-fA-F]{64}$"); function paramCheck(