这是个好问题。有很多方法可以应用一个小脚本,但最简单的方法需要几行代码。
关于以下代码的注释:
大多数参数可能会添加到查询中,如meta_query, category.wp_create_category(), 将创建一个类别。wp\\u set\\u post\\u terms(),仅适用于本机帖子类型,将新类别附加到其他现有类别。
function wpse_248054(){
    $custom_field_name = \'_credit\';
    $posts = new WP_Query(
        array(
            \'posts_per_page\' => -1,
            \'post_type\'=> \'post\',
        )   
    );
    foreach($posts->posts as $post){
        $meta = get_post_meta($post->ID, \'_credit\', true);
        if(! empty( $meta )){
            $term_id = wp_create_category($meta, 3); // 2nd argument, parent id (optional)
            $new_post_cat = wp_set_post_terms( $post->ID, $term_id, \'category\', true );
        }
    }
}
add_action(\'admin_init\', \'wpse_248054\');
 但很抱歉,我不知道有什么插件可以做到这一点;-)