· 6 years ago · Oct 30, 2019, 01:04 PM
1# Configuration for Alacritty, the GPU enhanced terminal emulator.
2
3# Any items in the `env` entry below will be added as
4# environment variables. Some entries may override variables
5# set by alacritty itself.
6#env:
7 # TERM variable
8 #
9 # This value is used to set the `$TERM` environment variable for
10 # each instance of Alacritty. If it is not present, alacritty will
11 # check the local terminfo database and use `alacritty` if it is
12 # available, otherwise `xterm-256color` is used.
13 #TERM: xterm-256color
14
15window:
16 # Window dimensions (changes require restart)
17 #
18 # Specified in number of columns/lines, not pixels.
19 # If both are `0`, this setting is ignored.
20 dimensions:
21 columns: 108
22 lines: 43
23
24 # Window position (changes require restart)
25 #
26 # Specified in number of pixels.
27 # If the position is not set, the window manager will handle the placement.
28 #position:
29 # x: 0
30 # y: 0
31
32 # Window padding (changes require restart)
33 #
34 # Blank space added around the window in pixels. This padding is scaled
35 # by DPI and the specified value is always added at both opposing sides.
36 padding:
37 x: 4
38 y: 4
39
40 # Spread additional padding evenly around the terminal content.
41 dynamic_padding: false
42
43 # Window decorations
44 #
45 # Values for `decorations`:
46 # - full: Borders and title bar
47 # - none: Neither borders nor title bar
48 #
49 # Values for `decorations` (macOS only):
50 # - transparent: Title bar, transparent background and title bar buttons
51 # - buttonless: Title bar, transparent background, but no title bar buttons
52 decorations: buttonless
53
54 # When true, alacritty starts maximized.
55 startup_mode: Windowed
56
57scrolling:
58 # Maximum number of lines in the scrollback buffer.
59 # Specifying '0' will disable scrolling.
60 history: 10000
61
62 # Number of lines the viewport will move for every line scrolled when
63 # scrollback is enabled (history > 0).
64 multiplier: 1
65
66 # Faux Scrolling
67 #
68 # The `faux_multiplier` setting controls the number of lines the terminal
69 # should scroll when the alternate screen buffer is active. This is used
70 # to allow mouse scrolling for applications like `man`.
71 #
72 # Specifying `0` will disable faux scrolling.
73 faux_multiplier: 1
74
75 # Scroll to the bottom when new text is written to the terminal.
76 auto_scroll: false
77
78# Spaces per Tab (changes require restart)
79#
80# This setting defines the width of a tab in cells.
81#
82# Some applications, like Emacs, rely on knowing about the width of a tab.
83# To prevent unexpected behavior in these applications, it's also required to
84# change the `it` value in terminfo when altering this setting.
85tabspaces: 8
86
87# Font configuration (changes require restart)
88font:
89 # Normal (roman) font face
90 normal:
91 # Font family
92 #
93 # Default:
94 # - (macOS) Menlo
95 # - (Linux) monospace
96 # - (Windows) Consolas
97 family: Liberation Mono for Powerline
98
99 # The `style` can be specified to pick a specific face.
100 #style: Regular
101
102 # Bold font face
103 bold:
104 # Font family
105 #
106 # If the bold family is not specified, it will fall back to the
107 # value specified for the normal font.
108 family: Liberation Mono for Powerline
109
110 # The `style` can be specified to pick a specific face.
111 #style: Bold
112
113 # Italic font face
114 italic:
115 # Font family
116 #
117 # If the italic family is not specified, it will fall back to the
118 # value specified for the normal font.
119 family: Liberation Mono for Powerline
120
121 # The `style` can be specified to pick a specific face.
122 #style: Italic
123
124 # Point size
125 size: 11.0
126
127 # Offset is the extra space around each character. `offset.y` can be thought of
128 # as modifying the line spacing, and `offset.x` as modifying the letter spacing.
129 offset:
130 x: 0
131 y: 0
132
133 # Glyph offset determines the locations of the glyphs within their cells with
134 # the default being at the bottom. Increasing `x` moves the glyph to the right,
135 # increasing `y` moves the glyph upwards.
136 glyph_offset:
137 x: 0
138 y: 0
139
140 # Thin stroke font rendering (macOS only)
141 #
142 # Thin strokes are suitable for retina displays, but for non-retina screens
143 # it is recommended to set `use_thin_strokes` to `false`
144 #
145 # macOS >= 10.14.x:
146 #
147 # If the font quality on non-retina display looks bad then set
148 # `use_thin_strokes` to `true` and enable font smoothing by running the
149 # following command:
150 # `defaults write -g CGFontRenderingFontSmoothingDisabled -bool NO`
151 #
152 # This is a global setting and will require a log out or restart to take
153 # effect.
154 use_thin_strokes: true
155
156# Display the time it takes to redraw each frame.
157debug.render_timer: false
158
159# Keep the log file after quitting Alacritty.
160debug.persistent_logging: false
161
162# If `true`, bold text is drawn using the bright color variants.
163draw_bold_text_with_bright_colors: true
164
165# Colors (Tomorrow Night Bright)
166colors:
167 # Default colors
168 primary:
169 background: '0x333333'
170 foreground: '0xffffff'
171
172 # Bright and dim foreground colors
173 #
174 # The dimmed foreground color is calculated automatically if it is not present.
175 # If the bright foreground color is not set, or `draw_bold_text_with_bright_colors`
176 # is `false`, the normal foreground color will be used.
177 dim_foreground: '0x9a9a9a'
178 bright_foreground: '0xffffff'
179
180 # Cursor colors
181 #
182 # Colors which should be used to draw the terminal cursor. If these are unset,
183 # the cursor color will be the inverse of the cell color.
184 cursor:
185 text: '0x000000'
186 cursor: '0xffffff'
187
188 # Selection colors
189 #
190 # Colors which should be used to draw the selection area. If selection
191 # background is unset, selection color will be the inverse of the cell colors.
192 # If only text is unset the cell text color will remain the same.
193 #selection:
194 # text: '0xeaeaea'
195 # background: '0x404040'
196
197 # Normal colors
198 normal:
199 black: '0x000000'
200 red: '0xd54e53'
201 green: '0xb9ca4a'
202 yellow: '0xe6c547'
203 blue: '0x7aa6da'
204 magenta: '0xc397d8'
205 cyan: '0x70c0ba'
206 white: '0xeaeaea'
207
208 # Bright colors
209 bright:
210 black: '0x666666'
211 red: '0xff3334'
212 green: '0x9ec400'
213 yellow: '0xe7c547'
214 blue: '0x7aa6da'
215 magenta: '0xb77ee0'
216 cyan: '0x54ced6'
217 white: '0xffffff'
218
219 # Dim colors
220 #
221 # If the dim colors are not set, they will be calculated automatically based
222 # on the `normal` colors.
223 #dim:
224 # black: '0x000000'
225 # red: '0x8c3336'
226 # green: '0x7a8530'
227 # yellow: '0x97822e'
228 # blue: '0x506d8f'
229 # magenta: '0x80638e'
230 # cyan: '0x497e7a'
231 # white: '0x9a9a9a'
232
233 # Indexed Colors
234 #
235 # The indexed colors include all colors from 16 to 256.
236 # When these are not set, they're filled with sensible defaults.
237 #
238 # Example:
239 # `- { index: 16, color: '0xff00ff' }`
240 #
241 indexed_colors: []
242
243# Visual Bell
244#
245# Any time the BEL code is received, Alacritty "rings" the visual bell. Once
246# rung, the terminal background will be set to white and transition back to the
247# default background color. You can control the rate of this transition by
248# setting the `duration` property (represented in milliseconds). You can also
249# configure the transition function by setting the `animation` property.
250#
251# Values for `animation`:
252# - Ease
253# - EaseOut
254# - EaseOutSine
255# - EaseOutQuad
256# - EaseOutCubic
257# - EaseOutQuart
258# - EaseOutQuint
259# - EaseOutExpo
260# - EaseOutCirc
261# - Linear
262#
263# Specifying a `duration` of `0` will disable the visual bell.
264visual_bell:
265 animation: EaseOutExpo
266 duration: 0
267 color: '0xffffff'
268
269# Background opacity
270#
271# Window opacity as a floating point number from `0.0` to `1.0`.
272# The value `0.0` is completely transparent and `1.0` is opaque.
273background_opacity: 0.96
274
275# Mouse bindings
276#
277# Available fields:
278# - mouse
279# - action
280# - mods (optional)
281#
282# Values for `mouse`:
283# - Middle
284# - Left
285# - Right
286# - Numeric identifier such as `5`
287#
288# All available `mods` and `action` values are documented in the key binding
289# section.
290mouse_bindings:
291 - { mouse: Middle, action: PasteSelection }
292
293mouse:
294 # Click settings
295 #
296 # The `double_click` and `triple_click` settings control the time
297 # alacritty should wait for accepting multiple clicks as one double
298 # or triple click.
299 double_click: { threshold: 300 }
300 triple_click: { threshold: 300 }
301
302 # If this is `true`, the cursor is temporarily hidden when typing.
303 hide_when_typing: false
304
305 url:
306 # URL launcher
307 #
308 # This program is executed when clicking on a text which is recognized as a URL.
309 # The URL is always added to the command as the last parameter.
310 #
311 # When set to `None`, URL launching will be disabled completely.
312 #
313 # Default:
314 # - (macOS) open
315 # - (Linux) xdg-open
316 # - (Windows) explorer
317 launcher: open
318
319 # URL modifiers
320 #
321 # These are the modifiers that need to be held down for opening URLs when clicking
322 # on them. The available modifiers are documented in the key binding section.
323 modifiers: None
324
325selection:
326 semantic_escape_chars: ",│`|:\"' ()[]{}<>"
327
328 # When set to `true`, selected text will be copied to the primary clipboard.
329 save_to_clipboard: true
330
331# Allow terminal applications to change Alacritty's window title.
332dynamic_title: true
333
334cursor:
335 # Cursor style
336 #
337 # Values for `style`:
338 # - ▇ Block
339 # - _ Underline
340 # - | Beam
341 style: Block
342
343 # If this is `true`, the cursor will be rendered as a hollow box when the
344 # window is not focused.
345 unfocused_hollow: true
346
347# Live config reload (changes require restart)
348live_config_reload: true
349
350# Shell
351#
352# You can set `shell.program` to the path of your favorite shell, e.g. `/bin/fish`.
353# Entries in `shell.args` are passed unmodified as arguments to the shell.
354#
355# Default:
356# - (Linux/macOS) /bin/bash --login
357# - (Windows) powershell
358shell:
359 program: /usr/local/bin/bash
360# args:
361# - --login
362
363# Windows 10 ConPTY backend (Windows only)
364#
365# This will enable better color support and may resolve other issues,
366# however this API and its implementation is still young and so is
367# disabled by default, as stability may not be as good as the winpty
368# backend.
369#
370# Alacritty will fall back to the WinPTY automatically if the ConPTY
371# backend cannot be initialized.
372enable_experimental_conpty_backend: false
373
374# Send ESC (\x1b) before characters when alt is pressed.
375alt_send_esc: true
376
377# Key bindings
378#
379# Key bindings are specified as a list of objects. Each binding will specify a
380# key and modifiers required to trigger it, terminal modes where the binding is
381# applicable, and what should be done when the key binding fires. It can either
382# send a byte sequence to the running application (`chars`), execute a
383# predefined action (`action`) or fork and execute a specified command plus
384# arguments (`command`).
385#
386# Bindings are always filled by default, but will be replaced when a new binding
387# with the same triggers is defined. To unset a default binding, it can be
388# mapped to the `None` action.
389#
390# Example:
391# `- { key: V, mods: Control|Shift, action: Paste }`
392#
393# Available fields:
394# - key
395# - mods (optional)
396# - chars | action | command (exactly one required)
397# - mode (optional)
398#
399# Values for `key`:
400# - `A` -> `Z`
401# - `F1` -> `F12`
402# - `Key1` -> `Key0`
403#
404# A full list with available key codes can be found here:
405# https://docs.rs/glutin/*/glutin/enum.VirtualKeyCode.html#variants
406#
407# Instead of using the name of the keys, the `key` field also supports using
408# the scancode of the desired key. Scancodes have to be specified as a
409# decimal number.
410# This command will allow you to display the hex scancodes for certain keys:
411# `showkey --scancodes`
412#
413# Values for `mods`:
414# - Command
415# - Control
416# - Super
417# - Shift
418# - Alt
419#
420# Multiple `mods` can be combined using `|` like this: `mods: Control|Shift`.
421# Whitespace and capitalization is relevant and must match the example.
422#
423# Values for `chars`:
424# The `chars` field writes the specified string to the terminal. This makes
425# it possible to pass escape sequences.
426# To find escape codes for bindings like `PageUp` ("\x1b[5~"), you can run
427# the command `showkey -a` outside of tmux.
428# Note that applications use terminfo to map escape sequences back to
429# keys. It is therefore required to update the terminfo when
430# changing an escape sequence.
431#
432# Values for `action`:
433# - Paste
434# - PasteSelection
435# - Copy
436# - IncreaseFontSize
437# - DecreaseFontSize
438# - ResetFontSize
439# - ScrollPageUp
440# - ScrollPageDown
441# - ScrollToTop
442# - ScrollToBottom
443# - ClearHistory
444# - Hide
445# - Quit
446# - ClearLogNotice
447# - SpawnNewInstance
448# - None
449#
450# Values for `command`:
451# The `command` field must be a map containing a `program` string and
452# an `args` array of command line parameter strings.
453#
454# Example:
455# `command: { program: "alacritty", args: ["-e", "vttest"] }`
456#
457# Values for `mode`:
458# - ~AppCursor
459# - AppCursor
460# - ~AppKeypad
461# - AppKeypad
462key_bindings:
463
464 # Use this to get the keycode for any letter:
465 #
466 #{ stty raw min 1 time 20 -echo; dd count=1 2> /dev/null | od -vAn -tx1; stty sane; }
467 #
468 # With this, subtract 6 from the first digit to get the ctrl + [letter] equivilant. I.e.:
469 # t = 74 - 60 = \x14
470
471 - { key: Equals, mods: Command, action: IncreaseFontSize }
472 - { key: Add, mods: Command, action: IncreaseFontSize }
473 - { key: Subtract, mods: Command, action: DecreaseFontSize }
474 - { key: Minus, mods: Command, action: DecreaseFontSize }
475 - { key: A, mods: Command, chars: "\x01" }
476 - { key: B, mods: Command, chars: "\x02" }
477 - { key: C, mods: Command, chars: "\x03" }
478 - { key: C, mods: Command|Shift, action: Copy }
479 - { key: D, mods: Command, chars: "\x04" }
480 - { key: E, mods: Command, chars: "\x05" }
481 - { key: F, mods: Command, chars: "\x06" }
482 - { key: G, mods: Command, chars: "\x07" }
483 - { key: H, mods: Command, chars: "\x08" }
484 - { key: I, mods: Command, chars: "\x09" }
485 - { key: J, mods: Command, chars: "\x0a" }
486 - { key: K, mods: Command, chars: "\x0b" }
487 - { key: L, mods: Command, chars: "\x0c" }
488 - { key: M, mods: Command, chars: "\x0d" }
489 - { key: N, mods: Command, chars: "\x0e" }
490 - { key: O, mods: Command, chars: "\x0f" }
491 - { key: P, mods: Command, chars: "\x10" }
492 - { key: Q, mods: Command, chars: "\x11" }
493 - { key: R, mods: Command, chars: "\x12" }
494 - { key: S, mods: Command, chars: "\x13" }
495 - { key: T, mods: Command, chars: "\x14" }
496 - { key: U, mods: Command, chars: "\x15" }
497 - { key: V, mods: Command, chars: "\x16" }
498 - { key: V, mods: Command, action: None }
499 - { key: V, mods: Command|Shift, action: Paste }
500 - { key: W, mods: Command, chars: "\x17" }
501 - { key: X, mods: Command, chars: "\x18" }
502 - { key: Y, mods: Command, chars: "\x19" }
503 - { key: Z, mods: Command, chars: "\x1a" }
504 - { key: Home, mods: Alt, chars: "\x1b[1;3H" }
505 - { key: Home, chars: "\x1bOH", mode: AppCursor }
506 - { key: Home, chars: "\x1b[H", mode: ~AppCursor }
507 - { key: End, mods: Alt, chars: "\x1b[1;3F" }
508 - { key: End, chars: "\x1bOF", mode: AppCursor }
509 - { key: End, chars: "\x1b[F", mode: ~AppCursor }
510 - { key: PageUp, mods: Shift, action: ScrollPageUp, mode: ~Alt }
511 - { key: PageUp, mods: Shift, chars: "\x1b[5;2~", mode: Alt }
512 - { key: PageUp, mods: Command, chars: "\x1b[5;5~" }
513 - { key: PageUp, mods: Alt, chars: "\x1b[5;3~" }
514 - { key: PageUp, chars: "\x1b[5~" }
515 - { key: PageDown, mods: Shift, action: ScrollPageDown, mode: ~Alt }
516 - { key: PageDown, mods: Shift, chars: "\x1b[6;2~", mode: Alt }
517 - { key: PageDown, mods: Command, chars: "\x1b[6;5~" }
518 - { key: PageDown, mods: Alt, chars: "\x1b[6;3~" }
519 - { key: PageDown, chars: "\x1b[6~" }
520 - { key: Tab, mods: Shift, chars: "\x1b[Z" }
521 - { key: Back, chars: "\x7f" }
522 - { key: Back, mods: Alt, chars: "\x1b\x7f" }
523 - { key: Insert, chars: "\x1b[2~" }
524 - { key: Delete, chars: "\x1b[3~" }
525 - { key: Left, mods: Shift, chars: "\x1b[1;2D" }
526 - { key: Left, mods: Control, chars: "\x1bb" }
527 - { key: Left, mods: Alt, chars: "\x1bb" }
528 - { key: Left, chars: "\x1b[D", mode: ~AppCursor }
529 - { key: Left, chars: "\x1bOD", mode: AppCursor }
530 - { key: Right, mods: Shift, chars: "\x1b[1;2C" }
531 - { key: Right, mods: Control, chars: "\x1bf" }
532 - { key: Right, mods: Alt, chars: "\x1bf" }
533 - { key: Right, chars: "\x1b[C", mode: ~AppCursor }
534 - { key: Right, chars: "\x1bOC", mode: AppCursor }
535 - { key: Up, mods: Shift, chars: "\x1b[1;2A" }
536 - { key: Up, mods: Command, chars: "\x1b[1;5A" }
537 - { key: Up, mods: Alt, chars: "\x1b[1;3A" }
538 - { key: Up, chars: "\x1b[A", mode: ~AppCursor }
539 - { key: Up, chars: "\x1bOA", mode: AppCursor }
540 - { key: Down, mods: Shift, chars: "\x1b[1;2B" }
541 - { key: Down, mods: Command, chars: "\x1b[1;5B" }
542 - { key: Down, mods: Alt, chars: "\x1b[1;3B" }
543 - { key: Down, chars: "\x1b[B", mode: ~AppCursor }
544 - { key: Down, chars: "\x1bOB", mode: AppCursor }
545 - { key: F1, chars: "\x1bOP" }
546 - { key: F2, chars: "\x1bOQ" }
547 - { key: F3, chars: "\x1bOR" }
548 - { key: F4, chars: "\x1bOS" }
549 - { key: F5, chars: "\x1b[15~" }
550 - { key: F6, chars: "\x1b[17~" }
551 - { key: F7, chars: "\x1b[18~" }
552 - { key: F8, chars: "\x1b[19~" }
553 - { key: F9, chars: "\x1b[20~" }
554 - { key: F10, chars: "\x1b[21~" }
555 - { key: F11, chars: "\x1b[23~" }
556 - { key: F12, chars: "\x1b[24~" }
557 - { key: F1, mods: Shift, chars: "\x1b[1;2P" }
558 - { key: F2, mods: Shift, chars: "\x1b[1;2Q" }
559 - { key: F3, mods: Shift, chars: "\x1b[1;2R" }
560 - { key: F4, mods: Shift, chars: "\x1b[1;2S" }
561 - { key: F5, mods: Shift, chars: "\x1b[15;2~" }
562 - { key: F6, mods: Shift, chars: "\x1b[17;2~" }
563 - { key: F7, mods: Shift, chars: "\x1b[18;2~" }
564 - { key: F8, mods: Shift, chars: "\x1b[19;2~" }
565 - { key: F9, mods: Shift, chars: "\x1b[20;2~" }
566 - { key: F10, mods: Shift, chars: "\x1b[21;2~" }
567 - { key: F11, mods: Shift, chars: "\x1b[23;2~" }
568 - { key: F12, mods: Shift, chars: "\x1b[24;2~" }
569 - { key: F1, mods: Command, chars: "\x1b[1;5P" }
570 - { key: F2, mods: Command, chars: "\x1b[1;5Q" }
571 - { key: F3, mods: Command, chars: "\x1b[1;5R" }
572 - { key: F4, mods: Command, chars: "\x1b[1;5S" }
573 - { key: F5, mods: Command, chars: "\x1b[15;5~" }
574 - { key: F6, mods: Command, chars: "\x1b[17;5~" }
575 - { key: F7, mods: Command, chars: "\x1b[18;5~" }
576 - { key: F8, mods: Command, chars: "\x1b[19;5~" }
577 - { key: F9, mods: Command, chars: "\x1b[20;5~" }
578 - { key: F10, mods: Command, chars: "\x1b[21;5~" }
579 - { key: F11, mods: Command, chars: "\x1b[23;5~" }
580 - { key: F12, mods: Command, chars: "\x1b[24;5~" }
581 - { key: F1, mods: Alt, chars: "\x1b[1;6P" }
582 - { key: F2, mods: Alt, chars: "\x1b[1;6Q" }
583 - { key: F3, mods: Alt, chars: "\x1b[1;6R" }
584 - { key: F4, mods: Alt, chars: "\x1b[1;6S" }
585 - { key: F5, mods: Alt, chars: "\x1b[15;6~" }
586 - { key: F6, mods: Alt, chars: "\x1b[17;6~" }
587 - { key: F7, mods: Alt, chars: "\x1b[18;6~" }
588 - { key: F8, mods: Alt, chars: "\x1b[19;6~" }
589 - { key: F9, mods: Alt, chars: "\x1b[20;6~" }
590 - { key: F10, mods: Alt, chars: "\x1b[21;6~" }
591 - { key: F11, mods: Alt, chars: "\x1b[23;6~" }
592 - { key: F12, mods: Alt, chars: "\x1b[24;6~" }
593 - { key: F1, mods: Super, chars: "\x1b[1;3P" }
594 - { key: F2, mods: Super, chars: "\x1b[1;3Q" }
595 - { key: F3, mods: Super, chars: "\x1b[1;3R" }
596 - { key: F4, mods: Super, chars: "\x1b[1;3S" }
597 - { key: F5, mods: Super, chars: "\x1b[15;3~" }
598 - { key: F6, mods: Super, chars: "\x1b[17;3~" }
599 - { key: F7, mods: Super, chars: "\x1b[18;3~" }
600 - { key: F8, mods: Super, chars: "\x1b[19;3~" }
601 - { key: F9, mods: Super, chars: "\x1b[20;3~" }
602 - { key: F10, mods: Super, chars: "\x1b[21;3~" }
603 - { key: F11, mods: Super, chars: "\x1b[23;3~" }
604 - { key: F12, mods: Super, chars: "\x1b[24;3~" }
605 - { key: NumpadEnter, chars: "\n" }