GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Find a way to share the HTML + CSS for our gcloud-* docs ? · Issue #1094 · googleapis/google-cloud-python

Find a way to share the HTML + CSS for our gcloud-* docs ? #1094

New issue
Copy link
New issue
Copy link
Closed
Closed
Find a way to share the HTML + CSS for our gcloud-* docs ?#1094
Copy link
Assignees
dhermes

Description

@jgeewax
jgeewax
opened on Aug 26, 2015
Issue body actions

From @dhermes in #1092 (comment):

@jgeewax I think we should tried to have shared HTML / JS / CSS for our custom theme.

It seems the Node.js theme continues to improve while ours looks like an old snapshot of what they had.

Comparing our custom docs to RTD is not great (i.e. ours look not so great):
http://googlecloudplatform.github.io/gcloud-python/latest/gcloud-auth.html
http://gcloud-python.readthedocs.org/en/latest/gcloud-auth.html

UPDATE: I think we should consider just using readthedocs and maybe customizing their theme.


Sharing themes:

I think if we can find a way to generate a JSON output of our docs like the dox script does, we could use the exact same theme. I would really really like that.

/cc @stephenplusplus @callmehiphop to comment

Just using read-the-docs:

I totally get that this is "the Python way to host docs" -- I'm all for it in addition to the gcloud themed docs, the same way I'm all for Javadocs for gcloud-java and Godocs for gcloud-golang (and MSDN looking docs for gcloud-dotnet when we do it). The branding piece is important as well, and I'm fine with us investing the time to continue maintaining these.

Am I correct in the assumption that RTD / Javadocs / etc should take relatively small amounts of work going forward?

Activity

Next
  1. jgeewax commented on Aug 26, 2015

    @jgeewax
    jgeewax
    on Aug 26, 2015
    ContributorAuthor
    More actions

    /cc @mpmcdonald

  2. jgeewax commented on Aug 26, 2015

    @jgeewax
    jgeewax
    on Aug 26, 2015
    ContributorAuthor
    More actions

    Maybe we can export stuff via http://sphinx-doc.org/builders.html#sphinx.builders.html.JSONHTMLBuilder ?

  3. dhermes commented on Aug 26, 2015

    @dhermes
    dhermes
    on Aug 26, 2015
    Contributor
    More actions

    I'm open to it but don't want to write our own custom docs builder. I think the readthedocs.org build script creates the JSON for something (not sure what it's used for).

  4. jgeewax commented on Aug 26, 2015

    @jgeewax
    jgeewax
    on Aug 26, 2015
    ContributorAuthor
    More actions

    I think you have to define "docs builder". My suggestion is:

    1. Get Sphinx to spit out some JSON
    2. Massage that JSON into some common format (we'll need to work with the gcloud-node team on this)
    3. Factor out the gcloud-node template (maybe move it over to gcloud-common)
    4. Shove that JSON into the template
  5. dhermes commented on Aug 26, 2015

    @dhermes
    dhermes
    on Aug 26, 2015
    Contributor
    More actions

    I was just making a general statement that we shouldn't put too much work in, since the payoff wouldn't be that large (and since we already have docs).

  6. jgeewax commented on Aug 26, 2015

    @jgeewax
    jgeewax
    on Aug 26, 2015
    ContributorAuthor
    More actions

    I think I hear what you're saying -- I'm trying to say "the branded site matters a lot", so unless we're talking about a 6-month, 2-person full-time project... I think we should definitely explore.

  7. callmehiphop commented on Aug 26, 2015

    @callmehiphop
    callmehiphop
    on Aug 26, 2015
    More actions

    I think the effort to move gcloud-nodes site to gcloud-common would be pretty minimal, imo the biggest part would be coming up with a common format for the JSON.

  8. dhermes commented on Aug 26, 2015

    @dhermes
    dhermes
    on Aug 26, 2015
    Contributor
    More actions

    That would be awesome! 👍

    UPDATE: From the latest build, it looks like readthedocs.org builds JSON via

    sphinx-build -T -b json -d _build/doctrees-json -D language=en . _build/json
    
  9. jgeewax commented on Aug 27, 2015

    @jgeewax
    jgeewax
    on Aug 27, 2015
    ContributorAuthor
    More actions

    I gave that a try, looks like it spits out some HTML formatted stuff, not a structured representation of the parse tree.

    Adding a custom builder/writer seems to spit out something more useful: https://gist.github.com/jgeewax/c254f8b4d9f48162eaad

    Now we just need to massage it to either look like the gcloud-node JSON (https://github.com/GoogleCloudPlatform/gcloud-node/blob/gh-pages/json/master/datastore/query.json) or massage them both into a common shared format....

    @stephenplusplus , thoughts?

  10. dhermes commented on Aug 27, 2015

    @dhermes
    dhermes
    on Aug 27, 2015
    Contributor
    More actions

    Not sure if this will make anyone happy but sphinx has JS support:
    http://ericholscher.com/blog/2014/feb/11/sphinx-isnt-just-for-python/
    http://sphinx-doc.org/domains.html#the-javascript-domain

    e.g. http://bootstrap-datepicker.readthedocs.org/en/latest/

  11. stephenplusplus commented on Aug 27, 2015

    @stephenplusplus
    stephenplusplus
    on Aug 27, 2015
    More actions

    I think finding a common format would be nice. As it is now, the JSON we get has a lot of extra junk in it we don't need. We'll just need to decide what those items are, then post-process our JSON build process.

    • Method name
    • Private?
    • Description
    • Example
    • Parameters
      • Name
      • Type
        • Is a custom type?
      • Optional?
      • Can be null?
    • Line of code (this could be optional)

    The node docs site is very closely linked to our library's directory structure, which is also our class hierarchy...

    Module -> Sub-module
    (ex: Storage -> File, Datastore -> Query)

    The site's routing is hooked to this tree, as that's also how the JSON is stored: https://github.com/GoogleCloudPlatform/gcloud-node/tree/gh-pages/json/v0.10.0

    I'm not sure it's possible to have all languages spit out files by the same structure (docs/json/module/submodule.json) -- if it is, that's a relief. If not, we'll have to figure that out.

  12. dhermes
    added
    docs
    on Aug 27, 2015
  13. jgeewax commented on Aug 27, 2015

    @jgeewax
    jgeewax
    on Aug 27, 2015
    ContributorAuthor
    More actions

    One extra thing to note is that in Python for example, we have docs that don't correspond directly to a module (ie, https://googlecloudplatform.github.io/gcloud-python/stable/pubsub-usage.html). Do we have anything comparable on gcloud-node?

  14. jgeewax commented on Aug 27, 2015

    @jgeewax
    jgeewax
    on Aug 27, 2015
    ContributorAuthor
    More actions

    I don't think there's a huge issue with the module -> submodule/class structure. We already cram this in a bit with Python based on the left-nav, ie:

    • Datastore
      • Client
      • Entities
      • Keys
      • Queries
      • Transactions
      • Batches
  15. jgeewax commented on Aug 27, 2015

    @jgeewax
    jgeewax
    on Aug 27, 2015
    ContributorAuthor
    More actions

    /cc @blowmage @quartzmo -- can you guys chime in about Ruby at all ?

  16. 19 remaining items

  17. callmehiphop commented on Sep 9, 2015

    @callmehiphop
    callmehiphop
    on Sep 9, 2015
    More actions

    @quartzmo my pleasure!

    {
      "dns.zone.Zone.createChange": {
        "name": "createChange",
        "description": "<p>Create a change of resource record sets for the zone.</p>",
        "line": 149,
        "type": "method",
        "params": [{
          "name": "options",
          "types": ["object"],
          "description": "<ul>\n<li>The configuration object.</li>\n</ul>\n",
          "optional": false,
          "nullable": false
        }, {
          "name": "options.add",
          "types": ["module:dns/record", "Array.<module:dns/record>"],
          "description": "<ul>\n<li>Record objects     to add to this zone.</li>\n</ul>\n",
          "optional": false,
          "nullable": false
        }, {
          "name": "options.delete",
          "types": ["module:dns/record", "Array.<module:dns/record>"],
          "description": "<ul>\n<li>Record     objects to delete from this zone. Be aware that the resource records here<br />  must match exactly to be deleted.</li>\n</ul>\n",
          "optional": false,
          "nullable": false
        }, {
          "name": "callback",
          "types": ["function"],
          "description": "<ul>\n<li>The callback function.</li>\n</ul>\n",
          "optional": false,
          "nullable": false
        }, {
          "name": "callback.err",
          "types": ["error"],
          "description": "<ul>\n<li>An API error.</li>\n</ul>\n",
          "optional": false,
          "nullable": true
        }, {
          "name": "callback.change",
          "types": ["module:dns/change"],
          "description": "<ul>\n<li>A {module:dns/change} object.</li>\n</ul>\n",
          "optional": false,
          "nullable": true
        }, {
          "name": "callback.apiResponse",
          "types": ["object"],
          "description": "<ul>\n<li>Raw API response. </li>\n</ul>\n",
          "optional": false,
          "nullable": false
        }],
        "example": "var oldARecord = zone.record('a', {\n  name: 'example.com.',\n  data: '1.2.3.4',\n  ttl: 86400\n});\n\nvar newARecord = zone.record('a', {\n  name: 'example.com.',\n  data: '5.6.7.8',\n  ttl: 86400\n});\n\nzone.createChange({\n  add: newARecord,\n  delete: oldARecord\n}, function(err, change, apiResponse) {\n  if (!err) {\n    // The change was created successfully.\n  }\n});"
      }
    }

    It's probably worth noting that the syntax for the custom types isn't really set in stone, it's just how we had it previously.

  18. stephenplusplus commented on Nov 19, 2015

    @stephenplusplus
    stephenplusplus
    on Nov 19, 2015
    More actions

    Anyone following along here, we've shifted the discussion over to gcloud-common: https://github.com/GoogleCloudPlatform/gcloud-common/issues/33 -- we're finalizing the schema, so please weigh in if you have any objections or just subscribe to stay updated.

  19. dhermes commented on Nov 19, 2015

    @dhermes
    dhermes
    on Nov 19, 2015
    Contributor
    More actions

    Thanks for doing this remembering people watching this thread

  20. dhermes commented on Dec 31, 2015

    @dhermes
    dhermes
    on Dec 31, 2015
    Contributor
    More actions

    Closing this since the discussion moved

  21. dhermes
    closed this as completedon Dec 31, 2015
  22. JustinBeckwith
    assigned
    dhermes
    on Feb 1, 2021
  23. parthea
    added a commit that references this issue on Jul 6, 2023

    Auto-update dependencies. [(#1094)](GoogleCloudPlatform/python-docs-s…

    e6d1533
  24. parthea
    added a commit that references this issue on Sep 22, 2023

    chore: move samples from python-docs-sample (#66)

    d3dcbbc
  25. parthea
    added 2 commits that reference this issue on Oct 21, 2023

    Auto-update dependencies. [(#1094)](GoogleCloudPlatform/python-docs-s…

    dbd5993

    move monitoring samples from python-docs-samples (#51)

    d95f563
  26. parthea
    added 5 commits that reference this issue on Nov 22, 2025

    docs: add samples from bigtable (#38)

    ab589eb

    feat: add support for long-running operations with rest transport. (#…

    6bf1231

    chore: release 0.58.0 (#1097)

    ca4054b

    fix: Use except distinct and intersect distinct (#1094)

    32aa5d9

    chore: update system creds (#1094)

    ce14a0a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @dhermes
    dhermes

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.