Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Have Travis CI push doc pages? #155

Closed
ceedubs opened this issue Feb 9, 2015 · 6 comments
Closed

Have Travis CI push doc pages? #155

ceedubs opened this issue Feb 9, 2015 · 6 comments

Comments

@ceedubs
Copy link
Contributor

ceedubs commented Feb 9, 2015

Thanks to the excellent work of @stew and @tpolecat, we now have fancy documentation at http://non.github.io/cats/. It may be tough for us to remember to keep it up to date. Would it be possible/desired to have the Travis CI job for the master branch automatically publish those pages?

I'm not sure if this is tough from a permissions perspective. Also I don't know if there might be an issue with a really noisy git history for the pages that gets bulky when you pull the project?

@travisbrown
Copy link
Contributor

I think it's perfectly reasonable to purge the gh-pages history occasionally if it gets too bulky, and it's not too hard to set up Travis to publish the site automatically.

The only concern I'd have about this is that when you have Travis doing something that relies on the central repo's GH_TOKEN, that means any builds on forks are going to fail. I'm sure there's some way to script your way out of this, but I've run into the issue on other projects, and if there's a nice solution I haven't seen it.

@non
Copy link
Contributor

non commented May 22, 2015

It sounds like @inthenow is going to look into this.

@travisbrown do you feel strongly that we shouldn't set it up from Travis?

@travisbrown
Copy link
Contributor

No, going ahead sounds good to me!—at a glance it looks like it shouldn't be too hard to set this up with deploy or after_success to get around my concern.

@rossabaker
Copy link
Member

http4s publishes from Travis. We call this bash script from after_success. I don't think that's a drop-in solution for cats, but it's a starting point.

@ghost
Copy link

ghost commented May 23, 2015

@rossabaker thanks for the head start link and @travisbrown for the tip :)

@rossabaker
Copy link
Member

The trickiest thing I encountered implementing this is to not prune docs from prior releases. Help may be on the way with sbt/sbt-ghpages#10, but until then, I had to resort to copying code out of the plugin.

The API version TaskKey[(Int, Int)], which reflects the current version minus the patch number. I use that to specify the api subdirectory to git clean, and leave the remainder of api unscathed. (This is also a useful key should we want to get into the business of MiMa checking for binary compatibility.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants