Skip to content

Commit 4a6308b

Browse files
committed
possible fix for showing changes outside of current selected folder
1 parent 9858cbf commit 4a6308b

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

src/model.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Model.prototype.tryOpenRepository = async function(path) {
2828
return;
2929
}
3030

31-
const repository = new Repository(this.svn.open(repositoryRoot));
31+
const repository = new Repository(this.svn.open(repositoryRoot, path));
3232

3333
this.open(repository);
3434
} catch (err) {

src/svn.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,8 @@ svn.prototype.isSVNAvailable = function() {
109109
});
110110
};
111111

112-
svn.prototype.open = function(repositoryRoot) {
113-
return new Repository(this, repositoryRoot);
112+
svn.prototype.open = function(repositoryRoot, workspaceRoot) {
113+
return new Repository(this, repositoryRoot, workspaceRoot);
114114
};
115115

116116
svn.prototype.cmd = function(args) {
@@ -145,12 +145,13 @@ svn.prototype.add = function(filePath) {
145145

146146
module.exports = svn;
147147

148-
function Repository(svn, repositoryRoot) {
148+
function Repository(svn, repositoryRoot, workspaceRoot) {
149149
this.svn = svn;
150150
this.root = repositoryRoot;
151+
this.workspaceRoot = workspaceRoot;
151152

152153
this.svn.client.option({
153-
cwd: this.root,
154+
cwd: this.workspaceRoot,
154155
noAuthCache: true
155156
});
156157
}

0 commit comments

Comments
 (0)