Then create a separate branch for your 'customized' version of Moodle, and keep all of the tweaks you make in commits in that branch. You can then merge updates from the main line into your custom branch fairly easily, though you will still have to watch for changes and in some ways re-apply your changes with each major version update, which is why keeping them in a separate branch with separate commits is so important.
Hi Raphael, yes, there are SCORM specific code changes from 2.5 to 2.8 also.. I would strongly recommend setting up a git repository tracking the Moodle core branches via the instructions here: https://docs.moodle.org/28/en/Git_for_Administrators