Skip to content

Add badges, links and labels #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Jun 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ updates:
schedule:
interval: "daily"
labels:
- "maintenance"
- "dependencies"
- "Maintenance"
- "Dependencies"
10 changes: 10 additions & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Documentation:
- doc/source/**/*
Maintenance:
- .github/**/*
- .flake8
- ignore_words.txt
Dependencies:
- requirements/*
CI/CD:
- .github/**/*
2 changes: 1 addition & 1 deletion .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ jobs:
run: |
sudo apt update
sudo apt-get install -y texlive-latex-extra latexmk
make -C doc latexpdf
make -C doc pdf

- name: Upload HTML Documentation
uses: actions/upload-artifact@v2
Expand Down
29 changes: 22 additions & 7 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,22 @@
PyOptics Library
########################
================
|pyansys| |GH-CI| |MIT| |black|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Revathyvenugopal162 Looks good at the moment. We will add the codacy and codecov badges when pyoptics repo is made public.


.. |pyansys| image:: https://img.shields.io/badge/Py-Ansys-ffc107.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABDklEQVQ4jWNgoDfg5mD8vE7q/3bpVyskbW0sMRUwofHD7Dh5OBkZGBgW7/3W2tZpa2tLQEOyOzeEsfumlK2tbVpaGj4N6jIs1lpsDAwMJ278sveMY2BgCA0NFRISwqkhyQ1q/Nyd3zg4OBgYGNjZ2ePi4rB5loGBhZnhxTLJ/9ulv26Q4uVk1NXV/f///////69du4Zdg78lx//t0v+3S88rFISInD59GqIH2esIJ8G9O2/XVwhjzpw5EAam1xkkBJn/bJX+v1365hxxuCAfH9+3b9/+////48cPuNehNsS7cDEzMTAwMMzb+Q2u4dOnT2vWrMHu9ZtzxP9vl/69RVpCkBlZ3N7enoDXBwEAAA+YYitOilMVAAAAAElFTkSuQmCC
:target: https://docs.pyansys.com/
:alt: PyAnsys

.. |GH-CI| image:: https://github.com/pyansys/pyoptics/actions/workflows/ci_cd.yml/badge.svg
:target: https://github.com/pyansys/pyoptics/actions/workflows/ci_cd.yml

.. |MIT| image:: https://img.shields.io/badge/License-MIT-yellow.svg
:target: https://opensource.org/licenses/MIT
:alt: MIT

.. |black| image:: https://img.shields.io/badge/code%20style-black-000000.svg?style=flat
:target: https://github.com/psf/black
:alt: Black

.. image:: https://github.com/pyansys/pyoptics/actions/workflows/ci_cd.yml/badge.svg

Project Overview
----------------
Expand All @@ -13,10 +28,10 @@ Installation can be done using the published `package`_ or the repository `sourc

Package
~~~~~~~
.. warning:: Not currently available, work in progress... Please use `Sources`_
.. warning:: Not currently available, work in progress... Please use `Sources`_.

This repository is deployed as the Python packages `ansys-pyoptics <...>`_.
As usual, installation is done by running
As usual, installation is done by running:

.. code::

Expand Down Expand Up @@ -52,7 +67,7 @@ All sources are located in `<./ansys>`_ folder.
Documentation
-------------
Documentation is stored in `<./doc>`_ folder and generated using `Sphinx <https://www.sphinx-doc.org/en/master/>`_.
To build it manually, just run
To build it manually, just run:

.. code::

Expand All @@ -74,8 +89,8 @@ Test configuration file
~~~~~~~~~~~~~~~~~~~~~~~
The configuration file `<tests/local_config.json>`_ located in tests folder contains several parameters that can be changed according to your needs, for example:

- **SpeosServerOnDocker** (boolean): Speos server launched in a docker container
- **SpeosServerPort** (integer): Port used by Speos server for HTTP transfert
- **SpeosServerOnDocker** (boolean): Speos server launched in a docker container.
- **SpeosServerPort** (integer): Port used by Speos server for HTTP transfer.

Start server
~~~~~~~~~~~~
Expand Down
6 changes: 6 additions & 0 deletions doc/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,9 @@ help:
# customized clean due to examples gallery
clean:
rm -rf build

#customized pdf build due to svg badges
pdf:
@$(SPHINXBUILD) -M latex "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
cd build/latex && latexmk -r latexmkrc -pdf *.tex -interaction=nonstopmode || true
(test -f build/latex/*.pdf && echo pdf exists) || exit 1
7 changes: 7 additions & 0 deletions doc/make.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ set SOURCEDIR=source
set BUILDDIR=build

if "%1" == "" goto help
if "%1" == "pdf" goto pdf

%SPHINXBUILD% >NUL 2>NUL
if errorlevel 9009 (
Expand All @@ -31,5 +32,11 @@ goto end
:help
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%

:pdf
%SPHINXBUILD% -M latex %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
cd "%BUILDDIR%\latex"
for %%f in (*.tex) do (
pdflatex "%%f" --interaction=nonstopmode)

:end
popd
4 changes: 4 additions & 0 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@

from ansys.pyoptics.speos import __version__

from sphinx.builders.latex import LaTeXBuilder

LaTeXBuilder.supported_image_types = ["image/png", "image/pdf", "image/svg+xml"]

# Project information
project = 'ansys-pyoptics'
copyright = f"(c) {datetime.now().year} ANSYS, Inc. All rights reserved"
Expand Down