diff --git a/GNUmakefile b/GNUmakefile index 42d7c33e46b..73d5c267705 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -98,6 +98,16 @@ package_archive: test: cd $(BUILD_DIR) ; ctest . --output-on-failure +# run pep8 check check on scripts we distribute. +test_pep8: + python source/tests/pep8.py > test_pep8.log 2>&1 + @echo "written: test_pep8.log" + +# run some checks on our cmakefiles. +test_cmake: + python build_files/cmake/cmake_consistency_check.py > test_cmake_consistency.log 2>&1 + @echo "written: test_cmake_consistency.txt" + clean: cd $(BUILD_DIR) ; make clean diff --git a/build_files/cmake/cmake_qtcreator_project.py b/build_files/cmake/cmake_qtcreator_project.py index 85d37549917..59b8b2a3b02 100644 --- a/build_files/cmake/cmake_qtcreator_project.py +++ b/build_files/cmake/cmake_qtcreator_project.py @@ -125,7 +125,6 @@ def cmake_advanced_info(): includes = [] defines = [] - create_eclipse_project(CMAKE_DIR) from xml.dom.minidom import parse diff --git a/doc/python_api/sphinx_changelog_gen.py b/doc/python_api/sphinx_changelog_gen.py index 4305157bd78..eb4fc4716e6 100644 --- a/doc/python_api/sphinx_changelog_gen.py +++ b/doc/python_api/sphinx_changelog_gen.py @@ -34,7 +34,7 @@ blender --background --python intern/tools/rna_api_dump.py -- \ # Api comparison can also run without blender -python intern/tools/rna_api_dump.py +python intern/tools/rna_api_dump.py --api_from blender_api_2_56_6.py \ --api_to blender_api_2_57.py \ --api_out changes.rst @@ -252,7 +252,6 @@ def api_changelog(api_from, api_to, api_out): if args_new != args_old: func_args.append((prop_id, args_old, args_new)) - if props_moved or set_props_new or set_props_old or func_args: props_moved.sort() props_new[:] = sorted(set_props_new) @@ -262,10 +261,6 @@ def api_changelog(api_from, api_to, api_out): api_changes.append((mod_id, class_id, props_moved, props_new, props_old, func_args)) # also document function argument changes - - - - fout = open(api_out, 'w') fw = fout.write @@ -298,7 +293,7 @@ def api_changelog(api_from, api_to, api_out): for prop_id_old, prop_id in props_moved: fw("* **%s** -> :class:`%s.%s.%s`\n" % (prop_id_old, mod_id, class_name, prop_id)) fw("\n") - + if func_args: write_title("Function Arguments", "^") for func_id, args_old, args_new in func_args: @@ -313,14 +308,13 @@ def api_changelog(api_from, api_to, api_out): def main(): import sys import os - + try: import argparse except: print("Old Blender, just dumping") api_dump() return - argv = sys.argv diff --git a/release/scripts/startup/bl_operators/object_quick_effects.py b/release/scripts/startup/bl_operators/object_quick_effects.py index c3de0a289a3..94074a52cd6 100644 --- a/release/scripts/startup/bl_operators/object_quick_effects.py +++ b/release/scripts/startup/bl_operators/object_quick_effects.py @@ -163,7 +163,7 @@ class MakeSmoke(bpy.types.Operator): # create a volume material with a voxel data texture for the domain bpy.ops.object.material_slot_add({"object": obj}) - mat = bpy.data.materials.new("Smoke Domain Material"); + mat = bpy.data.materials.new("Smoke Domain Material") obj.material_slots[0].material = mat mat.type = 'VOLUME' mat.volume.density = 0 @@ -274,8 +274,8 @@ class MakeFluid(bpy.types.Operator): # create a ray-transparent material for the domain bpy.ops.object.material_slot_add({"object": obj}) - - mat = bpy.data.materials.new("Fluid Domain Material"); + + mat = bpy.data.materials.new("Fluid Domain Material") obj.material_slots[0].material = mat mat.specular_intensity = 1 diff --git a/release/scripts/startup/bl_ui/space_nla.py b/release/scripts/startup/bl_ui/space_nla.py index 5c8e8cd9173..717adb3baa8 100644 --- a/release/scripts/startup/bl_ui/space_nla.py +++ b/release/scripts/startup/bl_ui/space_nla.py @@ -188,7 +188,7 @@ class NLA_MT_edit_transform(bpy.types.Menu): layout.column() layout.operator("transform.translate", text="Grab/Move") layout.operator("transform.transform", text="Extend").mode = 'TIME_EXTEND' - layout.operator("transform.transform", text="Scale").mode= 'TIME_SCALE' + layout.operator("transform.transform", text="Scale").mode = 'TIME_SCALE' if __name__ == "__main__": # only for live edit. bpy.utils.register_module(__name__) diff --git a/release/scripts/startup/keyingsets_builtins.py b/release/scripts/startup/keyingsets_builtins.py index cefc5cf38ed..0775d38c437 100644 --- a/release/scripts/startup/keyingsets_builtins.py +++ b/release/scripts/startup/keyingsets_builtins.py @@ -359,10 +359,11 @@ class BUILTIN_KSI_WholeCharacter(bpy.types.KeyingSetInfo): ############################### + # Delta Location class BUILTIN_KSI_DeltaLocation(bpy.types.KeyingSetInfo): bl_label = "Delta Location" - + # poll - selected objects only (and only if active object in object mode) poll = keyingsets_utils.RKS_POLL_selected_objects @@ -387,7 +388,7 @@ class BUILTIN_KSI_DeltaLocation(bpy.types.KeyingSetInfo): # Delta Rotation class BUILTIN_KSI_DeltaRotation(bpy.types.KeyingSetInfo): bl_label = "Delta Rotation" - + # poll - selected objects only (and only if active object in object mode) poll = keyingsets_utils.RKS_POLL_selected_objects @@ -406,7 +407,7 @@ class BUILTIN_KSI_DeltaRotation(bpy.types.KeyingSetInfo): elif data.rotation_mode == 'AXIS_ANGLE': # XXX: for now, this is not available yet #path = path_add_property(base_path, "delta_rotation_axis_angle") - return; + return else: path = keyingsets_utils.path_add_property(base_path, "delta_rotation_euler") @@ -415,12 +416,12 @@ class BUILTIN_KSI_DeltaRotation(bpy.types.KeyingSetInfo): ks.paths.add(id_block, path, group_method='NAMED', group_name=grouping) else: ks.paths.add(id_block, path) - + # Delta Scale class BUILTIN_KSI_DeltaScale(bpy.types.KeyingSetInfo): bl_label = "Delta Scale" - + # poll - selected objects only (and only if active object in object mode) poll = keyingsets_utils.RKS_POLL_selected_objects diff --git a/source/tests/pep8.py b/source/tests/pep8.py index 67ef12261d0..f7c416553b2 100644 --- a/source/tests/pep8.py +++ b/source/tests/pep8.py @@ -31,7 +31,7 @@ import os # in debian install pylint pyflakes pep8 with apt-get/aptitude/etc # # on *nix run -# python source/tests/pep8.py > pep8_error.txt 2>&1 +# python source/tests/pep8.py > test_pep8.log 2>&1 # how many lines to read into the file, pep8 comment # should be directly after the licence header, ~20 in most cases