1
0
Fork 0
mirror of https://github.com/composer/composer synced 2025-05-09 08:32:56 +00:00
Commit graph

76 commits

Author SHA1 Message Date
Rob Bast
acd1486406 Mark method as @private 2015-04-30 12:35:25 +02:00
Rob Bast
0fbc00f3fb Switch to QuestionHelper 2015-04-30 12:23:13 +02:00
Rob Bast
290fafa156 Docs and whitespace 2015-04-30 12:22:54 +02:00
Rob Bast
bef46a17dc Moved method 2015-04-30 12:22:09 +02:00
Jordi Boggiano
35a9b5dbf9 Merge pull request #3953 from alcohol/allow-numeric-author-name
Allow numeric author name
2015-04-21 20:47:49 +01:00
Evan Mattson
ec9eb2b799 update init type question 2015-04-21 13:19:18 -04:00
Evan Mattson
5ed001765f allow package type to be set with init command 2015-04-21 13:19:18 -04:00
Rob Bast
c7d387f599 Allow numeric characters 2015-04-20 13:09:25 +02:00
Jordi Boggiano
ab3622dff1 Merge pull request #3365 from WouterJ/patch-1
Updated validator
2015-03-23 11:56:30 +00:00
Rob Bast
cb336a5416 Implement writeError throughout Composer 2015-02-25 11:00:35 +01:00
Wouter J
3bf1ee939b Fixed validator to accept 'a/b' and 'a/b ~2.3' 2015-01-11 15:42:13 +01:00
Nils Adermann
859c8f5bb3 Use the repositories configured in composer.json for the require command 2014-12-04 16:14:32 +01:00
Jordi Boggiano
94926218e8 CS fixes 2014-10-17 18:57:27 +01:00
Jordi Boggiano
4bdd7adc55 Merge pull request #3319 from desyncr/bugfix/missing-default-author-value-validation
Fix missing validation on default value for author input
2014-10-15 13:33:30 +01:00
Jordi Boggiano
73e9db5d99 Fix the problem at the source, refs #3322 2014-10-07 16:03:19 +01:00
Jordi Boggiano
5c42cc8c8c Merge remote-tracking branch 'AydinHassan/hotfix/init-virtual-packages' 2014-10-07 15:51:21 +01:00
Jordi Boggiano
df7c8915fa Skip notification about matches found in case we have an exact match, refs #3261 2014-10-07 15:45:25 +01:00
Jordi Boggiano
d4062a5594 Merge remote-tracking branch 'kayladnls/kayla' 2014-10-07 15:40:33 +01:00
Aydin
432cdbcb31 Allow to select virtual packages 2014-10-02 12:07:31 +01:00
DC*
c698aa3a2b Fix missing validation on default value for author input
The default author value on the composer init command is not validated against `parseAuthorString` method and thus not being re-prompted, finally throwing an InvalidArgumentException when it tries to generate the composer.json file.

The changes forces the validation of both the entered author string or the default value.
2014-10-02 00:17:20 -03:00
frederik
d1d40502bf ProcessExecutor::escape 2014-09-24 18:30:12 +02:00
frederik
7ae1430689 #3297 ProcessUtil class using ProcessUtil of Symfony Console 2014-09-24 17:18:15 +02:00
Jordi Boggiano
b7b0901f87 Allow using new code in the init command and avoid initializing the composer instance too early, refs #3096 2014-09-23 15:17:53 +01:00
Ryan Weaver
895e62e859 Refactoring selection of the "recommended" version (e.g ~1.2) and adding some tests
This also modifies the behavior slightly (from a recommendation by seldaek) to always
propose the minor version of the recommendation (e.g. ~1.2 instead of ~1.2.1).
2014-09-12 11:26:51 -04:00
Ryan Weaver
aea2e901a9 Extracting logic into a new class related to selecting the latest version
Also refactored InitCommand slightly so that you can use this "latest version"
functionality when searching for a package as well.
2014-09-12 11:26:51 -04:00
Ryan Weaver
26179cc4b4 [#2492] Prefixed real versions with ~ when guessing the latest version
2.1.0 > ~2.1.0
v2.1.0 -> ~2.1.0
dev-master -> dev-master
2014-09-12 11:26:51 -04:00
Ryan Weaver
58535a62fa [#2492] Automatically using the latest version when requiring a package
This applies to the init and require commands.

Previously:

If you ommitted the version of a library, it prompted you to enter a version.

New Behavior:

If you omit the version, it automatically selects the latest version that is consistent
with your minimum-stability flag.

Is Jordi mentions, this is consistent with how npm works.
2014-09-12 11:26:51 -04:00
Kayla Daniels
ec758d95b0 updated package variable in gathering requirements 2014-09-06 07:58:57 -04:00
Haralan Dobrev
4abaaaf76d Use default description and license from CLI args
When running `composer init` with `--description` and `--license` arguments
on the command line they are later suggested as defaults during the
interactive flow. However when you press Enter (to use the default suggesstion)
Composer does not use it, but instead skip them entirely from the `composer.json`
generation.

This change provides a default argument not only to `DialogHelper::getQuestion()`,
but also to `DialogHelper::ask()`.
2013-09-21 02:10:24 +03:00
Przemysław Piechota
95cbb177dd Init command - diacritical marks in author name 2013-07-25 22:40:41 +02:00
Jordi Boggiano
1dd8bffce5 CS fixes 2013-05-27 10:41:50 +02:00
Francesc Rosàs
9aa0aba77c Extract email validation into a method 2013-05-25 17:01:14 +01:00
Jordi Boggiano
be861f090a Remove filterPackages and add RepositoryInterface::search, refactor all commands to use new methods and remove all usage of the full package list for Composer repositories that support providers, fixes #1646 2013-03-10 13:40:52 +01:00
Miklós Márton
67e5e0588d Fixes #1347 (new license argument / dialog for init command) 2013-03-03 07:06:29 +01:00
Jordi Boggiano
4c35f54356 Simplify regex pattern 2013-01-05 18:04:57 +01:00
Grégoire Pineau
fcac93b3f1 Fixed InitCommand::addVendorIgnore 2013-01-02 11:02:32 +01:00
Jordi Boggiano
247b02d077 Fix minimum-stability handling in InitCommand, fixes #1421 2012-12-15 18:35:32 +01:00
Jordi Boggiano
e7f4768668 Only ask for gitignore if the current dir is a git repo, fixes composer/satis#44 2012-12-08 17:47:44 +01:00
Igor Wiedler
423728440b Rename init --minimum-stability to --stability
This is consistent with create-project.
2012-11-30 17:40:52 +01:00
Jordi Boggiano
dee9bcb9f1 Add --stability and support for package:version and package=version to create-project, fixes #957 2012-11-24 15:34:50 +01:00
Colin Frei
e4b8fe85a1 Check --name value if it's passed in, as that's not validated anywhere 2012-11-20 20:54:48 +01:00
Colin Frei
b4cf3d06fd Make sure suggested value conforms to allowed values
Regex for replacement from https://github.com/composer/packagist/blob/master/src/Packagist/WebBundle/Entity/Package.php#L191
2012-11-20 20:53:19 +01:00
Colin Frei
6c4bdd14cd require $name to be lowercase 2012-11-20 20:49:45 +01:00
Nils Adermann
01593e0628 Merge pull request #1015 from Seldaek/memory
Reduce memory usage by only loading packages that are actually needed, fixes #456
2012-08-24 11:32:33 -07:00
Jordi Boggiano
41fc6ff9ee Fix formatRequirements return value, fixes #1026 2012-08-24 13:39:37 +02:00
Jordi Boggiano
c31d588b7d Update init and depends commands to use the new filterPackages method 2012-08-24 02:29:34 +02:00
Jordi Boggiano
de4e9c4022 Fix InputOption requirement flags 2012-08-15 18:29:43 +02:00
Beau Simensen
d0773b20df Added minimum-stability option to init command, minor bug fixes
Added the ability to specify `minimum-stability` as an option.
Also added `homepage` and `require-dev` to the whitelist and
added necessary code to format dev requirements only if dev
requirements are present.
2012-08-14 12:09:45 -07:00
Jordi Boggiano
ffecd39d33 Refactor repositories handling in config/factory/loader, fixes #828, fixes #826 2012-06-24 13:06:13 +02:00
Jordi Boggiano
3ac11b932c Expose default repositories in system config file 2012-06-23 12:55:05 +02:00