emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Juan Manuel Macías" <maciaschain@posteo.net>
To: Renato Pontefice <renato.pontefice@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Position 972
Date: Sat, 29 Oct 2022 18:16:30 +0000	[thread overview]
Message-ID: <875yg28phd.fsf@posteo.net> (raw)
In-Reply-To: <105D7533-F7E7-4779-B113-E231058D0648@gmail.com> (Renato Pontefice's message of "Sat, 29 Oct 2022 18:29:28 +0200")

Renato Pontefice writes:

> Bruno,
> With the common you told me I reach che 972 /M-g c 972) and I found this:
>
> ;;;;;;Org mode configuration
>  Enable Org mode
> (require ‘org)
>
> Could be this the error?
>
> Now I’ve erased the two ;; save init.el and restart emacs, but now I obtain:
> -------------------------------------------------------------
> Warning (initialization): An error occurred while loading ‘/Users/renatopontefice/.emacs.d/init.el’:
>
> Symbol's value as variable is void: Enable
>
> To ensure normal operation, you should investigate and remove the
> cause of the error in your initialization file.  Start Emacs with
> the ‘--debug-init’ option to view a complete error backtrace. Disable showing Disable logging
> ———————————————————————————————
>
> What’s now…

Renato, adding to what Tomas and Bruno have explained to you very well,
you have another case in the init that you sent me by mail. Notice the
third line here:

------------------
;; Make Org mode work with files ending in .org
(add-to-list 'auto-mode-alist '("\\.org$" . org-mode))
The above is the default in recent emacsen
(require 'org)
(setq org-log-done t)
------------------

Emacs will understand The line that begins "The above is the..." as
code, and it is not code but a comment to the code. Therefore, you must
protect that line with an escape character, which in Elisp is (at least)
one ";" (as Tomas explained to you):

;; Make Org mode work with files ending in .org
(add-to-list 'auto-mode-alist '("\\.org$" . org-mode))
;; The above is the default in recent emacsen
(require 'org)
(setq org-log-done t)

And you also have another case, towards the end:

---------------------
(custom-set-variables
 ;;custom-set-variables was added by Custom.
 ;;If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
;; '(package-selected-packages '(org-contacts frame-tabs ebdb)))
::(custom-set-faces
;;  custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
;;)
--------------------

The first line (custom-set-variables) is the beginning of a code that is
commented out (= protected, so that Emacs doesn't read it). This line
should also be commented out (protected), with ;. Otherwise Emacs will
run into a code that starts but doesn't have a resolution.

If you fix that and the line that starts with "Enable", you should no
longer have errors in your init.

Best regards,

Juan Manuel 


  parent reply	other threads:[~2022-10-29 18:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-29 16:29 Position 972 Renato Pontefice
2022-10-29 17:46 ` tomas
2022-10-29 18:04   ` Renato Pontefice
2022-10-29 18:29     ` Juan Manuel Macías
2022-10-29 18:42       ` tomas
2022-10-29 19:08   ` Init.el Renato Pontefice
2022-10-29 19:36     ` Init.el tomas
2022-10-29 22:16     ` Init.el Eduardo Ochs
2022-10-29 18:16 ` Juan Manuel Macías [this message]
2022-10-29 18:44   ` Position 972 tomas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875yg28phd.fsf@posteo.net \
    --to=maciaschain@posteo.net \
    --cc=emacs-orgmode@gnu.org \
    --cc=renato.pontefice@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).