From 4ce86b06d480383edcf19f1ca29ad75286bfaf0b Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Tue, 3 Sep 2019 00:45:32 -0400 Subject: [PATCH] Use more ambiguous reset target when normalizing repos Possibly addresses "ambiguous target" errors during 'doom update'. Might address #1738 and #1721 --- core/cli/packages.el | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/core/cli/packages.el b/core/cli/packages.el index 49c8d7de8..2483f8b2b 100644 --- a/core/cli/packages.el +++ b/core/cli/packages.el @@ -147,12 +147,11 @@ a list of packages that will be installed." (condition-case e (let (packages errors) (load ,(concat doom-core-dir "core.el")) - (doom-initialize 'force-p) + (doom-initialize 'force) (dolist (recipe ',group) (when (straight--repository-is-available-p recipe) (straight-vc-git--destructure recipe - (package local-repo nonrecursive upstream-remote upstream-repo upstream-host - branch remote) + (package local-repo nonrecursive upstream-remote upstream-repo upstream-host branch) (condition-case e (let ((default-directory (straight--repos-dir local-repo))) ;; HACK We normalize packages to avoid certain scenarios @@ -162,7 +161,7 @@ a list of packages that will be installed." ;; can't use `straight-normalize-package' because could ;; create popup prompts too, so we do it manually: (shell-command-to-string "git merge --abort") - (straight--get-call "git" "reset" "--hard" (format "%s/%s" remote branch)) + (straight--get-call "git" "reset" "--hard" branch) (straight--get-call "git" "clean" "-ffd") (unless nonrecursive (shell-command-to-string "git submodule update --init --recursive"))