Skip to content

Commit 793194f

Browse files
committed
Merge branch 'fix-private-to-private-contributions' of https://github.com/finos/git-proxy into fix-private-to-private-contributions
2 parents 2f679df + a5fb6eb commit 793194f

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

src/proxy/processors/push-action/pullRemote.js

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ const Step = require('../../actions').Step;
22
const fs = require('fs');
33
const dir = './.remote';
44
const git = require('isomorphic-git');
5-
const http = require('isomorphic-git/http/node');
5+
const gitHttpClient = require('isomorphic-git/http/node');
66

77
const exec = async (req, action) => {
88
const step = new Step('pullRemote');
@@ -31,20 +31,17 @@ const exec = async (req, action) => {
3131
await git
3232
.clone({
3333
fs,
34-
http,
34+
http: gitHttpClient,
3535
url: action.url,
36-
onAuth: () => {
37-
return {
38-
username: username,
39-
password: password,
40-
};
41-
},
36+
onAuth: () => ({
37+
username,
38+
password,
39+
}),
4240
dir: `${action.proxyGitPath}/${action.repoName}`,
43-
})
44-
.then(() => {
45-
console.log('Clone Success: ', action.url);
4641
});
4742

43+
console.log('Clone Success: ', action.url);
44+
4845
step.log(`Completed ${cmd}`);
4946
step.setContent(`Completed ${cmd}`);
5047
} catch (e) {

0 commit comments

Comments
 (0)