Compare commits

..

No commits in common. "c021061dc57e73d09d56c58e58b58db6b3879d43" and "4500cf9cb5f5890c94371edef8dab60b3043ea8c" have entirely different histories.

4 changed files with 5 additions and 56 deletions

View File

@ -20,9 +20,6 @@
(defun sp-wrap-single-quote () (defun sp-wrap-single-quote ()
(interactive) (interactive)
(sp-wrap-with-pair "'")) (sp-wrap-with-pair "'"))
(defun sp-wrap-angle-bracket ()
(interactive)
(sp-wrap-with-pair "<"))
(defun sp-after-equals-p (_id action _context) (defun sp-after-equals-p (_id action _context)
(when (memq action '(insert navigate)) (when (memq action '(insert navigate))
(sp--looking-back-p "=>" 2))) (sp--looking-back-p "=>" 2)))
@ -69,8 +66,7 @@
"g[" #'sp-wrap-square "g[" #'sp-wrap-square
"g{" #'sp-wrap-curly "g{" #'sp-wrap-curly
"g\"" #'sp-wrap-double-quote "g\"" #'sp-wrap-double-quote
"g'" #'sp-wrap-single-quote "g'" #'sp-wrap-single-quote))
"g<" #'sp-wrap-angle-bracket))
(use-package evil-smartparens (use-package evil-smartparens
:after (evil smartparens) :after (evil smartparens)

View File

@ -10,6 +10,7 @@
:custom :custom
(prodigy-completion-system 'default) (prodigy-completion-system 'default)
:config :config
(evil-collection-prodigy-setup)) (evil-collection-prodigy-setup)
(general-def 'normal prodigy-mode-map "`" #'prodigy-display-process-file-or-buffer))
(provide 'init-prodigy) (provide 'init-prodigy)

View File

@ -241,9 +241,6 @@
(list :command-name "install" (list :command-name "install"
:command-line "mvn install" :command-line "mvn install"
:working-dir local-pom-dir) :working-dir local-pom-dir)
(list :command-name "install (skip tests)"
:command-line "mvn install -DskipTests"
:working-dir local-pom-dir)
(list :command-name "deploy" (list :command-name "deploy"
:command-line "mvn deploy" :command-line "mvn deploy"
:working-dir local-pom-dir) :working-dir local-pom-dir)
@ -316,50 +313,6 @@
:command-line "cargo build --release" :command-line "cargo build --release"
:working-dir project-dir))))) :working-dir project-dir)))))
(defun run-command-recipe-rake ()
(when-let* ((rake-dir (or (locate-dominating-file default-directory "Rakefile")
(locate-dominating-file default-directory "Rakefile.rb")))
(cmds (->> (shell-command-to-string "rake -T")
(s-split "\n")
(-map (lambda (s) (s-split-up-to " " s 2)))
(-map (lambda (l) (s-join " " (-take 2 l))))
(-filter (-not 'string-empty-p)))))
(-map (lambda (cmd)
(list :command-name (cadr (s-split " " cmd))
:command-line cmd
:working-dir rake-dir))
cmds)))
(defvar run-command-recipe-scripts--script-dirs '("." "bin" "scripts"))
(defun get-script-run-command (file)
(with-temp-buffer
(insert-file-contents-literally file)
(when-let* ((line (s-trim (thing-at-point 'line t))))
(cadr (s-match (rx "#!" (group (1+ anychar))) line)))))
(defun run-command-recipe-scripts ()
(let* ((root-dir (expand-file-name (or (projectile-project-root) default-directory)))
(shell (or (getenv "SHELL") "/usr/bin/env bash"))
(scripts (-mapcat
(lambda (dir)
(let ((dir (f-join root-dir dir)))
(when (f-dir? dir)
(f-files
dir
(lambda (file)
(or (file-executable-p file)
(get-script-run-command file)))))))
run-command-recipe-scripts--script-dirs)))
(-map
(lambda (file)
(list :command-name (f-relative file root-dir)
:command-line (if (file-executable-p file)
file
(format "%s %s" (get-script-run-command file) file))
:working-dir root-dir))
scripts)))
:general :general
(leader-map "\"" #'run-command) (leader-map "\"" #'run-command)
:custom :custom
@ -379,8 +332,6 @@
run-command-recipe-web-ext run-command-recipe-web-ext
run-command-recipe-pip run-command-recipe-pip
run-command-recipe-maven run-command-recipe-maven
run-command-recipe-cargo run-command-recipe-cargo)))
run-command-recipe-rake
run-command-recipe-scripts)))
(provide 'init-run-command) (provide 'init-run-command)

View File

@ -5,4 +5,5 @@ fi
export PATH="$PATH:/Users/jdormit/.local/bin" export PATH="$PATH:/Users/jdormit/.local/bin"
eval "$(pyenv init --path)" eval "$(pyenv init --path)"
[[ -d "/opt/homebrew/opt/openjdk@17" ]] && export JAVA_HOME="/opt/homebrew/opt/openjdk@17" [[ -d "/opt/homebrew/opt/openjdk@17" ]] && export JAVA_HOME="/opt/homebrew/opt/openjdk@17"
export SYSTEM_VERSION_COMPAT=1
ulimit -n 524288 ulimit -n 524288