Skip to content

[AiMate] Add recipe#1535

Draft
wachterjohannes wants to merge 1 commit intosymfony:mainfrom
wachterjohannes:add-ai-mate-recipe
Draft

[AiMate] Add recipe#1535
wachterjohannes wants to merge 1 commit intosymfony:mainfrom
wachterjohannes:add-ai-mate-recipe

Conversation

@wachterjohannes
Copy link
Copy Markdown

@wachterjohannes wachterjohannes commented May 3, 2026

Adds the Symfony Flex recipe for symfony/ai-mate, replacing the behaviour previously provided by the symfony/ai-mate-composer-plugin package. Tracking issue: symfony/ai#1994.

Cross-repo PRs

# Repo PR What Status
1 symfony/ai symfony/ai#2027 mate discover --ignore-missing-file open
2 symfony/ai symfony/ai#2026 Drop symfony/ai-mate-composer-plugin from symfony/ai-mate's require list (depends on symfony/ai#2027) draft
3 symfony/flex symfony/flex#1089 Auto-wire @auto-scripts into post-install-cmd / post-update-cmd draft
4 symfony/recipes symfony/recipes#1535 The symfony/ai-mate recipe this PR (draft)
5 symfony/ai follow-up Delete the composer plugin source not started

Summary

  • Registers vendor/bin/mate discover --composer --ignore-missing-file as a composer-scripts entry.
  • Prints the "run vendor/bin/mate init" banner via post-install.txt.
  • Adds a mate alias.

Usage

After composer require symfony/ai-mate, Flex applies the recipe automatically: the discover script is wired into @auto-scripts and runs on every composer install / composer update, and the install banner is shown once.

Marking as draft until symfony/ai#2027, symfony/ai#2026 and symfony/flex#1089 are merged and a Flex release is cut.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 3, 2026

Thanks for the PR 😍

How to test these changes in your application

  1. Define the SYMFONY_ENDPOINT environment variable:

    # On Unix-like (BSD, Linux and macOS)
    export SYMFONY_ENDPOINT=https://raw.githubusercontent.com/symfony/recipes/flex/pull-1535/index.json
    # On Windows
    SET SYMFONY_ENDPOINT=https://raw.githubusercontent.com/symfony/recipes/flex/pull-1535/index.json
  2. Install the package(s) related to this recipe:

    composer req symfony/flex
    composer req 'symfony/ai-mate:^0.1'
  3. Don't forget to unset the SYMFONY_ENDPOINT environment variable when done:

    # On Unix-like (BSD, Linux and macOS)
    unset SYMFONY_ENDPOINT
    # On Windows
    SET SYMFONY_ENDPOINT=

Diff between recipe versions

In order to help with the review stage, I'm in charge of computing the diff between the various versions of patched recipes.
I'm going keep this comment up to date with any updates of the attached patch.

chr-hertel added a commit to symfony/ai that referenced this pull request May 4, 2026
… command (wachterjohannes)

This PR was merged into the main branch.

Discussion
----------

[Mate] Add `--ignore-missing-file` option to `discover` command

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| Docs?         | no
| Issues        | Fix #1994 (partial)
| License       | MIT

Adds an `--ignore-missing-file` option to `mate discover` that exits `0` as a no-op when `mate/extensions.php` does not exist. Required so the upcoming `symfony/ai-mate` Symfony Flex recipe can invoke `mate discover` unconditionally from Composer scripts.

## Cross-repo PRs

| # | Repo | PR | What | Status |
|---|---|---|---|---|
| 1 | symfony/ai | [#2027](#2027) | `mate discover --ignore-missing-file` | **this PR** |
| 2 | symfony/ai | [#2026](#2026) | Drop `symfony/ai-mate-composer-plugin` from `symfony/ai-mate`'s require list (depends on #2027) | draft |
| 3 | symfony/flex | [symfony/flex#1089](symfony/flex#1089) | Auto-wire ``@auto`-scripts` into `post-install-cmd` / `post-update-cmd` | draft |
| 4 | symfony/recipes | [symfony/recipes#1535](symfony/recipes#1535) | The `symfony/ai-mate` recipe | draft |
| 5 | symfony/ai | _follow-up_ | Delete the composer plugin source | not started |

## Summary

- Adds `--ignore-missing-file` option to `mate discover`: exits `0` when `mate/extensions.php` does not exist.

## Usage

The Flex recipe (symfony/recipes#1535) wires `vendor/bin/mate discover --composer --ignore-missing-file` into ``@auto`-scripts`, so it runs unconditionally on every `composer install` / `composer update` — including the first one, before `mate init` has been executed.

Commits
-------

439cabe [Mate] Add --ignore-missing-file option to discover command
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant