Update publish dependency script to support package project type