{"id":250,"date":"2013-02-05T17:26:25","date_gmt":"2013-02-05T17:26:25","guid":{"rendered":"http:\/\/mediacrash.com\/blog\/?p=250"},"modified":"2013-02-05T17:26:25","modified_gmt":"2013-02-05T17:26:25","slug":"mediacrash-emacs-stories-part-two","status":"publish","type":"post","link":"https:\/\/mediacrash.com\/blog\/?p=250","title":{"rendered":"MediaCrash &#038; Emacs Stories, Part Two"},"content":{"rendered":"<p><a href=\"https:\/\/mediacrash.com\/blog\/wp-content\/uploads\/2013\/02\/emacs_legendary.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignleft  wp-image-252\" style=\"margin: 4px 8px;\" alt=\"emacs_legendary\" src=\"https:\/\/mediacrash.com\/blog\/wp-content\/uploads\/2013\/02\/emacs_legendary.png\" width=\"176\" height=\"176\" srcset=\"https:\/\/mediacrash.com\/blog\/wp-content\/uploads\/2013\/02\/emacs_legendary.png 220w, https:\/\/mediacrash.com\/blog\/wp-content\/uploads\/2013\/02\/emacs_legendary-150x150.png 150w\" sizes=\"auto, (max-width: 176px) 100vw, 176px\" \/><\/a>I love Emacs. I use it every day for programming, writing, schoolwork, web stuff, email, news, listening to music, whatever. Sometimes I have to use different Emacs on remote machines and I have to revert to the default setup (tramp mitigates this somewhat). This means that I have to go back to that horrible (or wonderful I guess) day that I started Emacs for the first time and struggled like a bitch just to navigate the info page.<\/p>\n<p>In order to avoid that, I often place a stripped down copy of my .emacs on each machine so that the bare minimum of my customizations are available (I actually used to carry around a basic .emacs on a USB stick). But when you do this, you sometimes end up with a .emacs that won&#8217;t load correctly because things are in the wrong location or not present on the current machine.<\/p>\n<p>So, I was doing this the other day and I learned a command that I should have known since the beginning but it was one that I seemed to have missed. &#8220;<code>M-x toggle-debug-on-error<\/code>&#8220;! Basically drops you into the elisp debugger whenever something is fubar, giving you a complete stack trace of the error. Perfect.<\/p>\n<p>There are other ways to set debug flags directly in the .emacs file itself like adding:<\/p>\n<p><code>(setq debug-on-error t)<\/code><\/p>\n<p>Or you can start Emacs with the <code>--debug-init<\/code> flag (this one I already knew)<\/p>\n<p>Now, it only takes me a few minutes to figure out the exact source of the trouble. Doh!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I love Emacs. I use it every day for programming, writing, schoolwork, web stuff, email, news, listening to music, whatever. Sometimes I have to use different Emacs on remote machines and I have to revert to the default setup (tramp mitigates this somewhat). This means that I have to go back to that horrible (or [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[4],"class_list":["post-250","post","type-post","status-publish","format-standard","hentry","category-programming","tag-emacs"],"share_on_mastodon":{"url":"","error":""},"_links":{"self":[{"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/250","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=250"}],"version-history":[{"count":8,"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/250\/revisions"}],"predecessor-version":[{"id":259,"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/250\/revisions\/259"}],"wp:attachment":[{"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=250"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=250"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mediacrash.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=250"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}