[ranger] avoid forking the content of commands.py