Browse Source

herb-lsp

main
pvincent 2 weeks ago
parent
commit
edc9f3f94f
  1. 5
      install.sh
  2. 6
      src/template.rb

5
install.sh

@ -23,12 +23,15 @@ function install_ruby {
if ! command -v ruby >/dev/null; then
ruby_version=$(wget_semver github jdx/ruby)
mise use --global ruby@${ruby_version}
chmod u+w -R $HOME/.local/share/mise/installs/ruby
tee $HOME/.gemrc &>/dev/null <<EOF
# Skip documentation generation
install: --no-document
update: --no-document
EOF
# fix the gem update --system permission denied!
chmod u+w -R $HOME/.local/share/mise/installs/ruby
mise exec -- gem update --system
else
echo 'ruby already installed!'

6
src/template.rb

@ -41,7 +41,6 @@ inside '.vscode' do
file "extensions.json", <<-CODE
{
"recommendations": [
"aliariff.vscode-erb-beautify",
"aki77.rails-db-schema",
"bierner.markdown-mermaid",
"bpruitt-goddard.mermaid-markdown-syntax-highlighting",
@ -53,7 +52,7 @@ inside '.vscode' do
"waderyan.gitblame",
"yzhang.markdown-all-in-one",
"etsi0.class-collapse",
# "marcoroth.herb-lsp",
"marcoroth.herb-lsp",
"marcoroth.turbo-lsp",
"marcoroth.stimulus-lsp",
"joseph-ravenwolfe.kubernetes-yaml-formatter",
@ -78,7 +77,7 @@ CODE
"editor.formatOnType": true // Enable formatting while typing
},
"[erb]": {
"editor.defaultFormatter": "aliariff.vscode-erb-beautify",
"editor.defaultFormatter": "marcoroth.herb-lsp",
},
"debug.internalConsoleOptions": "neverOpen",
"editor.formatOnSave": true,
@ -116,6 +115,7 @@ CODE
"class-collapse.style.placeholderText": "",
"class-collapse.style.openCollapseOpacity": 0.7,
"class-collapse.style.placeholderTextColor": "#FFFF0055",
"languageServerHerb.formatter.enabled": true,
}
CODE

Loading…
Cancel
Save