String left-padding for MATLAB.
Clone the git repository.
git clone https://github.com/rks/left-pad-toolbox.git
Add the tbx/doc
and tbx/leftpad
directories to your MATLAB path.
addpath 'path-to-cloned-code/tbx/doc'
addpath 'path-to-cloned-code/tbx/leftpad'
>> leftpad('Hello!', 10)
ans =
Hello!
>> leftpad('Hello!', 10, '+')
ans =
++++Hello!
From the project's root:
>> run 'tests/runner'