Episode #125 of the Stack Overflow podcast is here. We talk Tilde Club and mechanical keyboards. Listen now

Questions tagged [start-up]

About starting and initializing an Emacs session

Filter by
Sorted by
Tagged with
3
votes
1answer
218 views

How to improve autoloading of Magit's git-commit-mode and other minor modes

Aim I would like to arrange for Magit's minor mode git-commit-mode to be enabled whenever a relevant Git file (e.g. COMMIT_EDITMSG) is visited, from both within Emacs (e.g. magit-commit) and without (...
2
votes
1answer
65 views

Conditional switch to file on startup

I'm using spacemacs and currently I'm using the following in my user-config to switch to the scratch buffer when emacs starts: (setq inhibit-splash-screen t) (switch-to-buffer "*scratch*") However, ...
2
votes
1answer
989 views

How can the start up log of Spacemac be viewed?

When I start Spacemacs there is a message about some faults on my setup which scroll past quickly before I can view them. Is there some file or some buffer that holds them for review?
0
votes
1answer
73 views

void-variable dired-after-readin-hook in emacs 25

I've get emacs 25 build ppa taken from this ask ubuntu answer and I have this functions and macro: (defun remove-lambda-helper (list matcher) "function that remove lambda from a list if match the ...
4
votes
2answers
1k views

Handle stale desktop lock files after emacs/system crash

If Emacs or the system crashes when desktop-save-mode is active, Emacs leaves a stale desktop lock file. The next time the desktop is loaded (from another Emacs process ID), loading is interrupted ...
4
votes
2answers
391 views

How to re-load a package?

The situation I have is this. First, I run (require 'prolog) ...which loads the system's default version of prolog.el, and makes the variable prolog-mode-version available. It has value "1.22". ...
2
votes
2answers
74 views

Why do symbols become suddenly defined right after startup?

Below is an example of the situation described in the question's title, using the variable prolog-mode-version as test case. If my Emacs init file consists of just the code shown below: (defun show-...
2
votes
3answers
698 views

How to make size of Emacs frame persistent?

When I start Emacs (by clicking on a desktop icon), its frame is too big for the screen, so the mode-line/mini-buffer area is not visible. It's not difficult to resize and reposition the frame, but ...
1
vote
3answers
188 views

Start Emacs, create new file and execute functions

I would like to automate the following when emacs start: open a new buffer launch a foo function (create-name) that writes something on the buffer and copy to clipboard a name YYY for the buffer save ...
1
vote
3answers
1k views

two different config files for Emacs

I am looking for method to use two different config files - init files. First config: when I am coding in full Emacs windows (open file as emacs namefile this define ~/.emacs_conf2) Second: when I ...
1
vote
1answer
313 views

ess R startup warning locale

I am using Emacs 25.1.1 with spacemacs. Everytime I run iESS, I get the warning about locale as, During startup - Warning messages: 1: Setting LC_CTYPE failed, using "C" 2: Setting LC_COLLATE failed,...
0
votes
1answer
391 views

Start Emacs with entering gdb mi mode (NOT after startup and enter gdb mi manually)

How do I start emacs with a command and its option, for example, I want emacs start with entering gdb mi mode, otherwise it does not go to the gdb mode during startup. The following works: emacs gdb ...
5
votes
2answers
2k views

How to lazy load init files to speedup Emacs startup?

My ~/.emacs.d/init.el file looks like this: (package-initialize) (require 'init-my-emacs-settings) (require 'init-my-emacs-performance) (require 'init-my-emacs-font) (require 'init-my-emacs-color-...
2
votes
1answer
326 views

Using org in emacs batch mode

I'd like to export an org file to LaTeX from the command line. I have created a file export.el with the following contents (simplified to reproduce the problem): (require 'org) (when (not (assoc "...
0
votes
3answers
2k views

How to get Emacs to automatically open a specific directory on startup?

I would like Emacs to open the folder $HOME/Documents/CodeLite/CPP-Math-Projects/Simple-Pendulum on startup and show it in the directory browser. Is there a way to do this? I have read https://www.gnu....
1
vote
0answers
174 views

Emacs times out trying to read from /dev/tty on startup?

After several years of being annoyed of Emacs on Ubuntu (not Mac via brew) having a ~2-3 second delay before displaying file contents at startup I finally decided to debug this. I ran strace -r emacs ...
0
votes
1answer
497 views

Emacs 25 png background transparency issue and sluggish init

I have just upgraded to Emacs 25 (windows 32-bit version on Windows 10), and found out that there are still quite a few things to smooth out. One includes potentially the PNG background not being ...
0
votes
0answers
75 views

What's the value of default-directory during startup?

I'm looking through startup.el, and normal-top-level-add-subdirs-to-load-path references the default-directory variable. What's the value of that variable during startup? I searched for calls to ...
1
vote
1answer
124 views

Loading addition org files along with default scratch buffer

I do a lot of my programming in Haskell and Python. I've started maintaining a personal cheat-sheet for each of these languages for common constructs and tasks I often come across. Hence whenever I ...
0
votes
1answer
52 views

Execute command on every start except you load a file from commandline

To load helm-mini every-time when emacs starts, I use the following line in my .emacs file as suggested in https://emacs.stackexchange.com/a/26402/2323 (add-hook 'emacs-startup-hook #'helm-mini) ...
0
votes
3answers
170 views

lazily activate an ELPA package?

I'd like a way to lazily activate certain ~/.emacs.d/elpa packages. I notice some of them have so many autoloads (which require other packages recursively from their *-autoloads.el), that you might as ...
5
votes
2answers
787 views

Restore welcome screen buffer when closed

How do I open startup/splash/welcome screen/message buffer (*GNU Emacs*) when it's not listed in list-buffers ?
0
votes
1answer
44 views

How can make emacs immediately compile a file I load?

Usually when I load a project, I want to compile it once right away, be it to again see the compilation error I was working on or just to build the dependencies of the checkout, so I don't have to ...
4
votes
2answers
969 views

Portable Emacs: Remapping user-emacs-directory

The Problem I want to install Emacs on a USB Flash Drive in a portable fashion, that is, Emacs should be able to be run from the UFD, once plugged on a device, without predefined paths to its ...
4
votes
3answers
1k views

Is it possible to install emacs 25.1 and emacs 24 on the same machine?

I currently have emacs 24.5.1 running on OSx el capitan. Since the first RC of emacs 25.1 released a few days ago, I am very curious to try it out. Can I have both versions installed on the same ...
2
votes
2answers
2k views

emacs does not start - how to debug?

After using emacs routinely for a long time, today I suddenly have problems starting emacs: When I type emacs in a terminal window, nothing at all happens, emacs seems to be running, but does not ...
0
votes
0answers
96 views

How can I make the initial frame invisible?

Using the following command line causes Emacs to briefly display the initial frame, then hide it: emacs -Q --eval "(setq initial-frame-alist '((visibility . nil)))" This is consistent with the ...
2
votes
3answers
345 views

Hide emacs frame until loaded

In my init.el file, I have some code to hide the Emacs toolbar: ;;; Hide the toolbar (tool-bar-mode -1) But when I load Emacs, it first enables the toolbar, and then quickly hides it, after it reads ...
1
vote
2answers
56 views

Changing the file association of todoo or alternatively completely disable it

I am using emacs on a debian system and have installed emacs-goodies-el. One of the many things in there is todoo which registers itself in auto-mode-alist for all files ending in TODO. This ...
1
vote
1answer
548 views

Debug emacs hanging at startup

So I've been using my custom config for a while now and no problems whatsoever, recently however there's a lag while loading emacs. It hangs at loading /home/<user>/.emacs.d/git_config.el (...
1
vote
0answers
43 views

If I move frame during Emacs startup, it moves back at the end of startup

I have a fairly long startup for Emacs 24.4 on Microsoft Windows 7. I try to move the frame where I want it during startup, but it snaps back after all the startup code is done running. I don't appear ...
1
vote
2answers
182 views

Current directory of Emacs in batch mode

I run Emacs in batch mode to execute some scripting actions. I'd like to get paths of files relative to where Emacs got started in batch mode: (file-relative-name (buffer-file-name) directory-where-...
5
votes
1answer
70 views

What mix of customisations are required to have org files always open exactly as they were closed?

org-customize has a node for startup folded, with options no fold, fold, content, and show everything. There doesn't seem to be an option for "remember last folded state". For such a customisable ...
5
votes
2answers
187 views

How to load start up screen (*GNU Emacs*) f it hasn't already been created?

When you run Emacs in daemon mode and then connect to it with emacsclient it doesn't show the start screen (*GNU Emacs*) but instead puts you into the *scratch* buffer, which is normally fine. But if ...
1
vote
1answer
219 views

“smart” ansi-term on start-up?

I have the following line in my .init.el (ansi-term "/usr/bin/bash") , because I usually like to have a terminal running in my emacs. The problem is that sometimes I don't, for instance, when I just ...
0
votes
0answers
164 views

Troubleshooting a blank window

I've run into a bit of an issue that I'm having trouble resolving. I use quite a few packages, one of which is ESS. The latest update to ESS seems to run into issues when trying to install. All I ...
5
votes
1answer
171 views

How to configure emacs to show the file I was working on when I open emacs?

I have save-place and save-visited-files installed however whenever I start emacs first a directory list shows (result of another setting in .emacs), I close it and then a few message buffers show up ...
5
votes
2answers
1k views

How to show startup screen instead of scratch, when no file is opened?

Like a lot of people I think I activated inhibit-startup-screen because it’s ugly and tedious to always have your emacs horizontally split when you open a file with half taken by an useless startup ...
3
votes
1answer
3k views

How to auto-toggle NeoTree on startup?

I would like to have NeoTree automatically toggle-open upon Emacs start up. I have tried adding: (neotree-mode t) under my: (require 'neotree) line in ~/.spacemacs (and yes, I am using Spacemacs ...
3
votes
1answer
591 views

How to customize a lazy-loaded variable?

In Spacemacs, how can I customize a variable used in a layer that's loaded lazily? Specifically, I'm trying to use Zathura and Synctex with Spacemacs' Latex layer. I have the following code in my ...
9
votes
1answer
4k views

How to start Emacs without the cmd.exe window (on MS Windows)?

It says emacs/bin/emacs.exe. If it's not necesarily useful, I'd like to stop it from starting with emacs. The extra window is messing me up a bit.
0
votes
1answer
593 views

Cryptic startup error messages

I just started out on emacs so this might have a really simple answer. I'm getting an error message on startup and have no idea what it means. The debug message doesn't help much either. What do ...
6
votes
1answer
549 views

What is the difference between `-Q` and `-q --no-init-file --nosplash`

I have started seeing some strange X related behaviour in emacs. I have not been able to pin it down. It goes away when I run emacs -Q, but is still present when running emacs -q --no-init-file --...
6
votes
1answer
101 views

How can one restore buffers on startup in correct order?

I use desktop-save-mode in order to restore buffers on startup. However, the buffer which is visible immediately after startup is *scratch*, *Messages*, .bbdb, etc. I am not interested in those. Is ...
2
votes
2answers
560 views

Error on reopening files from previous session via desktop-save-mode

I like my Emacs to reopen all previously opened files when I start it up. My setup is simple: ;; save desktop autosave sessions (setq desktop-dirname "~/" desktop-base-file-name ...
1
vote
1answer
308 views

Long pause during Emacs startup, prior to init file running [duplicate]

Inexperienced programmer here - When I open Emacs (24.5) on Mac Mavericks 10.9, I am getting a delay between the Emacs GUI opening and the init file being loaded. There is a white screen, which ...
1
vote
3answers
978 views

Org-mode does not load Latex previews at startup

In org-mode, Latex previews are not loaded at startup when using #+STARTUP: latexpreview. I've also tried customizing org-startup-with-latex-preview with no effect. Only way to preview latex fragment ...
1
vote
1answer
1k views

How to set `org-agenda-prefix-format` before org agenda starts?

I want to customize org-agenda-prefix-format before org agenda starts : (add-to-list 'org-agenda-prefix-format '(todo . " %b")) But if I put the previous line in my .emacs.d, Emacs will show me ...
2
votes
1answer
404 views

Turning off loading messages in Emacs minibuffer/GUI at startup

I would like to prevent Emacs from reporting on everyting that is being loaded at startup in the minibuffer. This is because it seems to pause when telling me which files are being loaded that I have ...
2
votes
1answer
2k views

How to activate python virtual environment in init file?

How would I activate a specific virtual environment in my init file? I know how to activate it manually, but I don't like to do it every time I start emacs. To activate it manually I used: pyvenv-...