-
Notifications
You must be signed in to change notification settings - Fork 112
Configuring CSharpRepl
Will Fuqua edited this page Oct 22, 2022
·
1 revision
The following options can be provided at the command line:
- Usage:
csharprepl [OPTIONS] [@response-file.rsp] [script-file.csx] [-- <additional-arguments>]
- [OPTIONS] can be provided at the command line, or via a [@response-file.rsp].
-
[script-file.csx], if provided, will be executed before the prompt starts. Arguments to this script can be passed as
<additional-arguments>
and will be available in a globalargs
variable.
- OPTIONS:
- -r or --reference : Reference assemblies, nuget packages, and csproj files. Can be specified multiple times.
- -u or --using : Add using statement. Can be specified multiple times.
-
-f or --framework : Reference a shared framework.
- Available shared frameworks: Microsoft.NETCore.App (default), Microsoft.AspNetCore.App, Microsoft.WindowsDesktop.App
-
-t <theme.json> or --theme <theme.json>: Read a theme file for syntax highlighting. Respects the NO_COLOR standard.
- Available default themes:
themes\dracula.json
,themes\VisualStudio_BlueExtraContrast.json
,themes\VisualStudio_Dark.json (default)
,themes\VisualStudio_Light.json
- Available default themes:
- --useTerminalPaletteTheme: Ignores theme loaded from file and uses default theme with terminal palette colors. Respects the NO_COLOR standard.
- --prompt: Formatted prompt string.
- --useUnicode: UTF8 output encoding will be enabled and unicode character will be used (requires terminal support).
- --usePrereleaseNugets: Determines whether prerelease NuGet versions should be taken into account when searching for the latest package version.
- --tabSize : Width of tab character.
- --triggerCompletionListKeys : Set up key bindings for trigger completion list. Can be specified multiple times.
- --newLineKeys : Set up key bindings for new line character insertion. Can be specified multiple times.
- --submitPromptKeys : Set up key bindings for the submit of current prompt. Can be specified multiple times.
- --submitPromptDetailedKeys : Set up key bindings for the submit of current prompt with detailed output. Can be specified multiple times.
- --trace: Produce a trace file in the current directory, for CSharpRepl bug reports.
- -v or --version: Show version number and exit.
- -h**** or --help: Show this help and exit.
CSharpRepl will read a configuration file located in your home directory, that can contain any of the above command line options, one per line. Run csharprepl --configure
to launch an editor for this file. On Windows, it's located at C:\Users\username\AppData\Roaming\.csharprepl\config.rsp
and on Linux / Mac OS it's at ~/.config/.csharprepl/config.rsp
.