forked from pgourlain/vscode_erlang
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migration to vscode engine 1.46 & fixes (pgourlain#166)
* Fix external debugger lunch error by removing vscode dependencies * update to vscode engine 1.46 * Add inline debugerAdpater implementation * exclude breakpoint set in .src file * compile arguments file into memory to avoid unwanted beam file * Add help.md * Fix pgourlain#106 * fix pgourlain#148 : Add 'plugins' path to includepaths * Goto definition on export atoms (pgourlain#146) * Changelog
- Loading branch information
Showing
21 changed files
with
328 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
|
||
# Introduction | ||
This file contains some help about Erlang extension. | ||
|
||
|
||
# Changing Debugger Mode | ||
- Debugger Mode setting is read at extension startup, so when you change this setting, you must restart vscode. | ||
|
||
# How exclude directories from "goto definition" feature | ||
|
||
Add in your local settings.json this section | ||
|
||
``` | ||
{ | ||
... | ||
"search.exclude" : { | ||
"**/_build": true | ||
} | ||
... | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,45 @@ | ||
import { | ||
workspace, WorkspaceFolder, DebugConfiguration, DebugConfigurationProvider, CancellationToken, ProviderResult | ||
} from 'vscode'; | ||
import { ErlangSettings } from './erlangSettings'; | ||
|
||
export class ErlangDebugConfigurationProvider implements DebugConfigurationProvider { | ||
provideDebugConfigurations?(folder: WorkspaceFolder | undefined, token?: CancellationToken): ProviderResult<DebugConfiguration[]> { | ||
if (folder) { | ||
return []; | ||
} | ||
return undefined; | ||
} | ||
|
||
resolveDebugConfiguration?(folder: WorkspaceFolder, debugConfiguration: DebugConfiguration, token?: CancellationToken): ProviderResult<DebugConfiguration> { | ||
debugConfiguration.verbose = workspace.getConfiguration("erlang").get("verbose", false); | ||
debugConfiguration.erlangPath = <string>workspace.getConfiguration("erlang").get("erlangPath", null); | ||
let cfg = getElangConfigConfiguration(); | ||
debugConfiguration.verbose = cfg.verbose; | ||
debugConfiguration.erlangPath = cfg.erlangPath; | ||
return debugConfiguration; | ||
} | ||
}; | ||
|
||
let currentSettings : ErlangSettings = null; | ||
|
||
export function configurationChanged() : void { | ||
let erlangConf = workspace.getConfiguration("erlang"); | ||
let settings : ErlangSettings = { | ||
erlangPath: erlangConf.get<string>("erlangPath", null), | ||
rebarPath: erlangConf.get<string>("rebarPath", null), | ||
codeLensEnabled: erlangConf.get<boolean>('codeLensEnabled', false), | ||
debuggerRunMode: erlangConf.get<string>("debuggerRunMode", "Server"), | ||
includePaths: erlangConf.get("includePaths", []), | ||
linting: erlangConf.get<boolean>('linting', false), | ||
rebarBuildArgs: erlangConf.get("rebarBuildArgs", ['compile']), | ||
rootPath : workspace.rootPath, | ||
verbose: erlangConf.get("verbose", false) | ||
}; | ||
currentSettings = settings; | ||
} | ||
|
||
export function getElangConfigConfiguration() : ErlangSettings { | ||
if (!currentSettings) { | ||
configurationChanged(); | ||
} | ||
return currentSettings; | ||
} |
Oops, something went wrong.