How to run hook specifically for 'ionic build --prod'?



I wrote a gulp task and run it on ionic:build:after.

Now I realy don’t need it for every build and would like to add functionality that should only be executed when ionic build --prod is called (opposed to just ionic build).

Is there a way to achieve this? Maybee with a condition in my gulpfile?

I’m using Ionic 4.