Skip to content

Instantly share code, notes, and snippets.

@tiborsimon
Created October 6, 2015 21:48
Show Gist options
  • Save tiborsimon/c9007ca307345eeff771 to your computer and use it in GitHub Desktop.
Save tiborsimon/c9007ca307345eeff771 to your computer and use it in GitHub Desktop.
MATLAB Library System documentation
my_mls_package
│ install.m
│ uninstall.m
│ librarydata.txt
└───library
│ files1.m
│ files2.m
│ ...
├───folder1
├───folder2
└───...
d = dir('.');
for k = 1:length(d)
if (d(k).isdir == 1)
switch d(k).name
case '.'
case '..'
% Nothing to do
otherwise
cd(d(k).name)
install()
cd('..')
end
end
end
>> install
#====================================================================================#
| |
| M A T L A B L I B R A R Y S Y S T E M |
| >>-------------------------~-------------------------<< |
| v2.3.0 |
#------------------------------------------------------------------------------------#
Installing My Library v0.0.0 by John Smith..
-> Path added: .../my_mls_package/library
Finished!
My Library v0.0.0 has been succesfully installed to your system!
Test your installation by running: my_function()
#====================================================================================#
My Library
http://google.com
John Smith
v0.0.0
my_function()
1st line: library name
2nd line: library url
3st line: author name
4th line: library version
5th line: demo command
>> uninstall
#====================================================================================#
| |
| M A T L A B L I B R A R Y S Y S T E M |
| >>-------------------------~-------------------------<< |
| v2.3.0 |
#------------------------------------------------------------------------------------#
Removing My Library v0.0.0 by John Smith..
-> Path removed: .../my_mls_package/library
Finished!
My Library v0.0.0 has been succesfully removed from your system!
#====================================================================================#
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment