Skip to content

Commit 9fbb1e6

Browse files
committed
Update
1 parent 98fcf34 commit 9fbb1e6

File tree

4 files changed

+15
-40
lines changed

4 files changed

+15
-40
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ Replace codes line by line with regex for target files
66

77
<img src="./image/demo.gif" />
88

9+
## Development environment
10+
11+
Tested on `Windows 10`, `macos Catalina`
12+
913
## How to install
1014

1115
Search vscode plugin's market place.
@@ -14,5 +18,7 @@ Or download and import vsix file.
1418

1519
## Related Repository
1620

21+
This extension is the Wrapper of the repository below.
22+
1723
* [code-replacer](https://github.com/jopemachine/code-replacer)
1824

code-replacer-0.0.1.vsix

17 Bytes
Binary file not shown.

extension.js

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,10 @@ async function handleTemplate ({ usageLogPath }) {
5858
return await getInput({
5959
placeHolder: 'Enter template.',
6060
validateInput: (str) => {
61-
return !validateTemplate(str)
61+
if (validateTemplate(str)) {
62+
return null
63+
}
64+
return 'Check template form to apply.'
6265
}
6366
})
6467
} else if (template === UIString.EXIT) {
@@ -156,6 +159,11 @@ const activate = (context) => {
156159

157160
const booleanFlags = await handleBooleanFlags()
158161

162+
if (!booleanFlags) {
163+
vscode.window.showInformationMessage(UIString.EXIT)
164+
return
165+
}
166+
159167
for (const booleanFlag of booleanFlags.values()) {
160168
flags[booleanFlag] = true
161169
}

vsc-extension-quickstart.md

Lines changed: 0 additions & 39 deletions
This file was deleted.

0 commit comments

Comments
 (0)