---
title: "Discussion on \"A Better Way to Build a WordPress Plugin\" | Hashnode"
description: "Discussion on \"A Better Way to Build a WordPress Plugin\". Scaffolding a WordPress plugin using WP CLI, WP ENV, PHPUnit and adding CI/CD with GitHub Actions"
url: "https://hashnode.com/posts/a-better-way-to-build-a-wordpress-plugin/6327752ab1a2e9b8401e181b"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [A Better Way to Build a WordPress Plugin](https://mc.hashnode.dev/a-better-way-to-build-a-wordpress-plugin?utm_source=hashnode&utm_medium=feed)

Scaffolding a WordPress plugin using WP CLI, WP ENV, PHPUnit and adding CI/CD with GitHub Actions

Sep 18, 2022 · 3 min read · mc.hashnode.dev  
Read the article

-   [#wordpress](https://hashnode.com/tag/wordpress)
-   [#github-actions-1](https://hashnode.com/tag/github-actions-1)
-   [#phpunit](https://hashnode.com/tag/phpunit)
-   [#wp-cli](https://hashnode.com/tag/wp-cli)
-   [#developer](https://hashnode.com/tag/developer)

## Written by

[Mark Cummins](https://hashnode.com/@markcummins)

@markcummins

  
[View profile](https://hashnode.com/@markcummins)

## Responses 1

Markdown supported · ⌘↵ to post

[Ritesh Tailor](https://hashnode.com/@riteshtailor)

[Nov 9, 2022](https://hashnode.com/posts/a-better-way-to-build-a-wordpress-plugin/6327752ab1a2e9b8401e181b/comment/636baed4846bd4f86306bd54)

Hi,

I have tried the exact procedure you have explained. Installed WP-CLI globally and then followed above code to create a custom plugin, but I am getting npm ERR! Missing script: "wp"

Could you please help me with what I am missing?
