File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -16,14 +16,14 @@ export function getPackageJson(relativePath: string): JSONSchemaForNPMPackageJso
16
16
return pkg
17
17
}
18
18
19
- const pkg = getPackageJson ( "../../package.json" )
20
- const codePkg = getPackageJson ( "../../vendor/modules/code-oss-dev/package.json" )
21
-
19
+ export const rootPath = path . resolve ( __dirname , "../.." )
20
+ export const vsRootPath = path . join ( rootPath , "vendor/modules/code-oss-dev" )
21
+ const PACKAGE_JSON = "package.json"
22
+ const pkg = getPackageJson ( `${ rootPath } /${ PACKAGE_JSON } ` )
23
+ const codePkg = getPackageJson ( `${ vsRootPath } /${ PACKAGE_JSON } ` ) || { version : "0.0.0" }
22
24
export const pkgName = pkg . name || "code-server"
23
25
export const version = pkg . version || "development"
24
26
export const commit = pkg . commit || "development"
25
- export const rootPath = path . resolve ( __dirname , "../.." )
26
- export const vsRootPath = path . join ( rootPath , "vendor/modules/code-oss-dev" )
27
27
export const codeVersion = codePkg . version || "development"
28
28
export const tmpdir = path . join ( os . tmpdir ( ) , "code-server" )
29
29
export const isDevMode = commit === "development"
You can’t perform that action at this time.
0 commit comments