Go to file
Eric Ludlam 4611551deb matlab-scan.el:
(matlab--valid-arguments-keyword-point):
If previous code is 'end', make sure it matches a valid arguments block.
(matlab-re-search-keyword-forward,matlab-re-search-keyword-backward):
When checking if in string/comment, don't pass in 'all comments' as t.
Do that only if in a comment.

matlab-syntax.el:
(matlab-beginning-of-string-or-comment):
Make doc accurate.
(matlab-end-of-string-or-comment):
Fix logic for case when not in a comment to only skip all comments if
looking at a comment.  Avoid moving pt if just looking at whitespace.

matlab.el:
(matlab-do-functions-have-end-p):
Improve scanning for end to not do condition-case.
This was hiding an error that was causing incorrect answer.
2021-04-11 15:35:26 -04:00
bin matlab-emacsclient.sh: 2020-05-22 21:45:34 -04:00
templates srecode-matlab.srt: 2019-11-22 14:04:53 -05:00
tests matlab-syntax.el: 2021-04-09 21:31:53 -04:00
toolbox toolbox/emacsrun.m: 2021-03-30 11:07:44 -04:00
.gitignore .gitignore: 2021-03-10 21:33:17 -05:00
ChangeLog tlc: new version 1.3, revamped implementation 2021-02-25 09:41:12 -05:00
ChangeLog.old1 *** empty log message *** 2005-12-01 18:37:46 +00:00
ChangeLog.old2 *** empty log message *** 2005-12-01 18:37:46 +00:00
INSTALL INSTALL: 2020-08-15 21:07:43 -04:00
Makefile matlab-scan.el: 2021-03-10 19:57:23 -05:00
NEWS.org Add some comments about the compilation problem with the Xemacsen 2019-12-23 21:05:10 +01:00
Project.ede matlab-scan.el: 2021-03-10 19:57:23 -05:00
README.org README.org: remove LocalWords 2017-12-05 21:09:22 -05:00
cedet-matlab.el cedet-matlab.el, matlab-cgen.el, matlab-compat.el, 2019-12-12 22:36:55 -05:00
company-matlab-shell.el matlab.el, mlint.el, semantic-matlab.el, 2020-02-08 21:43:34 -05:00
dl_emacs_support.m * dl_emacs_support.m (getfiles): update the url and README-->README.org 2016-03-16 14:04:58 +00:00
linemark.el linemark.el: 2021-03-23 17:10:47 -04:00
matlab-cgen.el matlab.el: 2021-03-23 20:29:55 -04:00
matlab-compat.el matlab-compat.el: 2021-03-13 20:59:21 -05:00
matlab-complete.el matlab-complete.el: 2021-03-27 13:58:07 -04:00
matlab-maint.el matlab-maint.el: 2021-03-26 18:43:13 -04:00
matlab-mode-pkg.el Update pkg information for MELPA 2020-01-06 23:12:44 +01:00
matlab-netshell.el matlab-netshell.el: 2020-01-25 10:36:44 -05:00
matlab-publish.el cedet-matlab.el, matlab-cgen.el, matlab-compat.el, 2019-12-12 22:36:55 -05:00
matlab-scan.el matlab-scan.el: 2021-04-11 15:35:26 -04:00
matlab-shell-gud.el matlab-shell-gud.el: 2021-03-30 12:48:38 -04:00
matlab-shell.el matlab-shell.el: 2021-03-30 20:52:15 -04:00
matlab-syntax.el matlab-scan.el: 2021-04-11 15:35:26 -04:00
matlab-topic.el cedet-matlab.el, matlab-cgen.el, matlab-compat.el, 2019-12-12 22:36:55 -05:00
matlab.el matlab-scan.el: 2021-04-11 15:35:26 -04:00
mlint.el mlint.el: 2021-03-30 20:37:04 -04:00
semantic-matlab.el matlab-scan.el: 2021-03-20 17:20:18 -04:00
semanticdb-matlab.el mlint.el: 2021-03-30 20:37:04 -04:00
srecode-matlab.el cedet-matlab.el, matlab-cgen.el, matlab-compat.el, 2019-12-12 22:36:55 -05:00
tlc.el tlc: new version 1.3, revamped implementation 2021-02-25 09:41:12 -05:00

README.org

Matlab-emacs Project:

MATLAB and Emacs integration:

  1. matlab-mode for editing *.m files.
  2. matlab-shell for running MATLAB -nodesktop within Emacs (Unix-only).

    • matlab-shell will use company-mode for completions.
  3. tlc-mode for editing *.tlc files (part of Simulink Coder).
  4. Integration with CEDET.

INSTALL

To install directly from the repository,

cd /path/to/matlab-emacs
make

Next, add the following to your ~/.emacs file:

;; Replace path below to be where your matlab.el file is.
(add-to-list 'load-path "/path/to/matlab-emacs")
(load-library "matlab-load")

;; Enable CEDET feature support for MATLAB code. (Optional)
;; (matlab-cedet-setup)

MELPA

GNU emacs (sorry Xemacs folks) users (version >=24) can use the package as provided by MELPA. Set

(add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/") t)

And then run M-x package-list-packages

Releases

The most recent version of matlab.el is in SourceForge GIT.

Homepage: http://matlab-emacs.sf.net

Project Page: http://sourceforge.net/projects/matlab-emacs

GIT Repository: https://sourceforge.net/p/matlab-emacs/src/ci/master/tree/

You can get a zip file using the "Download snapshot" button or use git to create a local repository:

git clone git://git.code.sf.net/p/matlab-emacs/src matlab-emacs-src

If you do not have a GIT client on your machine, you can use the MATLAB script dl_emacs_support.m to download a fresh copy of the matlab.el sources. https://sourceforge.net/p/matlab-emacs/src/ci/master/tree/dl_emacs_support.m

Older versions in the SourceForge CVS repository are no longer updated.

Dependencies

MATLAB-Emacs can use the CEDET suite for the following items:

  • Modifying the build system (Makefiles, etc)
  • mlint (uses EIEIO object system)
  • parsing/completion (uses semantic parsing system)

    • some template insertion features

    As of Emacs 23.2, CEDET is included in Emacs, and nothing extra is needed to satisfy that dependency.

    For older versions of Emacs:

    See http://cedet.sf.net for downloading CEDET.

    If you only want to use matlab.el for editing code or running the MATLAB shell, you DO NOT need to install CEDET.

    If you do want to use CEDET, add the following to your .emacs file:

    (matlab-cedet-setup)

Mailing List

Subscribe to matlab-emacs-discuss mailing list get updates on new releases and discuss topics relevant to the matlab-emacs project.

http://lists.sourceforge.net/mailman/listinfo/matlab-emacs-discuss

Old mailing list: The original mailing list where beta versions of matlab.el were posted, and where comments, questions, bug reports, and answers to questions could be sent. If you were subscribed to this list, please unsubscribe, and subscribe to the new list above. To unsubscribe, send email with the body of: "unsubscribe matlab-emacs"

FAQ

How Do I Customize matlab-emacs?

You can configure matlab-emacs using the "matlab" or "matlab-shell" customization groups:

Emacs -> Options -> Customize Emacs -> Specific Group

How do I customize "edit file.m" behavior?

By default when you run

M-x matlab-shell

>> edit file.m

file.m will open in emacs using 'emacsclient -n'. matlab-shell achieve this behavior by instructing MATLAB to use 'emacsclient -n' as the external text editor.

You can customize this by setting `matlab-shell-emacsclient-command' (Matlab Shell Emacsclient Command) of the matlab-shell customization group. You can change this command to what's appropriate. If you set it to the empty string, 'edit file.m' will use the default MATLAB editor setting.

The default MATLAB editor setting is controlled in the MATLAB preferences, (e.g. R2018a Home tab, Environment section, Preferences) where you can select which editor you want to edit a text file. MATLAB Editor or an external text editor. If you always want to use Emacs as your matlab editor even when running MATLAB outside of emacs, select Text editor and set it to the appropriate 'emacsclient -n' command.

Can I debug *.m files using Emacs as a debugger?

Starting with MATLAB 8.5 (R2015b), Emacs can no longer be used as a debugger for debugging MATLAB code. With R2015b, MATLAB no longer provides necessary file and line number information for external debuggers. Therefore, in matlab-shell:

>> dbstop in foo

will open foo in the MATLAB editor for debugging.