Skip to content

Commit

Permalink
Remove only .c files associated with .pyx source.
Browse files Browse the repository at this point in the history
  • Loading branch information
Josh Warner (Mac) committed Jul 12, 2015
1 parent 9bfcd44 commit 32510b9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ all:
python setup.py build_ext --inplace

clean:
find . -name "*.so" -o -name "*.pyc" -o -name "*.pyx.md5" -o -name "*.c" -o -name "*.pyd" | xargs rm -f
find . -name "*.so" -o -name "*.pyc" -o -name "*.pyx.md5" -o -name "*.pyd" | xargs rm -f
find . -name "*.pyx" -exec ./tools/make_clean_pyx-c_checker.sh {} \;

test:
python -c "import skimage, sys, io; sys.exit(skimage.test_verbose())"
Expand Down
6 changes: 6 additions & 0 deletions tools/rm_pyx_c_file.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash
# Gets passed all .pyx files in package, and deletes associated .c files.
filename="${1%.*}".c
if [ -e "$filename" ]; then
rm -f "$filename";
fi

0 comments on commit 32510b9

Please sign in to comment.