Skip to content

Commit

Permalink
Use our own hydra fork, for now
Browse files Browse the repository at this point in the history
  • Loading branch information
ubolonton committed May 24, 2019
1 parent 9c487e7 commit e9b6838
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 2 deletions.
6 changes: 5 additions & 1 deletion init.el
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@

(setq custom-file "~/.emacs.d/custom.el")

(add-to-list 'load-path "~/.emacs.d/lib")

(defvar ublt/packages
'(use-package))

Expand Down Expand Up @@ -60,10 +62,12 @@
;; TODO: Remove this once https://github.com/raxod502/straight.el/issues/377 is fixed.
(define-advice straight-use-package
(:around (orig package &rest args) ignore-loaded)
(if (featurep package)
(if (and (symbolp package) (featurep package))
t
(apply orig package args)))

(require 'ublt-straight-recipes)

(straight-use-package 'use-package)
;; We don't want to declare a package twice.
(setq straight-use-package-by-default t)
Expand Down
29 changes: 29 additions & 0 deletions lib/ublt-straight-recipes.el
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
(require 'straight)

(eval-and-compile
(require 'cl-lib))

(defun ublt/straight-recipe (name &rest plist)
(declare (indent 1))
(let ((recipe (cl-copy-list (cdr (straight-recipes-retrieve name)))))
(cl-loop for (key value) on plist by #'cddr
do (plist-put recipe key value))
(cons name recipe)))

(defun ublt/straight-override (name &rest plist)
(declare (indent 1))
(straight-override-recipe (apply #'ublt/straight-recipe name plist)))

(cl-defun ublt/-fork (name &key branch)
`(:repo ,(format "github:ubolonton/%s" name)
:host nil ; XXX: Otherwise straight tries to construct https URL.
:remote "ubolonton"
:branch ,branch))

(ublt/straight-override 'lv
:fork (ublt/-fork "hydra" :branch "delayed-hiding"))

(ublt/straight-override 'hydra
:fork (ublt/-fork "hydra" :branch "delayed-hiding"))

(provide 'ublt-straight-recipes)
2 changes: 1 addition & 1 deletion straight/versions/default.el
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
("highlight-symbol.el" . "7a789c779648c55b16e43278e51be5898c121b3a")
("hl-todo" . "487d349b7b8d6738223d5dd10957dd10b45eb9f3")
("ht.el" . "095fde55294bd20dc7f46d614e1b0504e3830cfa")
("hydra" . "406988f6e94a6844b38594f8e7b8fb7f98c89710")
("hydra" . "e3051ff4c917c5866c769d62fe1ca22beab7cb63")
("inf-mongo" . "2e498d1c88bd1904eeec18ed06b1a0cf8bdc2a92")
("info-colors" . "a8ebb7b8efa314c08ea8110d8b1876afb562bb45")
("js2-mode" . "ae9fea81cf9ed80f403c161fde4d8aff1ceb3769")
Expand Down

0 comments on commit e9b6838

Please sign in to comment.