Skip to content

gerblesh/modeline.hx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 

Repository files navigation

modeline.hx

Helix Plugin for modeline

Installation

git clone https://github.com/mattwparas/helix.git -b steel-event-system

then build/install the helix fork with:

cargo xtask steel

to install the plugin with forge:

forge pkg install --git https://github.com/gerblesh/modeline.hx.git

add the lines to your scm file to configure the modeline

(require "modeline/modeline.scm")

;; Make sure to put these AFTER your lsp configs in steel so that the document is reloaded with the LSP
;; register the modeline to automatically run on save/open
(modeline-enable)

;; this steel function refreshes the modeline, you can bind a key to call it manually in your helix/init.scm or config.toml
(refresh-modeline)

supports very basic emacs and vim modelines with some caveats:

example modelines:

# vim:ts=4 ft=py
# ex:ts=4:ft=py:et
# -*- mode: py; tab-width: 4; indent-tabs-mode: nil -*-

supported modeline fields:

et, expandtab: use spaces for indent

noet, noexpandtab: use tabs for indent (tab width not supported)

tab-width, ts, tabstop, sw, shiftwidth, sts, softtabstop: tab width (only affects spaces)

language, mode, ft, filetype: language/syntax highlighting, only some filetype aliases are supported and may vary

indent-tabs-mode: can either be nil (spaces) or t (tabs)

About

Helix Plugin for modeline

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages