diff options
-rw-r--r-- | emacs/.emacs.d/init.org | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/emacs/.emacs.d/init.org b/emacs/.emacs.d/init.org index 645bdcd..81cba44 100644 --- a/emacs/.emacs.d/init.org +++ b/emacs/.emacs.d/init.org @@ -570,7 +570,17 @@ ones. (expand-file-name project-dir (ghq--find-root)) arg))) (setq projectile-switch-project-action #'projectile-commander - projectile-completion-system 'ivy))) + projectile-completion-system 'ivy + projectile-create-missing-test-files t) + + (defun ap/projectile-test-suffix (project-type) + (cond + ((member project-type '(node-yarn node-npm)) ".test") + (t (projectile-test-suffix project-type)))) + (setq projectile-test-suffix-function #'ap/projectile-test-suffix) + + (projectile-register-project-type 'node-yarn '("yarn.lock") "yarn start" "yarn test") + (projectile-register-project-type 'node '("package.json") "npm start" "npm test"))) (use-package counsel-projectile :after (counsel projectile) |