| Age | Commit message (Collapse) | Author |
|
Re-resolve dependencies and compare with the current lock file to
detect packages that are no longer reachable from root requirements.
Removes them from the lock file and re-installs.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Walk vendor/<vendor>/<package>/composer.json files and run the same
manifest validations on each dependency, reporting per-package errors
and warnings with a summary count.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
- --patch-only: restrict updates to patch-level changes by pinning
packages back to locked versions when major.minor differs
- --root-reqs: auto-populate update list with root require/require-dev
packages when no explicit packages are specified
- --bump-after-update: bump composer.json version constraints to match
resolved versions after update, with dev/no-dev/all modes
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Use previously stored but unused fields: show installed_version in
advisory tables/plain/JSON output, and package version in abandoned
package output. Remove unused unlockable_ids field from LockTransaction.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Rename mozart-constraint to mozart-semver (mirrors composer/semver) and
extract mozart-class-map-generator from mozart-autoload (mirrors
composer/class-map-generator). No logic changes.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Match Composer behavior: instead of failing with an error when no
composer.lock is present, show a warning and delegate to the update
command to resolve dependencies from composer.json.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Composer never shows the internal __root__ identifier to users. Add
root_name field to ResolveRequest so the resolver can substitute the
real package name (e.g. "laravel/laravel") in pubgrub error reports.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
PlatformConfig::new() was hardcoded to PHP 8.1 with a fixed extension
list, causing resolution failures for packages requiring newer PHP
(e.g. Laravel 12 requires >=8.2). Now calls detect_platform() to
discover the actual PHP version, extensions and capabilities.
Also adds a mutex to composer_home_dir tests to prevent env-var races.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
|
|
Add mozart_core::http::user_agent() that returns a consistent
"Mozart/<version> (<os>; <arch>)" string. Replace all scattered
user-agent definitions across mozart-registry and mozart CLI commands.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
|
|
Replace the TODO placeholders with a full interactive search-and-pick
loop for both require and require-dev dependencies during `init`.
Users can search Packagist, pick packages by number or name, and
version constraints are auto-detected from available versions.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Extract shared helpers (composer_home, read/write_json_file,
add/remove_repository, render_value) from config.rs into
config_helpers.rs module. Implement all 7 repository actions:
list, add, remove, set-url, get-url, disable, enable with
--append/--before/--after positioning support.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
|
|
Replace reqwest::blocking with async reqwest across the entire codebase.
All command execute functions, registry API calls (packagist, downloader,
resolver, lockfile), and the main entry point now use async/await with
the tokio runtime. The pubgrub resolver runs on spawn_blocking since its
DependencyProvider trait is synchronous, using Handle::block_on for
async I/O within that context.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Wire up the existing --profile flag with tracing-subscriber to emit
span timings on stderr. Supports MOZART_LOG env var override and
verbose-level-aware filtering. No subscriber is installed when
--profile is off, keeping tracing macros zero-cost.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Extract modules from the single `mozart` crate into 5 focused library
crates to improve compilation parallelism and architectural clarity:
- mozart-constraint: version constraint parser (independent)
- mozart-core: base types, console, validation, platform utilities
- mozart-archiver: archive creation (tar, zip, bzip2)
- mozart-registry: Packagist API, cache, resolver, downloader, lockfile
- mozart-autoload: autoloader generation and PHP scanner
Refactor Console::from_cli and build_cache_config to accept primitive
args instead of &Cli to break circular dependencies. Introduce
[workspace.dependencies] for centralized version management. Remove 9
unused direct dependencies from the CLI crate.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add a `completion` subcommand that generates shell completion scripts
for Bash, Zsh, Fish, Elvish, and PowerShell using the clap_complete
crate.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Implement Phase 7.2 error handling & UX infrastructure:
- Add exit_code module with MozartError, bail()/bail_silent() helpers,
and Composer-compatible exit code constants (0-5, 100)
- Redesign Console struct with Verbosity enum (Quiet/Normal/Verbose/
VeryVerbose/Debug), ANSI auto-detection via IsTerminal, and
verbosity-gated output methods (info/verbose/debug/error)
- Thread Console through all 33 command execute() signatures
- Replace all std::process::exit() calls with structured MozartError
returns handled in main()
- Migrate eprintln\! status messages to console.info() for quiet-mode
suppression
- Add suggest module with Levenshtein distance and "Did you mean?"
formatting for future package name suggestions
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add ~136 tests across 7 categories: version parsing edge cases,
version ordering, constraint parsing, constraint matching, internal
functions, Composer behavioral compatibility, and divergence
investigation. One test (double equals) is #[ignore]d due to ==
operator not being supported.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add 23 integration tests using assert_cmd and predicates covering
about, validate, show, licenses, install, config, init, and
dump-autoload commands with shared test helpers and fixture projects.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add full self-update functionality: fetch releases from GitHub API,
download platform-specific binaries, atomically replace the running
executable using self-replace, and support --rollback and --preview
flags. Includes backup management and 12 unit tests.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add archive command supporting zip, tar, tar.gz, and tar.bz2 formats
with .gitattributes export-ignore filtering, composer.json archive.exclude
patterns, remote package archiving via Packagist, and self-exclusion to
prevent archives from including themselves.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
composer.json allows license to be either a string or an array. Parse
the raw JSON to support both forms, emit license as a proper array in
JSON output, and apply console::comment() coloring to the text header.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Resolves global home from $COMPOSER_HOME, $XDG_CONFIG_HOME, or
$HOME/.config/composer, then re-dispatches the given subcommand
with --working-dir set to that path. Forwards all global CLI flags
and accepts hyphen-prefixed trailing arguments.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Collects platform requirements (php, ext-*, lib-*, composer-*-api) from
lock file, installed.json, and root composer.json, then compares them
against the detected PHP environment. Supports text/JSON output and
exit codes 0 (pass), 1 (failed), 2 (missing).
Extracts shared platform detection into a new platform.rs module,
reused by both check-platform-reqs and show --platform.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add "Dependencies:" label and remove column headers/separator from
text output to align with Composer's licenses command behavior.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
connectivity
Adds 10 diagnostic checks: Mozart version, HTTPS/HTTP Packagist connectivity,
GitHub API, HTTP proxy detection, composer.json validation, composer.lock
freshness, git availability/version, disk free space, and cache directory
writability. Exit codes: 0=clean, 1=warnings, 2=errors.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Support shell commands, @php/@composer/@putenv prefixes, script
references with circular detection, @additional_args/@no_additional_args,
timeout handling, and COMPOSER_DEV_MODE. PHP callbacks are skipped with
a warning since Mozart cannot execute PHP class methods.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
vulnerabilities
Query Packagist security advisories API for known vulnerabilities
affecting installed or locked packages, with version constraint
matching, severity filtering, abandoned package detection, and
multiple output formats (table, plain, json, summary).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
projects from packages
Replaces the todo\!() stub with a full implementation that parses the
package argument, resolves the best matching version from Packagist,
downloads and extracts the dist archive into a target directory, removes
VCS metadata, replaces self.version constraints, and runs dependency
resolution and installation via the existing resolver and install
infrastructure. Includes version constraint matching (caret, tilde,
wildcard, comparison operators) and comprehensive unit tests.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Replaces the todo\!() stub with a full implementation that reads
installed.json and composer.lock, selects packages by name patterns
(with glob/wildcard support) or --type filter, removes vendor
directories, re-downloads from dist, and regenerates the autoloader.
Supports --dry-run, --no-dev, and all standard autoloader flags.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Downloads original dist archives, hashes files with SHA-1, and compares
against installed copies to detect modified, added, and removed files.
Supports verbose file listing and exits with code 1 when changes found.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add binary execution from vendor/bin/ with --list enumeration,
root package bin entries marked as (local), configurable bin-dir
resolution with {$vendor-dir} placeholder support, .bat filtering,
and PATH prepending. Add bin field to RawPackageData.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
versions
Adds the version_bumper module for constraint manipulation (caret, tilde,
wildcard, GTE, OR constraints, stability flags, dev versions) and wires
it into the bump command with --dev-only, --no-dev-only, --dry-run flags,
package filtering, lock file freshness checks, and content-hash updates.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Resolves URLs from composer.json, composer.lock, or Packagist API with
priority: support.source > source.url > homepage. Supports --homepage
flag, --show for printing URLs, and cross-platform browser opening.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
output modes
Replaces the todo\!() stub with full implementation that collects
suggested packages from lock file, installed packages, and root
composer.json. Supports --no-dev, --all, --list, --by-package,
--by-suggestion flags and package name filtering. Filters out
already-installed and platform packages. Includes 11 tests covering
collection, filtering, and edge cases.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Display funding links from installed packages grouped by vendor,
reading from lock file (preferred) or installed.json. Includes
GitHub URL rewriting to sponsor links.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Support listing dependency licenses from installed packages or lock file
with --no-dev filtering, format validation, and sorted output. Includes
unit tests for license extraction/counting and integration tests using
temp dirs for both installed and locked package sources.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Implement a cache module with CacheConfig and Cache structs supporting
read/write (string and binary), atomic writes via temp+rename, TTL-based
expiration, and size-limited garbage collection. Wire the repo cache into
packagist.rs and resolver.rs for API response caching, and the files
cache into downloader.rs for dist archive caching. Implement the
clear-cache command with full clear and --gc modes. All existing call
sites pass None for backward compatibility.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
strict-psr
Add PHP file scanner (php_scanner.rs) with class/interface/trait/enum
detection, comment/string/heredoc stripping, and PSR-4/PSR-0 validation.
Extend autoload generation with: classmap directory scanning, --optimize
mode (PSR-4/PSR-0 to classmap), --classmap-authoritative, --apcu caching
with optional prefix, platform_check.php generation, and --strict-psr
violation reporting. Wire new options through dump-autoload, install,
require, update, and remove commands.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
updates
Implement Phase 5.5 of the require/remove commands:
- Interactive package search when no packages specified on CLI (require)
- --with-dependencies/--with-all-dependencies partial update for require
- --with-all-dependencies/--no-update-with-dependencies for remove
- --minimal-changes support for remove
- Extract search API types and logic from search.rs into packagist.rs
for reuse by both search and require commands
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add full config write support: setting/unsetting config keys with type
validation, package properties, repository management, extra/suggest
fields, dotted subkeys, --editor mode, --json/--merge/--append flags,
and enhanced read mode for repos/extra/suggest/package properties.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
and interactive mode
Implement Phase 5.4 update command extensions:
- Wildcard package matching (e.g. symfony/*) against the lock file
- --with-dependencies expands update set to include direct deps
- --with-all-dependencies expands to full transitive dependency tree
- --minimal-changes pins all packages to locked versions unless constraints changed
- --interactive prompts user to select packages for update (y/n per package)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
and --format=json
Replace stub messages with full implementations for all show command
extensions: dependency tree rendering from lock file, latest version
fetching from Packagist, outdated filtering with update classification,
available versions listing, platform package detection via PHP CLI,
and JSON output format across all modes.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Replace positional boolean parameters in install_from_lock with a
structured InstallConfig. Add platform requirement warnings, download
progress display, classmap-authoritative autoloader support, and
prefer-source detection across install/update/require/remove commands.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Inline aliases ("1.0.x-dev as 1.0.0") now use the right side for
constraint matching via parse_for_constraint(), while parse() keeps
the left side for version identity.
Branch aliases from extra.branch-alias metadata create synthetic
dev-stability entries in the resolver, allowing constraints like
^2.0 to match dev-master aliased to 2.x-dev. Real releases take
precedence via entry().or_insert().
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
dependency logic
Add the `depends` (why) and `prohibits` (why-not) commands that query
the dependency graph to answer "which packages require X?" and "which
packages prevent version Y of X from being installed?" respectively.
Introduces the shared `dependency` module with package loading from
lock file or installed.json, forward/inverted dependency graph walking,
recursive traversal with cycle detection, and table/tree output formatters.
Adds `conflict` field to LockedPackage for conflict-based prohibition
detection, updating all struct literals across install, remove, require,
and update test helpers.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add ComposerConfig with Composer-compatible defaults, config merging
from global/local JSON files, placeholder resolution ({$vendor-dir},
{$home}, {$cache-dir}), single-key lookup, --list output, and 21 tests.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Replaces the todo\!() stub with full implementation that loads installed
or locked packages, fetches latest versions from Packagist, classifies
updates as semver-compatible (red) or semver-incompatible (yellow), and
supports all flags: --direct, --locked, --no-dev, --major-only,
--minor-only, --patch-only, --format json, --strict, and --ignore.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|