Adding run() function to run tasks from within other tasks.