{"action":"created","issue":{"url":"https://api.github.com/repos/ocaml/oasis/issues/70","repository_url":"https://api.github.com/repos/ocaml/oasis","labels_url":"https://api.github.com/repos/ocaml/oasis/issues/70/labels{/name}","comments_url":"https://api.github.com/repos/ocaml/oasis/issues/70/comments","events_url":"https://api.github.com/repos/ocaml/oasis/issues/70/events","html_url":"https://github.com/ocaml/oasis/pull/70","id":111725535,"number":70,"title":"Add SourcePatterns library field for locating source files.","user":{"login":"paurkedal","id":144070,"avatar_url":"https://avatars.githubusercontent.com/u/144070?v=3","gravatar_id":"","url":"https://api.github.com/users/paurkedal","html_url":"https://github.com/paurkedal","followers_url":"https://api.github.com/users/paurkedal/followers","following_url":"https://api.github.com/users/paurkedal/following{/other_user}","gists_url":"https://api.github.com/users/paurkedal/gists{/gist_id}","starred_url":"https://api.github.com/users/paurkedal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paurkedal/subscriptions","organizations_url":"https://api.github.com/users/paurkedal/orgs","repos_url":"https://api.github.com/users/paurkedal/repos","events_url":"https://api.github.com/users/paurkedal/events{/privacy}","received_events_url":"https://api.github.com/users/paurkedal/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2015-10-15T23:05:12Z","updated_at":"2016-08-25T07:15:02Z","closed_at":"2016-08-21T14:04:37Z","pull_request":{"url":"https://api.github.com/repos/ocaml/oasis/pulls/70","html_url":"https://github.com/ocaml/oasis/pull/70","diff_url":"https://github.com/ocaml/oasis/pull/70.diff","patch_url":"https://github.com/ocaml/oasis/pull/70.patch"},"body":"This allows overriding the built-in file extensions with a list of user-specified patterns, in order to support custom build rules.\r\n\r\nThe primary reason for this patch, is that I'm seen the pageful of \"Cannot find source file matching module\" warnings on a regular bases while developing Eliom applications.  With this patch, I can simply add \r\n\r\n    Library \"app\"\r\n      Path: src/server\r\n      SourcePatterns: %.ml, %.mli, ../%.eliom, ../%.eliomi\r\n      Modules: App_index, App_page\r\n\r\nto the library sections to help OASIS find the files.  It should be noted that the [Eliom section on the matter](http://ocsigen.org/eliom/4.2/manual/workflow-compilation) recommends prefixing each module with \"server\" and \"client\" paths:\r\n\r\n    Library \"app\"\r\n      Path: src\r\n      Modules: server/App_index, server/App_page\r\n\r\nIn this case `SourcePatterns` won't help.  I think it's better anyway to build the client and server parts into separate directories, which also permits having separate META files if building a client-side library instead of an executable.\r\n\r\nUpdate: If we want to support the style from the Eliom manual, I can send a update which extracts the base name of the directory-qualified module name before applying the pattern."},"comment":{"url":"https://api.github.com/repos/ocaml/oasis/issues/comments/242300507","html_url":"https://github.com/ocaml/oasis/pull/70#issuecomment-242300507","issue_url":"https://api.github.com/repos/ocaml/oasis/issues/70","id":242300507,"user":{"login":"gildor478","id":452797,"avatar_url":"https://avatars.githubusercontent.com/u/452797?v=3","gravatar_id":"","url":"https://api.github.com/users/gildor478","html_url":"https://github.com/gildor478","followers_url":"https://api.github.com/users/gildor478/followers","following_url":"https://api.github.com/users/gildor478/following{/other_user}","gists_url":"https://api.github.com/users/gildor478/gists{/gist_id}","starred_url":"https://api.github.com/users/gildor478/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gildor478/subscriptions","organizations_url":"https://api.github.com/users/gildor478/orgs","repos_url":"https://api.github.com/users/gildor478/repos","events_url":"https://api.github.com/users/gildor478/events{/privacy}","received_events_url":"https://api.github.com/users/gildor478/received_events","type":"User","site_admin":false},"created_at":"2016-08-25T07:15:02Z","updated_at":"2016-08-25T07:15:02Z","body":"Can you give me a 'ls -alR' (file listing) at each stage of the build process ?\r\n\r\nI think this is an advanced but nice use case. Would be nice to find  a solution for it!\r\n\r\nMaybe open a bug here:\r\nhttps://forge.ocamlcore.org/tracker/?atid=291&group_id=54&func=browse\r\nand attach the various directory listing."}}
{"actor":{"display_login":"gildor478"}}