All Questions

Filter by
Sorted by
Tagged with
0
votes
1answer
10 views

IntelliJ style comment block cannot be recognized

In java-mode, I find the IntelliJ style comment block /** ... */ cannot be recognized correctly. And I have checked that the value of comment-start-skip variable (inherit from c-mode) is set as "\...
0
votes
1answer
51 views

Dedicated python shells that runs the code

This answer how to map C-c ! to create a new python shell for the current buffer. The main code is this: (defun my-python-start-or-switch-repl (&optional msg) "Start and/or switch to the ...
0
votes
0answers
22 views

company mode: seamless scrolling for completion suggestions

How do I enable seamless scrolling for company-mode suggestions? To wit, I'd like to return to the top suggestion if I scroll down from the last, and go the the bottom if I scroll up from the first. I'...
4
votes
1answer
47 views

Is there a "switch to buffer" hook?

I'm running emacs 26.3. I want to run a hook every time I switch to a buffer. However, I have not been able to find any kind of "buffer switch hook". If I want to always run a function when ...
3
votes
1answer
36 views

Acceptance test for a flow that uses the transient package?

I am trying to write a test around a flow that uses transient. Here is the sample code: ;; -*- lexical-binding: t; coding: utf-8 -*- (require 'transient) (require 'buttercup) (require 'with-simulated-...
1
vote
2answers
24 views

Using defadvice to add an interactive argument to a non-interactive function?

Is there a way to wrap a non-interactive function within defadvice so that the new function can accept an interactive argument which can alter the way that the wrapped function gets called? In other ...
0
votes
1answer
17 views

How to bind a terminal command to a key for python code autoformatting using autopep8

I'd like to autoformat my python code from the buffer that contains it with a key. I was looking at this tutorial. One can autoformat the code from the terminal with the command: autopep8 --in-place --...
1
vote
1answer
34 views

How to automate the test step in "debugging by bisection"?

Sometimes I run into a problem with Emacs that goes away if invoke Emacs with the --no-init-flag. In other word, I can deduce that the problem in question is caused by code somewhere in my .emacs file....
1
vote
1answer
17 views

font-lock not working with my custom face

I defined a custom face (defface my-face '((t . (:background "green"))) "text") that I want to use for font-lock syntax highlighting. (defvar my-font-lock-keywords `( ("^\...
1
vote
0answers
16 views

Let emacsclient try to reconnect after running alternate_editor

If I set alternate_editor to an empty string, emacsclient runs "emacs --daemon" and then tries to reconnect. However, I want to run it a specific emacs executable that is not in my path. If ...
0
votes
0answers
13 views

How can I change code-sample's font color if its inside a quote

In markdown I can do following: code-sample inside a quote. Example: > `code_sample` output, which has white font color: How can I do similar behavior in org-mode, where keeping the code-sample's ...
1
vote
1answer
22 views

Ivy minibuffer colums not left-justified with my setup

I am following System Crafters series on Emacs from Scratch on YouTube. With my configuration as I have set it up, Ivy doesn't appear in nice left-justified easy-to-read columns. I am trying to figure ...
0
votes
0answers
17 views

How can I prevent opening URL in the browser using `cmd+ret` in org-mode

If I am on top of a URL and pressed Ctrl+Enter (C-m), it opens the link on my default browser. I just want to have default behavior of C-m, which is new-line. Is it possible to prevent this while ...
1
vote
1answer
16 views

How can I prevent Orgmode from opening links to `*.jot` files using GNU `less`

When I open a link in Emacs Orgmode to a *.txt or *.org file, the files are opened in a new Emacs buffer. However, I have a self-created set of plain-text *.jot files. If I open an otherwise ...
0
votes
0answers
21 views

itemize shortcut environment in emacs

I know that M-RET creates a \item in emacs (latex mode) even if there is no \begin{itemize} \end{itemize} around. In the case we are not within such environment I am wondering if it is possible to ...
0
votes
0answers
12 views

Syntax highlighting and formatting in org-src-mode editing mode

If I installed the correct mode and create a block like this. #+BEGIN_EXAMPLE k8s ... #+END_EXAMPLE I got correct syntax highlighting in the example block, but no syntax formatting. If I enter edit ...
1
vote
1answer
21 views

How can I apply function `max` to a list of numbers?

I want to find the max element in a list of numbers. (setq l (list 1 2 3 4 5)) What is an easy way to call the max function on l? So far I have this but this seems convoluted: (eval `(max ,@l)) It ...
0
votes
1answer
21 views

How can a function check which major mode is enabled?

The accepted answer to this question says: When the function is invoked, it can test the current mode and do something appropriate. For example, for some modes, or all modes except some modes, it can ...
0
votes
0answers
16 views

How to get more specific error message when loading major mode with syntax errors

When I load my custom major mode, Emacs reports an error in the minibuffer about unescaped character literals, but it doesn't say where. I cannot even copy the error message here, since it disappears ...
1
vote
1answer
48 views

Why are `defvars` in my macro ignored?

I want to use a macro to define variables. However, evaluating the macro does not define these vars. I seem to be missing something, but I can't find it. Here's the code: (defmacro delve--build-cmp (...
0
votes
1answer
27 views

How to debug error in process sentinel?

I've recently switched to doom emacs, and for the most part it's working great. However, when I'm looking at a folder in dired-mode, if I copy a file using C the file is copied but *Messages* contains ...
0
votes
0answers
24 views

Hiding Lsp UI Sideline but retaining actions

I am just starting to explore the LSP configuration options. But i am facing very annoying problem with lsp-ui-sideline. I like the options that it provides but hate that it shows up right next to my ...
3
votes
1answer
28 views

How do I mark certain "elisp:" type links as safe?

I have several [[elisp:org-todo-list][todo list]] links in my Org documents. When I use C-c C-o (org-open-at-point), Org mode asks me whether I really want to open that link. While this is good ...
0
votes
0answers
16 views

Why doesn't flycheck display any hadolint errors?

I have a Dockerfile with several errors or warnings, but emacs doesn't display any of them. This worked a good while (two years? maybe...) ago. flycheck-mode is active. I see the errors when I run ...
0
votes
0answers
7 views

How to change location of filetags on minibuffer

When doing an org-roam-node-find, using Ivy as my completion system, I get in the minibuffer the name of the nodes, and on the far right the filetags for those nodes. But for some of them the tags get ...
0
votes
0answers
30 views

I'm having difficulty using Latex preview in org mode

I have GNU Emacs 27.2 on MacOS 11.6. I have MacTex 2021 installed. I have a simple Latex equation in between $ and $. When I do C-C C-X C-L (Latex preview) I get this message: Creating LaTeX preview.....
0
votes
0answers
20 views

Elpy not working with python 3.10

It seems elpy doesn't work with python 3.10. For instance, see the issue here posted on the elpy repo in github. I had the same problem as that person mentions, and it seems many other people too when ...
0
votes
0answers
18 views

how to configure packages while using Straight

I see many examples of EMacs configurations using use-package For example: ;; lsp-mode configs (use-package lsp-mode :delight lsp-lens-mode "🔍" :ensure t :init ;; set prefix for lsp-...
0
votes
1answer
34 views

reftex does not recognize references even though default bibliography file is defined

reftex-citep does not suggest any possible completions, even though the variable reftex-default-bibliography is set to the correct bibtex file. What else do I need to do to get reftex to detect the ...
0
votes
0answers
14 views

gzip: stdin: unexpected end of file

Linux Mint 20.1 Emacs 27.1 I connect to remote Linux host by tramp mode. Success connect. Nice. But when in dired mode I try to open log file (press Enter) I get the next message: gzip: stdin: ...
0
votes
2answers
32 views

Org ref: (wrong-type-argument stringp nil)

I have just installed Emacs 27.9 on a new Mac running Monterey 12.0.1 (using https://emacsformacosx.com) I then installed org-ref by putting the following lines in my .emacs: (add-to-list 'load-path &...
0
votes
1answer
24 views

How can I apply code sample inside [] brackets in org-mode

In the markdown-mode I am able to do following: [one, two, three, four] But in org-mode when I do: [~one~, ~two~, ~three~, ~four~] , it printed as it is instead of converting ~varaible~ into code ...
0
votes
0answers
9 views

File is not under version control (Subversion/svn)

I have a Subversion checkout which works fine (I can do svn st, svn diff etc.) However, Emacs doesn't recognise that the files are in Subversion. E.g. if I do M-x vc-diff I get File is not under ...
0
votes
1answer
17 views

How to set shortcut for `M-" ` in emacs config file?

I need to assign M-" as a shortcut to some function. How do I do that? Doing this gives error (define-key some-mode-map (kbd 'M-"') 'somefunction)
0
votes
1answer
17 views

How to replace one face with another for propertized text?

Text with properties can have faces assigned, how can one face be replaced with another? An example use case for this is highlighting some text or it's background. Seeing as Emacs doesn't have the ...
0
votes
1answer
19 views

Keybinding shortcut for Tufte html export

I've perused a few of the org-mode html-export keybinding shortcuts, i.e., ways to just have one key do, e.g., the entire long-winded C-c C-e h o. Unfortunately, there doesn't seem to be one fell ...
0
votes
1answer
17 views

Allowed values at #+PROPERTY header line not recognized

I'd like to set allowed property values at the top of an org-mode cheatsheet i'm working on. Only two allowed values so far for the CATEGORY property. I'm getting the same "Allowed values for ...
6
votes
2answers
494 views

How to select and delete a column of text in emacs?

I have this text 1 A 2 B 3 C I want to remove the first column to make it A B C Ok so I need to make a rectangle. Reading about rectangles I see "To specify a rectangle for a command to work on,...
0
votes
0answers
23 views

Setting elpy with python 3.10

I was trying to setup elpy with python 3.10 and get the following error: Elpy Configuration Emacs.............: 27.2 Elpy..............: Not found (Python), 1.35.0 (Emacs Lisp) Virtualenv........: ...
0
votes
1answer
27 views

How to view URL of the links in org-mode

I am using [[LINK][DESCRIPTION]] format to define hyperlinks in org-mode. Org recognizes plain URIs, possibly wrapped within angle brackets, and activate them as clickable links. The general link ...
1
vote
1answer
15 views

Leaving only one space between words within a paragraph

I have read https://www.emacswiki.org/emacs/DeletingWhitespace but couldn't find a way to select a paragraph and remove extra white spaces. For instance: asd asdasd asdasd asdasdasd asdasda ...
1
vote
1answer
12 views

Is it possible to export an orgmode headline to orgmode format?

I keep notes in orgmode and a GitHub repository can display formatted orgmode. I currently copy a headline to a new orgmode file to 'export' my text for publication on GitHub. However, this differs ...
2
votes
1answer
43 views

How to move from one source block to another, in Org-mode?

Is there a key-binding, command, or even evil extension for Emacs, so that I can move from one source block to another? For example,org-forward-heading-same-level, which is bound in my system to C-j, ...
0
votes
1answer
22 views

fixed width of column in csv mode

I plan to use csv-mode. In Excel, csv can be shown like the Picture 2. In emacs, C-c C-a yields Picture 1. Can I fix the width of the columns in csv-mode? Picture 1 Picture 2
0
votes
0answers
25 views

Bullets in Lists (Org-Mode) [duplicate]

like asked here: custom bullet style Isn't there any way to use • in Org-mode lists? It would look much nicer than *... I made a shortkey to insert • bullets, but they won't be recognized by Emacs as ...
0
votes
1answer
23 views

Can I export conf source code in org-mode to aconf in LaTeX/pdf/minted?

Emacs org-mode source-code blocks (between #+begin_src conf and #+end_src) support the conf "language"/style with syntax highlighting, but this is not supported when exporting to LaTeX/pdf, ...
0
votes
0answers
10 views

How to include recipient in the message citation when forwarding email

I have a custom citation in mu4e to include the date and time: ;; Cite messages with date and time of original (setq message-citation-line-function 'message-insert-formatted-citation-line) (setq ...
0
votes
0answers
22 views

Emacs DOOM does not show tabs although 'centaur-tabs' is enabled

I'm currently using DOOM emacs. I enabled 'centaur-tabs' in ~/.doom.d/init.el by using (tabs +centaur-tabs). Configures are: (after! centaur-tabs :ensure t ...
0
votes
0answers
26 views

pdf-tools auctex question with split buffer (vertically split)

A related question to a previously answered question: pdf-tools now has a nice continuous scroll mode, unfortunately, horizontal split buffers dont work nicely for continuous scroll pdf preview. So, ...
2
votes
1answer
26 views

How can you list all non-child frames?

There's frame-list but this lists child-frames, and there's visible-frame-list but this doesn't list iconified frames. It seems like there should be a simple function to return all non-child frames. I ...

15 30 50 per page