{"action":"created","issue":{"url":"https://api.github.com/repos/composer/composer/issues/4592","labels_url":"https://api.github.com/repos/composer/composer/issues/4592/labels{/name}","comments_url":"https://api.github.com/repos/composer/composer/issues/4592/comments","events_url":"https://api.github.com/repos/composer/composer/issues/4592/events","html_url":"https://github.com/composer/composer/pull/4592","id":115877291,"number":4592,"title":"Allow composer script call within other script group","user":{"login":"giosh94mhz","id":5219975,"avatar_url":"https://avatars.githubusercontent.com/u/5219975?v=3","gravatar_id":"","url":"https://api.github.com/users/giosh94mhz","html_url":"https://github.com/giosh94mhz","followers_url":"https://api.github.com/users/giosh94mhz/followers","following_url":"https://api.github.com/users/giosh94mhz/following{/other_user}","gists_url":"https://api.github.com/users/giosh94mhz/gists{/gist_id}","starred_url":"https://api.github.com/users/giosh94mhz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/giosh94mhz/subscriptions","organizations_url":"https://api.github.com/users/giosh94mhz/orgs","repos_url":"https://api.github.com/users/giosh94mhz/repos","events_url":"https://api.github.com/users/giosh94mhz/events{/privacy}","received_events_url":"https://api.github.com/users/giosh94mhz/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-09T13:34:20Z","updated_at":"2015-11-09T14:37:32Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/composer/composer/pulls/4592","html_url":"https://github.com/composer/composer/pull/4592","diff_url":"https://github.com/composer/composer/pull/4592.diff","patch_url":"https://github.com/composer/composer/pull/4592.patch"},"body":"Since I got positive feedback in Issue #4578 here's a first implementation of scripts \"group\".\r\n\r\nScript prefixed by `@` are now considered alias of other script group. I've also implemented an infinite recursion detection (in a separate commit), to avoid simple configuration errors.\r\n\r\nI'm not aware of all composer internals, so this code will need an expert review. Here's my consideration:\r\n* prefixing by `@` can cause BC? I can't think of any real situation...\r\n* all command (including `post-install-cmd` and the like) are callable. Is this correct?\r\n* is the minimal documentation I've added enough?\r\n\r\nI've made some phpunit tests, and manually tested the following configurations:\r\n\r\n```yml\r\n{\r\n    \"scripts\": {\r\n        \"root\": \"@group2\",\r\n        \"group2\": [\r\n            \"@group1\",\r\n            \"echo 2\",\r\n            \"@group3\"\r\n        ],\r\n        \"group1\": [\r\n            \"echo 1\"\r\n        ],\r\n        \"group3\": [\r\n            \"echo 3\"\r\n        ]\r\n    }\r\n}\r\n```\r\nwhich result in 1 2 3 echoes.\r\n\r\n```yml\r\n{\r\n    \"scripts\": {\r\n        \"root\": \"@group\",\r\n        \"group\" : [\r\n            \"echo 1\",\r\n            \"@root\"\r\n        ]\r\n    }\r\n}\r\n```\r\nwhich triggers a `\\RuntimeException`"},"comment":{"url":"https://api.github.com/repos/composer/composer/issues/comments/155080558","html_url":"https://github.com/composer/composer/pull/4592#issuecomment-155080558","issue_url":"https://api.github.com/repos/composer/composer/issues/4592","id":155080558,"user":{"login":"giosh94mhz","id":5219975,"avatar_url":"https://avatars.githubusercontent.com/u/5219975?v=3","gravatar_id":"","url":"https://api.github.com/users/giosh94mhz","html_url":"https://github.com/giosh94mhz","followers_url":"https://api.github.com/users/giosh94mhz/followers","following_url":"https://api.github.com/users/giosh94mhz/following{/other_user}","gists_url":"https://api.github.com/users/giosh94mhz/gists{/gist_id}","starred_url":"https://api.github.com/users/giosh94mhz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/giosh94mhz/subscriptions","organizations_url":"https://api.github.com/users/giosh94mhz/orgs","repos_url":"https://api.github.com/users/giosh94mhz/repos","events_url":"https://api.github.com/users/giosh94mhz/events{/privacy}","received_events_url":"https://api.github.com/users/giosh94mhz/received_events","type":"User","site_admin":false},"created_at":"2015-11-09T14:37:32Z","updated_at":"2015-11-09T14:37:32Z","body":"Just noticed that `CommandEvent` class is deprecated and fixed with `Script\\Event`. I've not set constructor parameters `$args` and `$flags`: could this possibly be a bug?"}}