lang/csharp: add +unity flag

And group shader-mode & +csharp-unity-mode under it.
This commit is contained in:
Henrik Lissner 2018-12-29 00:09:17 -05:00
parent d87fba7944
commit 937252af4e
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
2 changed files with 11 additions and 5 deletions

View file

@ -1,9 +1,5 @@
;;; lang/csharp/config.el -*- lexical-binding: t; -*-
;; `shader-mode' --- unity shaders
(add-to-list 'auto-mode-alist '("\\.shader$" . shader-mode))
(def-package! omnisharp
:hook (csharp-mode . omnisharp-mode)
:commands omnisharp-install-server
@ -51,3 +47,12 @@
"r" (λ! (omnisharp-unit-test "fixture"))
"s" (λ! (omnisharp-unit-test "single"))
"a" (λ! (omnisharp-unit-test "all")))))
(when (featurep! +unity)
;; `shader-mode' --- unity shaders
(add-to-list 'auto-mode-alist '("\\.shader$" . shader-mode))
(def-project-mode! +csharp-unity-mode
:modes (csharp-mode shader-mode)
:files (and "Assets" "Library/MonoManager.asset" "Library/ScriptMapper")))

View file

@ -3,5 +3,6 @@
(package! csharp-mode)
(package! omnisharp)
(package! shader-mode)
(when (featurep! +unity)
(package! shader-mode))