WP Create New Theme

Powershell

"style.css","loop.php","index.php","functions.php","header.php","footer.php","single.php","page.php","archive.php","search.php","404.php","screenshot.png" | ForEach-Object { New-Item -Path $_ -ItemType File -Force }
Set-Content -Path "style.css" -Value "/* Theme Name: MyTheme */"
├── 404.php
├── archive.php
├── footer.php
├── functions.php
├── header.php
├── index.php
├── page.php
├── search.php
├── loop.php
├── single.php
├── style.css

Command (Linux / macOS / Git Bash on Windows)

mkdir mytheme && cd mytheme && touch style.css index.php functions.php header.php footer.php sidebar.php single.php page.php archive.php search.php 404.php && mkdir -p assets/{css,js,img} && echo "/* Theme Name: MyTheme */" > style.css
mytheme/
├── 404.php
├── archive.php
├── footer.php
├── functions.php
├── header.php
├── index.php
├── page.php
├── search.php
├── sidebar.php
├── single.php
├── style.css
└── assets/
    ├── css/
    ├── js/
    └── img/

Leave a Comment