mirror of
https://github.com/ckaczor/vscode-gitlens.git
synced 2026-01-14 10:03:15 -05:00
Reduces the size of the vsix
This commit is contained in:
@@ -3,9 +3,10 @@ import {CancellationToken, CodeLens, CodeLensProvider, commands, DocumentSelecto
|
||||
import {BuiltInCommands, Commands, DocumentSchemes, WorkspaceState} from './constants';
|
||||
import {CodeLensCommand, CodeLensLocation, ICodeLensesConfig} from './configuration';
|
||||
import GitProvider, {IGitBlame, IGitBlameLines, IGitCommit} from './gitProvider';
|
||||
import * as _ from 'lodash';
|
||||
import * as moment from 'moment';
|
||||
|
||||
const escapeRegExp = require('lodash.escapeRegExp');
|
||||
|
||||
export class GitRecentChangeCodeLens extends CodeLens {
|
||||
constructor(private git: GitProvider, public fileName: string, public symbolKind: SymbolKind, public blameRange: Range, range: Range) {
|
||||
super(range);
|
||||
@@ -105,7 +106,7 @@ export default class GitCodeLensProvider implements CodeLensProvider {
|
||||
|
||||
let startChar = -1;
|
||||
try {
|
||||
startChar = line.text.search(`\\b${_.escapeRegExp(symbol.name)}\\b`);
|
||||
startChar = line.text.search(`\\b${escapeRegExp(symbol.name)}\\b`);
|
||||
}
|
||||
catch (ex) { }
|
||||
if (startChar === -1) {
|
||||
|
||||
Reference in New Issue
Block a user