Skip to content

Commit f73dd38

Browse files
committed
Docs: commit a05e20d made on 2024-08-16T17:38:30+00:00 from refs/heads/main by bigcat88
0 parents  commit f73dd38

File tree

168 files changed

+40394
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+40394
-0
lines changed

.buildinfo

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Sphinx build info version 1
2+
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
3+
config: 87a6a57d29f9ef87e97c7efff7cdfdfb
4+
tags: 645f666f9bcd5a90fca523b33c5a78b7

.nojekyll

Whitespace-only changes.

DevSetup.html

Lines changed: 200 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,200 @@
1+
<!DOCTYPE html>
2+
<html class="writer-html5" lang="en" data-content_root="./">
3+
<head>
4+
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
5+
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
7+
<title>Setting up dev environment &mdash; NcPyApi 0.16.0 documentation</title>
8+
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
9+
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=19f00094" />
10+
<link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
11+
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
12+
<link rel="stylesheet" type="text/css" href="_static/autodoc_pydantic.css" />
13+
<link rel="stylesheet" type="text/css" href="_static/css/styles.css?v=0f758665" />
14+
<link rel="stylesheet" type="text/css" href="_static/css/dark.css?v=41caee7b" />
15+
<link rel="stylesheet" type="text/css" href="_static/css/light.css?v=c3d70dd7" />
16+
17+
18+
<!--[if lt IE 9]>
19+
<script src="_static/js/html5shiv.min.js"></script>
20+
<![endif]-->
21+
22+
<script src="_static/jquery.js?v=5d32c60e"></script>
23+
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
24+
<script src="_static/documentation_options.js?v=7de89ed4"></script>
25+
<script src="_static/doctools.js?v=9a2dae69"></script>
26+
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
27+
<script src="_static/clipboard.min.js?v=a7894cd8"></script>
28+
<script src="_static/copybutton.js?v=f281be69"></script>
29+
<script src="_static/tabs.js?v=3ee01567"></script>
30+
<script src="_static/js/script.js?v=783f4f19"></script>
31+
<script src="_static/js/theme.js"></script>
32+
<link rel="index" title="Index" href="genindex.html" />
33+
<link rel="search" title="Search" href="search.html" />
34+
<link rel="next" title="AppAPI Benchmarks" href="benchmarks/AppAPI.html" />
35+
<link rel="prev" title="Webhooks API" href="reference/Webhooks.html" />
36+
</head>
37+
38+
<body class="wy-body-for-nav">
39+
<div class="wy-grid-for-nav">
40+
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
41+
<div class="wy-side-scroll">
42+
<div class="wy-side-nav-search" >
43+
44+
45+
46+
<a href="index.html">
47+
48+
<img src="_static/logo.svg" class="logo" alt="Logo"/>
49+
</a>
50+
<div class="version">
51+
0.16.0
52+
</div>
53+
<div role="search">
54+
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
55+
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
56+
<input type="hidden" name="check_keywords" value="yes" />
57+
<input type="hidden" name="area" value="default" />
58+
</form>
59+
</div>
60+
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
61+
<ul class="current">
62+
<li class="toctree-l1"><a class="reference internal" href="Installation.html">Installation</a></li>
63+
<li class="toctree-l1"><a class="reference internal" href="FirstSteps.html">First steps</a></li>
64+
<li class="toctree-l1"><a class="reference internal" href="MoreAPIs.html">More APIs</a></li>
65+
<li class="toctree-l1"><a class="reference internal" href="NextcloudApp.html">Writing a Nextcloud Application</a></li>
66+
<li class="toctree-l1"><a class="reference internal" href="NextcloudApp3rdParty.html">Packaging 3rd party software as a Nextcloud Application</a></li>
67+
<li class="toctree-l1"><a class="reference internal" href="NextcloudTalkBot.html">Nextcloud Talk Bot API in Applications</a></li>
68+
<li class="toctree-l1"><a class="reference internal" href="NextcloudTalkBotTransformers.html">Talk Bot App with Transformers</a></li>
69+
<li class="toctree-l1"><a class="reference internal" href="NextcloudUiApp.html">Writing Nextcloud App with UI</a></li>
70+
<li class="toctree-l1"><a class="reference internal" href="Options.html">Options</a></li>
71+
<li class="toctree-l1"><a class="reference internal" href="reference/index.html">Reference</a></li>
72+
<li class="toctree-l1 current"><a class="current reference internal" href="#">Setting up dev environment</a></li>
73+
<li class="toctree-l1"><a class="reference internal" href="benchmarks/AppAPI.html">AppAPI Benchmarks</a></li>
74+
</ul>
75+
76+
</div>
77+
</div>
78+
</nav>
79+
80+
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
81+
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
82+
<a href="index.html">NcPyApi</a>
83+
</nav>
84+
85+
<div class="wy-nav-content">
86+
<div class="rst-content">
87+
<div role="navigation" aria-label="Page navigation">
88+
<ul class="wy-breadcrumbs">
89+
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
90+
<li class="breadcrumb-item active">Setting up dev environment</li>
91+
<li class="wy-breadcrumbs-aside">
92+
<a href="_sources/DevSetup.rst.txt" rel="nofollow"> View page source</a>
93+
</li>
94+
</ul>
95+
<hr/>
96+
</div>
97+
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
98+
<div itemprop="articleBody">
99+
100+
<section id="setting-up-dev-environment">
101+
<h1>Setting up dev environment<a class="headerlink" href="#setting-up-dev-environment" title="Link to this heading"></a></h1>
102+
<p>We highly recommend to use <a class="reference external" href="https://github.com/juliushaertl/nextcloud-docker-dev">Julius Haertl docker setup</a> for Nextcloud dev setup.</p>
103+
<p>Development of <cite>nc-py-api</cite> can be done on any OS as it is a <strong>pure</strong> Python package.</p>
104+
<p>Suggested IDE: <strong>PyCharm</strong>, but of course you can use any IDE you like for this like <strong>VS Code</strong> or <strong>Vim</strong>.</p>
105+
<p>Steps to setup up the development environment:</p>
106+
<ol class="arabic">
107+
<li><p>Setup Nextcloud locally or remotely.</p></li>
108+
<li><p>Install <a class="reference external" href="https://github.com/cloud-py-api/app_api">AppAPI</a>, follow it’s steps to register <code class="docutils literal notranslate"><span class="pre">deploy</span> <span class="pre">daemon</span></code> if needed.</p></li>
109+
<li><p>Clone the <a class="reference external" href="https://github.com/cloud-py-api/nc_py_api">nc_py_api</a> with <strong class="command">shell</strong>:</p>
110+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">clone</span> <span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">github</span><span class="o">.</span><span class="n">com</span><span class="o">/</span><span class="n">cloud</span><span class="o">-</span><span class="n">py</span><span class="o">-</span><span class="n">api</span><span class="o">/</span><span class="n">nc_py_api</span><span class="o">.</span><span class="n">git</span>
111+
</pre></div>
112+
</div>
113+
</li>
114+
<li><p>Set current working dir to the root folder of cloned <strong>nc_py_api</strong> with <strong class="command">shell</strong>:</p>
115+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">cd</span> <span class="n">nc_py_api</span>
116+
</pre></div>
117+
</div>
118+
</li>
119+
<li><p>Create and activate Virtual Environment with <strong class="command">shell</strong>:</p>
120+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">python3</span> <span class="o">-</span><span class="n">m</span> <span class="n">venv</span> <span class="n">env</span>
121+
</pre></div>
122+
</div>
123+
</li>
124+
<li><p>Activate Python Virtual Environment with <strong class="command">shell</strong>:</p>
125+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">source</span> <span class="o">./</span><span class="n">env</span><span class="o">/</span><span class="nb">bin</span><span class="o">/</span><span class="n">activate</span>
126+
</pre></div>
127+
</div>
128+
</li>
129+
<li><p>Update <code class="docutils literal notranslate"><span class="pre">pip</span></code> to the last version with <strong class="command">pip</strong>:</p>
130+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">python3</span> <span class="o">-</span><span class="n">m</span> <span class="n">pip</span> <span class="n">install</span> <span class="o">--</span><span class="n">upgrade</span> <span class="n">pip</span>
131+
</pre></div>
132+
</div>
133+
</li>
134+
<li><p>Install dev-dependencies with <strong class="command">pip</strong>:</p>
135+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">pip</span> <span class="n">install</span> <span class="s2">&quot;.[dev]&quot;</span>
136+
</pre></div>
137+
</div>
138+
</li>
139+
<li><p>Install <cite>pre-commit</cite> hooks with <strong class="command">shell</strong>:</p>
140+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">pre</span><span class="o">-</span><span class="n">commit</span> <span class="n">install</span>
141+
</pre></div>
142+
</div>
143+
</li>
144+
<li><p>If <code class="docutils literal notranslate"><span class="pre">deploy</span> <span class="pre">daemon</span></code> is registered for AppAPI, register <strong>nc_py_api</strong> as an application with <strong class="command">shell</strong>:</p>
145+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">make</span> <span class="n">register28</span>
146+
</pre></div>
147+
</div>
148+
</li>
149+
<li><p>In <code class="docutils literal notranslate"><span class="pre">tests/gfixture.py</span></code> edit <code class="docutils literal notranslate"><span class="pre">NC_AUTH_USER</span></code> and <code class="docutils literal notranslate"><span class="pre">NC_AUTH_PASS</span></code>, if they are different in your setup.</p></li>
150+
<li><p>Run tests to check that everything works with <strong class="command">shell</strong>:</p>
151+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">python3</span> <span class="o">-</span><span class="n">m</span> <span class="n">pytest</span>
152+
</pre></div>
153+
</div>
154+
</li>
155+
<li><p>Install documentation dependencies if needed with <strong class="command">pip</strong>:</p>
156+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">pip</span> <span class="n">install</span> <span class="s2">&quot;.[docs]&quot;</span>
157+
</pre></div>
158+
</div>
159+
</li>
160+
<li><p>You can easy build documentation with <strong class="command">shell</strong>:</p>
161+
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">make</span> <span class="n">docs</span>
162+
</pre></div>
163+
</div>
164+
</li>
165+
<li><p><strong>Your setup is ready for the developing nc_py_api and Applications based on it. Best of Luck!</strong></p></li>
166+
</ol>
167+
</section>
168+
169+
170+
</div>
171+
</div>
172+
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
173+
<a href="reference/Webhooks.html" class="btn btn-neutral float-left" title="Webhooks API" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
174+
<a href="benchmarks/AppAPI.html" class="btn btn-neutral float-right" title="AppAPI Benchmarks" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
175+
</div>
176+
177+
<hr/>
178+
179+
<div role="contentinfo">
180+
<p>&#169; Copyright 2024 NcPyApi Authors.</p>
181+
</div>
182+
183+
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
184+
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
185+
provided by <a href="https://readthedocs.org">Read the Docs</a>.
186+
187+
188+
</footer>
189+
</div>
190+
</div>
191+
</section>
192+
</div>
193+
<script>
194+
jQuery(function () {
195+
SphinxRtdTheme.Navigation.enable(true);
196+
});
197+
</script>
198+
199+
</body>
200+
</html>

0 commit comments

Comments
 (0)