Skip to content

Commit

Permalink
Копирование ресурсов в доках
Browse files Browse the repository at this point in the history
  • Loading branch information
K1llMan committed May 9, 2023
1 parent 07f096c commit 45940da
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
12 changes: 12 additions & 0 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,20 @@
#
import os
import sys
import shutil
sys.path.insert(0, os.path.abspath('../..'))

def copy_resources(app, docname):
if app.builder.name == 'html':
output_dir = os.path.join(app.outdir, 'src', 'Resources')
source_dir = os.path.join(app.srcdir, '..', 'src', 'Resources')
if not os.path.exists(output_dir):
os.makedirs(os.path.join(app.outdir, 'src'))
shutil.copytree(source_dir, output_dir)

def setup(app):
app.connect('build-finished', copy_resources)

master_doc = 'index'

source_suffix = {
Expand Down
2 changes: 0 additions & 2 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
Документация неофициальной C# библиотеки для API и клиента Yandex Music
==================================================================

readme

.. toctree::
readme
api/api
Expand Down

0 comments on commit 45940da

Please sign in to comment.