#1176 Add static page hosting
Cancelled 7 months ago by pingou. Opened 2 years ago by farhaan.
farhaan/pagure pagure_pages  into  master

@@ -67,6 +67,14 @@ 

              </div>

            {% endif %}

          </h2>

+         {% if config['DOC_APP_URL'] and repo and repo.settings.get('project_documentation', True) %}

+         <div class="m-t-0">

+             Documentation at

+             <a href="{{ config['DOC_APP_URL'] }}{{ repo.fullname }}">

+                     {{ config['DOC_APP_URL'] }}{{ repo.fullname }}

+             </a>

+         </div>

+         {% endif %}

          {% if repo.is_fork %}

          <div class="m-t-0">

              Forked from

@@ -94,17 +102,6 @@ 

              <span class="hidden-sm-down">Overview</span>

          </a>

        </li>

-         {% if config['DOC_APP_URL'] and repo and repo.settings.get('project_documentation', True) %}

-         <li class="nav-item" >

-           <a  {%

-             if select == 'docs' %}class="active nav-link" {%

-             else %}class="nav-link" {%

-             endif %}href="{{ url_for('.view_docs', username=username, repo=repo.name) }}">

-               <span class="oi hidden-md-up" data-glyph="book"></span>

-               <span class="hidden-sm-down">Docs</span>

-           </a>

-         </li>

-         {% endif %}

  

          <li class="nav-item{%

              if repo_obj and repo_obj.is_empty %} disabled{% endif %}">

As @ryanlerch suggested introducing the documentation link
in the header and removed the Doc tab from the project.

there is no need to remove the "docs" feature in order to implement a static hosting feature - these features are completely orthogonal - more about that here --> https://pagure.io/pagure/issue/469#comment-6064

furthermore this PR does not remove the docs feature but merely makes it inaccessible for any repo that may be using it

lastly the anchor URL does not appear to be what was suggested: (<project_name>.pagure.io)

{{ config['DOC_APP_URL'] }}{{ repo.fullname }}

it most likely should be using internals such as what was replaced

{{ url_for('.view_docs', username=username, repo=repo.name) }}

I am going to close this PR. It is 2 years old hasn't been updated in a while and we can always open a new PR when there is progress.

Sorry that we couldn't merge it in a timely fashion, please keep contributing to pagure :)

Pull-Request has been closed by pingou

7 months ago
Metadata