'Disable quiting when pressing `q` in NERDTree vim plugin

When I press q in the NERDTree window it quits. I would like to disable that behaviour.

I am using q to create a script when I need to make the same change to a lot of files. But I cannot start the script from the NERDTree window itself, because that quits it. Alternatively I would like to know how to start the q scripting with another command.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source