76 Commits

Author SHA1 Message Date
Lucas Werkmeister
e97f78ee11 Add %S, %C, %L specifiers
These specifiers for the state, cache, and log directory root were added in systemd v236.
2018-04-14 14:11:36 -04:00
Mark Oteiza
228f0b99ca happy new year 2018-01-01 21:03:40 -05:00
Mark Oteiza
1e7567a997 prepare v1.6 2017-09-18 20:49:18 -04:00
Mark Oteiza
23c0caf214 extend anchored matches past the current line if \ broken 2017-09-18 07:46:09 -04:00
Mark Oteiza
839094df0e use rx here 2017-09-17 15:37:16 -04:00
Mark Oteiza
47ae79aed0 Use syntax-propertize and font-lock-extend-region-functions 2017-09-17 14:50:12 -04:00
Mark Oteiza
a3d39214b7 extend multi-line matching to sections and keys 2017-09-11 09:25:09 -04:00
Mark Oteiza
5c9389dae3 move this matcher down with the other ones 2017-09-07 22:04:50 -04:00
Mark Oteiza
b0c1d64d62 add multi-line comment highlighting
between font-lock-keywords, the elisp manual, examples in the emacs
source (sh-mode is one) and the webernets, it is rather difficult to
find a way to properly deal with multi-line construct syntax
highlighting.  this is a way leveraging anchored matching and
jit-lock.
2017-09-07 22:03:17 -04:00
Mark Oteiza
3ff4f0f706 anchor some matchers to follow "=" 2017-09-07 21:59:33 -04:00
Mark Oteiza
a4f409641a moar keywords 2017-09-07 21:57:46 -04:00
Mark Oteiza
995ebbe3d5 add conventional environment variable highlighting 2017-09-03 04:33:37 -04:00
Mark Oteiza
4c0ec1e599 split font-lock-keywords into levels
more importantly, bind systemd-font-lock-keywords to a _symbol_.
this makes hacking font-lock-keywords on the fly a little easier, in
addition to adding to customization/granularity
(info "(elisp) Font Lock Basics")
2017-09-03 04:29:03 -04:00
Mark Oteiza
7bb8f0969d correct syntax? 2017-09-03 03:39:52 -04:00
Mark Oteiza
9cfd315337 simplify 2017-07-08 18:34:46 -04:00
Mark Oteiza
28601d814f woops 2017-07-08 18:02:26 -04:00
Mark Oteiza
930e82e5fe font lock additional exec prefix 2017-07-07 21:33:41 -04:00
Mark Oteiza
4c1b2befd0 bump 2017-02-02 21:44:22 -05:00
Mark Oteiza
59ce8ad415 simpler while test 2017-02-02 21:43:08 -05:00
Mark Oteiza
bd94a2cb97 shim in support for nspawn settings files 2017-01-22 20:45:01 -05:00
Mark Oteiza
b561c6bce9 happy new year 2017-01-01 00:03:40 -05:00
Mark Oteiza
fa1277d1cd add reminder
The new regex is not too hard to generate with some set/combinatorics
fun, but perhaps going about this a different way would be better

  (let ((s (delq nil (powerset '("@" "-" "+")))))
    (concat "="
     (regexp-opt
      (mapcar (lambda (ls) (apply #'concat ls))
              (apply #'append (mapcar #'permutations s)))
     "\\(?1:")))
2016-12-02 01:17:46 -05:00
Mark Oteiza
7874a102a5 future flycheck has a checker for units 2016-12-02 01:14:39 -05:00
Mark Oteiza
0a4b6c49d3 shrug 2016-12-02 01:14:06 -05:00
Mark Oteiza
bf7b281cdb nix unneeded arg 2016-12-02 01:11:04 -05:00
Mark Oteiza
7769000ba6 bump to 0.4.1 2016-09-28 22:56:56 -04:00
Mark Oteiza
a73c16aac0 nix LOCAL argument for adding to company-backends 2016-09-27 12:11:38 -04:00
Mark Oteiza
16be18350c don't indiscriminately use relative file name 2016-09-27 12:07:08 -04:00
Mark Oteiza
0e793b05e2 put the quotes back. faces are symbols
font-lock.el is an exception wrt defvar'ing faces, not the rule
2016-06-28 23:48:17 -04:00
Mark Oteiza
b03e616f0d bump 2016-05-14 10:15:10 -04:00
Mark Oteiza
fe443ac8ca use font-lock-defaults to disable syntax highlighting 2016-05-12 20:25:07 -04:00
Mark Oteiza
378eb3642c nix some quotes. use some rx 2016-05-10 01:09:31 -04:00
Mark Oteiza
63d64ad4e6 generate directive lists from files 2016-05-07 15:49:25 -04:00
Mark Oteiza
f74f3c8520 add to buffer-local hooks 2016-05-02 13:36:10 -04:00
Mark Oteiza
921f8d0df8 nix systemd-use-company-p 2016-05-02 13:12:02 -04:00
Mark Oteiza
ff523bc3da woops 2016-05-01 15:18:56 -04:00
Mark Oteiza
6fd29c5c85 font lock keywords: comments and sections
* let comments be prefixed with whitespace
* match ignored "X-" section headers
2016-05-01 13:58:47 -04:00
Mark Oteiza
5cb70eb684 change dropin filename restrictions
* do not match in .d/ subdirectories
* there are no restrictions on dropin config file base names
2016-05-01 13:06:14 -04:00
Mark Oteiza
b004b3725a autoload sorcery 2016-05-01 13:05:08 -04:00
Mark Oteiza
f3066147a1 dang spaces 2016-05-01 00:40:10 -04:00
Mark Oteiza
cd22a2c250 use a-zA-Z0-9
the alphanum class matches multibyte characters, and matching only
alphanumeric ASCII is what is desired here
2016-04-30 22:15:24 -04:00
Mark Oteiza
4121a9a37b section names can be prefixed with X- 2016-04-30 18:07:27 -04:00
Mark Oteiza
a434645e76 improvements to autoload regexen
many thanks to @Lompik
* don't match empty unit names. AIUI unit names are alphanumeric with
  the exception of the group [-_.@], non ascii are backslash-escaped.
* more strictly match temp file names: .# prefix, [[:hexdigit:]]{16}
  suffix. the filenames are a unit name with a unit suffix (systemctl
  edit --full) or just override.conf (edit without --full option)
* add regex for dropin config files. This is just a file with ".conf"
  extension, with the added constraint that it's a file having some
  parent directory named "systemd"
2016-04-30 17:56:25 -04:00
Mark Oteiza
bf39be20e4 assimilate systemd-company.el into systemd.el
hopefully didn't break everything \o/
* eventual goal is to have the large lists generated at byte compile
  time from the text files now present in the repo.  updating the lists
  in lisp is very annoying
* capf completion now exists and draws from the same infrastructure
* added capability to add a "=" after company completion of a directive
* systemd-use-company-p still works, but does not need to exist
2016-04-30 00:09:57 -04:00
Mark Oteiza
9fc054586d move systemd-font-lock-keywords 2016-04-29 12:40:17 -04:00
Mark Oteiza
070e15e4c0 autoload temp files generated by sd's tempfn_random
* adds 16 random hex digits to the end of file name
* instead of a bunch of autoloads, draw regexp into a pair of defconst
* not sure how to splice a reusable list of extensions into an rx call,
  which would be nicer than duplicating it
2016-04-29 10:20:50 -04:00
Mark Oteiza
dbf78305d4 happy new year 2016-01-01 02:34:11 -05:00
Mark Oteiza
26de1dd6f4 don't turn on company by default 2015-11-28 00:32:24 -05:00
Mark Oteiza
aa9f4f64e9 update commentary 2015-09-28 09:09:41 -04:00
Mark Oteiza
0f2f9361e4 clarify parent mode hooks 2015-09-28 08:19:12 -04:00