Skip to content

Commit 341d754

Browse files
authored
Merge pull request #1 from lightspeedwp/copilot/convert-starter-to-lightspeed-plugin
Convert ls-starter-plugin to LightSpeed Site Plugin
2 parents c147d99 + eb6ce51 commit 341d754

32 files changed

Lines changed: 21868 additions & 242 deletions

.agents/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# .agents
22

3-
This folder contains portable agent-specific assets for {{PLUGIN_NAME}}.
3+
This folder contains portable agent-specific assets for LightSpeed Site Plugin.
44
These assets are designed to be reusable across different AI systems and tools.
55

66
---

.agents/agents/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# .agents/agents
22

3-
This folder contains agent persona definitions for {{PLUGIN_NAME}}.
3+
This folder contains agent persona definitions for LightSpeed Site Plugin.
44

55
---
66

.agents/skills/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# .agents/skills
22

3-
This folder contains portable, reusable agent skills for {{PLUGIN_NAME}}.
3+
This folder contains portable, reusable agent skills for LightSpeed Site Plugin.
44

55
---
66

.agents/skills/block-plugin-audit/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ Use this skill when:
6464

6565
### 6. General quality
6666

67-
- Check for unreplaced `{{PLACEHOLDER}}` tokens.
67+
- Check for any unreplaced placeholder tokens (e.g. double-brace `{{ }}` style).
6868
- Check that `CHANGELOG.md` is up to date.
6969
- Check for unused files or stale commented-out code.
7070

.coderabbit.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ tone_instructions: "Be direct and professional. Focus on practical WordPress plu
1414

1515
# Path-level review instructions
1616
path_instructions:
17-
- path: "{{PLUGIN_SLUG}}.php"
17+
- path: "ls-plugin.php"
1818
instructions: |
1919
Review the main plugin bootstrap file.
2020
Check for: valid plugin header with all required fields, direct access protection (ABSPATH check),

.github/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# .github
22

3-
This folder contains GitHub-native AI and repository workflow infrastructure for {{PLUGIN_NAME}}.
3+
This folder contains GitHub-native AI and repository workflow infrastructure for LightSpeed Site Plugin.
44

55
---
66

.github/copilot-instructions.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
# GitHub Copilot Instructions
22

3-
This file configures GitHub Copilot for the {{PLUGIN_NAME}} repository.
3+
This file configures GitHub Copilot for the LightSpeed Site Plugin repository.
44
Read [`AGENTS.md`](../AGENTS.md) for full agent guidance.
55

66
---
77

88
## Repo overview
99

10-
This is a LightSpeed WordPress block plugin starter.
10+
This is the LightSpeed Site Plugin — custom blocks and site-specific functionality for [lightspeedwp.agency](https://lightspeedwp.agency/).
1111
- One plugin, one repo.
1212
- Block-ready but not locked into a large block framework.
13-
- Uses placeholder tokens (`{{DOUBLE_BRACES}}`) throughout — replace before production.
13+
- Plugin slug: `ls-plugin`, text domain: `ls-plugin`, constant prefix: `LS_PLUGIN_`.
1414

1515
---
1616

@@ -28,7 +28,7 @@ This is a LightSpeed WordPress block plugin starter.
2828

2929
| What | Where |
3030
|---|---|
31-
| Main plugin bootstrap | `{{PLUGIN_SLUG}}.php` |
31+
| Main plugin bootstrap | `ls-plugin.php` |
3232
| PHP includes | `inc/` |
3333
| Block source files | `src/blocks/` |
3434
| Built block assets | `blocks/` |

.github/instructions/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# .github/instructions
22

3-
This folder contains file-type-specific GitHub Copilot instruction files for {{PLUGIN_NAME}}.
3+
This folder contains file-type-specific GitHub Copilot instruction files for LightSpeed Site Plugin.
44

55
---
66

.github/instructions/assets.instructions.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ Use `wp_enqueue_style()` and `wp_enqueue_script()` with versioning:
3131

3232
```php
3333
wp_enqueue_style(
34-
'{{PLUGIN_SLUG}}-frontend',
35-
{{NAMESPACE}}_PLUGIN_URL . 'assets/css/frontend.css',
34+
'ls-plugin-frontend',
35+
LS_PLUGIN_PLUGIN_URL . 'assets/css/frontend.css',
3636
[],
37-
{{NAMESPACE}}_VERSION
37+
LS_PLUGIN_VERSION
3838
);
3939
```
4040

.github/instructions/blocks.instructions.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ applyTo: "**/{blocks,src/blocks}/**"
66

77
## Block structure
88

9-
Each block lives in its own directory under `src/blocks/{{block-name}}/`.
10-
Built assets are output to `blocks/{{block-name}}/`.
9+
Each block lives in its own directory under `src/blocks/{block-name}/`.
10+
Built assets are output to `blocks/{block-name}/`.
1111

1212
Typical block directory:
1313

@@ -26,9 +26,9 @@ Every block must have a `block.json` file with:
2626

2727
- `$schema`: reference the WordPress block schema
2828
- `apiVersion`: use `3`
29-
- `name`: `{{PLUGIN_SLUG}}/block-name`
29+
- `name`: `ls-plugin/block-name`
3030
- `title`, `description`, `category`, `icon`
31-
- `textdomain`: `{{TEXT_DOMAIN}}`
31+
- `textdomain`: `ls-plugin`
3232
- `editorScript`, `style`, `viewScript` as appropriate
3333
- `supports` and `attributes` declarations
3434

@@ -38,12 +38,12 @@ Example:
3838
{
3939
"$schema": "https://schemas.wp.org/trunk/block.json",
4040
"apiVersion": 3,
41-
"name": "{{PLUGIN_SLUG}}/my-block",
41+
"name": "ls-plugin/my-block",
4242
"title": "My Block",
4343
"category": "text",
4444
"icon": "block-default",
4545
"description": "A short block description.",
46-
"textdomain": "{{TEXT_DOMAIN}}",
46+
"textdomain": "ls-plugin",
4747
"editorScript": "file:./index.js",
4848
"style": "file:./style.css",
4949
"supports": {
@@ -58,7 +58,7 @@ Example:
5858
Register blocks in the main plugin file or a dedicated `inc/` file:
5959

6060
```php
61-
register_block_type( {{NAMESPACE}}_PLUGIN_DIR . 'blocks/my-block' );
61+
register_block_type( LS_PLUGIN_PLUGIN_DIR . 'blocks/my-block' );
6262
```
6363

6464
Do not manually register scripts and styles when `block.json` handles it.
@@ -68,9 +68,9 @@ Do not manually register scripts and styles when `block.json` handles it.
6868
For `render_callback` blocks:
6969

7070
```php
71-
function {{PLUGIN_SLUG}}_render_my_block( $attributes, $content, $block ) {
71+
function ls_plugin_render_my_block( $attributes, $content, $block ) {
7272
$title = isset( $attributes['title'] ) ? sanitize_text_field( $attributes['title'] ) : '';
73-
return '<div class="wp-block-{{PLUGIN_SLUG}}-my-block">' . esc_html( $title ) . '</div>';
73+
return '<div class="wp-block-ls-plugin-my-block">' . esc_html( $title ) . '</div>';
7474
}
7575
```
7676

0 commit comments

Comments
 (0)