Skip to content

🚀 Feature Request: Pages publish should support --site-exclude/--site-include #3176

@mcclure

Description

@mcclure

Describe the solution

Context: I have a static web page I am attempting to migrate from Amazon S3 to Cloudflare Pages. With Amazon, there was a simple program I could run on a directory and it would do something like an rsync (IE upload changed files only) of the directory to the server. CloudFlare pages appears to prefer a situation where I push a git repo and CloudFlare checks out the git repo and runs a "builder". I would prefer to just upload you the files. I have a source control repo for the site but it is not practical to give you access to it.

Problem: I have hit a blocker because wrangler pages publish appears to only be able to upload complete directories. However, I have a .hg (source control) subdirectory in the directory. That should absolutely not be uploaded.

The wrangler publish command, for whatever "workers" are, has a convenient --site-exclude command which addresses my need exactly. However it is not supported for wrangler pages publish: https://developers.cloudflare.com/workers/wrangler/commands/#pages

This is a feature the amazon equivalent does have (--exclude) and is a pretty standard feature for most archival/uploading tools (rsync, zip, etc).

Expected behavior: Could wrangler pages adopt a file include/exclude pattern system? Using the tool without this feature is going to be pretty awkward.

Metadata

Metadata

Labels

pagesRelating to Pages
No fields configured for Feature.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions