Stack Exchange Network

Stack Exchange network consists of 175 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 [custom]

The tag has no usage guidance.

1
vote
1answer
33 views

macro takes multiple pairs of arguments

I found this snippet of code from oremacs (defmacro csetq (variable value) `(funcall (or (get ',variable 'custom-set) 'set-default) ',variable ,value)) I would like to expand this macro so that is ...
1
vote
1answer
77 views

What happens when there is more than one custom-set-variables?

a quote from my init.el: ;; custom-set-variables was added by Custom. ... ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. What exactly ...
1
vote
1answer
48 views

Save filesets-data in file which is not the custom-file or other emacs config file

Background I store Emacs my configuration in a .emacs and separate custom file. I would like to store both in a public repository like Github. I also use filesets which saves filenames & file ...
5
votes
1answer
208 views

Add to a list that defcustom has not yet defined

We can avoid adding duplicate elements to a list variable by using add-to-list. When setting a customizable variable (i.e. one that is or will be defined by defcustom) from our init file, we're ...
1
vote
1answer
385 views

Where is the information passed to `custom-set-variables` and `custom-set-faces` stored?

The post's title pretty much says it all. In particular, I want to find out what happens if I invoke custom-set-variables twice, with completely different arguments each time. E.g. (custom-set-...
0
votes
1answer
108 views

Show name of variable in Custom-mode

I sometimes explore customisable variables in Custom-mode to get a structured overview, before manually setting them with setq-default in my .emacs. Can I make Custom-mode show the Lisp names of the ...
1
vote
2answers
130 views

How to make a Customize setting depend on another? or make a `setq` depend over a Customize setting?

I heard it’s better to use Customize to define variables/settings instead of just some setq inside .emacs.d… because it autoloads when loading packages, because it’s more consistent, more checked/...
3
votes
1answer
845 views

how to use custom-set-variables safely?

The help for custom-set-variables says: The arguments should each be a list of the form: (SYMBOL EXP [NOW [REQUEST [COMMENT]]]) This stores EXP (without evaluating it) as the saved value for ...
2
votes
1answer
2k views

What is causing this error: “Cannot open load file, no such file or directory, session”?

From time to time my Emacs doesn't load my init file at startup and gives me the following error message: File error: Cannot open load file, no such file or directory, session To ensure normal ...
1
vote
1answer
222 views

How to programmatically extract configurations from a defcustom variable?

How do I programmatically extract key-value pairs from "Babel Languages" list in defcustom org-babel-load-languages section of org.el? I want to read the "Babel Languages" configuration into an org-...
5
votes
2answers
621 views

Stop org-mode from defining agenda files in custom

I have the following line in my .emacs: (setq org-agenda-files (directory-files "~/org-files" 'absolute "[^#]*.org$" 'no-sort)) I would like for org-agenda-files to be defined in this way on startup....
1
vote
1answer
111 views

Automatically prompt for comment character and apply it in older versions of emacs

When I try to comment a block of code using comment-region in a file type emacs doesn't know the proper comment type for, then it prompts me No comment syntax is defined. Use: so I can specify the ...
4
votes
1answer
956 views

Where is the default color / custom theme defined?

When you start Emacs with emacs -Q, there appears to be some sort of default color scheme. Where are these colors defined? The default theme does not show up with M-x customize, nor can I find it in ...
23
votes
2answers
2k views

Reset custom variable to default value programmatically

Q: Using Elisp, how can I reset a variable to its default value without knowing what that value is? I tried to figure out how to do this by bringing up the Customize interface for a variable I set to ...
62
votes
4answers
9k views

Advantages of setting variables with setq instead of custom.el?

I see a lot of people (extension authors and others) give configuration examples with setq: (setq foo 'bar) These parameters are often defined with defcustom, making them available for customization ...