[Rakefile] Improve release task to support core