17,805 questions
0
votes
0
answers
21
views
Writing elisp exwm function to switch workspaces
I'm trying to write elisp functions to work with exwm to switch to the next or previous workspaces and I came up with the following. They work as required with M-x, but when binding to a key, they don'...
0
votes
0
answers
29
views
Error downloading markdown mode when installing lsp-mode
I'm trying to follow steps from the official website: https://emacs-lsp.github.io/lsp-mode/page/installation/
When i do M-x package-install and type in lsp-mode it gives the following result in the *...
-2
votes
0
answers
50
views
Fatfinger / random mouse click made emacs ctrl & meta no longor work., how to recover [closed]
I must have fat-fingered or random clicked with the mouse on screen. Now in Emacs the ctrl and meta keys no longer function.
I hold down ESC and type % and expect text replacement to come. But instead ...
1
vote
0
answers
36
views
How do I disable blink-and-insert upon entering closing bracket in mg editor c-mode?
I use the mg MicroGNUEmacs editor, a small emacs clone, and encountered a problem upon using c-mode. Whenever I type "}", ")", or "]", the cursor is taken to the matching ...
0
votes
2
answers
43
views
emacs lisp: symbols and keywords not interchangable in e.g. insert-button
running emacs29 on windows/cygwin, have noticed that:
(insert-button "foobar" 'help-echo "Hovering")
works just fine with "Hovering" tooltip, while
(insert-button "...
Advice
1
vote
0
replies
39
views
How to export from Orgmode to `.docx` via Pandoc filter with custom style NAMES?
I have a file in Orgmode, and I have to export it to .docx format using a heavily customised .docx template (publishers requirement). Specifically, all paragraph styles have their own names, including ...
0
votes
0
answers
30
views
Is there a way to make Emacs underline only part of the text when receiving long diagnostics?
In VS Code, when a diagnostic is received by the client, only tree dots appear under the first caracters of the concerned text.
Is there a way to customize Emacs to do the same when it receives long ...
0
votes
0
answers
50
views
how to see full error message from emacs verilog-batch-auto
I am using the following command line to run the auto processing on a verilog file:
emacs -batch file.v -f verilog-batch-auto;
When I get the error, it is not printed entirely, so the source of the ...
1
vote
0
answers
72
views
No *cider-error* buffer and no stacktraces with shadow-cljs
I am using Emacs+Cider to develop a ClojureScript project with shadow-cljs.
When I am using Cider with a .clj project, everything works fine. But in shadow-cljs projects specifically, I don't get the ...
1
vote
0
answers
38
views
How to properly associate .omnijs files with typescript-ts-mode in doom emacs?
I am using doom emacs as an editor for writing OmniJS automation files. According to the instructions, I've downloaded the tsconfig.json and omnifocus.d.ts files and put them in my project folder. ...
0
votes
1
answer
85
views
Stop emacs to replace spaces or tabs in Makefiles
I have upgraded from Emacs 29 to 30 and set indent-tabs-mode no nil. In makefile-mode the indent-tabs-mode is set. Therefore, Emacs replaces 8 spaces with a tab character.
In version 29, the spaces ...
0
votes
0
answers
51
views
org-agenda-redo affected by evil state hook
I use the code
(add-hook
'evil-insert-state-entry-hook
(lambda ()
(global-hl-line-mode 0)))
(add-hook
'evil-insert-state-exit-hook
(lambda ()
(global-hl-line-mode 1)))
to make it more clear ...
0
votes
1
answer
61
views
VSCode with DVT: Verilog indentation/formatting of ports declaration lists like in Emacs
I move from Emacs to VSCode with DVT for Verilog.
In Emacs by a single push of Tab I am able to indent/format beautifully the whole ports declaration list so that all declarations are aligned ...
1
vote
0
answers
78
views
Ligatures working in some modes but not others in Emacs 30.2
I have installed emacs using nix-darwin with home-manager. The version is:
GNU Emacs 30.2 (build 1, x86_64-apple-darwin24.6.0, NS appkit-2575.70 Version 15.6 (Build 24G84))
I have set it up using ...
0
votes
0
answers
48
views
Can I remap/swap two keys for all keyboard commands (all ctrl, alt, shift, etc combinations) that use these keys, but retain for normal text editing
I have a custom keyboard and I want to map "n", "e", "i", "u" for movement, instead of "b", "n", "f", "p".
I wish to ...
0
votes
0
answers
43
views
Emacs interactive functions that generate lisp-errors with some names when using Ivy and lsp
Many interactive functions generate lisp errors depending on the function name when using ivy and lsp and debugging it is difficult (in part because of the bytecode compile-function references). This ...
1
vote
2
answers
125
views
Adjusting syntax table for a derived mode in .emacs
In order to view/edit Doxygen files, I am using
(define-derived-mode dox-mode
html-mode "dox"
"Major mode for Doxygen."
)
(add-to-list 'auto-mode-alist '("\\.dox\\'&...
0
votes
1
answer
62
views
Emacs/R/ESS workflow and reverting back to previous behavior
I use emacs with ess on Windows for R development. My usual workflow is to open two emacs windows, one main (primary) one, and another (secondary) one using C-x 5 2. I start R in the secondary window (...
2
votes
2
answers
98
views
How to hide files from find-file in emacs?
What I need to do is simple: I have A-f bound to find-file in emacs, but want to hide specific files that I do not care about. I have them hidden in dired already using this config:
(setq dired-omit-...
-1
votes
1
answer
65
views
Emacs stop enclosing bracket to appear
In Emacs - Portacle when I want to add an opening bracket I got this (), So if I want to enclose (list 1 2 3) I get
(append () (list 1 2 3))
I do want
(append ( (list 1 2 3))
So I can put an closing ...
1
vote
1
answer
136
views
How to make emacs use tabs instead of windows
I am using (global-tab-bar-mode) in emacs, but almost all commands that have output (like shell commands) will split the current window and make another, ignoring tabs completely, which I do not want, ...
0
votes
1
answer
73
views
How to customise delimeters for C-backwards and C-forwards in emacs
I am configuring emacs, and would like to fix an issue with the Control Forwards, Control Backwards, Control backspace keybinds - since I am using CUA mode, these should take me backwards and forwards ...
1
vote
0
answers
42
views
Unable to create new Git repo with VC utilities in GNU Emacs
I am trying to initialize a Git repository with 'C-x v v'. I think it's feasible because according
to the Emacs Manual, Section 30.1.3.1:
‘C-x v v’ does the following when invoked from a buffer that ...
0
votes
1
answer
22
views
Pymacs Problems on Python 3.12, Emacs 29
I did the usual install steps, but Pymacs has some disagreements with the latest version of Python on Ubuntu 24. It cannot find a library named imp. Setup cannot find an readfp() method. Anyone has ...
1
vote
1
answer
70
views
Clangd find definition in external library
I have a setup with a project written in C that is statically linked with a library. The sources of the library are in a different folder somewhere else on the system.
I am using emacs and lsp-mode ...
2
votes
1
answer
61
views
Corrupted Dired Output, Disappears After Refresh
My dired output shows some additional information that are cluttering the screen, the first time I visit any directory I get an output like
drwxr-xr-x 2 user1 user1 4096 Jan 5 2024 dir1
drwxr-...
0
votes
2
answers
51
views
Why doesn't `re-search-forward` populate match data from all alternatives?
When using re-search-forward with a regexp that contains an or operator with a captured subexpression in an alternative after the first, the group is not captured.
Evaluating
(progn
(re-search-...
1
vote
1
answer
88
views
LISP macro indentation for sub-expressions?
I'm using Emacs, and I have a macro that's like a switch for regexes, and runs an expression with variables bound to match results.
The indentation isn't what I'd like but I can't find if there's a ...
0
votes
0
answers
74
views
How to install emacs with homebrew when ctags is installed too?
the info page does not mention a conflict with ctags, but when i run
brew install --cask emacs
the output is something like
==> Installing Cask emacs
==> Moving App 'Emacs.app' to '/...
0
votes
2
answers
90
views
How to inline a variable in Emacs?
I'm writing Rust using rust-analyzer and lsp-mode
Suppose I have code:
let x = 10;
let y = 20 + x;
I want to put my cursor over x and hit some shortcut (or whatever) and the code becomes:
let y = 20 +...
1
vote
0
answers
64
views
OrgMode: How to automatically include another org file content (without export or C-c C-c)?
I need to include the content of an org file (or a specific section) into my main org file, similarly to what I do in Obsidian with
![[File#Section]]
I've tried this, but it requires export:
#+...
2
votes
0
answers
31
views
yasnippet not present in company dropdown
In Emacs, I would like to see yasnippets in the company dropdown. Although I thought this would work out of the box, I can’t get this working. This is my config:
(use-package yasnippet
:ensure t
:...
0
votes
0
answers
38
views
Emacs - Passing the Option-Command H key to the OS (Hide Others)
I run Mitsuharu's Mac port of Emacs (v 29.1) on my MacBook Pro. I would like to use Cmd-Opt H key to hide other apps as it works in all other Mac apps. Right now Emacs gives me "M-s-h is ...
0
votes
1
answer
173
views
how to make an org-capture template which generates filename and title properties
I'm trying to write an org-capture-template and supporting functions for it, for a blogging setup that uses individual org files within a specific directory for posts. i want this to work such that I ...
-1
votes
1
answer
304
views
How to paste with mouse middle click the text copied from Emacs or other applications?
I would like to:
Copy text from Emacs by highlighting it with a mouse (or copy from other applications with command+c).
Paste the copied text into Emacs with mouse middle click (or paste it into ...
0
votes
0
answers
106
views
How do I use multiple languages in a treesit major mode in emacs?
I have written the following typescript code. I would like for typescript-ts-mode to recognize that the template literal is HTML and should use the HTML tree-sitter parser for that region of text. In ...
0
votes
0
answers
161
views
Emacs fonts on wayland
I just made the switch to wayland but when I opened emacs using the daemon and 'emacsclient -c' rather than the font that I set (Monaspace Krypton) in the config.el it automatically goes to some ...
0
votes
1
answer
64
views
How to fix C-c behaviour in emacs?
I'm configuring emacs, and have run into a roadblock trying to configure C-c to be copy:
;; Copy, cut
(global-unset-key (kbd "C-c"))
(global-unset-key (kbd "C-x"))
(global-set-key (...
0
votes
0
answers
35
views
How could I tracking job state changes and insert different logbook item into drawer in emacs org-mode?
I want to insert different formats of logbook items in the drawer for different job state changes.
Such as:
When the TODO--> VERY, logbook drawer will insert "[2025-04-27 Sun 15:33](VERY from ...
0
votes
2
answers
112
views
Is there a spacemacs-y way to comment lines in Doom Emacs?
Is there a spacemacs-y way to comment a line in Doom Emacs? In Spacemacs, it's SPC c l, but I couldn't find anything of the sort for Doom Emacs. I know I can comment a line using SPC : and then ...
0
votes
0
answers
29
views
Modifying Hunspell affix file to suggest more spelling variations
I'm encountering an issue with Hunspell's spell-checking in Emacs. When I misspell "preparing" as "perapring", Hunspell doesn't suggest the correct spelling. Instead, it offers ...
0
votes
1
answer
733
views
Run Ruff in Emacs
How can I run Ruff in Emacs? I need to enable 2 commands on the current buffer:
ruff check --select ALL current_buffer → bind to M-x ruff-check
ruff check --select ALL --fix current_buffer → bind to ...
0
votes
0
answers
46
views
Highlight org-heading depending on the content of its :PROPERTIES:
It would be useful to highlight any org-heading if its :PROPERTIES: block contains property with certain names.
So in my case need visually separate class names from instances (memebers of class) in ...
0
votes
1
answer
42
views
cygwin: emacs-w32 error while loading shared libraries: cygXpm-noX-4.dll
My emacs-w32 was running fine on my windows11. But since I did a cyg upgrade by setup-x86_64.exe, I got this error:
$ emacs-w32
C:/cygwin64/bin/emacs-w32.exe: error while loading shared libraries: ...
0
votes
0
answers
50
views
Emacs web-mode variables aren't set during .emacs initialization
I'm struggling to set up my emacs web-mode for .js files for React projects. They don't get indented properly. A known fix is to force the .js files into .jsx files, however, I'm not able to get that ...
1
vote
0
answers
42
views
How to preserve MathJax/LaTeX formatting converting from md to org
If I get a mathematical answer from Google Gemini, I can choose copy, then paste it into Emacs. At this point it's presumably markdown, so I save it as somemath.md. When I look at it, it has all the ...
0
votes
1
answer
329
views
How to debug C# and .Net Projects on Emacs?
I'm trying to debug a .Net Core project. I'm using emacs lsp and dap mode. But when I run dap-debug I get the message:
Have you loaded the ‘coreclr’ specific dap package?
I just want to debug my ...
0
votes
2
answers
320
views
error: Package ‘use-package-’ is unavailable (emacs 27.1)
I'm new to Emacs and started configuring it yesterday. And everything was going ok (show number lines, fonts, themes) but when I tried to install packages (MELPA) it keeps showing this.
MY OS: LINUX ...
0
votes
1
answer
59
views
Emacs bookmark with function
I would like an Emacs bookmark that jumps to a 'today' file. This is a different file every day, so I would like to use a function.
I tried an entry in bookmark-alist in the bookmarks file at .emacs.d/...
0
votes
0
answers
55
views
CMake does not find an external executable (Emacs)
On my system I have Emacs:
$ which emacs
/usr/bin/emacs
$ emacs --version
GNU Emacs 29.4
I cannot make CMake find it; this is the corresponding bit of CMakeLists.txt file:
find_program(EMACS emacs)
...