| --- |
| title: Contribute | Website |
| layout: default |
| --- |
| |
| <!-- Marketing messaging and featurettes |
| ================================================== --> |
| <!-- Wrap the rest of the page in another container to center all the content. --> |
| |
| <div class="container"> |
| <!-- CONTRIBUTE --> |
| <div class="row mb-5 mt-5 pt-3"> |
| <div class="col-2 sidenav-menu pt-3"> |
| <div class="pb-3 text-uppercase"><strong>Contribute</strong></div> |
| <ul class="list-unstyled mb-3"> |
| <li><a href="contribute.html">Get started contributing</a></li> |
| <li class="sidenav-menu-sub-title">Technical Docs</li> |
| <li> |
| <ul class="list-unstyled sidenav-menu-sub-list"> |
| <li><a href="contribute-testing.html">Testing guide</a></li> |
| <li><a href="contribute-dependencies-guide.html">Dependencies guide</a></li> |
| </ul> |
| </li> |
| <li class="sidenav-menu-sub-title">Policies</li> |
| <li> |
| <ul class="list-unstyled sidenav-menu-sub-list"> |
| <li><a href="contribute-pre-commit-test-policies.html">Pre-commit test policies</a></li> |
| <li><a href="contribute-post-commit-test-policies.html">Post-commit test policies</a></li> |
| </ul> |
| </li> |
| <li class="sidenav-menu-sub-title">Committers</li> |
| <li> |
| <ul class="list-unstyled sidenav-menu-sub-list"> |
| <li><a href="contribute-become-a-committer.html">Become a committer</a></li> |
| <li><a href="contribute-committer-guide.html">Committer guide</a></li> |
| <li><a href="contribute-release-guide.html">Release guide</a></li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="col-8 pt-3 offset-4"> |
| <h2 class="pb-1">Website Contributions</h2> |
| |
| <p>Contributions to the website require the same steps as contributions to the main repository, so start with the instructions for <a href="contribute.html">Contributing Code</a>.</p> |
| |
| <p>The Unomi website is in the <a target="_blank" href="https://github.com/apache/unomi-site">Unomi Site GitHub mirror</a> repository in the <code>asf-site</code> branch (<em>not</em> <code>master</code>).</p> |
| |
| <p>Issues are tracked in the <a target="_blank" href="https://issues.apache.org/jira/issues/?jql=project%20%3D%20UNOMI%20AND%20component%20%3D%20website">website</a> component in JIRA.</p> |
| |
| <h3 id="one-time-setup">One-time Setup</h3> |
| |
| <p>The <a target="_blank" href="https://github.com/apache/unomi-site/blob/asf-site/README.md">README file</a> in the website repository has more information on how to set up the required dependencies for your development environment.</p> |
| |
| <p>The general guidelines for cloning a repository can be adjusted to use the <code>asf-site</code> branch of <code>unomi-site</code>:</p> |
| |
| <p class="alert alert-primary"><code>$ git clone -b asf-site https://github.com/apache/unomi-site.git |
| $ cd unomi-site |
| $ git remote add <GitHub_user> git@github.com:<GitHub_user>/unomi-site.git |
| $ git fetch --all |
| $ git checkout -b <my-branch> origin/asf-site |
| </code></p> |
| |
| <h3 id="working-on-your-change">Working on your change</h3> |
| |
| <p>While you are working on your pull request, you can test and develop live by running the following command in the root folder of the website:</p> |
| |
| <p class="alert alert-primary"><code>$ bundle exec jekyll serve --incremental</code></p> |
| |
| <p>Jekyll will start a webserver on port 4000. As you make changes to the content, Jekyll will rebuild it automatically.</p> |
| |
| <p>In addition, you can run the tests to valid your links using:</p> |
| |
| <p class="alert alert-primary"><code>$ bundle exec rake test</code></p> |
| |
| <p>Both of these commands will cause the <code>content/</code> directory to be generated. Merging autogenerated content can get tricky, so please leave this directory out of your commits and pull request by doing:</p> |
| |
| <p class="alert alert-primary"><code>$ git checkout -- content</code></p> |
| |
| <p>When you are ready, submit a pull request using the <a target="_blank" href="https://github.com/apache/unomi-site">Unomi Site GitHub mirror</a>, including the JIRA issue as usual.</p> |
| |
| <p>During review, committers will patch in your PR, generate the static <code>content/</code>, and review the changes.</p> |
| |
| <h3 id="committing-website-changes-committers-only">Committing website changes (committers only)</h3> |
| |
| <p>We have a bot that runs tests and merges changes to the website. When the pull request is fully ready to be merged, a committer can comment</p> |
| |
| <p class="alert alert-primary"><code>@asfgit merge</code></p> |
| </div> |
| </div> |
| </div> |