You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by katsel <gi...@git.apache.org> on 2016/07/22 17:37:10 UTC

[GitHub] couchdb-documentation pull request #53: COUCHDB-3068 - Fixes to make docs bu...

GitHub user katsel opened a pull request:

    https://github.com/apache/couchdb-documentation/pull/53

    COUCHDB-3068 - Fixes to make docs build with Sphinx 1.4

    * Remove JSON as default highlight language from conf.py, so Sphinx does not assume all non-marked code blocks are JSON per default.
    * Use valid HTTP
      * add ` HTTP/1.1` to each request line
      * Pygments' http lexer currently does not recognize the COPY method, so disable highlighting for blocks that use COPY.
    * Minor changes with shell code-blocks - shell-sessions and shell-scripts require different lexers.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/katsel/couchdb-documentation 3068-sphinx-1-4

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/couchdb-documentation/pull/53.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #53
    
----
commit c94c04e84b72dcbba88ee6299d26884c012f4213
Author: katsel <ka...@users.noreply.github.com>
Date:   2016-07-22T17:20:38Z

    COUCHDB-3068 - Fixes to make docs build with Sphinx 1.4
    
    * remove JSON as default highlight language from config
    * use valid HTTP
    * minor changes with shell code-blocks

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation pull request #53: COUCHDB-3068 - Fixes to make docs bu...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on a diff in the pull request:

    https://github.com/apache/couchdb-documentation/pull/53#discussion_r71916762
  
    --- Diff: src/api/document/common.rst ---
    @@ -1167,7 +1167,7 @@ for the target document by appending the ``rev`` parameter to the
     
     **Request**:
     
    -.. code-block:: http
    +.. code-block:: none
    --- End diff --
    
    Hm...why http lang doesn't likes COPY examples?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    @katsel 
    > Using the local lexer for http seems like a possible workaround, but how would you do that in an elegant way? 
    
    Just use local one all the time? 
    
    > Is it worth the effort just because of 3 examples that use COPY?
    
    It seems we can cover them without problems and doing any coding work, I think we should try (:


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    @katsel Please do if this helps. Otherwise we'll just keep your initial changes.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation pull request #53: COUCHDB-3068 - Fixes to make docs bu...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/couchdb-documentation/pull/53


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    @katsel awesome! thank you!


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by katsel <gi...@git.apache.org>.
Github user katsel commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    Done. :)
    
    > Hm...PDF is broken. Seems like not your fault.
    
    What's broken about PDF?
    
    I tried `make pdf` and it works for me. (TeX Live 2015)
    The PDF looks good at first sight, it has some nice new things (such as automatic line breaks for long lines of code), but I haven't looked at it in detail.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by katsel <gi...@git.apache.org>.
Github user katsel commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    @kxepal 
    OK, so the workaround is to remove [the try clause](https://github.com/apache/couchdb-documentation/blob/master/ext/httpdomain.py#L653-L655) from `httpdomain.py` code so the local lexer becomes the default? :)
    
    Should I include that in the PR?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by katsel <gi...@git.apache.org>.
Github user katsel commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    @kxepal: I rebased my commits and unpinned the sphinx version. Building the PDF works now.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation pull request #53: COUCHDB-3068 - Fixes to make docs bu...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on a diff in the pull request:

    https://github.com/apache/couchdb-documentation/pull/53#discussion_r71916654
  
    --- Diff: src/config/couchdb.rst ---
    @@ -179,10 +179,13 @@ Base CouchDB Options
             * ``nolb``: The /_up endpoint will return a 404 response.
             * ``false``: The node responds normally, /_up returns a 200 response.
     
    +        .. highlight:: none
    +
             It is expected that the administrator has configured a load balancer
             in front of the CouchDB nodes in the cluster. This load balancer should
             use the /_up endpoint to determine whether or not to send HTTP requests
    -        to any particular node. For HAProxy, the following config is appropriate ::
    +        to any particular node. For HAProxy, the following config is
    +        appropriate::
    --- End diff --
    
    I think you better replace `::` with `.. code-block:: none` definition. That's more error-prone solution. Same for the rest similar cases.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by katsel <gi...@git.apache.org>.
Github user katsel commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    @kxepal Hi! Thanks for your feedback.
    
    1) Yup, using `code-block`  instead of :: makes sense in these cases. I will change that and do a new commit.
    
    2) COPY is not part of standard HTTP, so maybe that's why (here's the [relevant pygments source](https://bitbucket.org/birkenfeld/pygments-main/src/e79a7126551c39d5f8c1b83a79c14e86992155a4/pygments/lexers/textfmts.py?at=default#textfmts.py-175)). One could file an issue at pygments for that, but that's not a quick solution.
    Using the local lexer for http seems like a possible workaround, but how would you do that in an elegant way? Is it worth the effort just because of 3 examples that use COPY?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    @katsel 
    
    > Done. :)
    
    Awesome! Thank you, +1
    
    > What's broken about PDF?
    > I tried make pdf and it works for me. (TeX Live 2015)
    
    Same story for me. It seems like some issue about packages on Travis. I worked before, but not today. Let's handle this in separate iteration.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation pull request #53: COUCHDB-3068 - Fixes to make docs bu...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on a diff in the pull request:

    https://github.com/apache/couchdb-documentation/pull/53#discussion_r71917082
  
    --- Diff: src/api/document/common.rst ---
    @@ -1167,7 +1167,7 @@ for the target document by appending the ``rev`` parameter to the
     
     **Request**:
     
    -.. code-block:: http
    +.. code-block:: none
    --- End diff --
    
    We do have it supported in [local lexer](https://github.com/apache/couchdb-documentation/blob/master/ext/httpdomain.py#L629). May be worth to switch onto in instead of doing [fallback](https://github.com/apache/couchdb-documentation/blob/master/ext/httpdomain.py#L653-L656)?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-documentation issue #53: COUCHDB-3068 - Fixes to make docs build wit...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the issue:

    https://github.com/apache/couchdb-documentation/pull/53
  
    Hm...PDF is broken. Seems like not your fault.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---