Skip to content

Commit

Permalink
deploy: 8536838
Browse files Browse the repository at this point in the history
  • Loading branch information
linkfrg committed Jan 2, 2025
1 parent 4f37f43 commit 1de1a8c
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 136 deletions.
70 changes: 9 additions & 61 deletions latest/_sources/dev/env.rst.txt
Original file line number Diff line number Diff line change
@@ -1,74 +1,22 @@
Setting up a Development Environment
=====================================

Clone repository
-------------------
Firstly, clone the repository:

.. code-block:: bash
# replace with the actual URL of your fork (if needed)
git clone https://github.com/linkfrg/ignis.git
cd ignis
Update submodules
------------------
Then, run the script:

.. code-block:: bash
bash tools/setup_devenv.sh
git submodule update --init --recursive
Create Python Virtual Environment
----------------------------------

.. code-block:: bash
python -m venv venv
Activate Virtual Environment
----------------------------

- For Bash:

.. code-block:: bash
source venv/bin/activate
- For Fish:

.. code-block:: fish
. venv/bin/activate.fish
Install dependencies to Virtual Environment
-------------------------------------------

Common dependencies:

.. code-block:: bash
pip install --upgrade -r requirements.txt
Development dependencies:

.. code-block:: bash
pip install --upgrade -r dev.txt
Build and Install Ignis to Virtual Environment
----------------------------------------------

.. code-block:: bash
meson setup build --prefix=$(pwd)/venv --libdir "lib/ignis"
meson compile -C build
meson install -C build
Make a symbolic link to Ignis sources
-------------------------------------

Replace ``python3.12`` with actual version of python.
It will create a Python virtual environment,
install Ignis with its dependencies (including dev dependencies), and create a symbolic link to the Ignis source files.

.. code-block:: bash
rm -R venv/lib/python3.12/site-packages/ignis
ln -sf $(pwd)/ignis venv/lib/python3.12/site-packages/ignis
Now you can edit the ``ignis`` directory at the root of the repository,
and the changes will be applied without the need to reinstall Ignis.
83 changes: 9 additions & 74 deletions latest/dev/env.html
Original file line number Diff line number Diff line change
Expand Up @@ -435,67 +435,20 @@

<section id="setting-up-a-development-environment">
<h1>Setting up a Development Environment<a class="headerlink" href="#setting-up-a-development-environment" title="Link to this heading">#</a></h1>
<section id="clone-repository">
<h2>Clone repository<a class="headerlink" href="#clone-repository" title="Link to this heading">#</a></h2>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>git<span class="w"> </span>clone<span class="w"> </span>https://github.com/linkfrg/ignis.git
<p>Firstly, clone the repository:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="c1"># replace with the actual URL of your fork (if needed)</span>
git<span class="w"> </span>clone<span class="w"> </span>https://github.com/linkfrg/ignis.git
<span class="nb">cd</span><span class="w"> </span>ignis
</pre></div>
</div>
</section>
<section id="update-submodules">
<h2>Update submodules<a class="headerlink" href="#update-submodules" title="Link to this heading">#</a></h2>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>git<span class="w"> </span>submodule<span class="w"> </span>update<span class="w"> </span>--init<span class="w"> </span>--recursive
</pre></div>
</div>
</section>
<section id="create-python-virtual-environment">
<h2>Create Python Virtual Environment<a class="headerlink" href="#create-python-virtual-environment" title="Link to this heading">#</a></h2>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>python<span class="w"> </span>-m<span class="w"> </span>venv<span class="w"> </span>venv
</pre></div>
</div>
</section>
<section id="activate-virtual-environment">
<h2>Activate Virtual Environment<a class="headerlink" href="#activate-virtual-environment" title="Link to this heading">#</a></h2>
<ul class="simple">
<li><p>For Bash:</p></li>
</ul>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="nb">source</span><span class="w"> </span>venv/bin/activate
</pre></div>
</div>
<ul class="simple">
<li><p>For Fish:</p></li>
</ul>
<div class="highlight-fish notranslate"><div class="highlight"><pre><span></span>. venv/bin/activate.fish
<p>Then, run the script:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>bash<span class="w"> </span>tools/setup_devenv.sh
</pre></div>
</div>
</section>
<section id="install-dependencies-to-virtual-environment">
<h2>Install dependencies to Virtual Environment<a class="headerlink" href="#install-dependencies-to-virtual-environment" title="Link to this heading">#</a></h2>
<p>Common dependencies:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>--upgrade<span class="w"> </span>-r<span class="w"> </span>requirements.txt
</pre></div>
</div>
<p>Development dependencies:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>--upgrade<span class="w"> </span>-r<span class="w"> </span>dev.txt
</pre></div>
</div>
</section>
<section id="build-and-install-ignis-to-virtual-environment">
<h2>Build and Install Ignis to Virtual Environment<a class="headerlink" href="#build-and-install-ignis-to-virtual-environment" title="Link to this heading">#</a></h2>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>meson<span class="w"> </span>setup<span class="w"> </span>build<span class="w"> </span>--prefix<span class="o">=</span><span class="k">$(</span><span class="nb">pwd</span><span class="k">)</span>/venv<span class="w"> </span>--libdir<span class="w"> </span><span class="s2">&quot;lib/ignis&quot;</span>
meson<span class="w"> </span>compile<span class="w"> </span>-C<span class="w"> </span>build
meson<span class="w"> </span>install<span class="w"> </span>-C<span class="w"> </span>build
</pre></div>
</div>
</section>
<section id="make-a-symbolic-link-to-ignis-sources">
<h2>Make a symbolic link to Ignis sources<a class="headerlink" href="#make-a-symbolic-link-to-ignis-sources" title="Link to this heading">#</a></h2>
<p>Replace <code class="docutils literal notranslate"><span class="pre">python3.12</span></code> with actual version of python.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>rm<span class="w"> </span>-R<span class="w"> </span>venv/lib/python3.12/site-packages/ignis
ln<span class="w"> </span>-sf<span class="w"> </span><span class="k">$(</span><span class="nb">pwd</span><span class="k">)</span>/ignis<span class="w"> </span>venv/lib/python3.12/site-packages/ignis
</pre></div>
</div>
</section>
<p>It will create a Python virtual environment,
install Ignis with its dependencies (including dev dependencies), and create a symbolic link to the Ignis source files.</p>
<p>Now you can edit the <code class="docutils literal notranslate"><span class="pre">ignis</span></code> directory at the root of the repository,
and the changes will be applied without the need to reinstall Ignis.</p>
</section>


Expand Down Expand Up @@ -538,24 +491,6 @@ <h2>Make a symbolic link to Ignis sources<a class="headerlink" href="#make-a-sym


<div class="sidebar-secondary-item">
<div
id="pst-page-navigation-heading-2"
class="page-toc tocsection onthispage">
<i class="fa-solid fa-list"></i> On this page
</div>
<nav class="bd-toc-nav page-toc" aria-labelledby="pst-page-navigation-heading-2">
<ul class="visible nav section-nav flex-column">
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#clone-repository">Clone repository</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#update-submodules">Update submodules</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#create-python-virtual-environment">Create Python Virtual Environment</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#activate-virtual-environment">Activate Virtual Environment</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#install-dependencies-to-virtual-environment">Install dependencies to Virtual Environment</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#build-and-install-ignis-to-virtual-environment">Build and Install Ignis to Virtual Environment</a></li>
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#make-a-symbolic-link-to-ignis-sources">Make a symbolic link to Ignis sources</a></li>
</ul>
</nav></div>

<div class="sidebar-secondary-item">


<div class="tocsection editthispage">
Expand Down
2 changes: 1 addition & 1 deletion latest/searchindex.js

Large diffs are not rendered by default.

0 comments on commit 1de1a8c

Please sign in to comment.