{"action":"created","issue":{"url":"https://api.github.com/repos/common-workflow-language/common-workflow-language/issues/201","repository_url":"https://api.github.com/repos/common-workflow-language/common-workflow-language","labels_url":"https://api.github.com/repos/common-workflow-language/common-workflow-language/issues/201/labels{/name}","comments_url":"https://api.github.com/repos/common-workflow-language/common-workflow-language/issues/201/comments","events_url":"https://api.github.com/repos/common-workflow-language/common-workflow-language/issues/201/events","html_url":"https://github.com/common-workflow-language/common-workflow-language/issues/201","id":150133428,"number":201,"title":"Implementation: Directory type","user":{"login":"mr-c","id":1330696,"avatar_url":"https://avatars.githubusercontent.com/u/1330696?v=3","gravatar_id":"","url":"https://api.github.com/users/mr-c","html_url":"https://github.com/mr-c","followers_url":"https://api.github.com/users/mr-c/followers","following_url":"https://api.github.com/users/mr-c/following{/other_user}","gists_url":"https://api.github.com/users/mr-c/gists{/gist_id}","starred_url":"https://api.github.com/users/mr-c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mr-c/subscriptions","organizations_url":"https://api.github.com/users/mr-c/orgs","repos_url":"https://api.github.com/users/mr-c/repos","events_url":"https://api.github.com/users/mr-c/events{/privacy}","received_events_url":"https://api.github.com/users/mr-c/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2016-04-21T17:01:21Z","updated_at":"2016-05-03T17:47:53Z","closed_at":null,"body":"This is for @psaffrey-illumina, myself, and others to co-ordinate adding support for the Directory type as proposed in https://github.com/common-workflow-language/common-workflow-language/issues/172\r\n\r\n> So I presume I need to modify the CommandLineTool.yml to add the directory option. I thought it should just be adding a similar entry to this:\r\nhttps://github.com/common-workflow-language/common-workflow-language/blob/draft-4/draft-4/CommandLineTool.yml#L78\r\n> but I'm a bit confused about this entry in the comments:\r\n> \"Define a file that must be placed in the designated output directory prior to executing the command line tool.\"\r\n> I thought this was defining an input file but it talks about an *output* directory?\r\n\r\nHere, FileDef is only used by http://www.commonwl.org/draft-3/CommandLineTool.html#CreateFileRequirement so the references to the output directory are correct.\r\n\r\nFor Draft-4 we will amend FileDef so we can use it to describe files where the name or content is changed.\r\n\r\nHere is my understanding of what we need to do:\r\n\r\n- [ ] Add `initialWorkDir` as an optional top-level entry for CommandLineTools\r\n- [ ] Define the following fields for `initialWorkDir`: `class` (always `directory`), and `listing` (an array of `File`, expression, `FileDef`, or subdirectories)\r\n- [ ] Update description of `FileDef`\r\n- [ ] implement support for all of the above in `cwltool`\r\n- [ ] write tests\r\n"},"comment":{"url":"https://api.github.com/repos/common-workflow-language/common-workflow-language/issues/comments/216609499","html_url":"https://github.com/common-workflow-language/common-workflow-language/issues/201#issuecomment-216609499","issue_url":"https://api.github.com/repos/common-workflow-language/common-workflow-language/issues/201","id":216609499,"user":{"login":"mr-c","id":1330696,"avatar_url":"https://avatars.githubusercontent.com/u/1330696?v=3","gravatar_id":"","url":"https://api.github.com/users/mr-c","html_url":"https://github.com/mr-c","followers_url":"https://api.github.com/users/mr-c/followers","following_url":"https://api.github.com/users/mr-c/following{/other_user}","gists_url":"https://api.github.com/users/mr-c/gists{/gist_id}","starred_url":"https://api.github.com/users/mr-c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mr-c/subscriptions","organizations_url":"https://api.github.com/users/mr-c/orgs","repos_url":"https://api.github.com/users/mr-c/repos","events_url":"https://api.github.com/users/mr-c/events{/privacy}","received_events_url":"https://api.github.com/users/mr-c/received_events","type":"User","site_admin":false},"created_at":"2016-05-03T17:47:53Z","updated_at":"2016-05-03T17:47:53Z","body":"@psaffrey-illumina You can use `schema-salad-tool` from https://pypi.python.org/pypi/schema-salad / https://github.com/common-workflow-language/schema_salad to check your work\r\n\r\n```\r\n(env) mcrusoe@mrcdev:~/common-workflow-language$ schema-salad-tool draft-3/CommandLineTool-standalone.yml \r\n/home/mcrusoe/common-workflow-language/env/bin/schema-salad-tool 1.7.20160316203940\r\nSchema `draft-3/CommandLineTool-standalone.yml` is valid\r\n```\r\nvs. your latest branch\r\n\r\n```\r\n(env) mcrusoe@mrcdev:~/common-workflow-language$ schema-salad-tool draft-4/CommandLineTool-standalone.yml \r\n/home/mcrusoe/common-workflow-language/env/bin/schema-salad-tool 1.7.20160316203940\r\nSchema `draft-4/CommandLineTool-standalone.yml` failed link checking:\r\nWhile checking object `https://w3id.org/cwl/cwl#InitialWorkingDirectory`\r\n  While checking field `fields`\r\n    While checking object `https://w3id.org/cwl/cwl#InitialWorkingDirectory/dirDef`\r\n      Field `items` contains undefined reference to `https://w3id.org/cwl/File`\r\n      Field `items` contains undefined reference to `https://w3id.org/cwl/Directory`\r\n      While checking field `type`\r\n        Field `items` contains undefined reference to `https://w3id.org/cwl/File`\r\n        Field `items` contains undefined reference to `https://w3id.org/cwl/Directory`\r\n```"}}