From 83fc4e15797e134452877f84ba4cf81372ab71a2 Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Thu, 10 Jul 2025 07:28:31 -0700 Subject: [PATCH 1/6] add spec for file Signed-off-by: Andy Fragen --- specification.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/specification.md b/specification.md index 1147e70..3512c85 100644 --- a/specification.md +++ b/specification.md @@ -212,6 +212,7 @@ The following properties are defined for the metadata document: | releases | yes | A list of [Releases](#release-document) | | slug | no | A string that conforms to the rules of [slug](#property-slug) | | name | no | A string. | +| file | no | A string that conforms to the rules of [file](#property-file) | | description | no | A string. | | keywords | no | A list of strings. | | sections | no | A map that conforms to the rules of [sections](#property-sections) | @@ -328,7 +329,14 @@ Clients SHOULD use the slug for file or directory names used during installation The `name` property specifies a human-readable name for the package, which the client may display in index or list pages. -The name MUST be a string. + +### file + +The `file` property specifies the file name for the package as a `slug/plugin.php` for a plugin, or just the `slug` for a theme. The client in WordPress will utilize this information when the package requires updating. The file is used as a key in the update transient associative array. + +The file MUST be a string containing only alphanumeric characters, dashes, or underscores. The file MUST start with an alphabetic character. + +The file MUST be a string. ### description From 1548d7af2bb0f530033743ddfe3438fe5671f591 Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Thu, 10 Jul 2025 12:41:41 -0700 Subject: [PATCH 2/6] make more generic Signed-off-by: Andy Fragen --- specification.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification.md b/specification.md index 3512c85..300cd34 100644 --- a/specification.md +++ b/specification.md @@ -332,7 +332,7 @@ The `name` property specifies a human-readable name for the package, which the c ### file -The `file` property specifies the file name for the package as a `slug/plugin.php` for a plugin, or just the `slug` for a theme. The client in WordPress will utilize this information when the package requires updating. The file is used as a key in the update transient associative array. +The `file` property specifies the file name for the package. The file MUST be a string containing only alphanumeric characters, dashes, or underscores. The file MUST start with an alphabetic character. From b420a4586f01c11425aab5855b9d41f6af472bd7 Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Sat, 12 Jul 2025 08:03:04 -0700 Subject: [PATCH 3/6] change file to filename Signed-off-by: Andy Fragen --- specification.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/specification.md b/specification.md index 300cd34..6463bf2 100644 --- a/specification.md +++ b/specification.md @@ -212,7 +212,7 @@ The following properties are defined for the metadata document: | releases | yes | A list of [Releases](#release-document) | | slug | no | A string that conforms to the rules of [slug](#property-slug) | | name | no | A string. | -| file | no | A string that conforms to the rules of [file](#property-file) | +| filename | no | A string that conforms to the rules of [filename](#property-file) | | description | no | A string. | | keywords | no | A list of strings. | | sections | no | A map that conforms to the rules of [sections](#property-sections) | @@ -330,13 +330,13 @@ Clients SHOULD use the slug for file or directory names used during installation The `name` property specifies a human-readable name for the package, which the client may display in index or list pages. -### file +### filename -The `file` property specifies the file name for the package. +The `filename` property specifies the file name for the package. -The file MUST be a string containing only alphanumeric characters, dashes, or underscores. The file MUST start with an alphabetic character. +The filename MUST be a string containing only alphanumeric characters, dashes, or underscores. Optionally the filename may contain a period or a forward slash. The file MUST start with an alphabetic character. -The file MUST be a string. +The filename MUST be a string. ### description From 3fac247d3f05771f1f8b44d3e7ebc5a0ed39ac7e Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Sat, 12 Jul 2025 08:06:08 -0700 Subject: [PATCH 4/6] modification of description Signed-off-by: Andy Fragen --- specification.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/specification.md b/specification.md index 6463bf2..a753628 100644 --- a/specification.md +++ b/specification.md @@ -332,7 +332,7 @@ The `name` property specifies a human-readable name for the package, which the c ### filename -The `filename` property specifies the file name for the package. +The `filename` property specifies the root folder and file name for the package. The filename MUST be a string containing only alphanumeric characters, dashes, or underscores. Optionally the filename may contain a period or a forward slash. The file MUST start with an alphabetic character. From 6e8f79dd636445ab6a3972e5894102d5a10fa8b4 Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Wed, 15 Oct 2025 12:32:23 -0700 Subject: [PATCH 5/6] Move to wp spec Signed-off-by: Andy Fragen --- ext-wp.md | 7 +++++++ specification.md | 10 ---------- 2 files changed, 7 insertions(+), 10 deletions(-) diff --git a/ext-wp.md b/ext-wp.md index d126646..d8eea75 100644 --- a/ext-wp.md +++ b/ext-wp.md @@ -91,6 +91,13 @@ Additionally, the following are recognised as aliases: All section content MAY contain HTML +#### filename + +The `filename` property specifies the root folder and file name for the package. + +The filename MUST be a string containing only alphanumeric characters, dashes, or underscores. Optionally the filename may contain a period or a forward slash. The file MUST start with an alphabetic character. + +The filename MUST be a string. ### Release Document diff --git a/specification.md b/specification.md index a753628..4b96fdd 100644 --- a/specification.md +++ b/specification.md @@ -212,7 +212,6 @@ The following properties are defined for the metadata document: | releases | yes | A list of [Releases](#release-document) | | slug | no | A string that conforms to the rules of [slug](#property-slug) | | name | no | A string. | -| filename | no | A string that conforms to the rules of [filename](#property-file) | | description | no | A string. | | keywords | no | A list of strings. | | sections | no | A map that conforms to the rules of [sections](#property-sections) | @@ -330,15 +329,6 @@ Clients SHOULD use the slug for file or directory names used during installation The `name` property specifies a human-readable name for the package, which the client may display in index or list pages. -### filename - -The `filename` property specifies the root folder and file name for the package. - -The filename MUST be a string containing only alphanumeric characters, dashes, or underscores. Optionally the filename may contain a period or a forward slash. The file MUST start with an alphabetic character. - -The filename MUST be a string. - - ### description The `description` property specifies a short description of the package, which the client may display in index or list pages. From 04482afc477bb7eeb6db8a27ad3efb609a5babeb Mon Sep 17 00:00:00 2001 From: Andy Fragen Date: Wed, 15 Oct 2025 12:38:28 -0700 Subject: [PATCH 6/6] Add back this line Signed-off-by: Andy Fragen --- specification.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/specification.md b/specification.md index 4b96fdd..1147e70 100644 --- a/specification.md +++ b/specification.md @@ -328,6 +328,8 @@ Clients SHOULD use the slug for file or directory names used during installation The `name` property specifies a human-readable name for the package, which the client may display in index or list pages. +The name MUST be a string. + ### description