diff options
author | Alan Pearce | 2017-01-27 16:02:51 +0100 |
---|---|---|
committer | Alan Pearce | 2017-01-27 16:02:51 +0100 |
commit | 8c8d10f5f0529d0b650b0b2006855972a8fa2acc (patch) | |
tree | 5bacf3fdfa6fb9c9127cd0555f1e1c4e9d279600 /tag-emacs | |
parent | c090565b332d5ec6a90ef1a35f953979edd09f32 (diff) | |
download | nixfiles-8c8d10f5f0529d0b650b0b2006855972a8fa2acc.tar.lz nixfiles-8c8d10f5f0529d0b650b0b2006855972a8fa2acc.tar.zst nixfiles-8c8d10f5f0529d0b650b0b2006855972a8fa2acc.zip |
Emacs: Add commands for yarn add {,--dev}
Diffstat (limited to 'tag-emacs')
-rw-r--r-- | tag-emacs/emacs.d/init.org | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tag-emacs/emacs.d/init.org b/tag-emacs/emacs.d/init.org index cbe5d911..ba739581 100644 --- a/tag-emacs/emacs.d/init.org +++ b/tag-emacs/emacs.d/init.org @@ -439,6 +439,16 @@ based upon some folder conventions I use. (projectile-with-default-dir (projectile-project-root) (cmd-to-echo "yarn" "install"))) + (defun yarn-add-dev (package) + (interactive "spackage: ") + (projectile-with-default-dir (projectile-project-root) + (cmd-to-echo "yarn" (concat "add --dev " package)))) + + (defun yarn-add (package) + (interactive "spackage: ") + (projectile-with-default-dir (projectile-project-root) + (cmd-to-echo "yarn" (concat "add " package)))) + (defun ap/open-work-project (&optional arg) (interactive "P") (ap/open-subfolder-project work-project-directory arg)) |