File tree Expand file tree Collapse file tree 2 files changed +18
-14
lines changed Expand file tree Collapse file tree 2 files changed +18
-14
lines changed Original file line number Diff line number Diff line change @@ -60,8 +60,8 @@ initCppSpm
6060```
6161
6262Please see our
63- [ documentation] ( https://cpp_spm.readthedocs.io/en/latest/index.html ) for
64- more detailed instructions.
63+ [ documentation] ( https://cpp_spm.readthedocs.io/en/latest/index.html ) for more
64+ detailed instructions.
6565
6666### Dependencies
6767
@@ -76,7 +76,7 @@ For instructions see the following links:
7676| ---------------------------------------------------------- | ------------ |
7777| [ Matlab] ( https://www.mathworks.com/products/matlab.html ) | 20??? |
7878| or [ octave] ( https://www.gnu.org/software/octave/ ) | 4.? |
79- | [ SPM12] ( https://www.fil.ion.ucl.ac.uk/spm/software/spm12/ ) | v7487 |
79+ | [ SPM12] ( https://www.fil.ion.ucl.ac.uk/spm/software/spm12/ ) | >7219 |
8080
8181<!-- lint enable -->
8282
@@ -109,8 +109,8 @@ This can perform:
109109The core functions are in the ` src ` folder.
110110
111111Please see our
112- [ documentation] ( https://cpp_spm.readthedocs.io/en/latest/index.html ) for
113- more info.
112+ [ documentation] ( https://cpp_spm.readthedocs.io/en/latest/index.html ) for more
113+ info.
114114
115115## Octave compatibility
116116
@@ -148,12 +148,14 @@ Constant are written in `UPPERCASE`.
148148There is a [ pre-commit hook] ( https://pre-commit.com/ ) that you can use to
149149reformat files as you commit them.
150150
151- Install pre-commit by using our ` requirements.txt ` file
151+ Install pre-commit by using our ` requirements.txt ` file
152+
152153``` bash
153154pip install -r requirements.txt
154155```
155156
156157Install the hook
158+
157159``` bash
158160pre-commit install
159161```
Original file line number Diff line number Diff line change @@ -13,22 +13,24 @@ function checkDependencies()
1313 fprintf(' Checking dependencies\n ' );
1414
1515 SPM_main = ' SPM12' ;
16- SPM_sub = ' 7487 ' ;
16+ SPM_sub = 7219 ;
1717
1818 %% check spm version
1919 try
2020 [a , b ] = spm(' ver' );
21- fprintf(' Using %s %s\n ' , a , b );
22- if any(~[strcmp(a , SPM_main ) strcmp(b , SPM_sub )])
23- str = sprintf(' %s %s %s .\n%s ' , ...
24- ' The current version SPM version is not' , SPM_main , SPM_sub , ...
25- ' In case of problems (e.g json file related) consider updating.' );
26- warning(str ); % #ok<*SPWRN>
27- end
2821 catch
2922 error(' Failed to check the SPM version: Are you sure that SPM is in the matlab path?' );
3023 end
3124
25+ fprintf(' Using %s %s\n ' , a , b );
26+
27+ if ~strcmp(a , SPM_main ) || str2num(b ) < 7219
28+ str = sprintf(' %s %s %s .\n%s ' , ...
29+ ' The current version SPM version is less than' , SPM_main , SPM_sub , ...
30+ ' Update with: spm_update update' );
31+ warning(str ); % #ok<*SPWRN>
32+ end
33+
3234 spm(' defaults' , ' fmri' );
3335
3436 %% Check the Nifti tools are indeed there.
You can’t perform that action at this time.
0 commit comments