Skip to content

Commit

Permalink
generalize paths - still not working
Browse files Browse the repository at this point in the history
  • Loading branch information
TylerLeonhardt committed Jun 25, 2019
1 parent bda1046 commit 8fad527
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
17 changes: 9 additions & 8 deletions client/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,32 +5,33 @@
'use strict';

import * as path from 'path';
import { workspace, ExtensionContext, commands, StatusBarItem } from 'coc.nvim';
import { TerminalResult } from 'coc.nvim/lib/types';
import { workspace, ExtensionContext, commands } from 'coc.nvim';
import { LanguageClient, LanguageClientOptions, ServerOptions, TransportKind } from 'coc.nvim';
import { Range } from 'vscode-languageserver-types';
import { getDefaultPowerShellPath, getPlatformDetails } from './platform';

const cocPowerShellRoot = path.join(__dirname, "..", "..");
const bundledModulesPath = path.join(cocPowerShellRoot, "PowerShellEditorServices");
const logPath = path.join(cocPowerShellRoot, "/.pses/logs/1234");

export function activate(context: ExtensionContext) {

const pwshPath = getDefaultPowerShellPath(getPlatformDetails())


let serverOptions: ServerOptions = {
command: pwshPath,
args: [
"-NoProfile",
"-NonInteractive",
"/Users/tyler/Code/PowerShell/coc-powershell/PowerShellEditorServices/PowerShellEditorServices/Start-EditorServices.ps1",
path.join(bundledModulesPath, "/PowerShellEditorServices/Start-EditorServices.ps1"),
"-HostName", "coc.vim",
"-HostProfileId", "0",
"-HostVersion", "2.0.0",
"-LogPath", "/Users/tyler/Code/PowerShell/coc-powershell/.pses/logs/1234/log.txt",
"-LogPath", path.join(logPath, "log.txt"),
"-LogLevel", "Diagnostic",
"-FeatureFlags", "[]",
"-BundledModulesPath", "/Users/tyler/Code/PowerShell/coc-powershell/PowerShellEditorServices/",
"-BundledModulesPath", bundledModulesPath,
"-Stdio",
"-SessionDetailsPath", "/Users/tyler/Code/PowerShell/coc-powershell/.pses/logs/1234/session"],
"-SessionDetailsPath", path.join(logPath, "session")],
transport: TransportKind.stdio
}

Expand Down
2 changes: 1 addition & 1 deletion ftplugin/ps1.vim
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ let s:vimscript_dir = expand('<sfile>:p:h')
" endfunction

" call s:PSESSetup()
" set rtp+=resolve(expand(s:vimscript_dir . '/../package.json'))
" set rtp+=resolve(expand(s:vimscript_dir . '/../package.json'))

0 comments on commit 8fad527

Please sign in to comment.