Gastove
  • Member for 6 years, 2 months
  • Last seen more than 1 year ago
Warning (yasnippet): modified buffer in a backquote expression
Accepted answer
13 votes

warning-suppress-types is a list defined in the warnings package. You first need to load this package with: (require 'warnings) and after this, add the warning using add-to-list: (add-to-list '...

View answer
How to never have a major mode enabled automatically
Accepted answer
10 votes

Emacs keeps a list of regexp-mode pairs in an alist called auto-mode-alist. Any file you open has it's name matched against the nodes in the alist; every match activates a mode. So, what you want to ...

View answer
Should I have removed `(shell . t)` to clear an ob-shell initialization error?
7 votes

Did you successfully fix the problem? Sure! ob-shell was flipping out and you stopped loading it. That is, in some sense, a fix! That said: the chunk of code you found and commented out controls ...

View answer
Workspace configuration
6 votes

I use a combination of two different tools for project management:projectile, for switching between projects, and perspective, for managing frames within a given project. (The two also integrate well, ...

View answer
graphing R in org-babel
Accepted answer
6 votes

You're very close! Two changes: For the R code, you'll need a few more headers: #+BEGIN_SRC R :results output graphics :file test.png library("ggplot2") ggplot(iris, aes(x = Sepal.Width, y = ...

View answer
Wrong type argument: stringp, nil
5 votes

@Dan's comment is quite correct: you don't need to be quoting inside your let form, and also, you can't access let-bound variables outside the scope of the let form. (You might notice that Emacs lisp ...

View answer
Python in org babel will not work
Accepted answer
5 votes

Ah. It's entirely possible python is actually working; depending on exactly how you've set up your python src blocks in Org, you may simply not be getting any results. You may know this already, but ...

View answer
How do I get an expanded sparse tree?
Accepted answer
5 votes

You need to modify the variable, org-show-context-detail. C-h v org-show-context-detail will offer you quite a lot of documentation about the values this variable can take; the pertinent information ...

View answer
Auto-complete C/C++ functions
Accepted answer
4 votes

A vanilla company install wont quite get you where you want; you'll need to use use something like the company-c-headers package. Tuhdo has written an excellent document on using Emacs as a C/C++ IDE, ...

View answer
change colors of already opened links
3 votes

This is literally possible, but it isn't provided for by Org itself -- you'll have to do it manually. It will be a bit complex; I can tell you where the pieces are, but you'll need to figure out how ...

View answer
Make multiple lines TODOs at once in org mode
Accepted answer
3 votes

You can achieve this, with a caveat, by defining your own org function. Something like so: (defun my/mark-todo-in-region () (interactive) (let ((scope (if mark-active 'region 'tree)) (...

View answer
two different config files for Emacs
3 votes

You can achieve this "fast load, slow load" using the server/client functionality of emacs, which works like this: Emacs can be started as a server. This can either be done as a stand-alone, running ...

View answer
org-capture + mu4e failures
Accepted answer
3 votes

To my overwhelming exasperation, the problem has turned out to be: emoji-cheat-sheet-plus-display-mode, and the order in which it was activated in org mode. I had a hook like so: (defun text-...

View answer
Function to restart python console
3 votes

If you're using ipython, why not just use the baked-in %reset magic command? You can also use: %load_ext autoreload %autoreload To automatically reload imported modules on change.

View answer
Set flycheck-compile command
Accepted answer
2 votes

The basic mechanism you're looking for is to add a hook; if you aren't familiar, hooks are an emacs mechanism that causes a specific function to be called at a particular time. For instance, go-mode-...

View answer
ffap.el currently ignores file path with whitespace. How can I change this behaviour?
2 votes

There are very good odds that ffap is already doing something like what you'd like, but it's hidden from you. Try calling ffap on one of your filepaths; when it offers you only a partial result, hit C-...

View answer
Under org mode, Save section of file to another file
2 votes

You can achieve this, at least most of the ways, using Org's export functionality. By default, the Org export dispatcher is bound to C-c C-e; hitting that will allow you to select "export as org," to ...

View answer
In org-mode, a function to export to HTML file AND open?
2 votes

I don't think there's a direct function for this, but you could achieve what you want using org-export-to-file, the last argument of which is a "post-processing" step: (org-export-to-file BACKEND ...

View answer
Shifting Emacs Theme from one Computer to Another
2 votes

Sounds to me like your theme isn't being loaded at first. Let me explain. For Emacs to be able to use the code in a file, two things need to be true: Emacs needs to be able to find it; it must be ...

View answer
python process failed to load environment variables in OSX
2 votes

Under OSX, Emacs itself wont, by default, load the same environment as your user unless you either: Start emacs from the shell (in terminal or gui mode) Use the exec-path-from-shell package, here ...

View answer
loading tramp overrides tramp-remote-path customization back to default value
2 votes

Fascinating. I can exactly reproduce what you're running in to if I try to use the customization interface. However! I can successfully change the value of tramp-remote-path by skipping the ...

View answer
How can I setup the tab indentation size for ***-mode (Rust, Python, Ruby, etc)?
2 votes

In general, you can do something like this: (add-hook '<foo>-mode-hook (lambda () (setq tab-width 4))) If you have a single global default you prefer: (setq-default tab-width <number you ...

View answer
use-package and js2-mode: setting fill-column
Accepted answer
2 votes

fill-column immediately becomes buffer-local when set. So, when your config is evaluated, that buffer's fill-column is set... but then nothing else happens. If you set it with a hook, then fill-column ...

View answer
View for version control (git) status with full file names
Accepted answer
2 votes

If you're open to a new tool, Magit has this baked in. If you invoke magit-status while visiting a file that's part of a git repo, Magit's default view will show you the path from the project root of ...

View answer
Diminish org-indent-mode
1 votes

You're very close! add-hook expects that you're going to add a function to a hook, not the evaluation of an expression. You just need to wrap your call to diminish in a lambda, like this: (add-hook '...

View answer
How to automatically install Auctex if certain package is unable to be activated on startup?
1 votes

If you're open to a sliiiightly different approach, may I heartily recommend use-package? Rather than "attempt to use, check for error, install if error," use-package will, on first install, check if ...

View answer
Magit - "user" in Branch / Create from Pull Request
1 votes

I think you are probably just fine, and don't need to worry much about "undoing" anything. Forgive me if some or all of this is review, but here's what I think is happening for you: A "pull request" ...

View answer
Offlineimap, updates email, is not working with Emacs
1 votes

command not found: offlineimap is a weird hint, but a better one than you might expect. Emacs doesn't always have the PATH you might expect; there's a very good package designed precisely to help with ...

View answer
How can I start a server in the background from a source code block without freezing emacs?
1 votes

By default, Org src block evaluation is synchronous -- Emacs will wait for evaluation to finish, potentially forever. However, there are some very nice async functions built in to Emacs Lisp. You ...

View answer
Revert all open buffers (and ignore errors)
1 votes

I'd fix this with a condition-case or ignore-errors (docs here). I don't know exactly what you'll want it to do; if you want to do something with errors, if you can use condition-case to specify the ...

View answer