Skip to content

Commit 6f52ebe

Browse files
authored
[docs] Removing GitHub proxy references (#3009)
This pull request updates the documentation for plugin and theme developers to reflect the deprecation of the GitHub proxy in favor of the new `git:directory` resource for loading plugins and themes from GitHub repositories in WordPress Playground. It also improves clarity, updates example blueprints, and enhances the Spanish translation for plugin developer documentation.
1 parent 5de7bcf commit 6f52ebe

File tree

9 files changed

+1112
-327
lines changed

9 files changed

+1112
-327
lines changed

packages/docs/site/docs/main/guides/for-plugin-developers.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -50,19 +50,13 @@ Blueprints can be passed to a Playground instance [in several ways](/blueprints/
5050

5151
A plugin stored in a GitHub repository can also be loaded in a Playground instance via Blueprints.
5252

53-
With the `pluginData` property of the [`installPlugin` blueprint step](/blueprints/steps#installPlugin), you can define a [`url` resource](/blueprints/steps/resources#urlreference) that points to the location of the `.zip` file containing the plugin you want to load in the Playground instance.
54-
55-
To avoid CORS issues, the Playground project provides a [GitHub proxy](https://playground.wordpress.net/proxy) that allows you to generate a `.zip` from a repository (or even a folder inside a repo) containing your plugin.
53+
With the `pluginData` property of the [`installPlugin` blueprint step](/blueprints/steps#installPlugin), you can define a [`git:directory` resource](/blueprints/steps/resources#gitdirectoryreference) that will build a plugin from the files from a repository in the Playground instance.
5654

5755
:::info
58-
[GitHub proxy](https://playground.wordpress.net/proxy) is an incredibly useful tool to load plugins from GitHub repositories as it allows you to load a plugin from a specific branch, a specific directory, a specific commit or a specific PR.
59-
:::
60-
61-
:::tip
62-
If your plugin is hosted on GitHub, you can automatically add preview buttons to your pull requests using the Playground PR Preview GitHub Action. This lets reviewers test your changes instantly without any setup. See [Adding PR Preview Buttons with GitHub Actions](/guides/github-action-pr-preview) for details.
56+
For the past few months, the [GitHub proxy](https://playground.wordpress.net/proxy) was an incredibly useful tool to load plugins from GitHub repositories, as it allows you to load a plugin from a specific branch, a specific directory, a specific commit, or a specific PR. But with the recent improvements to Playground, this feature is no longer necessary. The GitHub Proxy will be discontinued soon, please update your blueprints to `git:directory` resource.
6357
:::
6458

65-
For example, the following `blueprint.json` installs a plugin from a GitHub repository leveraging the https://github-proxy.com tool:
59+
For example, the following `blueprint.json` installs a plugin from a GitHub repository:
6660

6761
```json
6862
{
@@ -72,15 +66,21 @@ For example, the following `blueprint.json` installs a plugin from a GitHub repo
7266
{
7367
"step": "installPlugin",
7468
"pluginData": {
75-
"resource": "url",
76-
"url": "https://github-proxy.com/proxy/?repo=wptrainingteam/devblog-dataviews-plugin"
69+
"resource": "git:directory",
70+
"url": "https://github.com/wptrainingteam/devblog-dataviews-plugin",
71+
"ref": "HEAD",
72+
"refType": "refname"
7773
}
7874
}
7975
]
8076
}
8177
```
8278

83-
[<kbd> &nbsp; Run Blueprint &nbsp; </kbd>](https://playground.wordpress.net/builder/builder.html#{%22landingPage%22:%22/wp-admin/admin.php?page=add-media-from-third-party-service%22,%22login%22:true,%22steps%22:[{%22step%22:%22installPlugin%22,%22pluginData%22:{%22resource%22:%22url%22,%22url%22:%22https://github-proxy.com/proxy/?repo=wptrainingteam/devblog-dataviews-plugin%22}}]})
79+
:::tip
80+
If your plugin is hosted on GitHub, you can automatically add preview buttons to your pull requests using the Playground PR Preview GitHub Action. This lets reviewers test your changes instantly without any setup. See [Adding PR Preview Buttons with GitHub Actions](/guides/github-action-pr-preview) for details.
81+
:::
82+
83+
[<kbd> &nbsp; Run Blueprint &nbsp; </kbd>](https://playground.wordpress.net/#{%22landingPage%22:%22/wp-admin/admin.php?page=add-media-from-third-party-service%22,%22login%22:true,%22steps%22:[{%22step%22:%22installPlugin%22,%22pluginData%22:{%22resource%22:%22git:directory%22,%22url%22:%22https://github.com/wptrainingteam/devblog-dataviews-plugin%22,%22ref%22:%22HEAD%22,%22refType%22:%22refname%22}}],%22$schema%22:%22https://playground.wordpress.net/blueprint-schema.json%22,%22meta%22:{%22title%22:%22Empty%20Blueprint%22,%22author%22:%22https://github.com/akirk/playground-step-library%22}})
8484

8585
### Plugin from code in a file or gist in GitHub
8686

@@ -126,9 +126,9 @@ When providing a link to a WordPress Playground instance with some plugins activ
126126

127127
Some useful tools and resources provided by the Playground project to work with blueprints are:
128128

129-
- Check the [Blueprints Gallery](https://github.com/WordPress/blueprints/blob/trunk/GALLERY.md) to explore real-world code examples of using WordPress Playground to launch a WordPress site with a variety of setups.
130-
- The [WordPress Playground Step Library](https://akirk.github.io/playground-step-library/#) tool provides a visual interface to drag or click the steps to create a blueprint for WordPress Playground. You can also create your own steps!
131-
- The [Blueprints builder](https://playground.wordpress.net/builder/builder.html) tool allows you edit your blueprint online and run it directly in a Playground instance.
129+
- Check the [Blueprints Gallery](https://github.com/WordPress/blueprints/blob/trunk/GALLERY.md) to explore real-world code examples of using WordPress Playground to launch a WordPress site with a variety of setups.
130+
- The [WordPress Playground Step Library](https://akirk.github.io/playground-step-library/#) tool provides a visual interface to drag or click the steps to create a blueprint for WordPress Playground. You can also create your own steps!
131+
- The [Blueprints builder](https://playground.wordpress.net/builder/builder.html) tool allows you edit your blueprint online and run it directly in a Playground instance.
132132

133133
:::
134134

@@ -213,8 +213,8 @@ npx @wp-playground/cli server --auto-mount
213213

214214
With Google Chrome you can synchronize a Playground instance with your local plugin's code and your plugin's GitHub repo. With this connection you can:
215215

216-
- See live (in the Playground instance) your local changes
217-
- Create PRs in the GitHub repo with your changes
216+
- See live (in the Playground instance) your local changes
217+
- Create PRs in the GitHub repo with your changes
218218

219219
Here's a little demo of this workflow in action:
220220

packages/docs/site/docs/main/guides/for-theme-developers.md

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -46,26 +46,24 @@ You can also load any theme from the WordPress themes directory by setting the [
4646

4747
A theme stored in a GitHub repository can also be loaded in a Playground instance with Blueprints.
4848

49-
In the `themeData` property of the [`installTheme` blueprint step](/blueprints/steps#InstallThemeStep), you can define a [`url` resource](/blueprints/steps/resources#urlreference) that points to the location of the `.zip` file containing the theme you want to load in the Playground instance.
49+
With the `themeData` property of the [`installTheme` blueprint step](/blueprints/steps#InstallThemeStep), you can define a [`git:directory` resource](/blueprints/steps/resources#gitdirectoryreference) that will build a theme from the files from a repository in the Playground instance.
5050

51-
To avoid CORS issues, the Playground project provides a [GitHub proxy](https://playground.wordpress.net/proxy) that allows you to generate a `.zip` from a repository (or even a folder inside a repo) containing your or theme.
52-
53-
:::tip
54-
[GitHub proxy](https://playground.wordpress.net/proxy) is an incredibly useful tool to load themes from GitHub repositories as it allows you to load a theme from a specific branch, a specific directory, a specific commit or a specific PR.
55-
56-
If your theme is hosted on GitHub, you can automatically add preview buttons to your pull requests using the Playground PR Preview GitHub Action. This lets reviewers test your changes instantly without any setup. See [Adding PR Preview Buttons with GitHub Actions](/guides/github-action-pr-preview) for details.
51+
:::info
52+
For the past few months, the [GitHub proxy](https://playground.wordpress.net/proxy) was an incredibly useful tool to load themes from GitHub repositories, as it allows you to load a theme from a specific branch, a specific directory, a specific commit, or a specific PR. But with the recent improvements to Playground, this feature is no longer necessary. The GitHub Proxy will be discontinued soon, please update your blueprints to `git:directory` resource.
5753
:::
5854

59-
For example the following `blueprint.json` installs a theme from a GitHub repository leveraging the https://github-proxy.com tool:
55+
For example the following `blueprint.json` installs a theme from a GitHub repository:
6056

6157
```json
6258
{
6359
"steps": [
6460
{
6561
"step": "installTheme",
6662
"themeData": {
67-
"resource": "url",
68-
"url": "https://github-proxy.com/proxy/?repo=Automattic/themes&branch=trunk&directory=assembler"
63+
"resource": "git:directory",
64+
"url": "https://github.com/Automattic/themes",
65+
"ref": "trunk",
66+
"path": "assembler"
6967
},
7068
"options": {
7169
"activate": true
@@ -75,7 +73,11 @@ For example the following `blueprint.json` installs a theme from a GitHub reposi
7573
}
7674
```
7775

78-
[<kbd> &nbsp; Run Blueprint &nbsp; </kbd>](https://playground.wordpress.net/builder/builder.html#{%22steps%22:[{%22step%22:%22installTheme%22,%22themeData%22:{%22resource%22:%22url%22,%22url%22:%22https://github-proxy.com/proxy/?repo=Automattic/themes&branch=trunk&directory=assembler%22},%22options%22:{%22activate%22:true}}]})
76+
:::tip
77+
If your theme is hosted on GitHub, you can automatically add preview buttons to your pull requests using the Playground PR Preview GitHub Action. This lets reviewers test your changes instantly without any setup. See [Adding PR Preview Buttons with GitHub Actions](/guides/github-action-pr-preview) for details.
78+
:::
79+
80+
[<kbd> &nbsp; Run Blueprint &nbsp; </kbd>](https://playground.wordpress.net/#{%22steps%22:[{%22step%22:%22installTheme%22,%22themeData%22:{%22resource%22:%22git:directory%22,%22url%22:%22https://github.com/Automattic/themes%22,%22ref%22:%22trunk%22,%22path%22:%22assembler%22},%22options%22:{%22activate%22:true}}],%22$schema%22:%22https://playground.wordpress.net/blueprint-schema.json%22,%22meta%22:{%22title%22:%22Empty%20Blueprint%22,%22author%22:%22https://github.com/akirk/playground-step-library%22}})
7981

8082
A blueprint can be passed to a Playground instance [in several ways](/blueprints/using-blueprints).
8183

@@ -87,9 +89,9 @@ When providing a link to a WordPress Playground instance with a specific theme a
8789

8890
Some useful tools and resources provided by the Playground project to work with blueprints are:
8991

90-
- Check the [Blueprints Gallery](https://github.com/WordPress/blueprints/blob/trunk/GALLERY.md) to explore real-world code examples of using WordPress Playground to launch a WordPress site with a variety of setups.
91-
- The [WordPress Playground Step Library](https://akirk.github.io/playground-step-library/#) tool provides a visual interface to drag or click the steps to create a blueprint for WordPress Playground. You can also create your own steps!
92-
- The [Blueprints builder](https://playground.wordpress.net/builder/builder.html) tool allows you edit your blueprint online and run it directly in a Playground instance.
92+
- Check the [Blueprints Gallery](https://github.com/WordPress/blueprints/blob/trunk/GALLERY.md) to explore real-world code examples of using WordPress Playground to launch a WordPress site with a variety of setups.
93+
- The [WordPress Playground Step Library](https://akirk.github.io/playground-step-library/#) tool provides a visual interface to drag or click the steps to create a blueprint for WordPress Playground. You can also create your own steps!
94+
- The [Blueprints builder](https://playground.wordpress.net/builder/builder.html) tool allows you edit your blueprint online and run it directly in a Playground instance.
9395

9496
:::
9597

0 commit comments

Comments
 (0)