当前位置: 首页>>代码示例>>TypeScript>>正文


TypeScript path.join函数代码示例

本文整理汇总了TypeScript中vs/base/common/path.join函数的典型用法代码示例。如果您正苦于以下问题:TypeScript join函数的具体用法?TypeScript join怎么用?TypeScript join使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了join函数的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。

示例1: machineSettingsPath

	@memoize
	get machineSettingsPath(): string { return path.join(this.machineSettingsHome, 'settings.json'); }
开发者ID:eamodio,项目名称:vscode,代码行数:2,代码来源:environmentService.ts

示例2: globalStorageHome

	@memoize
	get globalStorageHome(): string { return path.join(this.appSettingsHome, 'globalStorage'); }
开发者ID:eamodio,项目名称:vscode,代码行数:2,代码来源:environmentService.ts

示例3: uniqueStorageDir

	function uniqueStorageDir(): string {
		const id = generateUuid();

		return join(tmpdir(), 'vsctests', id, 'storage2', id);
	}
开发者ID:PKRoma,项目名称:vscode,代码行数:5,代码来源:storageService.test.ts

示例4: machineSettingsHome

	@memoize
	get machineSettingsHome(): string { return path.join(this.userDataPath, 'Machine'); }
开发者ID:eamodio,项目名称:vscode,代码行数:2,代码来源:environmentService.ts

示例5: untitledWorkspacesHome

	@memoize
	get untitledWorkspacesHome(): URI { return URI.file(path.join(this.userDataPath, 'Workspaces')); }
开发者ID:eamodio,项目名称:vscode,代码行数:2,代码来源:environmentService.ts

示例6:

/*---------------------------------------------------------------------------------------------
 *  Copyright (c) Microsoft Corporation. All rights reserved.
 *  Licensed under the MIT License. See License.txt in the project root for license information.
 *--------------------------------------------------------------------------------------------*/

import * as path from 'vs/base/common/path';
import { getPathFromAmdModule } from 'vs/base/common/amd';

export interface IPackageConfiguration {
	name: string;
	version: string;
}

const rootPath = path.dirname(getPathFromAmdModule(require, ''));
const packageJsonPath = path.join(rootPath, 'package.json');
export default require.__$__nodeRequire(packageJsonPath) as IPackageConfiguration;
开发者ID:PKRoma,项目名称:vscode,代码行数:16,代码来源:package.ts

示例7:

			return service.backupResource(untitledFile, model.createSnapshot()).then(() => {
				assert.equal(fs.readdirSync(path.join(workspaceBackupPath, 'untitled')).length, 1);
				assert.equal(fs.existsSync(untitledBackupPath), true);
				assert.equal(fs.readFileSync(untitledBackupPath), `${untitledFile.toString()}\n${largeString}`);
				model.dispose();
			});
开发者ID:joelday,项目名称:vscode,代码行数:6,代码来源:backupFileService.test.ts

示例8: backupHome

	@memoize
	get backupHome(): string { return path.join(this.userDataPath, 'Backups'); }
开发者ID:eamodio,项目名称:vscode,代码行数:2,代码来源:environmentService.ts

示例9: createTextBufferFactory

			return service.backupResource(untitledFile, createTextBufferFactory('test').create(DefaultEndOfLine.LF).createSnapshot(false)).then(() => {
				assert.equal(fs.readdirSync(path.join(workspaceBackupPath, 'untitled')).length, 1);
				assert.equal(fs.existsSync(untitledBackupPath), true);
				assert.equal(fs.readFileSync(untitledBackupPath), `${untitledFile.toString()}\ntest`);
			});
开发者ID:joelday,项目名称:vscode,代码行数:5,代码来源:backupFileService.test.ts


注:本文中的vs/base/common/path.join函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。