Questions tagged [scratch-buffer]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
7
votes
2answers
392 views

How can I view the full `package-alist` value (without the truncation characters “…”)?

When I do C-h v package-alist, I see something like ((PACKAGE-NAME1 [cl-struct-package-desc PACKAGE-NAME1 (VERSION1) "DESCRIPTION1" (...
24
votes
1answer
893 views

How can I quickly toggle between a file and a *scratch* buffer having the same major mode?

At times while working on a code, it's useful to quickly open a *scratch* buffer to paste a snippet from that code file. If I am working on a Perl script, I would like to quickly open a *scratch* ...
14
votes
4answers
2k views

Is it possible to create an org-mode *scratch* buffer?

While working on a document in emacs I often find myself opening a new buffer, doing something in org-mode, copying the org-mode content, and pasting it into my document. I used to create a new org-...
10
votes
3answers
1k views

never close scratch

If I ever close the *scratch* buffer it is always an accident. I have persistent-scratch so it's as easy as a persistent-scratch-reload but it'd be nice if the scratch couldn't be killed. How can I ...
3
votes
4answers
999 views

How to replace the default contents of the scratch buffer with the contents of a file (if it exists)?

I would like emacs to check for a ~/emacs.d/scratch.txt and use it's contents instead of the default message when emacs starts. How can this be done?
2
votes
1answer
119 views

Function coloring in scratch buffer

When I am typing in the scratch buffer, I type certain functions such as defun and while and they are recognized by the buffer and appear in purple. However, with other Lisp functions such as set or +,...
3
votes
1answer
937 views

Scratch always starts in fundamental mode

I don't know what change in my configuration caused this, but scratch buffer always starts in fundamental-mode. I would like to have emacs-lisp-mode in the scratch buffer. I tried to do (setq initial-...
1
vote
1answer
54 views

Can I open emacs in nw mode with the scratch buffer?

When starting emacs from the shell command line, if you pass the "dot", it opened emacs with a 'dired' of the current directory. But can I do this? emacs '*scratch*' so emacs opens with the focus ...