* [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects @ 2016-02-29 16:40 Anton Bachin 2016-02-29 16:53 ` Arto Bendiken 2016-02-29 18:37 ` Ivan Gotovchits 0 siblings, 2 replies; 7+ messages in thread From: Anton Bachin @ 2016-02-29 16:40 UTC (permalink / raw) To: OCaml users [-- Attachment #1: Type: text/plain, Size: 1082 bytes --] Hello, I would like to announce the release of Namespaces, an Ocamlbuild plugin that gives your project logical nested modules based on its directory layout, as is common in the build systems of many other languages. So, src/server/foo.ml becomes Server.Foo, and src/client/foo.ml becomes Client.Foo. There is no conflict between the two foo.ml files, and thus no need to call them server_foo.ml and client_foo.ml. The project page and documentation can be found here: https://github.com/aantron/namespaces <https://github.com/aantron/namespaces> Namespaces works, but it abuses Ocamlbuild heavily, so there may be many corner cases that are not yet addressed well. Bug reports are very much welcome. If something can’t be fixed by changing Namespaces, perhaps Namespaces will be a good point of discussion for updating Ocamlbuild itself, or other OCaml tooling. Regards and enjoy, Anton P.S. How is Ocamlbuild spelled? I have seen it as Ocamlbuild, OCamlbuild (which stands to reason), and ocamlbuild in monospace font, in the original manual. [-- Attachment #2: Type: text/html, Size: 1945 bytes --] ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects 2016-02-29 16:40 [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects Anton Bachin @ 2016-02-29 16:53 ` Arto Bendiken 2016-02-29 18:37 ` Ivan Gotovchits 1 sibling, 0 replies; 7+ messages in thread From: Arto Bendiken @ 2016-02-29 16:53 UTC (permalink / raw) To: Anton Bachin; +Cc: OCaml users Good afternoon Anton, On Mon, Feb 29, 2016 at 5:40 PM, Anton Bachin <antronbachin@gmail.com> wrote: > So, src/server/foo.ml becomes Server.Foo, and src/client/foo.ml becomes > Client.Foo. There is no conflict between the two foo.ml files, and thus no > need to call them server_foo.ml and client_foo.ml. Kudos for this, it's a most welcome development. So far accomplishing this sane project structure has required the use of Cppo or ppx_include, which in turn has tended to preclude the use of other PPX packages. Anything that can simplify all this is a definite boon. Cheers, Arto -- Arto Bendiken | @bendiken | http://ar.to ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects 2016-02-29 16:40 [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects Anton Bachin 2016-02-29 16:53 ` Arto Bendiken @ 2016-02-29 18:37 ` Ivan Gotovchits 2016-02-29 18:45 ` Anton Bachin 1 sibling, 1 reply; 7+ messages in thread From: Ivan Gotovchits @ 2016-02-29 18:37 UTC (permalink / raw) To: Anton Bachin; +Cc: OCaml users [-- Attachment #1: Type: text/plain, Size: 1322 bytes --] Hi Anton! It is a great project! But nowadays I always want to know, does it work with merlin? Regards, Ivan On Mon, Feb 29, 2016 at 11:40 AM, Anton Bachin <antronbachin@gmail.com> wrote: > Hello, > > I would like to announce the release of Namespaces, an Ocamlbuild plugin > that > gives your project logical nested modules based on its directory layout, > as is > common in the build systems of many other languages. > > So, src/server/foo.ml becomes Server.Foo, and src/client/foo.ml becomes > Client.Foo. There is no conflict between the two foo.ml files, and thus > no need > to call them server_foo.ml and client_foo.ml. > > The project page and documentation can be found here: > > https://github.com/aantron/namespaces > > Namespaces works, but it abuses Ocamlbuild heavily, so there may be many > corner > cases that are not yet addressed well. Bug reports are very much welcome. > If > something can’t be fixed by changing Namespaces, perhaps Namespaces will > be a > good point of discussion for updating Ocamlbuild itself, or other OCaml > tooling. > > > Regards and enjoy, > Anton > > > P.S. How is Ocamlbuild spelled? I have seen it as Ocamlbuild, OCamlbuild > (which > stands to reason), and ocamlbuild in monospace font, in the original > manual. > [-- Attachment #2: Type: text/html, Size: 2266 bytes --] ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects 2016-02-29 18:37 ` Ivan Gotovchits @ 2016-02-29 18:45 ` Anton Bachin 2016-03-01 1:00 ` Junsong Li 0 siblings, 1 reply; 7+ messages in thread From: Anton Bachin @ 2016-02-29 18:45 UTC (permalink / raw) To: Ivan Gotovchits; +Cc: OCaml users [-- Attachment #1: Type: text/plain, Size: 2048 bytes --] Thanks Arto, Ivan. The question about Merlin is a good one. I better start using Merlin myself, because I don’t know the answer. I suppose if Merlin reads things from src/ (or lib/, or whatever) in a project, then it shouldn’t work. But if Merlin reads from _build/, as I would think it does, then it “should" work. But I don’t know either way at the moment. It will probably take some time for me to set Merlin up, but I will look into it. Best, Anton > On Feb 29, 2016, at 12:37, Ivan Gotovchits <ivg@ieee.org> wrote: > > > Hi Anton! > > It is a great project! > > But nowadays I always want to know, does it work with merlin? > > Regards, > Ivan > > On Mon, Feb 29, 2016 at 11:40 AM, Anton Bachin <antronbachin@gmail.com <mailto:antronbachin@gmail.com>> wrote: > Hello, > > I would like to announce the release of Namespaces, an Ocamlbuild plugin that > gives your project logical nested modules based on its directory layout, as is > common in the build systems of many other languages. > > So, src/server/foo.ml <http://foo.ml/> becomes Server.Foo, and src/client/foo.ml <http://foo.ml/> becomes > Client.Foo. There is no conflict between the two foo.ml <http://foo.ml/> files, and thus no need > to call them server_foo.ml <http://server_foo.ml/> and client_foo.ml <http://client_foo.ml/>. > > The project page and documentation can be found here: > > https://github.com/aantron/namespaces <https://github.com/aantron/namespaces> > > Namespaces works, but it abuses Ocamlbuild heavily, so there may be many corner > cases that are not yet addressed well. Bug reports are very much welcome. If > something can’t be fixed by changing Namespaces, perhaps Namespaces will be a > good point of discussion for updating Ocamlbuild itself, or other OCaml tooling. > > > Regards and enjoy, > Anton > > > P.S. How is Ocamlbuild spelled? I have seen it as Ocamlbuild, OCamlbuild (which > stands to reason), and ocamlbuild in monospace font, in the original manual. > [-- Attachment #2: Type: text/html, Size: 4054 bytes --] ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects 2016-02-29 18:45 ` Anton Bachin @ 2016-03-01 1:00 ` Junsong Li 2016-03-01 9:25 ` Thomas Refis 0 siblings, 1 reply; 7+ messages in thread From: Junsong Li @ 2016-03-01 1:00 UTC (permalink / raw) To: Anton Bachin; +Cc: Ivan Gotovchits, OCaml users [-- Attachment #1: Type: text/plain, Size: 2275 bytes --] I don't think that would be a problem. You can always configure Merlin to read the directory that you want it to read, right? On Monday, February 29, 2016, Anton Bachin <antronbachin@gmail.com> wrote: > Thanks Arto, Ivan. > > The question about Merlin is a good one. I better start using Merlin > myself, because I don’t know the answer. I suppose if Merlin reads > things from src/ (or lib/, or whatever) in a project, then it shouldn’t > work. But if Merlin reads from _build/, as I would think it does, then > it “should" work. But I don’t know either way at the moment. It will > probably take some time for me to set Merlin up, but I will look into > it. > > Best, > Anton > > On Feb 29, 2016, at 12:37, Ivan Gotovchits <ivg@ieee.org > <javascript:_e(%7B%7D,'cvml','ivg@ieee.org');>> wrote: > > > Hi Anton! > > It is a great project! > > But nowadays I always want to know, does it work with merlin? > > Regards, > Ivan > > On Mon, Feb 29, 2016 at 11:40 AM, Anton Bachin <antronbachin@gmail.com > <javascript:_e(%7B%7D,'cvml','antronbachin@gmail.com');>> wrote: > >> Hello, >> >> I would like to announce the release of Namespaces, an Ocamlbuild plugin >> that >> gives your project logical nested modules based on its directory layout, >> as is >> common in the build systems of many other languages. >> >> So, src/server/foo.ml becomes Server.Foo, and src/client/foo.ml becomes >> Client.Foo. There is no conflict between the two foo.ml files, and thus >> no need >> to call them server_foo.ml and client_foo.ml. >> >> The project page and documentation can be found here: >> >> https://github.com/aantron/namespaces >> >> Namespaces works, but it abuses Ocamlbuild heavily, so there may be many >> corner >> cases that are not yet addressed well. Bug reports are very much welcome. >> If >> something can’t be fixed by changing Namespaces, perhaps Namespaces will >> be a >> good point of discussion for updating Ocamlbuild itself, or other OCaml >> tooling. >> >> >> Regards and enjoy, >> Anton >> >> >> P.S. How is Ocamlbuild spelled? I have seen it as Ocamlbuild, OCamlbuild >> (which >> stands to reason), and ocamlbuild in monospace font, in the original >> manual. >> > > > [-- Attachment #2: Type: text/html, Size: 3601 bytes --] ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects 2016-03-01 1:00 ` Junsong Li @ 2016-03-01 9:25 ` Thomas Refis 2016-03-07 22:38 ` Anton Bachin 0 siblings, 1 reply; 7+ messages in thread From: Thomas Refis @ 2016-03-01 9:25 UTC (permalink / raw) To: Junsong Li; +Cc: Anton Bachin, Ivan Gotovchits, OCaml users Hi, I haven't tested Namespaces (nice project btw) but it should work just fine with merlin. Thomas. ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects 2016-03-01 9:25 ` Thomas Refis @ 2016-03-07 22:38 ` Anton Bachin 0 siblings, 0 replies; 7+ messages in thread From: Anton Bachin @ 2016-03-07 22:38 UTC (permalink / raw) To: Thomas Refis; +Cc: Junsong Li, Ivan Gotovchits, OCaml users Indeed, I can confirm that Namespaces and Merlin work fine together. Anton > On Mar 1, 2016, at 03:25, Thomas Refis <thomas.refis@gmail.com> wrote: > > Hi, > > I haven't tested Namespaces (nice project btw) but it should work just > fine with merlin. > > Thomas. ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2016-03-07 22:39 UTC | newest] Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2016-02-29 16:40 [Caml-list] [ANN] Namespaces – sensible file naming for OCaml projects Anton Bachin 2016-02-29 16:53 ` Arto Bendiken 2016-02-29 18:37 ` Ivan Gotovchits 2016-02-29 18:45 ` Anton Bachin 2016-03-01 1:00 ` Junsong Li 2016-03-01 9:25 ` Thomas Refis 2016-03-07 22:38 ` Anton Bachin
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox