Mercurial > hg > octave-nkf
changeset 19472:98a18bc3208e
Use cd rather than chdir in core Octave code.
* edit.m, __run_test_suite__.m: Replace chdir with cd in 4 instances.
author | Rik <rik@octave.org> |
---|---|
date | Wed, 22 Oct 2014 11:37:00 -0700 |
parents | da86488d3d59 |
children | 4b8b942ef8db |
files | scripts/miscellaneous/edit.m scripts/testfun/__run_test_suite__.m |
diffstat | 2 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/miscellaneous/edit.m +++ b/scripts/miscellaneous/edit.m @@ -221,10 +221,10 @@ if (exist (FUNCTION.HOME, "dir") == 7) curr_dir = pwd (); unwind_protect - chdir (FUNCTION.HOME); + cd (FUNCTION.HOME); do_edit (FUNCTION.EDITOR, "", FUNCTION.MODE); unwind_protect_cleanup - chdir (curr_dir); + cd (curr_dir); end_unwind_protect else do_edit (FUNCTION.EDITOR, "", FUNCTION.MODE);
--- a/scripts/testfun/__run_test_suite__.m +++ b/scripts/testfun/__run_test_suite__.m @@ -187,7 +187,7 @@ endfor saved_dir = pwd (); unwind_protect - chdir (d); + cd (d); for i = 1:length (lst) nm = lst(i).name; if (length (nm) > 4 && strcmpi (nm((end-3):end), ".tst")) @@ -208,7 +208,7 @@ endif endfor unwind_protect_cleanup - chdir (saved_dir); + cd (saved_dir); end_unwind_protect endfunction