Add folders to path excluding .svn

Version 1.0.0.0 (913 Bytes) by H. Brian Hui
Changes to genpath to exclude the .svn to the path
1K Downloads
Updated 22 Jun 2007

No License

We use SVN for our Matlab toolbox Brainstorm. A .svn sub folder is created within every folder in the repository by SVN. When I was trying to add folders(including sub folders) to path, It will add all these .svn folders to the path. Then I found out you can simply add one line to the GENPATH function, and use
ddpath(genpath('My folder'))
to add to the path.

The line to be added in is at #48 in GENPATH function for Matlab R2006b:
~strcmp( dirname,'.svn') &...

Alternatively, you can replace the attached function with the default one. (Remember to make a backup copy)

Cite As

H. Brian Hui (2024). Add folders to path excluding .svn (https://www.mathworks.com/matlabcentral/fileexchange/15393-add-folders-to-path-excluding-svn), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2006b
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Search Path in Help Center and MATLAB Answers
Tags Add Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.0.0.0