-
Notifications
You must be signed in to change notification settings - Fork 374
Deprecate github-proxy.com with automatic migration to native resources #3007
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
adamziel
wants to merge
6
commits into
trunk
Choose a base branch
from
github-proxy-com-migration-path
base: trunk
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-proxy.com is being shut down. This change provides a graceful migration path for existing Blueprints that reference github-proxy.com URLs. When a Blueprint contains a URL resource pointing to github-proxy.com, it is now automatically rewritten to native Blueprint resources: - Repository URLs (?repo=...) become `zip` wrapping `git:directory` - Branch/PR/commit/release parameters map to git refs - Release assets (?release=...&asset=...) become direct GitHub URLs - Proxied GitHub URLs are unwrapped to direct URLs A new `zip` resource type wraps file or directory resources and outputs them as ZIP files, maintaining semantic compatibility with github-proxy.com which always returned ZIP files. Also fixes ZIP encoding to use 0-based disk numbering, which was causing PHP's ZipArchive to reject files with "multi-disk archive" error. Documentation updated to use git:directory instead of github-proxy.com. The /proxy redirect now points to the resources documentation. Local dev server now proxies /cors-proxy/ requests through Vite to avoid Chrome's Private Network Access restrictions.
f444655 to
8080edb
Compare
Resolved conflicts in documentation files by keeping the PR's removal of github-proxy.com deprecation notices (since this PR implements automatic migration) while preserving other trunk updates.
…roxyUrl The original function name was misleading - it didn't "parse" the URL, it rewrote it. Splitting into two functions makes the intent clearer: - isGithubProxyUrl: predicate that checks if a URL is a github-proxy.com URL - rewriteGithubProxyUrl: rewrites the URL to a native Blueprint resource The original parseGithubProxyUrl is kept as a deprecated alias for backwards compatibility.
782c3bd to
20fba49
Compare
Collaborator
Author
|
The Gatherpress link fails, something's off with Git sparse checkout. Edit: Actually it seems like it was just my network |
adamziel
commented
Dec 12, 2025
| if ( str_ends_with( $requested_path, '/proxy' ) ) { | ||
| return array( | ||
| 'location' => 'https://github-proxy.com/', | ||
| 'location' => 'https://wordpress.github.io/wordpress-playground/blueprints/steps/resources#gitdirectoryreference', |
Collaborator
Author
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@brandonpayton do you remember why did we need this redirect?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
github-proxy.com is being shut down. This PR provides a graceful migration path for existing Blueprints that reference github-proxy.com URLs.
When a Blueprint contains a URL resource pointing to github-proxy.com, it is now automatically rewritten to native Blueprint resources with a console warning prompting users to update their Blueprints.
Migration mapping
?repo=owner/namezipwrappinggit:directoryat HEAD?repo=...&branch=trunkzipwrappinggit:directorywith branch ref?repo=...&pr=123zipwrappinggit:directorywithrefs/pull/123/head?repo=...&commit=abczipwrappinggit:directorywith commit ref?repo=...&release=v1.0zipwrappinggit:directorywith tag ref?repo=...&directory=subdirzipwrappinggit:directorywith path?repo=...&release=v1.0&asset=file.zipurlto GitHub releases download?repo=...&release=latest&asset=file.zipurlto GitHub/releases/latest/download/https://github-proxy.com/https://...urlwith the inner GitHub URLNew
zipresource typeA new resource type that wraps file or directory resources and outputs them as ZIP files. This maintains semantic compatibility with github-proxy.com which always returned ZIP files.
{ "resource": "zip", "inner": { "resource": "git:directory", "url": "https://github.com/owner/repo", "ref": "main" } }Other changes
git:directoryinstead of github-proxy.com examples/proxyredirect now points to the resources documentation/cors-proxy/requests through Vite to avoid Chrome's Private Network Access restrictionsTest plan
Run
npm run devlocally and click through each link below. They should all load successfully and show a deprecation warning in the console.Real-world Blueprints using github-proxy.com
Here's a few blueprints actually used out in the wild containing references to github-proxy.com that now work without requesting github-proxy.com (all links lead to local playground):
Manual verification
[Blueprints] github-proxy.com is deprecated...zipresource type works withinstallPluginandinstallThemestepsgit:directoryresources still work as expected