Open ahjohannessen opened 11 years ago
@krasserm
What do you prefer, a fully-fledged site a la spray or something similar to that of Akka, sbt and Slick docs site? One difference is that the Spray approach requires hosting whereas the latter can be on github.
Using the same doc templates as Akka and sbt are using would be great. Would that mean we also have to rewrite the user guide in rst format?
I am not entirely sure, but Pandoc seems to be fit for the conversion job. If not, I could happily do that. But again, this depends on your preferences.
Ah, didn't know Pandoc. Sure, let's give it a try and see what happens. If the conversion is good, we still could have the mastercopies in markdown and publish the rst result. But I'm also open to work with rst only ... once I learned it :)
@krasserm
I was thinking that publishing to gh-pages by way of https://github.com/sbt/sbt-ghpages could be a nice thing to have. I just need to figure if travis allows for installing sphinx via its yaml file (not entirely sure, but almost certain that is possible)
I have been a bit busy with work stuff and such, but will start work on this soon :)
@ahjohannessen
no rush, take as much time as you need :)
Using sbt-ghpages in combination with sbt-site sounds reasonable to me. Even if we can't get it running on Travis, we can also install it on the Linux server I'm running locally. This server is running Jenkins and currently doing the following tasks:
target/unidoc
by running sbt unidoc
.api/snapshot
directory on the gh-pages branch. I'm completely open to switching to a sbt-ghpages and sbt-site based approach here.Whatever we're going to change, I'd like to keep the api/snapshot
directory, if possible. Some external links are already pointing to it. From what I've seen so far, it doesn't seem to conflict with other stuff we want to generate.
Furthermore, I want to avoid storing any credentials (private deploy keys, maven repo passwords, ...) on the Travis CI infrastructure unless they have some convincing means to protect them ...
WDYT?
... and thanks for keeping working on this task. Highly appreciate it.
Furthermore, I want to avoid storing any credentials (private deploy keys, maven repo passwords, ...) on the Travis CI infrastructure unless they have some convincing means to protect them ...
I see http://about.travis-ci.org/docs/user/travis-pro/#How-can-I-encrypt-files-that-include-sensitive-data%3F as an option to encrypt credentials.
@ahjohannessen do you still plan to work on that?
@krasserm I think your comments above are sound:
Unfortunately, I have been swamped with work around using akka/eventsourced for our backend. So, with that in mind I still have high interested in Eventsourced, reason for being so quiet is because of priorities and learning new stuff about this new ecosystem (coming from .net) .
I still plan to work on this, I just need to get my air back :)
No rush and thanks for your ongoing interest :)
@krasserm Finally got around to start working on this :)
Exciting. Can't wait to see it.
Woohoo!
Just a little heads up.
I have managed to setup the necessary bits for:
Now I am struggling a bit with some minor conversion issues, but I am investigating this.
Essentially, I have created a project called "eventsourced-site" that has a sphinx folder with stuff like extensions, pygments and theme and then a rst folder with the documentation.
So, as soon one does a "make-site" from top-level project (eventsourced) in sbt it generates a folder under es-site/target/ that contains the generated html. It is also possible to do a preview-site in sbt that opens the site in your browser.
@ahjohannessen this sounds really good, thanks for the update. Is the markdown -> rst conversion good enough so that we can continue writing docs in markdown or should we switch to rst directly? What I like with markdown is that github does the rendering automatically.
+1 for markdown.
On Fri, Apr 12, 2013 at 1:33 AM, Martin Krasser notifications@github.comwrote:
@ahjohannessen https://github.com/ahjohannessen this sounds really good, thanks for the update. Is the markdown -> rst conversion good enough so that we can continue writing docs in markdown or should we switch to rst directly? What I like with markdown is that github does the rendering automatically.
— Reply to this email directly or view it on GitHubhttps://github.com/eligosource/eventsourced/issues/59#issuecomment-16276660 .
Duncan K. DeVore <><
@krasserm Longterm, it probably makes sense to switch to rst directly if we are going to have the docs spread across different subfolders (like akka etc. do) and if pandoc cannot convert without intervention.
I understand your point with markdown being rendered automatically. However, there are a few tools available for editing and rendering automatically in rst:
http://stackoverflow.com/questions/2746692/restructuredtext-tool-support
I wonder how the Akka, Spray and SBT guys approach this and what kind of rst editor they use.
This seems to be a nice, yet simple, online editor for rst: http://rst.ninjs.org
@ahjohannessen thanks for the rst tooling links. They make it clear that the tooling support for rst is pretty strong. For processing markdown docs spread across different folders we could also consider using http://software.clapper.org/sbt-lwm/ but I'm not sure if this plugin is still actively developed and maintained. Compared to the rst tooling chain this plugin seems to be more limited, though. But what interests me most: could you automatically convert the existing markdown files to rst or was there manual intervention necessary?
@ddevore what are your main reasons for preferring markdown? Mine are primarily that I'm familiar with it in addition to the reason mentioned my previous comment. But there are also things that I'm missing with markdown (at least I'm not aware of their existence):
What I'm missing with markdown is that code cannot be included/inlined into docs based on tags/metadata in the scala source files which would be very helpful for the examples. This could avoid stale code in the docs should the example code change e.g. during a refactoring. @ahjohannessen is this possible with rst and its tooling chain?
@krasserm I think that I can get most of it to work automatically with some minor corrections in the markdown. This is mainly centered around using ticks in some links, the html build reference and some spaces after code examples. Even though much is transformed for free, some corrections are probably needed to get it to look nice.
@krasserm I believe it is possible to embed code examples directly, Slick does this, not sure about Akka and Spray though. My general impression is that rst is more powerful for automating things. I have noticed that some of the docs from other Scala projects take advantage of automation, e.g. inject version number, embed code and so on.
@ddevore As far as I can tell, rst is as powerful as markdown, but the convenience with github editor is nice. However, IMO, going with sphinx it becomes possible to do some interesting things, e.g. embed code in docs and ensure that examples break the doc builds if the API changes and similar. We get docs a la Akka style :)
@krasserm Mine is the same as yours. I'm familiar w/ Markdown and have been a big fan of it for some time. I appreciate its simplicity. On a side note, I know the author of sbt-lwm as he (Brian Clapper) is a friend of mine. I'll reach out to him and see if he is/intends to maintain the library.
@ahjohannessen We should use the best tool for the job, and if that's RST then it makes sense to use it. I'm not familiar w/ it but it sounds pretty powerful. I know some guys at Typesafe (previous co-workers) and reached out to them to see what tools they use. I'll let you know what I find out.
My bad - clicked the wrong button ;-(
@ahjohannessen From looking at the Akka Github site, it does indeed look like they are using sphinx and RST.
@krasserm As for editor's, it looks like there is a lot of stuff out there. In particular I found two plugins for sublime:
On a side note, I know the author of sbt-lwm as he (Brian Clapper) is a friend of mine. I'll reach out to him and see if he is/intends to maintain the library.
Great, thanks.
We should use the best tool for the job, and if that's RST then it makes sense to use it.
+1
As for editor's, it looks like there is a lot of stuff out there
I'll also try http://plugins.jetbrains.com/plugin?pr=idea&pluginId=7124
I think that I can get most of it to work automatically with some minor corrections in the markdown
If this allows us to have a fully automated markdown -> rst conversion, I think this is a reasonable short-term solution. Should we succeed to include snippets from .scala
files and this is possible with rst only, we should consider switching to rst in a second step. But let's also wait for Brian Clapper's response.
@krasserm Spoke to Brian and he does stay on top of it recompiling when necessary, etc.
@ddevore good to know, thanks.
@krasserm @ahjohannessen Just found out from Typsafe the Akka team (Viktor) that they use Jekyll. Here's the Jekyll Github link.
That confuses me a bit, because I cannot find traces of Jekyll in the akka source. All their docs are in rst, take a look here: https://github.com/akka/akka/tree/master/akka-docs/rst and here: https://github.com/akka/akka/blob/master/project/AkkaBuild.scala#L471
If this allows us to have a fully automated markdown -> rst conversion, I think this is a reasonable short-term solution.
I will look more into this tonight :)
@ahjohannessen yeah I see what your saying about Jekyll. Not sure, just the feedback I got from them. I say lets use whatever works best for us. ;-)
It would be awesome to have a small site for Eventsourced that follows same "mantra" as the one Spray has.
Inspiration for build stuff: