diff --git a/replace-string/action.yml b/replace-string/action.yml index 17658e6..52b88a9 100644 --- a/replace-string/action.yml +++ b/replace-string/action.yml @@ -1,7 +1,9 @@ --- name: Replace string description: | - Replaces string... + This action replaces a specified string using regular expression. + It can be passed as an input or read from a file. + Also, the output string can be additional written to file. inputs: string: description: String to be replaced diff --git a/replace-string/index.js b/replace-string/index.js index 38bbcbd..a5eb1bd 100644 --- a/replace-string/index.js +++ b/replace-string/index.js @@ -34,7 +34,7 @@ try { } const regex = new RegExp(inReplaceRegex, inFlags); - strReplaced = string.replace(regex, inReplaceWith); + strReplaced = strToReplace.replace(regex, inReplaceWith); // Output