Skip to content

Commit

Permalink
Bumped to version 5.1.0 (#185)
Browse files Browse the repository at this point in the history
* Bumped to version 5.1.0

* Testcase fix

* Fixed Tests

* Fixed Tests
  • Loading branch information
fr43nk authored Nov 22, 2024
1 parent 6c104d4 commit 620e7a3
Show file tree
Hide file tree
Showing 5 changed files with 264 additions and 36 deletions.
1 change: 1 addition & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"runtimeExecutable": "${execPath}",
"args": [
"--extensionDevelopmentPath=${workspaceFolder}",
"--disable-extensions",
"--extensionTestsPath=${workspaceFolder}/out/test/suite/index",
"${workspaceFolder}/out"
],
Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
## Release Notes

### 5.1.0

_Feature_

- Cleartool context menu as submenu
- Editor title commands
- Handling of internal commands

### 5.0.0

_Feature_
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "vscode-clearcase",
"displayName": "Unofficial ClearCase SCM Commands",
"description": "Unofficial support for IBM Rational ClearCase most common commands",
"version": "5.1.0-beta.1",
"version": "5.1.0",
"publisher": "OpenNingia",
"license": "MIT",
"repository": {
Expand Down
19 changes: 10 additions & 9 deletions src/clearcase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1148,15 +1148,13 @@ export class ClearCase {
// convert backslash to slash
cmd.files = cmd.files.map((f) => this.wslPath(f, false));

const outputChannel = this.outputChannel;

outputChannel.appendLine(cmd.getCmd().toString(), LogLevel.Debug);
this.outputChannel.appendLine(cmd.getCmd().toString(), LogLevel.Debug);
const command = spawn(executable, cmd.getCmd(), { cwd: cwd, env: process.env, detached: true });

// remove old running command
this.killRunningCommand(cmdId, command.pid);
this.mRunningCommands.set(cmdId, command);
outputChannel.appendLine(`Command ${cmdId} (${command.pid}) started`, LogLevel.Trace);
this.outputChannel.appendLine(`Command ${cmdId} (${command.pid}) started`, LogLevel.Trace);

let allData: Buffer = Buffer.alloc(0);
let cmdErrMsg = "";
Expand All @@ -1180,19 +1178,22 @@ export class ClearCase {
});

command.on("close", (code, signal) => {
outputChannel.appendLine(`Command ${cmdId} (${command.pid}), with Signal (${signal}) deleted`, LogLevel.Trace);
this.outputChannel.appendLine(
`Command ${cmdId} (${command.pid}), with Signal (${signal}) deleted`,
LogLevel.Trace
);
if (this.mRunningCommands.has(cmdId)) {
if (this.mRunningCommands.get(cmdId)?.pid === command.pid) {
this.mRunningCommands.delete(cmdId);
outputChannel.appendLine(`Command ${cmdId} (${command.pid}) deleted`, LogLevel.Trace);
this.outputChannel.appendLine(`Command ${cmdId} (${command.pid}) deleted`, LogLevel.Trace);
}
outputChannel.appendLine(`Command ${cmdId} (${command.pid}) finished`, LogLevel.Trace);
this.outputChannel.appendLine(`Command ${cmdId} (${command.pid}) finished`, LogLevel.Trace);
}
if (cmdErrMsg !== "") {
// If something was printed on stderr, log it, regardless of the exit code
outputChannel.appendLine(`exit code ${code}, stderr: ${cmdErrMsg}`, LogLevel.Error);
this.outputChannel.appendLine(`exit code ${code}, stderr: ${cmdErrMsg}`, LogLevel.Error);
} else {
outputChannel.appendLine(`${allData.toString()}`, LogLevel.Debug);
this.outputChannel.appendLine(`${allData.toString()}`, LogLevel.Debug);
}
if (code !== null && code !== 0 && this.isView && cmdErrMsg !== "") {
reject(cmdErrMsg);
Expand Down
Loading

0 comments on commit 620e7a3

Please sign in to comment.