{"action":"created","issue":{"url":"https://api.github.com/repos/fsprojects/Paket/issues/1018","labels_url":"https://api.github.com/repos/fsprojects/Paket/issues/1018/labels{/name}","comments_url":"https://api.github.com/repos/fsprojects/Paket/issues/1018/comments","events_url":"https://api.github.com/repos/fsprojects/Paket/issues/1018/events","html_url":"https://github.com/fsprojects/Paket/pull/1018","id":103529852,"number":1018,"title":"Introduce \"Groups\"","user":{"login":"forki","id":57396,"avatar_url":"https://avatars.githubusercontent.com/u/57396?v=3","gravatar_id":"","url":"https://api.github.com/users/forki","html_url":"https://github.com/forki","followers_url":"https://api.github.com/users/forki/followers","following_url":"https://api.github.com/users/forki/following{/other_user}","gists_url":"https://api.github.com/users/forki/gists{/gist_id}","starred_url":"https://api.github.com/users/forki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/forki/subscriptions","organizations_url":"https://api.github.com/users/forki/orgs","repos_url":"https://api.github.com/users/forki/repos","events_url":"https://api.github.com/users/forki/events{/privacy}","received_events_url":"https://api.github.com/users/forki/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/fsprojects/Paket/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-08-27T14:59:52Z","updated_at":"2015-08-27T17:40:12Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/fsprojects/Paket/pulls/1018","html_url":"https://github.com/fsprojects/Paket/pull/1018","diff_url":"https://github.com/fsprojects/Paket/pull/1018.diff","patch_url":"https://github.com/fsprojects/Paket/pull/1018.patch"},"body":"*This is what's going to be Paket 2.0*\r\n\r\n## Basic feature description\r\n\r\nThis new feature will allow us to organize our dependencies in groups and also allows easier conflict resolutions. Let's consider a small sample:\r\n\r\n### paket.dependencies\r\n\r\n    source https://nuget.org/api/v2\r\n    \r\n    nuget Newtonsoft.Json\r\n    nuget UnionArgParser\r\n    nuget FSharp.Core\r\n    \r\n    github forki/FsUnit FsUnit.fs\r\n    github fsharp/FAKE src/app/FakeLib/Globbing/Globbing.fs\r\n    github fsprojects/Chessie src/Chessie/ErrorHandling.fs\r\n    \r\n    group Build\r\n        source https://nuget.org/api/v2\r\n    \r\n        nuget FAKE\r\n        nuget FSharp.Formatting\r\n        nuget ILRepack\r\n    \r\n        github fsharp/FAKE modules/Octokit/Octokit.fsx\r\n    \r\n    group Test\r\n        source https://nuget.org/api/v2\r\n    \r\n        nuget NUnit.Runners\r\n        nuget NUnit\r\n\r\nAs you can see we have 3 different groups. The first one is the default group (currently called \"Main\") and represents the backwards-compatible case. So the main group is what you currently have in Paket 1.x. The other two groups contain dependencies that are used for `Build` and `Test`.\r\n\r\nNotice the indentation in groups is optional.\r\n\r\nAfter `paket update` the corresponding lock file looks the following: \r\n\r\n### paket.lock\r\n\r\n    NUGET\r\n      remote: https://nuget.org/api/v2\r\n      specs:\r\n        FSharp.Core (4.0.0.1)\r\n        Newtonsoft.Json (7.0.1)\r\n        UnionArgParser (0.6.3)\r\n    GITHUB\r\n      remote: forki/FsUnit\r\n      specs:\r\n        FsUnit.fs (81d27fd09575a32c4ed52eadb2eeac5f365b8348)\r\n      remote: fsharp/FAKE\r\n      specs:\r\n        src/app/FakeLib/Globbing/Globbing.fs (991bea743c5d5e8eec0defc7338a89281ed3f51a)\r\n      remote: fsprojects/Chessie\r\n      specs:\r\n        src/Chessie/ErrorHandling.fs (1f23b1caeb1f87e750abc96a25109376771dd090)\r\n\r\n    GROUP Build\r\n    NUGET\r\n      remote: https://nuget.org/api/v2\r\n      specs:\r\n        FAKE (4.3.1)\r\n        FSharp.Compiler.Service (1.4.0.1)\r\n        FSharp.Formatting (2.10.0)\r\n          FSharp.Compiler.Service (>= 0.0.87)\r\n          FSharpVSPowerTools.Core (1.8.0)\r\n        FSharpVSPowerTools.Core (1.8.0)\r\n          FSharp.Compiler.Service (>= 0.0.87)\r\n        ILRepack (2.0.5)\r\n        Microsoft.Bcl (1.1.10)\r\n          Microsoft.Bcl.Build (>= 1.0.14)\r\n        Microsoft.Bcl.Build (1.0.21)\r\n        Microsoft.Net.Http (2.2.29)\r\n          Microsoft.Bcl (>= 1.1.10)\r\n          Microsoft.Bcl.Build (>= 1.0.14)\r\n        Octokit (0.14.0)\r\n          Microsoft.Net.Http\r\n    GITHUB\r\n      remote: fsharp/FAKE\r\n      specs:\r\n        modules/Octokit/Octokit.fsx (991bea743c5d5e8eec0defc7338a89281ed3f51a)\r\n          Octokit\r\n\r\n    GROUP Test\r\n    NUGET\r\n      remote: https://nuget.org/api/v2\r\n      specs:\r\n        NUnit (2.6.4)\r\n        NUnit.Runners (2.6.4)\r\n        \r\nAs you can see every group is listed separately and we still have the backwards-compatible case for the \"Main\" group.\r\nIf you want to reference dependencies from projects you can do this via the following syntax in references files:\r\n\r\n## paket.references\r\n\r\n    File:FsUnit.fs .\r\n    FSharp.Core\r\n    \r\n    group Test\r\n      NUnit\r\n      NUnit.Runners\r\n\r\n## New ways for conflict resolution\r\n\r\nWe got many requests to support multiple versions of the same package with Paket. This was not possible since we had no way to discriminate these.\r\nNow we can support that by using multiple groups:\r\n\r\n    source https://nuget.org/api/v2\r\n    \r\n    nuget Newtonsoft.Json\r\n    \r\n    group Legacy\r\n        source https://nuget.org/api/v2\r\n    \r\n        nuget Newtonsoft.Json ~> 6\r\n\r\nEvery group will be resolved independently so that we get:\r\n\r\n    NUGET\r\n      remote: https://nuget.org/api/v2\r\n      specs:\r\n        Newtonsoft.Json (7.0.1)\r\n    \r\n    GROUP Legacy\r\n    NUGET\r\n      remote: https://nuget.org/api/v2\r\n      specs:\r\n        Newtonsoft.Json (6.0.8)\r\n        \r\nPaket is downloading both version. We will get `packages/Newtonsoft.Json` with version 7.0.1 and `packages/legacy/Newtonsoft.Json` with the 6.0.8 bits.\r\nIn your references files you can now decide which version you want to use:\r\n\r\n    group Legacy\r\n    Newtonsoft.Json\r\n\r\n## Open stuff\r\n\r\nThis is currently early alpha and definetly not production ready. But I will update this PR frequently and \r\n\r\n- [ ] - Create group specific commands like `paket restore group Test`\r\n- [ ] - Documentation\r\n- [ ] - Testing\r\n- [ ] - https://github.com/fsprojects/Paket/pull/1014 is not merged - @mrinaldi could you try to merge and send a PR against the `groups`branch?\r\n\r\n## Organizational remarks\r\n\r\n* Please send all Paket 2.0 PRs against the `groups` branch. I will start to release alpha versions from this branch.\r\n* Please continue to send all bugfix PR's against `master` branch."},"comment":{"url":"https://api.github.com/repos/fsprojects/Paket/issues/comments/135503013","html_url":"https://github.com/fsprojects/Paket/pull/1018#issuecomment-135503013","issue_url":"https://api.github.com/repos/fsprojects/Paket/issues/1018","id":135503013,"user":{"login":"Stift","id":1169723,"avatar_url":"https://avatars.githubusercontent.com/u/1169723?v=3","gravatar_id":"","url":"https://api.github.com/users/Stift","html_url":"https://github.com/Stift","followers_url":"https://api.github.com/users/Stift/followers","following_url":"https://api.github.com/users/Stift/following{/other_user}","gists_url":"https://api.github.com/users/Stift/gists{/gist_id}","starred_url":"https://api.github.com/users/Stift/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Stift/subscriptions","organizations_url":"https://api.github.com/users/Stift/orgs","repos_url":"https://api.github.com/users/Stift/repos","events_url":"https://api.github.com/users/Stift/events{/privacy}","received_events_url":"https://api.github.com/users/Stift/received_events","type":"User","site_admin":false},"created_at":"2015-08-27T17:40:12Z","updated_at":"2015-08-27T17:40:12Z","body":"Very nice. I just throw my +1 in the round.\r\nWill start testing ASAP"}}