{"action":"created","issue":{"url":"https://api.github.com/repos/PDMLab/docker-compose/issues/3","repository_url":"https://api.github.com/repos/PDMLab/docker-compose","labels_url":"https://api.github.com/repos/PDMLab/docker-compose/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/PDMLab/docker-compose/issues/3/comments","events_url":"https://api.github.com/repos/PDMLab/docker-compose/issues/3/events","html_url":"https://github.com/PDMLab/docker-compose/issues/3","id":332987929,"node_id":"MDU6SXNzdWUzMzI5ODc5Mjk=","number":3,"title":"Additional API proposal","user":{"login":"modjke","id":2504184,"node_id":"MDQ6VXNlcjI1MDQxODQ=","avatar_url":"https://avatars1.githubusercontent.com/u/2504184?v=4","gravatar_id":"","url":"https://api.github.com/users/modjke","html_url":"https://github.com/modjke","followers_url":"https://api.github.com/users/modjke/followers","following_url":"https://api.github.com/users/modjke/following{/other_user}","gists_url":"https://api.github.com/users/modjke/gists{/gist_id}","starred_url":"https://api.github.com/users/modjke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/modjke/subscriptions","organizations_url":"https://api.github.com/users/modjke/orgs","repos_url":"https://api.github.com/users/modjke/repos","events_url":"https://api.github.com/users/modjke/events{/privacy}","received_events_url":"https://api.github.com/users/modjke/received_events","type":"User","site_admin":false},"labels":[{"id":621820396,"node_id":"MDU6TGFiZWw2MjE4MjAzOTY=","url":"https://api.github.com/repos/PDMLab/docker-compose/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"state":"open","locked":false,"assignee":{"login":"modjke","id":2504184,"node_id":"MDQ6VXNlcjI1MDQxODQ=","avatar_url":"https://avatars1.githubusercontent.com/u/2504184?v=4","gravatar_id":"","url":"https://api.github.com/users/modjke","html_url":"https://github.com/modjke","followers_url":"https://api.github.com/users/modjke/followers","following_url":"https://api.github.com/users/modjke/following{/other_user}","gists_url":"https://api.github.com/users/modjke/gists{/gist_id}","starred_url":"https://api.github.com/users/modjke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/modjke/subscriptions","organizations_url":"https://api.github.com/users/modjke/orgs","repos_url":"https://api.github.com/users/modjke/repos","events_url":"https://api.github.com/users/modjke/events{/privacy}","received_events_url":"https://api.github.com/users/modjke/received_events","type":"User","site_admin":false},"assignees":[{"login":"modjke","id":2504184,"node_id":"MDQ6VXNlcjI1MDQxODQ=","avatar_url":"https://avatars1.githubusercontent.com/u/2504184?v=4","gravatar_id":"","url":"https://api.github.com/users/modjke","html_url":"https://github.com/modjke","followers_url":"https://api.github.com/users/modjke/followers","following_url":"https://api.github.com/users/modjke/following{/other_user}","gists_url":"https://api.github.com/users/modjke/gists{/gist_id}","starred_url":"https://api.github.com/users/modjke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/modjke/subscriptions","organizations_url":"https://api.github.com/users/modjke/orgs","repos_url":"https://api.github.com/users/modjke/repos","events_url":"https://api.github.com/users/modjke/events{/privacy}","received_events_url":"https://api.github.com/users/modjke/received_events","type":"User","site_admin":false}],"milestone":null,"comments":3,"created_at":"2018-06-16T13:39:08Z","updated_at":"2018-09-30T03:59:18Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"So while i was implementing an npm build system for my docker-compose project i had this idea of changing existing API for this module (or adding it on top of an existing one) to make this module more OOPeish and to avoid repetion of `cwd` , `log` and other parameters.\r\nWould you be interested in something like this?\r\n```javascript\r\nconst DockerCompose = require('docker-compose')\r\n// DockerCompose.method will still be a thing (legacy support), but the main course is\r\nconst compose = new DockerCompose({\r\n  cwd: '.',\r\n  log: false,\r\n  config: 'docker-compose.yml'\r\n})\r\n\r\nawait compose.build()\r\nawait compose.up()\r\nconst container = 'node'\r\nconst command = 'npm install'\r\nawait compose.exec(container, command, {\r\n  log: true, // will override initial constructor settings\r\n  workdir: './var/www' //  cli args for exec and other commands will be also supported\r\n})\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/PDMLab/docker-compose/issues/comments/425692755","html_url":"https://github.com/PDMLab/docker-compose/issues/3#issuecomment-425692755","issue_url":"https://api.github.com/repos/PDMLab/docker-compose/issues/3","id":425692755,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNTY5Mjc1NQ==","user":{"login":"SgtPooki","id":1173416,"node_id":"MDQ6VXNlcjExNzM0MTY=","avatar_url":"https://avatars1.githubusercontent.com/u/1173416?v=4","gravatar_id":"","url":"https://api.github.com/users/SgtPooki","html_url":"https://github.com/SgtPooki","followers_url":"https://api.github.com/users/SgtPooki/followers","following_url":"https://api.github.com/users/SgtPooki/following{/other_user}","gists_url":"https://api.github.com/users/SgtPooki/gists{/gist_id}","starred_url":"https://api.github.com/users/SgtPooki/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SgtPooki/subscriptions","organizations_url":"https://api.github.com/users/SgtPooki/orgs","repos_url":"https://api.github.com/users/SgtPooki/repos","events_url":"https://api.github.com/users/SgtPooki/events{/privacy}","received_events_url":"https://api.github.com/users/SgtPooki/received_events","type":"User","site_admin":false},"created_at":"2018-09-30T03:59:18Z","updated_at":"2018-09-30T03:59:18Z","author_association":"NONE","body":"maybe i'm missing something but how exactly is this proposal different than what exists? Can you call out the changes and additions so others could see the pros/cons of your proposal?"}}
{"actor":{"display_login":"SgtPooki"}}