Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Signal an error if reading a recipe causes an error

Without this, a parse error in a recipe will cause (el-get ...) to
die with a less than helpful message.
  • Loading branch information...
commit 6063f379b7fdef713c3d9eacff16e3cff6a74ce5 1 parent 8e85266
Kyle Hargraves pd authored

Showing 1 changed file with 6 additions and 3 deletions. Show diff stats Hide diff stats

  1. +6 3 el-get-recipes.el
9 el-get-recipes.el
@@ -70,9 +70,12 @@ Used to avoid errors when exploring the path for recipes"
70 70 ;;
71 71 (defun el-get-read-recipe-file (filename)
72 72 "Read given filename and return its content (a valid form is expected)"
73   - (with-temp-buffer
74   - (insert-file-contents-literally filename)
75   - (read (current-buffer))))
  73 + (condition-case err
  74 + (with-temp-buffer
  75 + (insert-file-contents-literally filename)
  76 + (read (current-buffer)))
  77 + ((debug error)
  78 + (error "Error reading recipe %s: %S" filename err))))
76 79
77 80 (defun el-get-recipe-filename (package)
78 81 "Return the name of the file that contains the recipe for PACKAGE, if any."

0 comments on commit 6063f37

Please sign in to comment.
Something went wrong with that request. Please try again.