Automattic / Automattic/studio

Support WordPress in a subdirectory

Open
#1 5 comments 3 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
517
Forks
95
Avg merge
1d 22h
Merged PRs (30d)
162

Description

I am trying to add an existing site in a folder like `~/my-site`.

`my-site` uses WordPress in a subdirectory. This is the basic structure of `my-site`:

```
.
├── index.php
├── salt.php
├── wp
├── wp-cli.yml
├── wp-config.php
├── wp-content
└── xmlrpc.php
```

Studio does not recognize `my-site` as an existing WordPress folder.

Context: I use WordPress in a subdirectory so that I can use [the WordPress composer package](https://github.com/johnpbloch/wordpress) to manage which version of Core is installed.

It looks like the immediate cause for the error message is the logic in this function: https://github.com/Automattic/studio/blob/trunk/src/lib/fs-utils.ts#L47-L53

However I don't know if updating that function would be enough to fix the issue, there definitely could be other parts of Studio which could not be compatible with the subdirectory approach for sites.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.