mirror of
https://oauth2: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@github.com/m1ngsama/chopsticks.git
synced 2026-05-13 20:41:04 +08:00
Fix opt-in keymap install messaging (#61)
This commit is contained in:
parent
2514d2e803
commit
8e6dcc6e97
2 changed files with 24 additions and 15 deletions
|
|
@ -131,7 +131,7 @@ Esc exit insert mode ,? cheat sheet
|
||||||
|
|
||||||
### Windows
|
### Windows
|
||||||
|
|
||||||
`<C-w>hjkl` navigate | `,z` maximize | `,h` `,l` buffers | `,bd` close buffer | `,=` `,−` resize | `,tv` `,th` terminal | `Esc Esc` exit terminal
|
`<C-w>hjkl` navigate | `,z` maximize | `,h` `,l` buffers | `,bd` close buffer | `,=` `,−` resize | `,tv` `,th` terminal
|
||||||
|
|
||||||
### Markdown
|
### Markdown
|
||||||
|
|
||||||
|
|
|
||||||
11
install.sh
11
install.sh
|
|
@ -1075,6 +1075,9 @@ fi
|
||||||
# ============================================================================
|
# ============================================================================
|
||||||
|
|
||||||
step "LSP language servers"
|
step "LSP language servers"
|
||||||
|
if [[ $CONFIG_PROFILE == "minimal" ]]; then
|
||||||
|
skip "LSP disabled by minimal profile"
|
||||||
|
else
|
||||||
info "vim-lsp installs language servers on demand — no action needed here."
|
info "vim-lsp installs language servers on demand — no action needed here."
|
||||||
info ""
|
info ""
|
||||||
info "To install a server: open a source file in Vim and run:"
|
info "To install a server: open a source file in Vim and run:"
|
||||||
|
|
@ -1083,6 +1086,7 @@ info ""
|
||||||
info "Supported: Python, JS/TS, Go, Rust, C/C++, Shell, HTML, CSS, JSON, YAML, Markdown, SQL"
|
info "Supported: Python, JS/TS, Go, Rust, C/C++, Shell, HTML, CSS, JSON, YAML, Markdown, SQL"
|
||||||
info ""
|
info ""
|
||||||
info "For Markdown LSP (marksman), the installer already handled it above."
|
info "For Markdown LSP (marksman), the installer already handled it above."
|
||||||
|
fi
|
||||||
|
|
||||||
# ============================================================================
|
# ============================================================================
|
||||||
# Summary
|
# Summary
|
||||||
|
|
@ -1122,13 +1126,18 @@ echo -e " ${CYAN}vim .${NC} Open dashboard in current directory"
|
||||||
echo -e " ${CYAN}vim myfile${NC} Edit a specific file"
|
echo -e " ${CYAN}vim myfile${NC} Edit a specific file"
|
||||||
echo ""
|
echo ""
|
||||||
echo -e "${BOLD} First steps inside Vim${NC}"
|
echo -e "${BOLD} First steps inside Vim${NC}"
|
||||||
echo -e " ${CYAN}Esc${NC} or ${CYAN}jk${NC} Exit insert mode → back to Normal"
|
echo -e " ${CYAN}Esc${NC} Exit insert mode → back to Normal"
|
||||||
echo -e " ${CYAN}:q!${NC} + Enter Emergency quit without saving"
|
echo -e " ${CYAN}:q!${NC} + Enter Emergency quit without saving"
|
||||||
echo -e " ${CYAN},x${NC} Save and quit"
|
echo -e " ${CYAN},x${NC} Save and quit"
|
||||||
echo -e " ${CYAN},?${NC} Open cheat sheet"
|
echo -e " ${CYAN},?${NC} Open cheat sheet"
|
||||||
|
if [[ $CONFIG_PROFILE != "minimal" ]]; then
|
||||||
echo -e " ${CYAN}:LspInstallServer${NC} Install LSP for current filetype"
|
echo -e " ${CYAN}:LspInstallServer${NC} Install LSP for current filetype"
|
||||||
|
fi
|
||||||
|
if [[ -f "$LOCAL_CONFIG" ]] && \
|
||||||
|
grep -Eq '^[[:space:]]*let[[:space:]]+g:chopsticks_enable_ctrl_s_save[[:space:]]*=[[:space:]]*1([[:space:]]|$)' "$LOCAL_CONFIG"; then
|
||||||
echo ""
|
echo ""
|
||||||
echo -e "${YELLOW}[!]${NC} Ctrl+s is mapped to save in Vim."
|
echo -e "${YELLOW}[!]${NC} Ctrl+s is mapped to save in Vim."
|
||||||
echo " If it freezes your terminal, add this to ~/.bashrc or ~/.zshrc:"
|
echo " If it freezes your terminal, add this to ~/.bashrc or ~/.zshrc:"
|
||||||
echo -e " ${CYAN}stty -ixon${NC}"
|
echo -e " ${CYAN}stty -ixon${NC}"
|
||||||
|
fi
|
||||||
echo ""
|
echo ""
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue