Browse Source

Apply Review Comments.

main
Amanda Cameron 7 years ago
committed by Eric Amodio
parent
commit
04ea3b7971
1 changed files with 14 additions and 2 deletions
  1. +14
    -2
      src/git/remotes/gitlab.ts

+ 14
- 2
src/git/remotes/gitlab.ts View File

@ -1,8 +1,8 @@
'use strict';
import { Range } from 'vscode';
import { GitHubService } from './github';
import { RemoteProvider } from './provider';
export class GitLabService extends GitHubService {
export class GitLabService extends RemoteProvider {
constructor(public domain: string, public path: string, public custom: boolean = false) {
super(domain, path);
@ -12,6 +12,18 @@ export class GitLabService extends GitHubService {
return this.formatName('GitLab');
}
protected getUrlForBranches(): string {
return `${this.baseUrl}/branches`;
}
protected getUrlForBranch(branch: string): string {
return `${this.baseUrl}/commits/${branch}`;
}
protected getUrlForCommit(sha: string): string {
return `${this.baseUrl}/commit/${sha}`;
}
protected getUrlForFile(fileName: string, branch?: string, sha?: string, range?: Range): string {
let line = '';
if (range) {

Loading…
Cancel
Save