Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Open other file extensions in org mode

Tags:

emacs

org-mode

How can I make Emacs open other file extensions than .org with the Emacs org mode? I have an editor on the iPad that is not able to handle .org files, so I'd like to use e.g. .text with org mode.

like image 564
Uwe Ziegenhagen Avatar asked Oct 07 '13 19:10

Uwe Ziegenhagen


2 Answers

This might be a duplicate, but the answer is easy enough:

(add-to-list 'auto-mode-alist '("\\.text\\'" . org-mode))
like image 114
abo-abo Avatar answered Sep 30 '22 02:09

abo-abo


Add the following line at the beginning of your .text file:

#    -*- mode: org -*-

You can also use this for .org_archive files

I know this question is old, but I think it is slightly easier and works, as far as I know, for all text-like files.

like image 39
Peter Bamm Avatar answered Sep 30 '22 02:09

Peter Bamm