1 ;;; flycheck-kotlin.el --- Support kotlin in flycheck
3 ;; Copyright (C) 2017 Elric Milon <whirm@__REMOVETHIS__gmx.com>
5 ;; Author: Elric Milon <whirm_REMOVETHIS__@gmx.com>
6 ;; Created: 20 January 2017
8 ;; Package-Version: 20170122.1137
9 ;; Package-Requires: ((flycheck "0.18"))
13 ;; This package adds support for kotlin to flycheck. To use it, add
16 ;; (require 'flycheck-kotlin)
17 ;; (add-hook 'kotlin-mode-hook 'flycheck-mode)
21 ;; This file is not part of GNU Emacs.
22 ;; However, it is distributed under the same license.
24 ;; GNU Emacs is free software; you can redistribute it and/or modify
25 ;; it under the terms of the GNU General Public License as published by
26 ;; the Free Software Foundation; either version 3, or (at your option)
29 ;; GNU Emacs is distributed in the hope that it will be useful,
30 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
31 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
32 ;; GNU General Public License for more details.
34 ;; You should have received a copy of the GNU General Public License
35 ;; along with GNU Emacs; see the file COPYING. If not, write to the
36 ;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
37 ;; Boston, MA 02110-1301, USA.
42 (flycheck-define-checker kotlin-ktlint
43 "A Kotlin syntax and style checker using the ktlint utility.
44 See URL `https://github.com/shyiko/ktlint'."
45 :command ("ktlint" source-inplace)
47 ((error line-start (file-name) ":" line ":" column ": " (message) line-end))
52 (defun flycheck-kotlin-setup ()
53 "Setup Flycheck for Kotlin."
54 (add-to-list 'flycheck-checkers 'kotlin-ktlint))
56 (provide 'flycheck-kotlin)
57 ;;; flycheck-kotlin.el ends here