From 5511e18133694cf78979e29df65d931371350aab Mon Sep 17 00:00:00 2001 From: Marijn van der Werf Date: Thu, 4 May 2023 11:03:02 +0200 Subject: [PATCH] Clean executable files (#1047) * Mark headers as non-executable * Update shebangs --- include/PR/PRimage.h | 0 include/PR/R4300.h | 0 include/PR/abi.h | 0 include/PR/gbi.h | 0 include/PR/gs2dex.h | 0 include/PR/gt.h | 0 include/PR/gu.h | 0 include/PR/leo.h | 0 include/PR/leoappli.h | 0 include/PR/libaudio.h | 0 include/PR/mbi.h | 0 include/PR/n_libaudio.h | 0 include/PR/n_libaudio_s_to_n.h | 0 include/PR/os.h | 0 include/PR/os_ai.h | 0 include/PR/os_cache.h | 0 include/PR/os_cont.h | 0 include/PR/os_convert.h | 0 include/PR/os_debug.h | 0 include/PR/os_eeprom.h | 0 include/PR/os_error.h | 0 include/PR/os_exception.h | 0 include/PR/os_gbpak.h | 0 include/PR/os_gio.h | 0 include/PR/os_host.h | 0 include/PR/os_internal.h | 0 include/PR/os_internal_debug.h | 0 include/PR/os_internal_error.h | 0 include/PR/os_internal_exception.h | 0 include/PR/os_internal_gio.h | 0 include/PR/os_internal_host.h | 0 include/PR/os_internal_reg.h | 0 include/PR/os_internal_rsp.h | 0 include/PR/os_internal_si.h | 0 include/PR/os_internal_thread.h | 0 include/PR/os_internal_tlb.h | 0 include/PR/os_libc.h | 0 include/PR/os_message.h | 0 include/PR/os_motor.h | 0 include/PR/os_pfs.h | 0 include/PR/os_pi.h | 0 include/PR/os_rdp.h | 0 include/PR/os_reg.h | 0 include/PR/os_rsp.h | 0 include/PR/os_si.h | 0 include/PR/os_system.h | 0 include/PR/os_thread.h | 0 include/PR/os_time.h | 0 include/PR/os_tlb.h | 0 include/PR/os_version.h | 0 include/PR/os_vi.h | 0 include/PR/os_voice.h | 0 include/PR/ramrom.h | 0 include/PR/rcp.h | 0 include/PR/rdb.h | 0 include/PR/region.h | 0 include/PR/rmon.h | 0 include/PR/sched.h | 0 include/PR/sp.h | 0 include/PR/sptask.h | 0 include/PR/ucode.h | 0 include/PR/ucode_debug.h | 0 include/PR/ultraerror.h | 0 include/PR/ultralog.h | 0 include/PR/ultratypes.h | 0 include/controller.h | 0 include/gcc/string.h | 0 include/libc/xstdio.h | 0 include/ultra64.h | 0 install.sh | 2 +- make_expected.sh | 2 ++ tools/asm_sizes.py | 2 +- tools/build/bin_inc_c.py | 2 +- tools/build/genobjcopy.py | 2 +- tools/build/img/build.py | 2 +- tools/build/img/header.py | 2 +- tools/build/imgfx/imgfx_data.py | 0 tools/build/ld/multilink_calc.py | 2 +- tools/build/mapfs/combine.py | 2 +- tools/build/mapfs/map_header.py | 2 +- tools/build/mapfs/pack_title_data.py | 2 +- tools/build/msg/combine.py | 2 +- tools/build/msg/parse_compile.py | 2 +- tools/build/pal_inc_c.py | 2 +- tools/build/pm_charset.py | 2 +- tools/build/pm_charset_palettes.py | 2 +- tools/build/sprite/combine.py | 2 +- tools/build/sprite/header.py | 2 +- tools/build/sprite/sprite.py | 2 +- tools/build/sprite/sprite_shading_profiles.py | 0 tools/disasm_animation.py | 2 +- tools/disasm_hud_element_animation.py | 2 +- tools/disasm_script.py | 2 +- tools/find_duplicates.py | 2 +- tools/find_similar_areas.py | 2 +- tools/gen_effect_renames.py | 2 +- tools/get_variable.py | 2 +- tools/migrate_data_to_c.py | 2 +- tools/migrate_effect_rodata.py | 2 +- tools/migrate_exit_strings.py | 2 +- tools/migrate_rodata.py | 2 +- tools/mv_segment.py | 2 +- tools/old/bootstrap_effects.py | 2 +- tools/old/codescan.py | 2 +- tools/old/create_renames.py | 0 tools/old/fix_s_filenames.py | 2 +- tools/old/m_map_funcs.py | 2 +- tools/old/set_reorder_asm.sh | 2 +- tools/precommit_check_no_assets.sh | 2 +- tools/rename.py | 2 +- tools/sjis.py | 2 +- tools/sort_symbol_addrs.py | 2 +- tools/splat/create_config.py | 2 +- tools/splat/split.py | 2 +- tools/splat/util/gc/gcinfo.py | 2 +- tools/splat/util/n64/find_code_length.py | 2 +- tools/splat/util/n64/rominfo.py | 2 +- tools/star_rod_enum_to_decomp.py | 2 +- tools/star_rod_idx_to_c.py | 2 +- tools/substitute.py | 2 +- tools/update_symbol_addrs.py | 2 +- tools/warnings_count/check_new_warnings.sh | 2 +- 122 files changed, 51 insertions(+), 49 deletions(-) mode change 100755 => 100644 include/PR/PRimage.h mode change 100755 => 100644 include/PR/R4300.h mode change 100755 => 100644 include/PR/abi.h mode change 100755 => 100644 include/PR/gbi.h mode change 100755 => 100644 include/PR/gs2dex.h mode change 100755 => 100644 include/PR/gt.h mode change 100755 => 100644 include/PR/gu.h mode change 100755 => 100644 include/PR/leo.h mode change 100755 => 100644 include/PR/leoappli.h mode change 100755 => 100644 include/PR/libaudio.h mode change 100755 => 100644 include/PR/mbi.h mode change 100755 => 100644 include/PR/n_libaudio.h mode change 100755 => 100644 include/PR/n_libaudio_s_to_n.h mode change 100755 => 100644 include/PR/os.h mode change 100755 => 100644 include/PR/os_ai.h mode change 100755 => 100644 include/PR/os_cache.h mode change 100755 => 100644 include/PR/os_cont.h mode change 100755 => 100644 include/PR/os_convert.h mode change 100755 => 100644 include/PR/os_debug.h mode change 100755 => 100644 include/PR/os_eeprom.h mode change 100755 => 100644 include/PR/os_error.h mode change 100755 => 100644 include/PR/os_exception.h mode change 100755 => 100644 include/PR/os_gbpak.h mode change 100755 => 100644 include/PR/os_gio.h mode change 100755 => 100644 include/PR/os_host.h mode change 100755 => 100644 include/PR/os_internal.h mode change 100755 => 100644 include/PR/os_internal_debug.h mode change 100755 => 100644 include/PR/os_internal_error.h mode change 100755 => 100644 include/PR/os_internal_exception.h mode change 100755 => 100644 include/PR/os_internal_gio.h mode change 100755 => 100644 include/PR/os_internal_host.h mode change 100755 => 100644 include/PR/os_internal_reg.h mode change 100755 => 100644 include/PR/os_internal_rsp.h mode change 100755 => 100644 include/PR/os_internal_si.h mode change 100755 => 100644 include/PR/os_internal_thread.h mode change 100755 => 100644 include/PR/os_internal_tlb.h mode change 100755 => 100644 include/PR/os_libc.h mode change 100755 => 100644 include/PR/os_message.h mode change 100755 => 100644 include/PR/os_motor.h mode change 100755 => 100644 include/PR/os_pfs.h mode change 100755 => 100644 include/PR/os_pi.h mode change 100755 => 100644 include/PR/os_rdp.h mode change 100755 => 100644 include/PR/os_reg.h mode change 100755 => 100644 include/PR/os_rsp.h mode change 100755 => 100644 include/PR/os_si.h mode change 100755 => 100644 include/PR/os_system.h mode change 100755 => 100644 include/PR/os_thread.h mode change 100755 => 100644 include/PR/os_time.h mode change 100755 => 100644 include/PR/os_tlb.h mode change 100755 => 100644 include/PR/os_version.h mode change 100755 => 100644 include/PR/os_vi.h mode change 100755 => 100644 include/PR/os_voice.h mode change 100755 => 100644 include/PR/ramrom.h mode change 100755 => 100644 include/PR/rcp.h mode change 100755 => 100644 include/PR/rdb.h mode change 100755 => 100644 include/PR/region.h mode change 100755 => 100644 include/PR/rmon.h mode change 100755 => 100644 include/PR/sched.h mode change 100755 => 100644 include/PR/sp.h mode change 100755 => 100644 include/PR/sptask.h mode change 100755 => 100644 include/PR/ucode.h mode change 100755 => 100644 include/PR/ucode_debug.h mode change 100755 => 100644 include/PR/ultraerror.h mode change 100755 => 100644 include/PR/ultralog.h mode change 100755 => 100644 include/PR/ultratypes.h mode change 100755 => 100644 include/controller.h mode change 100755 => 100644 include/gcc/string.h mode change 100755 => 100644 include/libc/xstdio.h mode change 100755 => 100644 include/ultra64.h mode change 100644 => 100755 tools/build/bin_inc_c.py mode change 100644 => 100755 tools/build/genobjcopy.py mode change 100644 => 100755 tools/build/imgfx/imgfx_data.py mode change 100644 => 100755 tools/build/mapfs/map_header.py mode change 100644 => 100755 tools/build/pal_inc_c.py mode change 100644 => 100755 tools/build/pm_charset.py mode change 100644 => 100755 tools/build/pm_charset_palettes.py mode change 100644 => 100755 tools/build/sprite/sprite_shading_profiles.py mode change 100755 => 100644 tools/old/create_renames.py mode change 100644 => 100755 tools/old/m_map_funcs.py mode change 100644 => 100755 tools/splat/util/gc/gcinfo.py diff --git a/include/PR/PRimage.h b/include/PR/PRimage.h old mode 100755 new mode 100644 diff --git a/include/PR/R4300.h b/include/PR/R4300.h old mode 100755 new mode 100644 diff --git a/include/PR/abi.h b/include/PR/abi.h old mode 100755 new mode 100644 diff --git a/include/PR/gbi.h b/include/PR/gbi.h old mode 100755 new mode 100644 diff --git a/include/PR/gs2dex.h b/include/PR/gs2dex.h old mode 100755 new mode 100644 diff --git a/include/PR/gt.h b/include/PR/gt.h old mode 100755 new mode 100644 diff --git a/include/PR/gu.h b/include/PR/gu.h old mode 100755 new mode 100644 diff --git a/include/PR/leo.h b/include/PR/leo.h old mode 100755 new mode 100644 diff --git a/include/PR/leoappli.h b/include/PR/leoappli.h old mode 100755 new mode 100644 diff --git a/include/PR/libaudio.h b/include/PR/libaudio.h old mode 100755 new mode 100644 diff --git a/include/PR/mbi.h b/include/PR/mbi.h old mode 100755 new mode 100644 diff --git a/include/PR/n_libaudio.h b/include/PR/n_libaudio.h old mode 100755 new mode 100644 diff --git a/include/PR/n_libaudio_s_to_n.h b/include/PR/n_libaudio_s_to_n.h old mode 100755 new mode 100644 diff --git a/include/PR/os.h b/include/PR/os.h old mode 100755 new mode 100644 diff --git a/include/PR/os_ai.h b/include/PR/os_ai.h old mode 100755 new mode 100644 diff --git a/include/PR/os_cache.h b/include/PR/os_cache.h old mode 100755 new mode 100644 diff --git a/include/PR/os_cont.h b/include/PR/os_cont.h old mode 100755 new mode 100644 diff --git a/include/PR/os_convert.h b/include/PR/os_convert.h old mode 100755 new mode 100644 diff --git a/include/PR/os_debug.h b/include/PR/os_debug.h old mode 100755 new mode 100644 diff --git a/include/PR/os_eeprom.h b/include/PR/os_eeprom.h old mode 100755 new mode 100644 diff --git a/include/PR/os_error.h b/include/PR/os_error.h old mode 100755 new mode 100644 diff --git a/include/PR/os_exception.h b/include/PR/os_exception.h old mode 100755 new mode 100644 diff --git a/include/PR/os_gbpak.h b/include/PR/os_gbpak.h old mode 100755 new mode 100644 diff --git a/include/PR/os_gio.h b/include/PR/os_gio.h old mode 100755 new mode 100644 diff --git a/include/PR/os_host.h b/include/PR/os_host.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal.h b/include/PR/os_internal.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_debug.h b/include/PR/os_internal_debug.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_error.h b/include/PR/os_internal_error.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_exception.h b/include/PR/os_internal_exception.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_gio.h b/include/PR/os_internal_gio.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_host.h b/include/PR/os_internal_host.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_reg.h b/include/PR/os_internal_reg.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_rsp.h b/include/PR/os_internal_rsp.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_si.h b/include/PR/os_internal_si.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_thread.h b/include/PR/os_internal_thread.h old mode 100755 new mode 100644 diff --git a/include/PR/os_internal_tlb.h b/include/PR/os_internal_tlb.h old mode 100755 new mode 100644 diff --git a/include/PR/os_libc.h b/include/PR/os_libc.h old mode 100755 new mode 100644 diff --git a/include/PR/os_message.h b/include/PR/os_message.h old mode 100755 new mode 100644 diff --git a/include/PR/os_motor.h b/include/PR/os_motor.h old mode 100755 new mode 100644 diff --git a/include/PR/os_pfs.h b/include/PR/os_pfs.h old mode 100755 new mode 100644 diff --git a/include/PR/os_pi.h b/include/PR/os_pi.h old mode 100755 new mode 100644 diff --git a/include/PR/os_rdp.h b/include/PR/os_rdp.h old mode 100755 new mode 100644 diff --git a/include/PR/os_reg.h b/include/PR/os_reg.h old mode 100755 new mode 100644 diff --git a/include/PR/os_rsp.h b/include/PR/os_rsp.h old mode 100755 new mode 100644 diff --git a/include/PR/os_si.h b/include/PR/os_si.h old mode 100755 new mode 100644 diff --git a/include/PR/os_system.h b/include/PR/os_system.h old mode 100755 new mode 100644 diff --git a/include/PR/os_thread.h b/include/PR/os_thread.h old mode 100755 new mode 100644 diff --git a/include/PR/os_time.h b/include/PR/os_time.h old mode 100755 new mode 100644 diff --git a/include/PR/os_tlb.h b/include/PR/os_tlb.h old mode 100755 new mode 100644 diff --git a/include/PR/os_version.h b/include/PR/os_version.h old mode 100755 new mode 100644 diff --git a/include/PR/os_vi.h b/include/PR/os_vi.h old mode 100755 new mode 100644 diff --git a/include/PR/os_voice.h b/include/PR/os_voice.h old mode 100755 new mode 100644 diff --git a/include/PR/ramrom.h b/include/PR/ramrom.h old mode 100755 new mode 100644 diff --git a/include/PR/rcp.h b/include/PR/rcp.h old mode 100755 new mode 100644 diff --git a/include/PR/rdb.h b/include/PR/rdb.h old mode 100755 new mode 100644 diff --git a/include/PR/region.h b/include/PR/region.h old mode 100755 new mode 100644 diff --git a/include/PR/rmon.h b/include/PR/rmon.h old mode 100755 new mode 100644 diff --git a/include/PR/sched.h b/include/PR/sched.h old mode 100755 new mode 100644 diff --git a/include/PR/sp.h b/include/PR/sp.h old mode 100755 new mode 100644 diff --git a/include/PR/sptask.h b/include/PR/sptask.h old mode 100755 new mode 100644 diff --git a/include/PR/ucode.h b/include/PR/ucode.h old mode 100755 new mode 100644 diff --git a/include/PR/ucode_debug.h b/include/PR/ucode_debug.h old mode 100755 new mode 100644 diff --git a/include/PR/ultraerror.h b/include/PR/ultraerror.h old mode 100755 new mode 100644 diff --git a/include/PR/ultralog.h b/include/PR/ultralog.h old mode 100755 new mode 100644 diff --git a/include/PR/ultratypes.h b/include/PR/ultratypes.h old mode 100755 new mode 100644 diff --git a/include/controller.h b/include/controller.h old mode 100755 new mode 100644 diff --git a/include/gcc/string.h b/include/gcc/string.h old mode 100755 new mode 100644 diff --git a/include/libc/xstdio.h b/include/libc/xstdio.h old mode 100755 new mode 100644 diff --git a/include/ultra64.h b/include/ultra64.h old mode 100755 new mode 100644 diff --git a/install.sh b/install.sh index 79cc1b38aa..f2cdd51230 100755 --- a/install.sh +++ b/install.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash if [[ "$UID" -eq "0" ]]; then SUDO="" diff --git a/make_expected.sh b/make_expected.sh index 8a0afa6558..357669c544 100755 --- a/make_expected.sh +++ b/make_expected.sh @@ -1,3 +1,5 @@ +#!/usr/bin/env sh + rm -rf ver/*/expected mkdir -p ver/us/expected/ver/us diff --git a/tools/asm_sizes.py b/tools/asm_sizes.py index 673eac5550..6de3f3e84e 100755 --- a/tools/asm_sizes.py +++ b/tools/asm_sizes.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import json import glob diff --git a/tools/build/bin_inc_c.py b/tools/build/bin_inc_c.py old mode 100644 new mode 100755 index 38ca859026..c05118a0bd --- a/tools/build/bin_inc_c.py +++ b/tools/build/bin_inc_c.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from pathlib import Path from sys import argv diff --git a/tools/build/genobjcopy.py b/tools/build/genobjcopy.py old mode 100644 new mode 100755 index 4d24023772..2232a4e828 --- a/tools/build/genobjcopy.py +++ b/tools/build/genobjcopy.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import sys, os #Under normal compilation we rely on splat to use a discard option in the ldscript diff --git a/tools/build/img/build.py b/tools/build/img/build.py index 9892fa6829..65c15579f9 100755 --- a/tools/build/img/build.py +++ b/tools/build/img/build.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv, stderr from math import floor, ceil diff --git a/tools/build/img/header.py b/tools/build/img/header.py index ac6c9d847d..855298aa03 100755 --- a/tools/build/img/header.py +++ b/tools/build/img/header.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv import re diff --git a/tools/build/imgfx/imgfx_data.py b/tools/build/imgfx/imgfx_data.py old mode 100644 new mode 100755 diff --git a/tools/build/ld/multilink_calc.py b/tools/build/ld/multilink_calc.py index 046c859cb0..05af4a7fa0 100755 --- a/tools/build/ld/multilink_calc.py +++ b/tools/build/ld/multilink_calc.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import os from pathlib import Path diff --git a/tools/build/mapfs/combine.py b/tools/build/mapfs/combine.py index b710dee9bf..86d53597a3 100755 --- a/tools/build/mapfs/combine.py +++ b/tools/build/mapfs/combine.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import os from sys import argv diff --git a/tools/build/mapfs/map_header.py b/tools/build/mapfs/map_header.py old mode 100644 new mode 100755 index 59841f9b6d..7812fa31da --- a/tools/build/mapfs/map_header.py +++ b/tools/build/mapfs/map_header.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv, stderr from os import path diff --git a/tools/build/mapfs/pack_title_data.py b/tools/build/mapfs/pack_title_data.py index 19dd54ab27..222c7f2697 100755 --- a/tools/build/mapfs/pack_title_data.py +++ b/tools/build/mapfs/pack_title_data.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv diff --git a/tools/build/msg/combine.py b/tools/build/msg/combine.py index 186547b9da..5b6cc4af41 100755 --- a/tools/build/msg/combine.py +++ b/tools/build/msg/combine.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv from collections import OrderedDict diff --git a/tools/build/msg/parse_compile.py b/tools/build/msg/parse_compile.py index b9b14e6197..85d40c731a 100755 --- a/tools/build/msg/parse_compile.py +++ b/tools/build/msg/parse_compile.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv from collections import OrderedDict diff --git a/tools/build/pal_inc_c.py b/tools/build/pal_inc_c.py old mode 100644 new mode 100755 index 25a7f7909b..4256da94ad --- a/tools/build/pal_inc_c.py +++ b/tools/build/pal_inc_c.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from pathlib import Path from sys import argv diff --git a/tools/build/pm_charset.py b/tools/build/pm_charset.py old mode 100644 new mode 100755 index 970d647d3f..b7830021f7 --- a/tools/build/pm_charset.py +++ b/tools/build/pm_charset.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv diff --git a/tools/build/pm_charset_palettes.py b/tools/build/pm_charset_palettes.py old mode 100644 new mode 100755 index 7c7825e29a..af5040a218 --- a/tools/build/pm_charset_palettes.py +++ b/tools/build/pm_charset_palettes.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv diff --git a/tools/build/sprite/combine.py b/tools/build/sprite/combine.py index 19bb8a82f8..fd208d850f 100755 --- a/tools/build/sprite/combine.py +++ b/tools/build/sprite/combine.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv diff --git a/tools/build/sprite/header.py b/tools/build/sprite/header.py index c1d7c29600..5e06458a87 100755 --- a/tools/build/sprite/header.py +++ b/tools/build/sprite/header.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from sys import argv, path from pathlib import Path diff --git a/tools/build/sprite/sprite.py b/tools/build/sprite/sprite.py index 7662486f08..7bf95fad4b 100755 --- a/tools/build/sprite/sprite.py +++ b/tools/build/sprite/sprite.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 from math import floor, ceil from sys import argv, path diff --git a/tools/build/sprite/sprite_shading_profiles.py b/tools/build/sprite/sprite_shading_profiles.py old mode 100644 new mode 100755 diff --git a/tools/disasm_animation.py b/tools/disasm_animation.py index b10e2a4823..7f50b962c2 100755 --- a/tools/disasm_animation.py +++ b/tools/disasm_animation.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import struct diff --git a/tools/disasm_hud_element_animation.py b/tools/disasm_hud_element_animation.py index d74a6eaa1c..ce9a1dcc31 100755 --- a/tools/disasm_hud_element_animation.py +++ b/tools/disasm_hud_element_animation.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import struct import argparse diff --git a/tools/disasm_script.py b/tools/disasm_script.py index 4533e68fcb..2b6e46ab40 100755 --- a/tools/disasm_script.py +++ b/tools/disasm_script.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import sym_info from pathlib import Path diff --git a/tools/find_duplicates.py b/tools/find_duplicates.py index aafdcb81f0..862ea1f661 100755 --- a/tools/find_duplicates.py +++ b/tools/find_duplicates.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import argparse from collections import Counter, OrderedDict diff --git a/tools/find_similar_areas.py b/tools/find_similar_areas.py index ab38f06492..095a955b78 100755 --- a/tools/find_similar_areas.py +++ b/tools/find_similar_areas.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import argparse import os diff --git a/tools/gen_effect_renames.py b/tools/gen_effect_renames.py index 5984672bc2..9886f610b7 100755 --- a/tools/gen_effect_renames.py +++ b/tools/gen_effect_renames.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import argparse import os diff --git a/tools/get_variable.py b/tools/get_variable.py index da88b2ddce..3455e5b6b0 100755 --- a/tools/get_variable.py +++ b/tools/get_variable.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import sys diff --git a/tools/migrate_data_to_c.py b/tools/migrate_data_to_c.py index bac72a2015..743f946293 100755 --- a/tools/migrate_data_to_c.py +++ b/tools/migrate_data_to_c.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import re import os diff --git a/tools/migrate_effect_rodata.py b/tools/migrate_effect_rodata.py index 08480e3cf2..ce4fa2695d 100755 --- a/tools/migrate_effect_rodata.py +++ b/tools/migrate_effect_rodata.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import os from pathlib import Path diff --git a/tools/migrate_exit_strings.py b/tools/migrate_exit_strings.py index 39fd0bf45e..067f378bee 100755 --- a/tools/migrate_exit_strings.py +++ b/tools/migrate_exit_strings.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import os from pathlib import Path diff --git a/tools/migrate_rodata.py b/tools/migrate_rodata.py index c069071463..65393e5b06 100755 --- a/tools/migrate_rodata.py +++ b/tools/migrate_rodata.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import os from pathlib import Path diff --git a/tools/mv_segment.py b/tools/mv_segment.py index aa613e9250..457435ce0e 100755 --- a/tools/mv_segment.py +++ b/tools/mv_segment.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import argparse import os diff --git a/tools/old/bootstrap_effects.py b/tools/old/bootstrap_effects.py index 430af0eb9c..c591461d6c 100755 --- a/tools/old/bootstrap_effects.py +++ b/tools/old/bootstrap_effects.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import os import re diff --git a/tools/old/codescan.py b/tools/old/codescan.py index 6b6bfdd60d..95441525ae 100755 --- a/tools/old/codescan.py +++ b/tools/old/codescan.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import glob import os diff --git a/tools/old/create_renames.py b/tools/old/create_renames.py old mode 100755 new mode 100644 diff --git a/tools/old/fix_s_filenames.py b/tools/old/fix_s_filenames.py index 9f0424e5c0..4fd73c460b 100755 --- a/tools/old/fix_s_filenames.py +++ b/tools/old/fix_s_filenames.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 # Renames asm/nonmatchings/ files to match the glabel they hold. diff --git a/tools/old/m_map_funcs.py b/tools/old/m_map_funcs.py old mode 100644 new mode 100755 index cca22172e4..755fb588d6 --- a/tools/old/m_map_funcs.py +++ b/tools/old/m_map_funcs.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import os import sys diff --git a/tools/old/set_reorder_asm.sh b/tools/old/set_reorder_asm.sh index 4168a45074..ccfaa97440 100755 --- a/tools/old/set_reorder_asm.sh +++ b/tools/old/set_reorder_asm.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash shopt -s globstar diff --git a/tools/precommit_check_no_assets.sh b/tools/precommit_check_no_assets.sh index d5a73bd99b..080174e9cb 100755 --- a/tools/precommit_check_no_assets.sh +++ b/tools/precommit_check_no_assets.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # This script is copied into the pre-commit git hooks folder. # It ensures that a commit is aborted if you try to accidentally commit game assets. # install.sh will install this for you. diff --git a/tools/rename.py b/tools/rename.py index ce1874de57..f245b9a9fe 100755 --- a/tools/rename.py +++ b/tools/rename.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import os from tqdm import tqdm diff --git a/tools/sjis.py b/tools/sjis.py index a2977312a1..19252ff334 100755 --- a/tools/sjis.py +++ b/tools/sjis.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 def decode(data): length = 0 diff --git a/tools/sort_symbol_addrs.py b/tools/sort_symbol_addrs.py index 95966c80d0..38d452c09e 100755 --- a/tools/sort_symbol_addrs.py +++ b/tools/sort_symbol_addrs.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 from collections import OrderedDict import os diff --git a/tools/splat/create_config.py b/tools/splat/create_config.py index 55241d0952..a41a3f8eed 100755 --- a/tools/splat/create_config.py +++ b/tools/splat/create_config.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python3 +#!/usr/bin/env python3 import argparse import sys diff --git a/tools/splat/split.py b/tools/splat/split.py index 040f286727..a8503ff07b 100755 --- a/tools/splat/split.py +++ b/tools/splat/split.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python3 +#!/usr/bin/env python3 import argparse import hashlib diff --git a/tools/splat/util/gc/gcinfo.py b/tools/splat/util/gc/gcinfo.py old mode 100644 new mode 100755 index 78130df8bc..57641e109a --- a/tools/splat/util/gc/gcinfo.py +++ b/tools/splat/util/gc/gcinfo.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python3 +#!/usr/bin/env python3 import argparse diff --git a/tools/splat/util/n64/find_code_length.py b/tools/splat/util/n64/find_code_length.py index 1f9053cab4..4f2caeaadb 100755 --- a/tools/splat/util/n64/find_code_length.py +++ b/tools/splat/util/n64/find_code_length.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python3 +#!/usr/bin/env python3 import argparse diff --git a/tools/splat/util/n64/rominfo.py b/tools/splat/util/n64/rominfo.py index a210c2340d..05ec7aae27 100755 --- a/tools/splat/util/n64/rominfo.py +++ b/tools/splat/util/n64/rominfo.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python3 +#!/usr/bin/env python3 import argparse diff --git a/tools/star_rod_enum_to_decomp.py b/tools/star_rod_enum_to_decomp.py index 434c023a04..0e9874325a 100755 --- a/tools/star_rod_enum_to_decomp.py +++ b/tools/star_rod_enum_to_decomp.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import argparse import sys diff --git a/tools/star_rod_idx_to_c.py b/tools/star_rod_idx_to_c.py index 5dc3b88dbe..9d0fe629a8 100755 --- a/tools/star_rod_idx_to_c.py +++ b/tools/star_rod_idx_to_c.py @@ -1,4 +1,4 @@ -#! /usr/bin/python3 +#!/usr/bin/env python3 import sys import os diff --git a/tools/substitute.py b/tools/substitute.py index 0dbbe2ecdf..ea7c39f7fd 100755 --- a/tools/substitute.py +++ b/tools/substitute.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import argparse import os diff --git a/tools/update_symbol_addrs.py b/tools/update_symbol_addrs.py index 2e7fba9b1f..5e1263ecf4 100755 --- a/tools/update_symbol_addrs.py +++ b/tools/update_symbol_addrs.py @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 import os import re diff --git a/tools/warnings_count/check_new_warnings.sh b/tools/warnings_count/check_new_warnings.sh index 1117fd432f..24072a7ebb 100755 --- a/tools/warnings_count/check_new_warnings.sh +++ b/tools/warnings_count/check_new_warnings.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash set -e set -o pipefail