integrations/codebase.html: Migrate to Markdown.

This commit is contained in:
Aditya Bansal 2017-06-14 04:42:01 +05:30 committed by Tim Abbott
parent 4d66d74938
commit 914ab1040d
4 changed files with 42 additions and 55 deletions

View File

@ -1,53 +0,0 @@
<p>
First, create the streams you'd like to use for Codebase notifications. There will be two types of
messages: commit-related updates and issue-related updates. After creating these streams (we suggest naming
them <code>codebase commits</code> and <code>codebase issues</code>), make sure to subscribe all interested
parties.
</p>
<p>
Next, download and install our
<a href="/api">Python bindings and example scripts</a> on the computer you'd like to run this mirroring script from.
</p>
<p>
You will need your Codebase API Username. You can find it in the settings page of your account, under
<code>API Credentials</code>.
</p>
<p>
Edit the Codebase and Zulip credentials in <code>integrations/codebase/zulip_codebase_config.py</code> using
your favorite editor:
</p>
<div class="codehilite">
<pre><span class="n">CODEBASE_API_USERNAME</span> <span class="o">=</span> <span class="s">"zulip-inc/leo-franchi-15"</span>
<span class="n">CODEBASE_API_KEY</span> <span class="o">=</span> <span class="s">0123456789abcdef0123456789abcdef</span>
<span class="n">ZULIP_USER</span> <span class="o">=</span> <span class="s">"codebase-bot@example.com"</span>
<span class="n">ZULIP_API_KEY</span> <span class="o">=</span> <span class="s">"0123456789abcdef0123456789abcdef"</span>
{% if api_site_required %}<span class="n">ZULIP_SITE</span> <span class="o">=</span><span class="s">"{{ external_api_uri_subdomain }}"</span>{% endif %}</pre>
</div>
<p>
Before your first run of the script, you may optionally choose to
configure it to mirror some number of hours of prior Codebase activity:
</p>
<div class="codehilite">
<pre><span class="n">CODEBASE_INITIAL_HISTORY_HOURS</span> <span class="o">=</span> <span
class="s">10</span></pre>
</div>
<p>
Now, simply run the <code>api/integrations/codebase/zulip_codebase_mirror</code> script.
If needed, this script may be restarted, and it will automatically resume from when
it was last running.
</p>
<p>
<b>Congratulations! You're done!</b><br/> Whenever you create a new project,
commit, issue, deployment, or more, you'll get notifications in your selected streams
with the associated information.
</p>
<img class="screenshot" src="/static/images/integrations/codebase/001.png"/>

View File

@ -0,0 +1,41 @@
First, create the streams youd like to use for Codebase notifications. There
will be two types of messages: commit-related updates and issue-related updates.
After creating these streams (we suggest naming them `codebase commits` and
`codebase issues`), make sure to subscribe all interested parties.
{!download-python-bindings.md!}
You will need your Codebase API Username. You can find it in the settings page
of your account, under `API Credentials`.
Edit the Codebase and Zulip credentials in `integrations/codebase/zulip_codebase_config.py`
using your favorite editor:
```
CODEBASE_API_USERNAME = "zulip-inc/leo-franchi-15"
CODEBASE_API_KEY = 0123456789abcdef0123456789abcdef
ZULIP_USER = "codebase-bot@example.com"
ZULIP_API_KEY = "0123456789abcdef0123456789abcdef"
{% if api_site_required %}ZULIP_SITE = "{{ external_api_uri_subdomain }}"{% endif %}
```
Before your first run of the script, you may optionally choose to configure it
to mirror some number of hours of prior Codebase activity:
```
CODEBASE_INITIAL_HISTORY_HOURS = 10
```
Now, simply run the `api/integrations/codebase/zulip_codebase_mirror` script.
If needed, this script may be restarted, and it will automatically resume from
when it was last running.
Whenever you create a new project, commit, issue, deployment, or more, youll
get notifications in your selected streams with the associated information.
{! congrats.md !}
![](/static/images/integrations/codebase/001.png)

View File

@ -105,7 +105,6 @@ def check_html_templates(templates, all_dups):
'templates/zerver/hello.html',
'templates/zerver/home.html',
'templates/zerver/integrations/index.html',
'templates/zerver/integrations/codebase.html',
'templates/zerver/login.html',
'templates/zerver/markdown_help.html',
'templates/zerver/register.html',

View File

@ -256,7 +256,7 @@ WEBHOOK_INTEGRATIONS = [
INTEGRATIONS = {
'asana': Integration('asana', 'asana', doc='zerver/integrations/asana.html'),
'capistrano': Integration('capistrano', 'capistrano', display_name='Capistrano', doc='zerver/integrations/capistrano.md'),
'codebase': Integration('codebase', 'codebase', doc='zerver/integrations/codebase.html'),
'codebase': Integration('codebase', 'codebase', doc='zerver/integrations/codebase.md'),
'email': EmailIntegration('email', 'email', doc='zerver/integrations/email.html'),
'git': Integration('git', 'git', doc='zerver/integrations/git.md'),
'google-calendar': Integration(