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
11 changes: 11 additions & 0 deletions .changelog/consistent-skill-sources.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
category: changed
type: patch
---

Synchronize the bundled local skill automatically and trust Fast Forward Composer
skill donors through `fast-forward/*`.
Resolve Changelog contributor skills from stable `0.4.x` releases without a
redundant skill allowlist.
Load the project autoloader for PHPDoc checks when DevTools is installed as a
dependency.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@
/.changelog/ export-ignore
/CONTRIBUTING.md export-ignore
/skills.json export-ignore
/.php-cs-fixer.dist.php export-ignore
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ vendor/
composer.lock
*.cache
/.agents/
/.dev-tools/
38 changes: 38 additions & 0 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<?php

declare(strict_types=1);

/**
* This file is part of php-fast-forward/clock.
*
* This source file is subject to the license bundled
* with this source code in the file LICENSE.
*
* @copyright Copyright (c) 2025-2026 Felipe Sayão Lobato Abreu <github@mentordosnerds.com>
* @license https://opensource.org/licenses/MIT MIT License
*
* @see https://github.com/php-fast-forward/clock
* @see https://github.com/php-fast-forward
* @see https://datatracker.ietf.org/doc/html/rfc2119
*/

use FastForward\DevTools\Path\WorkingProjectPathResolver;
use PhpCsFixer\Config;
use PhpCsFixer\Finder;

require __DIR__ . '/vendor/autoload.php';

return (new Config())
->setRiskyAllowed(false)
->setFinder(Finder::create()->in(__DIR__)->exclude(WorkingProjectPathResolver::TOOLING_EXCLUDED_DIRECTORIES))
->setRules([
'phpdoc_indent' => true,
'phpdoc_order' => ['order' => ['param', 'return', 'throws']],
'phpdoc_separation' => true,
'phpdoc_trim' => true,
'phpdoc_trim_consecutive_blank_line_separation' => true,
'phpdoc_scalar' => true,
'phpdoc_types' => true,
'phpdoc_to_comment' => false,
'phpdoc_add_missing_param_annotation' => true,
]);
12 changes: 9 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,15 @@ still need editorial review; no PR attribution is inferred from prose alone.

The development-only manager restores `fast-forward-container` and
`fast-forward-config` from the installed Composer packages, including Config as
a transitive dependency. `skills.json` explicitly trusts only those two Composer
donors; dependency trust does not extend to other installed packages. No separate
GitHub source or version pin is used for either library.
a transitive dependency. `skills.json` trusts installed donors in the
`fast-forward/*` namespace; `trusted-replace` keeps other namespaces untrusted.
No separate GitHub source or version pin is used for either library.

The bundled skill is also synchronized from the local `resources/skills`
directory, without a package override. Changelog instructions come from the
GitHub source at `^0.4.0`, discovered through its Composer metadata without a
skill allowlist. `auto-sync: true` restores these skills after normal Composer
install/update operations; `composer skills:update` refreshes them explicitly.

Inspect donors with `composer skills:show` and refresh their payloads with
`composer skills:update --from=composer`. The existing GitHub source continues
Expand Down
11 changes: 6 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,25 +51,26 @@
"ergebnis/composer-normalize": true,
"fast-forward/dev-tools": true,
"infection/extension-installer": true,
"llm/skills": true,
"phpdocumentor/shim": true,
"phpro/grumphp": true,
"pyrech/composer-changelogs": true,
"llm/skills": true
"phpro/grumphp-shim": true,
"pyrech/composer-changelogs": true
},
"platform": {
"php": "8.3.0"
},
"sort-packages": true
},
"extra": {
"skills": {
"source": "resources/skills"
},
"branch-alias": {
"dev-main": "1.x-dev"
},
"grumphp": {
"config-default-path": "vendor/fast-forward/dev-tools/grumphp.yml"
},
"skills": {
"source": "resources/skills"
}
},
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion examples/01-system-clock.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* @see https://datatracker.ietf.org/doc/html/rfc2119
*/

require dirname(__DIR__) . '/vendor/autoload.php';
require __DIR__ . '/../vendor/autoload.php';

use FastForward\Clock\SystemClock;

Expand Down
2 changes: 1 addition & 1 deletion examples/02-system-clock-with-timezone.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* @see https://datatracker.ietf.org/doc/html/rfc2119
*/

require dirname(__DIR__) . '/vendor/autoload.php';
require __DIR__ . '/../vendor/autoload.php';

use FastForward\Clock\SystemClock;

Expand Down
2 changes: 1 addition & 1 deletion examples/03-frozen-clock.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* @see https://datatracker.ietf.org/doc/html/rfc2119
*/

require dirname(__DIR__) . '/vendor/autoload.php';
require __DIR__ . '/../vendor/autoload.php';

use FastForward\Clock\FrozenClock;

Expand Down
2 changes: 1 addition & 1 deletion examples/04-frozen-clock-inputs.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* @see https://datatracker.ietf.org/doc/html/rfc2119
*/

require dirname(__DIR__) . '/vendor/autoload.php';
require __DIR__ . '/../vendor/autoload.php';

use FastForward\Clock\FrozenClock;

Expand Down
2 changes: 1 addition & 1 deletion examples/05-frozen-clock-container.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* @see https://datatracker.ietf.org/doc/html/rfc2119
*/

require dirname(__DIR__) . '/vendor/autoload.php';
require __DIR__ . '/../vendor/autoload.php';

use FastForward\Clock\ServiceProvider\ClockServiceProvider;
use FastForward\Clock\FrozenClock;
Expand Down
2 changes: 1 addition & 1 deletion examples/06-psr20-clock-interface.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* @see https://datatracker.ietf.org/doc/html/rfc2119
*/

require dirname(__DIR__) . '/vendor/autoload.php';
require __DIR__ . '/../vendor/autoload.php';

use FastForward\Clock\ServiceProvider\ClockServiceProvider;
use Psr\Clock\ClockInterface;
Expand Down
14 changes: 7 additions & 7 deletions skills.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"$schema": "https://raw.githubusercontent.com/roxblnfk/skills/master/resources/skills.schema.json",
"$schema": "https://raw.githubusercontent.com/roxblnfk/skills/1.15.0/resources/skills.schema.json",
"target": ".agents/skills",
"aliases": [],
"discovery": false,
Expand All @@ -8,20 +8,20 @@
"dependencies": {
"composer": {
"trusted": [
"fast-forward/config",
"fast-forward/container"
"fast-forward/*"
],
"trusted-replace": true
}
},
"sources": [
{
"from": "dir",
"path": "resources/skills"
},
{
"from": "github",
"package": "php-fast-forward/changelog",
"ref": "^0.3.0",
"skills": [
"fast-forward-changelog"
]
"ref": "^0.4.0"
}
]
}
Loading