Skip to content

Commit dd2f686

Browse files
authored
Merge pull request #71 from alleyinteractive/feature/issue-70/enable-theme-scaffolding-release
Issue-70: Release initial version of create-wordpress-theme and enable theme scaffolding
2 parents eac1d1c + 9bab58e commit dd2f686

File tree

1 file changed

+12
-9
lines changed

1 file changed

+12
-9
lines changed

configure.php

+12-9
Original file line numberDiff line numberDiff line change
@@ -464,15 +464,18 @@ function install_plugin( array $plugin_data, bool $prompt = false ): void {
464464
echo "Done!\n\n";
465465
}
466466

467-
// TODO: scaffold the theme from create-wordpress-theme when the project is ready.
468-
// if ( ! empty( $theme_slug ) ) {
469-
// write( "Scaffolding create-wordpress-theme to themes/{$theme_slug}..." );
470-
471-
// run(
472-
// "composer create-project alleyinteractive/create-wordpress-theme themes/{$theme_slug}",
473-
// $current_dir,
474-
// );
475-
// }
467+
if ( ! empty( $theme_slug ) ) {
468+
write( "Scaffolding create-wordpress-theme to themes/{$theme_slug}..." );
469+
470+
run(
471+
"composer create-project alleyinteractive/create-wordpress-theme themes/{$theme_slug}",
472+
$current_dir,
473+
);
474+
run(
475+
"wp theme activate {$theme_slug}",
476+
$current_dir,
477+
);
478+
}
476479

477480
foreach ( list_all_files_for_replacement() as $path ) {
478481
echo "Updating $path...\n";

0 commit comments

Comments
 (0)