From b931478277265eeedc67463c86dd5f92c89bed65 Mon Sep 17 00:00:00 2001 From: davidvarga Date: Wed, 12 Oct 2016 17:34:27 +0200 Subject: [PATCH] Clean-up and preparation for release v1.2 #24 --- README.md | 10 +++++++--- testfile.m | 44 -------------------------------------------- 2 files changed, 7 insertions(+), 47 deletions(-) delete mode 100644 testfile.m diff --git a/README.md b/README.md index a70c63f..924e0da 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,6 @@ # MBeautifier -MBeautifier is a lightweight M-Script based tool that can be usable to format Matlab M-Code directly in the Matlab Editor. - +MBeautifier is a lightweight M-Script based tool usable to format Matlab M-Code directly in the Matlab Editor. Main features @@ -16,7 +15,7 @@ Main features Deployment and Configuration ---------------------------- -Add container directory to the Matlab path, then execute: `MBeautify.setup`. +Add containing directory to the Matlab path, then execute: `MBeautify.setup()`. This command will create the standard configuration of formatting stored in `MBeautifier\resources\settings\MBeautyConfigurationRules.m`. @@ -66,3 +65,8 @@ Currently there are three approaches supported: - Perform formatting on the currently selected text of the active page of Matlab Editor. Command: `MBeautify.formatEditorSelection()`. An optional saving mechanism as above exists also in this case. Useful in case of large files, but in any case `MBeautify.formatCurrentEditorPage()` is suggested. - Perfrom formatting on a file. Command: `MBeautify.formatFile(file)`. Can be used with (1)one argument: the input file is formatted and remains open in the Matlab editor unsaved; (2)two arguments as `MBeautify.formatFile(file, outFile)`: the formatted file is saved to the specified output file if possible. Output can be the same as input. + Supported Matlab versions + ------------------------- + + As MBeautifier uses the built-in Matlab Editor functionality, it supports Matlab versions from R2011a. + diff --git a/testfile.m b/testfile.m deleted file mode 100644 index 02a674d..0000000 --- a/testfile.m +++ /dev/null @@ -1,44 +0,0 @@ -% This file should NOT change when run through MBeautify -% If you find anything that is difficult or failed in some MBeautify -% version, please add it here. - -% unary operator testcases - -+2 -+2. -+.2 -' string with lots of spaces ' -1 + 2 -f(+1) + 1 - -x = y -x + 1. + 2 -x + 1. + +.1 -x + 1 + 2 -x = 1 -x = -1 -x = +1 -x = +.1 -if +1 > +2 - +(-[-.1]) - z = [1, 2, 3, 4] - return -end; % comment +-+-+- +++ 123 *** - -% different meanings of 'end' -if any(z == -[-1, -2, -3, -4]) - ifmyvariablenamecontainsif = z(1:end); -end - -% old-style function calls -disp +end+ this is not any keyword if else endif while +1 -% bracket handling -while (1) - a = [0, 1]; - a(1) = 2 * [a(0)]; - break -end; - -% transpose --x' + +1 + x'' + 2 * x''' * 1 -