Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ All notable changes to this project will be documented in this file, per [the Ke
- `list_service_versions` MCP tool — list the PHP, database, and web server versions available to `create_site`, flagging which are already installed versus downloaded on demand (props [@ivanlopez](https://github.com/ivanlopez) via [#80](https://github.com/10up/localwp-agent-tools/pull/80)).
- `site_status` now reports a `creationError` when a site created with `create_site` failed during provisioning (props [@ivanlopez](https://github.com/ivanlopez) via [#80](https://github.com/10up/localwp-agent-tools/pull/80)).

### Fixed

- The add-on no longer adds each agent's context file (`CLAUDE.md`, `.cursorrules`, `.windsurfrules`) to the project's `.gitignore`. Those files are human-authored and usually committed; the add-on only writes a marked section into them, so ignoring them is misleading and does nothing for a file that is already tracked. Only the machine-generated MCP config files stay ignored (props [@claytoncollie](https://github.com/claytoncollie)).

## [0.2.1] - 2026-03-19

### Fixed
Expand Down
8 changes: 4 additions & 4 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
findWpCli,
} from './helpers/paths';
import { SiteConfig, SiteConfigRegistry } from './helpers/site-config';
import { findAvailablePort, savePort, removePortFile, removePortFileSync } from './helpers/port';

Check warning on line 14 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

'removePortFile' is defined but never used
import { createMcpHttpServer, startMcpHttpServer, stopMcpHttpServer, closeSessionsForSite } from './mcp-server';
import { LocalApi, CreateSiteOptions, CreateSiteResult, ServiceVersion, ServiceVersions } from './tools';
import {
Expand Down Expand Up @@ -45,7 +45,7 @@
mcpConfigTopLevelKey: string;
/** Path to project context/instructions file, relative to project dir */
contextFilePath: string;
/** Extra entries to add to .gitignore */
/** Machine-generated config files to add to .gitignore (never the human-authored context file) */
gitignoreEntries: string[];
}

Expand All @@ -55,21 +55,21 @@
mcpConfigPath: '.mcp.json',
mcpConfigTopLevelKey: 'mcpServers',
contextFilePath: 'CLAUDE.md',
gitignoreEntries: ['.mcp.json', 'CLAUDE.md'],
gitignoreEntries: ['.mcp.json'],
},
cursor: {
label: 'Cursor',
mcpConfigPath: path.join('.cursor', 'mcp.json'),
mcpConfigTopLevelKey: 'mcpServers',
contextFilePath: '.cursorrules',
gitignoreEntries: ['.cursorrules'],
gitignoreEntries: [],
},
windsurf: {
label: 'Windsurf',
mcpConfigPath: path.join('.windsurf', 'mcp.json'),
mcpConfigTopLevelKey: 'mcpServers',
contextFilePath: '.windsurfrules',
gitignoreEntries: ['.windsurfrules'],
gitignoreEntries: [],
},
vscode: {
label: 'VS Code Copilot',
Expand Down Expand Up @@ -193,7 +193,7 @@
* Builds the MCP server entry for a specific agent.
* Each agent has different JSON shapes for HTTP MCP servers.
*/
function buildMcpServerEntry(agent: AgentTarget, port: number, siteId: string): Record<string, any> {

Check warning on line 196 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
const url = `http://localhost:${port}/sites/${siteId}/mcp`;

switch (agent) {
Expand All @@ -215,10 +215,10 @@
*/
async function mergeMcpConfig(
configPath: string,
serverEntry: Record<string, any>,

Check warning on line 218 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
topLevelKey: string,
): Promise<void> {
let existing: any = {};

Check warning on line 221 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type

if (await fs.pathExists(configPath)) {
try {
Expand Down Expand Up @@ -409,7 +409,7 @@
// Core Functions
// ---------------------------------------------------------------------------

async function setupSite(site: Local.Site, notifier: any, projectDir: string, agents: AgentTarget[]): Promise<void> {

Check warning on line 412 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
const sitePath = getSitePath(site);
const projectPath = getProjectPath(sitePath, projectDir);

Expand Down Expand Up @@ -461,7 +461,7 @@
});
}

async function teardownSite(site: Local.Site, notifier: any): Promise<void> {

Check warning on line 464 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
const sitePath = getSitePath(site);
const projectDir = getStoredProjectDir(site);
const projectPath = getProjectPath(sitePath, projectDir);
Expand Down Expand Up @@ -500,7 +500,7 @@
});
}

async function changeProjectDir(site: Local.Site, newProjectDir: string, notifier: any): Promise<void> {

Check warning on line 503 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
const sitePath = getSitePath(site);
const oldProjectDir = getStoredProjectDir(site);
const oldPath = getProjectPath(sitePath, oldProjectDir);
Expand Down Expand Up @@ -549,7 +549,7 @@
});
}

async function updateAgents(site: Local.Site, newAgents: AgentTarget[], notifier: any): Promise<void> {

Check warning on line 552 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint

Unexpected any. Specify a different type
if (!isAgentToolsEnabled(site)) return;

const sitePath = getSitePath(site);
Expand Down
Loading