actions: Sort actions before running them.