diff options
author | Hsieh Chin Fan <pham@topo.tw> | 2023-05-25 12:34:25 +0800 |
---|---|---|
committer | Hsieh Chin Fan <pham@topo.tw> | 2023-05-25 12:34:25 +0800 |
commit | aa4f32a2eec77e95f53788de010c2c74ac050ea8 (patch) | |
tree | f01e5b392fae4c2d45a84809464d27835b4c53e5 | |
parent | 97680e698f4f977119b46cd97dd21898214e52d5 (diff) |
Update
-rw-r--r-- | X11/alacritty/alacritty.yml | 20 | ||||
-rw-r--r-- | bin/gpt/shellrc | 5 |
2 files changed, 25 insertions, 0 deletions
diff --git a/X11/alacritty/alacritty.yml b/X11/alacritty/alacritty.yml index 899453b..869ec11 100644 --- a/X11/alacritty/alacritty.yml +++ b/X11/alacritty/alacritty.yml | |||
@@ -50,3 +50,23 @@ live_config_reload: true | |||
50 | key_bindings: | 50 | key_bindings: |
51 | - { key: W, mods: None, action: SemanticRight, mode: Vi } | 51 | - { key: W, mods: None, action: SemanticRight, mode: Vi } |
52 | - { key: B, mods: None, action: SemanticLeft, mode: Vi } | 52 | - { key: B, mods: None, action: SemanticLeft, mode: Vi } |
53 | |||
54 | hints: | ||
55 | enabled: | ||
56 | - regex: "(ipfs:|ipns:|magnet:|mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)\ | ||
57 | [^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+" | ||
58 | hyperlinks: true | ||
59 | command: xdg-open | ||
60 | post_processing: true | ||
61 | mouse: | ||
62 | enabled: true | ||
63 | mods: None | ||
64 | binding: | ||
65 | key: U | ||
66 | mods: Control|Shift | ||
67 | - regex: "([-0-9\u0040-\u005A\u0061-\u007A]{4,})" | ||
68 | action: Copy | ||
69 | post_processing: true | ||
70 | binding: | ||
71 | key: I | ||
72 | mods: Control|Shift | ||
diff --git a/bin/gpt/shellrc b/bin/gpt/shellrc index 1cdbce9..eeeec5d 100644 --- a/bin/gpt/shellrc +++ b/bin/gpt/shellrc | |||
@@ -1,3 +1,8 @@ | |||
1 | # Use vim to handle input | ||
2 | gptt() { | ||
3 | file=`mktemp` | ||
4 | vim $file && cat $file | gpt --skip | ||
5 | } | ||
1 | # Ask GPT what's wrong with the last command | 6 | # Ask GPT what's wrong with the last command |
2 | h() { | 7 | h() { |
3 | printf '%s\n\n%s' "$(fc -s 2>&1 >/dev/null)" "Tell me what's wrong with the command above" | \ | 8 | printf '%s\n\n%s' "$(fc -s 2>&1 >/dev/null)" "Tell me what's wrong with the command above" | \ |