<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.3.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: M-Lint across a project</title>
	<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/</link>
	<description>Ken &#38; Mike work on the MATLAB Desktop team</description>
	<pubDate>Sun, 22 Nov 2009 23:38:03 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.3.1</generator>
		<item>
		<title>By: Mike</title>
		<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6426</link>
		<dc:creator>Mike</dc:creator>
		<pubDate>Thu, 20 Aug 2009 20:32:57 +0000</pubDate>
		<guid>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6426</guid>
		<description>Tom,

 Thanks for the suggestion. These tools predate classes and packages and the infrastructure they use doesn't really deal well with the workflow. We're working on a much more useful and comprehensive solution, but that will take a few releases. 

Thanks for the suggestion.</description>
		<content:encoded><![CDATA[<p>Tom,</p>
<p> Thanks for the suggestion. These tools predate classes and packages and the infrastructure they use doesn&#8217;t really deal well with the workflow. We&#8217;re working on a much more useful and comprehensive solution, but that will take a few releases. </p>
<p>Thanks for the suggestion.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom</title>
		<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6425</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Thu, 20 Aug 2009 20:17:23 +0000</pubDate>
		<guid>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6425</guid>
		<description>Can we please make these tools have a "recursive" option?  Would be very useful, especially for code written using package directories!
Thanks!</description>
		<content:encoded><![CDATA[<p>Can we please make these tools have a &#8220;recursive&#8221; option?  Would be very useful, especially for code written using package directories!<br />
Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike</title>
		<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6396</link>
		<dc:creator>Mike</dc:creator>
		<pubDate>Thu, 06 Aug 2009 14:59:57 +0000</pubDate>
		<guid>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6396</guid>
		<description>There's no way to disable the disabling of a message. You can make an individual configuration file read only on the system, but that won't prevent a user from changing his configuration.</description>
		<content:encoded><![CDATA[<p>There&#8217;s no way to disable the disabling of a message. You can make an individual configuration file read only on the system, but that won&#8217;t prevent a user from changing his configuration.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Subhankar</title>
		<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6386</link>
		<dc:creator>Subhankar</dc:creator>
		<pubDate>Wed, 29 Jul 2009 08:00:09 +0000</pubDate>
		<guid>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6386</guid>
		<description>Hi i pretty happy with this concept, but is there any way we can make our customize file as read only , bcoz if you ignore this mLint warning in editor it updates the mLint configuaration file , is there any way to disable "Ignore This "m-Lint " on right click.</description>
		<content:encoded><![CDATA[<p>Hi i pretty happy with this concept, but is there any way we can make our customize file as read only , bcoz if you ignore this mLint warning in editor it updates the mLint configuaration file , is there any way to disable &#8220;Ignore This &#8220;m-Lint &#8221; on right click.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike</title>
		<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6251</link>
		<dc:creator>Mike</dc:creator>
		<pubDate>Tue, 19 May 2009 12:42:36 +0000</pubDate>
		<guid>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6251</guid>
		<description>George, 

This is a capability we're definitely interested in bringing to the editor. If you think it's safe to a string replace, you can use &lt;a href="http://www.mathworks.com/access/helpdesk/help/techdoc/ref/regexprep.html" rel="nofollow"&gt;&lt;tt&gt;regexrep&lt;/tt&gt;&lt;/a&gt; and file i/o to just parse through your files and replace a string. It's not as nice or clean as it will be when we have a GUI.

&lt;pre style="background: #F9F7F3; padding: 10px; border: 1px solid rgb(200,200,200)"&gt;files = what;
mfiles = files.m;
&lt;span style="color: #0000FF"&gt;for&lt;/span&gt; n = 1:length(mfiles)-1;
    afile = mfiles{n};
    fid = fopen(afile);
    txt = textscan(fid,&lt;span style="color: #A020F0"&gt;'%s'&lt;/span&gt;,&lt;span style="color: #A020F0"&gt;'delimiter'&lt;/span&gt;,&lt;span style="color: #A020F0"&gt;'\n'&lt;/span&gt;,&lt;span style="color: #A020F0"&gt;'whitespace'&lt;/span&gt;,&lt;span style="color: #A020F0"&gt;''&lt;/span&gt;);
    fclose(fid);
    txt = txt{1};
    txt = regexprep(txt,pattern_string,replacement_string);
    fid = fopen(afile,&lt;span style="color: #A020F0"&gt;'w+'&lt;/span&gt;);
    fprintf(fid,&lt;span style="color: #A020F0"&gt;'%s\n'&lt;/span&gt;,txt{:});
    fclose(fid);
&lt;span style="color: #0000FF"&gt;end&lt;/span&gt;&lt;/pre&gt;</description>
		<content:encoded><![CDATA[<p>George, </p>
<p>This is a capability we&#8217;re definitely interested in bringing to the editor. If you think it&#8217;s safe to a string replace, you can use <a href="http://www.mathworks.com/access/helpdesk/help/techdoc/ref/regexprep.html" rel="nofollow"><tt>regexrep</tt></a> and file i/o to just parse through your files and replace a string. It&#8217;s not as nice or clean as it will be when we have a GUI.</p>
<pre style="background: #F9F7F3; padding: 10px; border: 1px solid rgb(200,200,200)">files = what;
mfiles = files.m;
<span style="color: #0000FF">for</span> n = 1:length(mfiles)-1;
    afile = mfiles{n};
    fid = fopen(afile);
    txt = textscan(fid,<span style="color: #A020F0">&#8216;%s&#8217;</span>,<span style="color: #A020F0">&#8216;delimiter&#8217;</span>,<span style="color: #A020F0">&#8216;\n&#8217;</span>,<span style="color: #A020F0">&#8216;whitespace&#8217;</span>,<span style="color: #A020F0">&#8221;</span>);
    fclose(fid);
    txt = txt{1};
    txt = regexprep(txt,pattern_string,replacement_string);
    fid = fopen(afile,<span style="color: #A020F0">&#8216;w+&#8217;</span>);
    fprintf(fid,<span style="color: #A020F0">&#8216;%s\n&#8217;</span>,txt{:});
    fclose(fid);
<span style="color: #0000FF">end</span></pre>
]]></content:encoded>
	</item>
	<item>
		<title>By: Aurélien Queffurust</title>
		<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6250</link>
		<dc:creator>Aurélien Queffurust</dc:creator>
		<pubDate>Tue, 19 May 2009 06:42:43 +0000</pubDate>
		<guid>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6250</guid>
		<description>@George : Are you looking for the "Find Files tool" (just  select Edit &#62; Find Files from any desktop tool):
Finding Files and Content Within Files in Any Directory 
http://www.mathworks.com/access/helpdesk/help/techdoc/matlab_env/f10-14803.html#brpyzt7-1

For all my projects I use M-Lint to find unused variables or variables growing in the loop for example.

Aurélien</description>
		<content:encoded><![CDATA[<p>@George : Are you looking for the &#8220;Find Files tool&#8221; (just  select Edit &gt; Find Files from any desktop tool):<br />
Finding Files and Content Within Files in Any Directory<br />
<a href="http://www.mathworks.com/access/helpdesk/help/techdoc/matlab_env/f10-14803.html#brpyzt7-1" rel="nofollow">http://www.mathworks.com/access/helpdesk/help/techdoc/matlab_env/f10-14803.html#brpyzt7-1</a></p>
<p>For all my projects I use M-Lint to find unused variables or variables growing in the loop for example.</p>
<p>Aurélien</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: George</title>
		<link>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6249</link>
		<dc:creator>George</dc:creator>
		<pubDate>Tue, 19 May 2009 04:15:08 +0000</pubDate>
		<guid>http://blogs.mathworks.com/desktop/2009/05/18/m-lint-across-a-project/#comment-6249</guid>
		<description>This is useful - glad I stumbled upon it.  What I'm looking for, though, is how to easily search and replace all occurrences of a whole word in multiple files (i.e. all files in a directory).  Basically, I want the same functionality provided by Ctrl+F with the "whole words only" option but with the ability to perform on multiple files at once.

After writing my PSO toolbox, I decided that some of my variables could have been named more transparently.  For example, "Ns" could be named "num_trials_successful" so as to be obvious in meaning to any user.  I've been going through the process: Ctrl+Home, Ctrl+F, Alt+A (with "whole words only" selected), click in m-file, Ctrl+S, click new tab, repeat.  But lately I've been breaking my code up into m-files of specific purpose to make it easier to understand, and making project-wide improvements is now a more painful process.

A simple search and replace is not what I want though since "ns," for example, could occur within words, which is why I want to keep the "whole words only" option.

Any ideas???</description>
		<content:encoded><![CDATA[<p>This is useful - glad I stumbled upon it.  What I&#8217;m looking for, though, is how to easily search and replace all occurrences of a whole word in multiple files (i.e. all files in a directory).  Basically, I want the same functionality provided by Ctrl+F with the &#8220;whole words only&#8221; option but with the ability to perform on multiple files at once.</p>
<p>After writing my PSO toolbox, I decided that some of my variables could have been named more transparently.  For example, &#8220;Ns&#8221; could be named &#8220;num_trials_successful&#8221; so as to be obvious in meaning to any user.  I&#8217;ve been going through the process: Ctrl+Home, Ctrl+F, Alt+A (with &#8220;whole words only&#8221; selected), click in m-file, Ctrl+S, click new tab, repeat.  But lately I&#8217;ve been breaking my code up into m-files of specific purpose to make it easier to understand, and making project-wide improvements is now a more painful process.</p>
<p>A simple search and replace is not what I want though since &#8220;ns,&#8221; for example, could occur within words, which is why I want to keep the &#8220;whole words only&#8221; option.</p>
<p>Any ideas???</p>
]]></content:encoded>
	</item>
</channel>
</rss>
