@eclipse-che/theia-factory-plugin
Advanced tools
Comparing version 0.0.1-1542962448 to 0.0.1-1547041312
@@ -6,3 +6,3 @@ { | ||
], | ||
"version": "0.0.1-1542962448", | ||
"version": "0.0.1-1547041312", | ||
"license": "EPL-2.0", | ||
@@ -15,2 +15,6 @@ "files": [ | ||
"@theia/plugin-packager": "^0.0.1-1539891078", | ||
"@eclipse-che/plugin": "^0.0.1-1546522786", | ||
"@types/jest": "22.2.3", | ||
"jest": "22.4.3", | ||
"ts-jest": "22.4.3", | ||
"rimraf": "2.6.2", | ||
@@ -21,8 +25,4 @@ "tslint": "5.10.0", | ||
}, | ||
"dependencies": { | ||
"@eclipse-che/workspace-client": "latest", | ||
"axios": "0.18.0" | ||
}, | ||
"scripts": { | ||
"prepare": "yarn run clean && yarn run build", | ||
"prepare": "yarn run clean && yarn run build && yarn tslint-fix && yarn run test", | ||
"clean": "rimraf lib", | ||
@@ -33,3 +33,5 @@ "format-code": "tsfmt -r", | ||
"build": "yarn run format-code && yarn run compile && theia:plugin pack", | ||
"tslint-fix": "tslint --fix --project ." | ||
"tslint-fix": "tslint --fix --project .", | ||
"test": "jest", | ||
"test-watch": "jest --watchAll" | ||
}, | ||
@@ -40,4 +42,26 @@ "engines": { | ||
"theiaPlugin": { | ||
"backend": "lib/plugin-backend-plugin.js" | ||
"backend": "lib/factory-plugin.js" | ||
}, | ||
"jest": { | ||
"collectCoverage": true, | ||
"collectCoverageFrom": [ | ||
"src/**/*.ts" | ||
], | ||
"coverageDirectory": "./coverage", | ||
"transform": { | ||
"^.+\\.tsx?$": "<rootDir>/node_modules/ts-jest/preprocessor.js" | ||
}, | ||
"modulePathIgnorePatterns": [ | ||
"<rootDir>/lib" | ||
], | ||
"testRegex": "(/__tests__/.*|(\\.|/)(test|spec))\\.(jsx?|tsx?)$", | ||
"moduleFileExtensions": [ | ||
"ts", | ||
"tsx", | ||
"js", | ||
"jsx", | ||
"json" | ||
], | ||
"testURL": "http://localhost/" | ||
} | ||
} |
@@ -11,2 +11,4 @@ /********************************************************************* | ||
import * as theia from '@theia/plugin'; | ||
import * as che from '@eclipse-che/plugin'; | ||
import convertToFileURI from './openfile'; | ||
@@ -24,11 +26,15 @@ const CHE_TASK_TYPE = 'che'; | ||
export class TheiaCloneCommand { | ||
constructor( | ||
protected readonly locationURI: string | undefined, | ||
protected readonly folder: string, | ||
protected readonly checkoutBranch?: string | undefined | ||
) { | ||
private locationURI: string | undefined; | ||
private folder: string; | ||
private checkoutBranch?: string | undefined; | ||
constructor(project: che.ProjectConfig, projectsRoot: string) { | ||
this.locationURI = project.source && project.source.location ? project.source.location : undefined; | ||
this.folder = projectsRoot + project.path; | ||
this.checkoutBranch = project.source && project.source.parameters && project.source.parameters['branch'] ? | ||
project.source.parameters['branch'] : undefined; | ||
} | ||
execute(): PromiseLike<void> { | ||
if (!this.locationURI) { | ||
@@ -46,4 +52,7 @@ return new Promise(() => { }); | ||
} | ||
} | ||
export class TheiaCommand { | ||
constructor( | ||
@@ -61,6 +70,6 @@ protected readonly id: string, | ||
execute(): PromiseLike<void> { | ||
if (this.id === ActionId.OPEN_FILE) { | ||
if (this.properties && this.properties.file) { | ||
return theia.commands.executeCommand('file-search.openFile', this.properties.file) | ||
const fileLocation = convertToFileURI(this.properties.file); | ||
return theia.commands.executeCommand('file-search.openFile', fileLocation) | ||
.then(() => { | ||
@@ -86,6 +95,6 @@ | ||
} | ||
return new Promise(() => { console.error('action nor openfile nor run command'); }); | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 2 instances in 1 package
0
3
35724
10
8
270
1
- Removed@eclipse-che/workspace-client@latest
- Removedaxios@0.18.0
- Removed@eclipse-che/api@7.96.0(transitive)
- Removed@eclipse-che/workspace-client@0.0.1-1675348695(transitive)
- Removedaxios@0.18.00.21.4(transitive)
- Removedcall-bind-apply-helpers@1.0.1(transitive)
- Removedcall-bound@1.0.3(transitive)
- Removeddunder-proto@1.0.1(transitive)
- Removedes-define-property@1.0.1(transitive)
- Removedes-errors@1.3.0(transitive)
- Removedes-object-atoms@1.0.0(transitive)
- Removedfollow-redirects@1.15.9(transitive)
- Removedfunction-bind@1.1.2(transitive)
- Removedget-intrinsic@1.2.7(transitive)
- Removedget-proto@1.0.1(transitive)
- Removedgopd@1.2.0(transitive)
- Removedhas-symbols@1.1.0(transitive)
- Removedhasown@2.0.2(transitive)
- Removedis-buffer@1.1.6(transitive)
- Removedmath-intrinsics@1.1.0(transitive)
- Removedobject-inspect@1.13.3(transitive)
- Removedqs@6.13.1(transitive)
- Removedside-channel@1.1.0(transitive)
- Removedside-channel-list@1.0.0(transitive)
- Removedside-channel-map@1.0.1(transitive)
- Removedside-channel-weakmap@1.0.2(transitive)
- Removedtunnel@0.0.6(transitive)