Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [init-file]

for questions about initialization files `.emacs` or `init.el. DO NOT USE this tag if you assume answers require tweaking initialization files because many solutions do not involve directly manipulating initialization files.

1
vote
1answer
118 views

My emacs installation does not initialise

I don't know what happened but now I cannot initialise my emacs installation. emacs --debug-init gives this answer: Debugger entered--Lisp error: (error "Unable to activate package ‘org-ac’. Required ...
1
vote
3answers
104 views

Putting emacs .org file options in .emacs file

I use a template for my work. It contains following options. Can I put those in .emacs file. #+OPTIONS: num:nil; p:t #+OPTIONS: toc:nil #+LATEXCLASS_OPTIONS: {10pt} #+LATEX_HEADER: \...
2
votes
1answer
171 views

Customize Xah Fly Keys

I am using Xah Fly Keys. How should I change the function one of Xah Fly Keys key bindings calls? For example when in Xah Fly Keys command mode space c . calls the find-file function but I would ...
1
vote
1answer
87 views

Verifying behaviour of featurep when checking if a package is installed

;; Install package.el for package management (require 'package) (setq package-enable-at-startup nil) (add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/") t) (add-to-list 'package-...
0
votes
1answer
186 views

default directory is not working in Windows [duplicate]

I am trying to set the default directory to D:/ by (setq default-directory "D:/") but when I type c-x c-f, it is showing D:\software\emacs\bin, which is the installation directory.
0
votes
1answer
33 views

imenu list automatically toggled in new frame

I tried to run imenu-list-show in hook which is called after frame creation but it doesnt work as expected. It toggled the imenu-list in new frame but my keyboard arrows become unresponsive. Code is: ...
0
votes
0answers
54 views

scroll is undefined

I have a strange problem on emacs (tried 25-27) on Windows 7. Apparently it's some of the modes and plugins. This message keeps popping up (I don't do anything apart from focusing on the emacs window):...
0
votes
0answers
43 views

Initialization Error Right out of the Gate

I'm starting out with emacs on macOS with an eye to setting up a latex editing environment. NB: I'm new to emacs and everything like it -- though from what I've read, nothing comes close to it! For ...
1
vote
1answer
153 views

Running emacs client: how do you know if the init files had errors loading

I use emacs 25, in nw mode, with "alias emacs='emacsclient -nw'" When I add something to my personal.el, I do brew services restart emacs My issue is, if I make a big blunder inside my personal.el ...
1
vote
1answer
119 views

Troubleshooting: changing default folder in .emacs not working

I am trying to make emacs start on the folder where all my orgfiles are saved. I achieved this in my windows machine by changing the "Start In" field of the shortcut properties, as suggested in this ...
0
votes
0answers
127 views

how to use multiple emacs distributions?

I'd like to use multiple emacs distributions e.g. spacemacs, prelude, starter-kit and my personal config for demonstration purposes. What would be some recommended ways to realize this?
0
votes
1answer
82 views

error: Package `xah-fly-keys-' is unavailable

I am setting up a .emacs file that I will be using in Docker containers. I want to include xah-fly-keys but I am getting this error message. Package `xah-fly-keys-' is unavailable When I start ...
0
votes
1answer
62 views

Strange regex behavior

I want to skip blank region under cursor, so I created this regex: \s+\w translated to emacs regex [:space:]+[:graph:] but it doesnt match what I want. It matches some random space somewhere! Whats ...
1
vote
1answer
50 views

Emacs triple click handler

What handler is called when I make triple click ? For me, it select whole line. I want this behavior to be binded to C-l, how to do it ? EDIT: I tried to bind this to key, but not works, how to fix ...
0
votes
1answer
54 views

Ignored keybinding

I have a problem with following key binding: (global-set-key (kbd "C-/") 'comment-or-uncomment-region) Actually, it is ignored by Emacs so undo is executed instead. I'm running Emacs in gui mode.
0
votes
2answers
66 views

how do you turn off smart brackets//parenthesis in prelude

I hate it when prelude auto adds the ending } when I type { (this is ruby mode) This is very common, for example typing ( auto adds a ) This is really annoying when trying to edit code, or a lot of ...
1
vote
0answers
119 views

osx - disable left option/command key, enable right option

I'm learning Emacs. On my Macbook, I have in keyboard settings: Capslock and Ctrl key swapped Option and Command key swapped Emacs commands like ctrl-r, ctrl-s work fine for me (obviously I use them ...
0
votes
2answers
69 views

Evil mode interacting with python.el (invoking skeletons)

Skeletons such as python-skeleton-if in python.el has been giving me problems - I never use them but they get invoked unexpectedly. If they are invoked, it is a pain to get out of it and also it ...
1
vote
1answer
52 views

Load elisp file only when file with specific extension is opened

I've been using SLIME mode with the quicklisp slime helper, and I load the package with the following code (in my .emacs): (load (expand-file-name slime-helper-path)) (setq inferior-lisp-program "...
0
votes
3answers
278 views

How to make Emacs start using the Xetex engine as default

I am using Emacs to edit all the stuff I'm writing. As I make extensive use of fontspec, I would like to configure my Emacs (running within OpenSuse Linux)so as to start using the xetex-engine without ...
0
votes
0answers
106 views

Emacs hung with Error running timer 'blink-cursor-start'

I just installed a fresh Ubuntu 17.10 on a Dell XPS 15, and then installed Emacs from the repos with apt-get in the normal way. The moment I start Emacs, I get the error message Error running timer '...
3
votes
2answers
391 views

Use several Emacs configurations/versions simultaneously

I want to use several emacs configurations/versions simultaneously so that no configuration disturbs each other, each with their own configuration directory and elpa repository. I heard about the ...
0
votes
0answers
125 views

Error in emacs org-mode table: “Match data clobbered by buffer modification hooks”

When I try enter a value within a cell in an org mode table I get the following error: "Match data clobbered by buffer modification hooks" It was suggested that the issue is: It is probably ...
2
votes
1answer
84 views

how to define a yasnippet in init file?

My init file (.emacs) is version-controlled, my packages are installed with use-package, so my Emacs config is self-contained. I don't want to add (and manage) specific snippet files into my ...
0
votes
0answers
44 views

Emacs configurations samples

I am starting over with emacs after a long time and installed GNU OSX (https://emacsformacosx.com/). I was configuring it for key strokes and themes and was wondering if there are samples out there ...
0
votes
0answers
24 views

C-x C-f Edit File As Root [duplicate]

Is there a way to open a local file for editing as a root? I need to make some changes to a config file located at ~/.emacs.d/init.el, but the Emacs tells me that the buffer is read-only.
0
votes
0answers
33 views

frame title as buffer file resets to default after some time

In my ~/.emacs I have the following: (setq frame-title-format '("" invocation-name ": " (:eval (if (buffer-file-name) (abbreviate-file-name (buffer-file-name)) ...
0
votes
0answers
179 views

Error when initializing Emacs

This is what I get when starting Emacs from terminal with emacs --debug-init. I don't know the reason why emacs suddenly started to not working. Debugger entered--Lisp error: (wrong-type-argument ...
3
votes
0answers
119 views

.emacs bankruptcy — how to do it well [closed]

So, at this point my .emacs.d and files with it is older than a lot of people reading this question, and with packages, version changes, packages that have gone obsolete, and so on. It's a mess. It's ...
0
votes
1answer
61 views

Variable user-init-file not found (No Match) when trying to set it, but it's documented and has a value when examined

I'm new to emacs and looking to change my default init file as the current is set to be ~/.emacs and I want it to be ~/.emacs.d/init.el I can clearly C-h v user-init-file to see but but M-x set-...
1
vote
1answer
60 views

Emacs 25 function error

Recently I upgraded my emacs from 24 to 25.3.1. After the upgrade, the following code does not work anymore: ;;================================== ;; Wrap Query Replace ;;====================...
0
votes
1answer
42 views

Modes have no effect unless I deactivate and activate again

I'm extremely new to emacs (started using it yesterday), I use the latest version of emacs. The problem is, The modes I have enabled such as auto-complete-mode and org-bullets-mode seem to be ...
0
votes
0answers
183 views

Emacs: How to open new frame on a second screen in windows

I use two screens and windows 10, and want to open a new emacs frame on the other screen than the one I use. How do I do this? Preferably, I want the new frame made to be maximized in size. I have ...
1
vote
1answer
122 views

Emacs: how to avoid line wrapping in buffer selection window?

I often use my Emacs frame split vertically. This makes a problem when I list my open buffers (C-x C-b). The lines in the displayed buffer-selection list will wrap and the list becomes very untidy ...
3
votes
1answer
61 views

Was Emacs launched with a filename argument?

Suppose I want Emacs to be configured differently depending on whether or not it was launched with a filename as an argument. Is there a way I can deduce this as part of my init file? One way is to ...
0
votes
0answers
109 views

Using hooks to organize configuration

Up to this point, I used to have a separate configuration for each major mode, e.g. init.org.el, init.c++.el etc. I would invoke Emacs using an one of the aliases like these: alias emacs-org='emacs -...
1
vote
0answers
285 views

Init using org-babel-tangle with Emacs Prelude

Trying to convert my personal configuration for Emacs Prelude to use an org-based config. Looked around for a couple of days on this site, github and elsewhere but have not found a way to get org-...
0
votes
1answer
39 views

Strange <left> behaviour

Usually <left> is bound to 'left-char I have never edited this in my init file or <right> for that matter. However recently when I'm at the beggining of a line and I type <left> it ...
1
vote
1answer
710 views

Loading and executing .el file if it exists on startup

I am having trouble telling Emacs to load and evaluate an additional .el file which only contains some lisp code to load an org file ;; keep my personal settings not in the .emacs file ;; http://www....
1
vote
1answer
91 views

customize-face for display-graphic-p only

I run graphical GNU/Emacs on macOS and also emacs in Mac Terminal installed via Homebrew. I would like to customize the default face for only the graphical display. I used M-x customize-face default,...
1
vote
1answer
41 views

Key assignments in init file issue

I am customizing emacs X11 on a Linux box. By default, C-x C-s is bound to save-buffer, and C-x C-s shows as the keyboard shortcut in the File->Save menu. If I put into my .emacs file the following ...
1
vote
2answers
103 views

Is it possible to lazy-load language mode packages?

Most of the packages I currently use are major modes for various languages that are only included in the off-chance I load a file of that type. Is there a way to postpone loading them at startup in ...
4
votes
1answer
152 views

Are there any disadvantages to moving init.el to org-mode?

I've noticed some people have their init files in org-mode, using org-babel-load-file. Are there significant performance penalties or other disadvantages to doing this?
1
vote
1answer
212 views

How to autoload a package without requiring in the init file?

When you install clojure-mode via package-install, you can then open any .clj file and automatically enter the mode. And this works for every subsequent Emacs launch ; Yet, no (require 'clojure-mode) ...
5
votes
0answers
1k views

Best practice for Emacs Helm setup after (use-package) verse [closed]

Just recently discovered use-package (a macro written by John Wiegley) that comes in handy if you want to avoid .emacs bankruptcy declaration and keep things tidy in your configuration dot file. ...
7
votes
1answer
1k views

Emacs setup for LaTeX after (use-package) verse

How to make this configuration file work with use-package with regard to AucTeX, RefTeX and LaTeX. I usually write latex rahter than pure tex documents. Current Working Emacs Configuration (load "...
0
votes
1answer
63 views

Hook that fires any time ANY file is opened?

Is there a hook that gets called any time a file is opened, not a buffer but an actual file?
2
votes
3answers
794 views

Error (initialization): User … has no home directory

I just installed GNU Emacs 23.1.1 on a new machine and copied my ~/.emacs and ~/.emacs.d/ from another machine where I'm running emacs 25.1.1. When I launch emacs it writes Error (initialization): ...
0
votes
1answer
811 views

No Title Bar on Emacs 25 + Mac

I'm running Emacs 25.1 on macOS Sierra. After opening Emacs using the GUI and maximizing its frame, I execute (C-x C-e) the following code: (setq ns-auto-hide-menu-bar t) (set-frame-position nil 0 -...
3
votes
1answer
49 views

Prevent bmkp-last-as-first-bookmark-file from being placed in custom-set-variables

I have the following code to set a custom.el file and load Bookmark+: (setq custom-file (concat elf-emacs-lib-home-directory "emacs-config/" "custom.el")) (when (file-exists-p custom-file) (load ...