[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/haskell-tng-mode fe9d65d 222/385: helper for yatemplates
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/haskell-tng-mode fe9d65d 222/385: helper for yatemplates |
Date: |
Tue, 5 Oct 2021 23:59:35 -0400 (EDT) |
branch: elpa/haskell-tng-mode
commit fe9d65d7d2d25784132b08af534c5c0a0db3ca17
Author: Tseen She <ts33n.sh3@gmail.com>
Commit: Tseen She <ts33n.sh3@gmail.com>
helper for yatemplates
---
haskell-tng-contrib.el | 19 +++++++++++++++++--
1 file changed, 17 insertions(+), 2 deletions(-)
diff --git a/haskell-tng-contrib.el b/haskell-tng-contrib.el
index 1c9499f..25fa70c 100644
--- a/haskell-tng-contrib.el
+++ b/haskell-tng-contrib.el
@@ -5,8 +5,8 @@
;;; Commentary:
;;
-;; Untested / untestable commands that are either contributed by the community
-;; or require an external process to exist on PATH.
+;; Untested / untestable commands that may require an external process to
exist
+;; on PATH.
;;
;;; Code:
@@ -52,5 +52,20 @@
(re-search-forward (rx point (group (+ (not space))) space))
(kill-new (match-string 1))))
+;;;###autoload
+(defun haskell-tng-filename-to-modulename ()
+ "Infers the ModuleName for the current file based on filesystem layout."
+ (mapconcat
+ 'identity
+ (reverse
+ (seq-take-while
+ (lambda (e) (let (case-fold-search)
+ (string-match-p (rx bos upper) e)))
+ (reverse
+ (split-string
+ (file-name-sans-extension buffer-file-name)
+ "\\/"))))
+ "."))
+
(provide 'haskell-tng-contrib)
;;; haskell-tng-contrib.el ends here
- [nongnu] elpa/haskell-tng-mode dbcef71 235/385: workaround the env file situation, (continued)
- [nongnu] elpa/haskell-tng-mode dbcef71 235/385: workaround the env file situation, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 5892c04 232/385: small things, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 44dc467 248/385: notes on motivation, contributing and collaboration, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 6f2b5ee 266/385: font lock CPP, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode fdbd0a2 239/385: updates for hsinspect, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode b2e2c3a 293/385: stop stack from being an asshole, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode ee07f6d 172/385: type indentation tests, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 59354b6 198/385: support hanging type alignment, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode a788ab2 209/385: more efficient layout caching, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode f7e8040 213/385: = ends a type sig, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode fe9d65d 222/385: helper for yatemplates,
ELPA Syncer <=
- [nongnu] elpa/haskell-tng-mode bc93c3d 224/385: very alpha hsinspect support, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 658ddb6 251/385: docs, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 73a60f5 309/385: cache `which hsinspect` per project, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 5707166 365/385: use new ghcflags-provided PATH, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode b1c664b 364/385: allow hsinspect population in the background, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode ce17d96 376/385: new hsinspect release, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode eb6b487 357/385: test fqn-at-point and fix a longstanding bug, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 103e758 325/385: expose some more hsinspect-0.0.8 index info, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode 374835c 355/385: a test for interactive commands, ELPA Syncer, 2021/10/06
- [nongnu] elpa/haskell-tng-mode e3c6dc6 336/385: follow re-exports, ELPA Syncer, 2021/10/06