Providing Gradle Dash Docset

I use Dash for API documentation and noticed Gradle doesn’t have a Docset.

I have created a docset for Gradle that has the api-doc and the dsl guide and would like to submit this to be included with Dash, but would like to get permission to use the new elephant icon. Who do I need to email to get permission for this?

1 Like

Hey ethan,

great idea! I reached out to our marketing guy @miko1 for clarification.

cheers,
René

I’d like to have something like this available too. Not just the User Guide - but the DSL would also be nice to have.

If you would like to look at the docset and give some feedback that would be greatly appreciated.

Looks great (from my cursory test). I’m going to keep it installed and use it as I am learning Gradle right now.

One question I do have…would it be possible to also include the User Guide (i.e. the document at https://docs.gradle.org/current/userguide/userguide)? I’d suggest tagging each chapter as either a “Guide” or a “Section” (as defined at https://kapeli.com/docsets#supportedentrytypes).

I would also suggest that you work towards submitting this as an official (or even third-party: https://github.com/Kapeli/Dash-User-Contributions#contribute-a-new-docset) - even without the official “elephant” icon… In my opinion, having the data available would be much more helpful than having the icon (and the docset could be updated at a later point).

Those are my only (very minor) suggestions.

Using the following xslt file (gradle-userguide.xslt), I was able to just throw in the userguide directory to the docset and get it to work (may need tweaks):

<?xml version="1.0"?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="text" omit-xml-declaration="yes" />

<xsl:template match="/">
    <xsl:for-each select="//span[@class='chapter']">
        <xsl:text>INSERT OR IGNORE INTO searchIndex(name, type, path) VALUES ('</xsl:text>
        <xsl:value-of select="." />
        <xsl:text>','Section','userguide/</xsl:text>
        <xsl:value-of select="a[1]/@href" />
        <xsl:text>');&#10;</xsl:text>
    </xsl:for-each>
</xsl:template>

</xsl:stylesheet>

I then ran the command (from the gradle.docset/Contents/Resources directory):

xsltproc --html gradle-userguide.xslt Documents/userguide/userguide.html | sed -e "s/'\([0-9]\.\)/'0\1/g" | sqlite3 docSet.dsidx

I’ll take a look and try to add it!

@toonetown I updated the link from the previous post and added chapter’s to it. Could you give it a look and see how it works for you? I also removed things from the index that don’t have any javadoc to remove some of those overloaded calls.

@ethankhall - sorry, I haven’t had a chance to test it right now - and I’m going to be out for the next few weeks, so I’ll have to take a look at it when I get back.