Skip to content

Commit 77fd434

Browse files
authored
Initial Code Contribution
2 parents 85f6492 + 4e49ad5 commit 77fd434

Some content is hidden

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

62 files changed

+5706
-16
lines changed

.btd.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
input: doc
2+
output: _build
3+
requirements: requirements.txt
4+
target: gh-pages
5+
formats: [ html, pdf, man ]
6+
images:
7+
base: edaa/doc
8+
latex: btdi/latex
9+
theme: https://codeload.github.com/buildthedocs/sphinx.theme/tar.gz/v1

.editorconfig

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
# end_of_line = lf
6+
insert_final_newline = true
7+
trim_trailing_whitespace = true
8+
indent_style = tab
9+
indent_size = 2
10+
tab_width = 2
11+
12+
13+
[*.py]
14+
indent_style = tab
15+
indent_size = 2
16+
17+
[*.{yml,yaml}]
18+
indent_style = space
19+
indent_size = 2
20+
21+
[*.{json,ini}]
22+
indent_style = tab
23+
indent_size = 2
24+
25+
[*.md]
26+
trim_trailing_whitespace = false
27+
28+
[*.rst]
29+
indent_style = space
30+
indent_size = 3

.github/workflows/Pipeline.yml

Lines changed: 75 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
fail-fast: false
1616
matrix:
1717
include:
18-
- {python: 3.6, icon: 🔴}
18+
# - {python: 3.6, icon: 🔴}
1919
- {python: 3.7, icon: 🟠}
2020
- {python: 3.8, icon: 🟡}
2121
- {python: 3.9, icon: 🟢}
@@ -49,8 +49,10 @@ jobs:
4949

5050
env:
5151
PYTHON: 3.9
52+
ARTIFACT: pyEDAA-ProjectModel-coverage-html
5253
outputs:
5354
python: ${{ env.PYTHON }}
55+
artifact: ${{ env.ARTIFACT }}
5456

5557
steps:
5658
- name: ⏬ Checkout repository
@@ -75,6 +77,10 @@ jobs:
7577
run: |
7678
coverage xml
7779
80+
- name: Convert to HTML format
81+
run: |
82+
coverage html
83+
7884
- name: 📊 Publish coverage at CodeCov
7985
continue-on-error: true
8086
uses: codecov/codecov-action@v1
@@ -90,6 +96,55 @@ jobs:
9096
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
9197
coverage-reports: ./coverage.xml
9298

99+
- name: 📤 Upload 'Coverage Report' artifact
100+
continue-on-error: true
101+
uses: actions/upload-artifact@v2
102+
with:
103+
name: ${{ env.ARTIFACT }}
104+
path: htmlcov
105+
if-no-files-found: error
106+
retention-days: 1
107+
108+
StaticTypeCheck:
109+
name: 📈 Check Static Typing using Python 3.9
110+
runs-on: ubuntu-latest
111+
112+
env:
113+
PYTHON: 3.9
114+
ARTIFACT: pyEDAA-ProjectModel-typing-html
115+
outputs:
116+
python: ${{ env.PYTHON }}
117+
artifact: ${{ env.ARTIFACT }}
118+
119+
steps:
120+
- name: ⏬ Checkout repository
121+
uses: actions/checkout@v2
122+
123+
- name: 🐍 Setup Python ${{ env.PYTHON }}
124+
uses: actions/setup-python@v2
125+
with:
126+
python-version: ${{ env.PYTHON }}
127+
128+
- name: 🗂 Install dependencies
129+
run: |
130+
python -m pip install --upgrade pip
131+
pip install -r tests/requirements.txt
132+
133+
- name: Check Static Typing
134+
continue-on-error: true
135+
run: |
136+
mypy --html-report htmlmypy --pretty pyEDAA/ProjectModel
137+
138+
- name: 📤 Upload 'Static Typing Report' artifact
139+
continue-on-error: true
140+
uses: actions/upload-artifact@v2
141+
with:
142+
name: ${{ env.ARTIFACT }}
143+
path: htmlmypy
144+
if-no-files-found: error
145+
retention-days: 1
146+
147+
93148
Release:
94149
name: 📝 Create 'Release Page' on GitHub
95150
runs-on: ubuntu-latest
@@ -98,6 +153,7 @@ jobs:
98153
needs:
99154
- UnitTesting
100155
- Coverage
156+
- StaticTypeCheck
101157

102158
env:
103159
PYTHON: ${{ needs.Coverage.outputs.python }}
@@ -232,43 +288,55 @@ jobs:
232288

233289
# needs:
234290
# - VerifyDocs
291+
env:
292+
ARTIFACT: pyEDAA-ProjectModel-documentation
293+
outputs:
294+
artifact: ${{ env.ARTIFACT }}
235295

236296
steps:
237297
- name: Checkout repository
238298
uses: actions/checkout@v2
239299

240300
- name: 🚢 Build container image 'vhdl/doc'
241301
run: |
242-
docker build -t vhdl/doc - <<-EOF
302+
docker build -t edaa/doc - <<-EOF
243303
FROM btdi/sphinx:featured
244304
RUN apk add -U --no-cache graphviz
245305
EOF
246306
247-
- name: 🛳️ Build documentation from './pyEDAA.ProjectModel/doc'
307+
- name: 🛳️ Build documentation using container edaa/doc and publish to GitHub Pages
248308
uses: buildthedocs/btd@v0
249309
with:
250310
token: ${{ github.token }}
251311

252-
- name: 📤 Upload artifacts to GitHub Pages
312+
- name: 📤 Upload 'documentation' artifacts
253313
uses: actions/upload-artifact@master
254314
with:
255-
name: doc
315+
name: ${{ env.ARTIFACT }}
256316
path: doc/_build/html
317+
retention-days: 7
257318

258319
ArtifactCleanUp:
259320
name: 🗑️ Artifact Cleanup
260321
runs-on: ubuntu-latest
261322

262323
needs:
324+
- Coverage
325+
- StaticTypeCheck
263326
- Package
264327
- PublishOnPyPI
265328

266329
env:
267-
ARTIFACT: ${{ needs.Package.outputs.artifact }}
330+
COVERAGE: ${{ needs.Coverage.outputs.artifact }}
331+
TYPING: ${{ needs.StaticTypeCheck.outputs.artifact }}
332+
PACKAGE: ${{ needs.Package.outputs.artifact }}
268333

269334
steps:
270335
- name: 🗑️ Delete all Artifacts
271336
uses: geekyeggo/delete-artifact@v1
272337
with:
273338
name: |
274-
${{ env.ARTIFACT }}
339+
${{ env.PACKAGE }}
340+
341+
# ${{ env.COVERAGE }}
342+
# ${{ env.TYPING }}

.gitignore

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Python cache and object files
2+
__pycache__/
3+
*.py[cod]
4+
5+
# Coverage.py
6+
.coverage
7+
.cov
8+
coverage.xml
9+
10+
# setuptools
11+
/build
12+
/dist
13+
/*.egg-info
14+
15+
# Sphinx
16+
doc/_build/
17+
doc/pyEDAA.ProjectModel/**/*.*
18+
!doc/pyEDAA.ProjectModel/index.rst
19+
20+
# BuildTheDocs
21+
doc/_theme/**/*.*
22+
23+
# IntelliJ project files
24+
/.idea/workspace.xml

.idea/inspectionProfiles/profiles_settings.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/modules.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/pyEDAA.ProjectModel.iml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,17 @@
3333

3434

3535
```python
36-
print(some.python.code.here())
36+
from pathlib import Path
37+
from pyEDAA.ProjectModel import Project, Design, FileSet, VHDLSourceFile
38+
39+
projectPath = Path("temp/project")
40+
project = Project("project", rootDirectory=projectPath)
41+
design = Design("design", project=project)
42+
fileset = FileSet("uart", Path("src/uart"), design=design)
43+
44+
for vhdlFilePath in fileset.ResolvedPath.glob("*.vhdl"):
45+
vhdlFile = VHDLSourceFile(vhdlFilePath)
46+
fileset.AddFile(vhdlFile)
3747
```
3848

3949

doc/ChangeLog/index.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
ChangeLog
2+
#########
3+
4+
Upcoming Release
5+
================
6+
7+
* tbd
8+
9+
01.09.2021
10+
==========
11+
12+
`pyEDAA.ProjectModel` was split from `pyIPCMI` (v1.1.6) as an independent Python package.

doc/Dependency.rst

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
.. _dependency:
2+
3+
Dependency
4+
##########
5+
6+
.. |img-ProjectModel-lib-status| image:: https://img.shields.io/librariesio/release/pypi/pyEDAA.ProjectModel
7+
:alt: Libraries.io status for latest release
8+
:height: 22
9+
:target: https://libraries.io/github/edaa-org/pyEDAA.ProjectModel
10+
.. |img-ProjectModel-req-status| image:: https://img.shields.io/requires/github/edaa-org/pyEDAA.ProjectModel
11+
:alt: Requires.io
12+
:height: 22
13+
:target: https://requires.io/github/edaa-org/pyEDAA.ProjectModel/requirements/?branch=master
14+
15+
+------------------------------------------+------------------------------------------+
16+
| `Libraries.io <https://libraries.io/>`_ | `Requires.io <https://requires.io/>`_ |
17+
+==========================================+==========================================+
18+
| |img-ProjectModel-lib-status| | |img-ProjectModel-req-status| |
19+
+------------------------------------------+------------------------------------------+
20+
21+
22+
.. _dependency-package:
23+
24+
pyEDAA.ProjectModel Package
25+
***************************
26+
27+
+-------------------------------------------------------+-------------+-----------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+
28+
| **Package** | **Version** | **License** | **Dependencies** |
29+
+=======================================================+=============+===================================================================================+===================================================================================================================================+
30+
| `pydecor <https://github.com/mplanchard/pydecor>`__ | ≥2.0.1 | `MIT <https://github.com/mplanchard/pydecor/blob/master/LICENSE>`__ | * `dill <https://github.com/uqfoundation/dill>`__ (`BSD 3-clause <https://github.com/uqfoundation/dill/blob/master/LICENSE>`__) |
31+
| | | | * `six <https://github.com/benjaminp/six>`__ (`MIT <https://github.com/benjaminp/six/blob/master/LICENSE>`__) |
32+
+-------------------------------------------------------+-------------+-----------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+
33+
| `pyVHDLModel <https://github.com/VHDL/pyVHDLModel>`__ | ≥0.13.0 | `Apache License, 2.0 <https://github.com/VHDL/pyVHDLModel/blob/master/LICENSE>`__ | * `pydecor <https://github.com/mplanchard/pydecor>`__ (`MIT <https://github.com/mplanchard/pydecor/blob/master/LICENSE>`__) |
34+
| | | | |
35+
| | | | * `dill <https://github.com/uqfoundation/dill>`__ (`BSD 3-clause <https://github.com/uqfoundation/dill/blob/master/LICENSE>`__) |
36+
| | | | * `six <https://github.com/benjaminp/six>`__ (`MIT <https://github.com/benjaminp/six/blob/master/LICENSE>`__) |
37+
+-------------------------------------------------------+-------------+-----------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+
38+
| `pySVModel <https://github.com/edaa-org/pySVModel>`__ | ≥0.3.0 | `Apache License, 2.0 <https://github.com/VHDL/pyVHDLModel/blob/master/LICENSE>`__ | * `pydecor <https://github.com/mplanchard/pydecor>`__ (`MIT <https://github.com/mplanchard/pydecor/blob/master/LICENSE>`__) |
39+
| | | | |
40+
| | | | * `dill <https://github.com/uqfoundation/dill>`__ (`BSD 3-clause <https://github.com/uqfoundation/dill/blob/master/LICENSE>`__) |
41+
| | | | * `six <https://github.com/benjaminp/six>`__ (`MIT <https://github.com/benjaminp/six/blob/master/LICENSE>`__) |
42+
+-------------------------------------------------------+-------------+-----------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+
43+
44+
45+
.. _dependency-testing:
46+
47+
Unit Testing / Coverage
48+
***********************
49+
50+
Additional Python packages needed for testing and code coverage collection.
51+
These packages are only needed for developers or on a CI server, thus
52+
sub-dependencies are not evaluated further.
53+
54+
+-----------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
55+
| **Package** | **Version** | **License** | **Dependencies** |
56+
+===========================================================+=============+========================================================================================+======================+
57+
| `pytest <https://github.com/pytest-dev/pytest>`__ | ≥6.2.4 | `MIT <https://github.com/pytest-dev/pytest/blob/master/LICENSE>`__ | *Not yet evaluated.* |
58+
+-----------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
59+
| `pytest-cov <https://github.com/pytest-dev/pytest-cov>`__ | ≥2.12.1 | `MIT <https://github.com/pytest-dev/pytest-cov/blob/master/LICENSE>`__ | *Not yet evaluated.* |
60+
+-----------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
61+
| `Coverage <https://github.com/nedbat/coveragepy>`__ | ≥6.0 | `Apache License, 2.0 <https://github.com/nedbat/coveragepy/blob/master/LICENSE.txt>`__ | *Not yet evaluated.* |
62+
+-----------------------------------------------------------+-------------+----------------------------------------------------------------------------------------+----------------------+
63+
64+
65+
.. _dependency-documentation:
66+
67+
Sphinx Documentation
68+
********************
69+
70+
Additional Python packages needed for documentation generation. These packages
71+
are only needed for developers or on a CI server, thus sub-dependencies are not
72+
evaluated further.
73+
74+
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+----------------------+
75+
| **Package** | **Version** | **License** | **Dependencies** |
76+
+=================================================================================================+==============+==========================================================================================================+======================+
77+
| `Sphinx <https://github.com/sphinx-doc/sphinx>`__ | ≥4.2.0 | `BSD 3-Clause <https://github.com/sphinx-doc/sphinx/blob/master/LICENSE>`__ | *Not yet evaluated.* |
78+
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+----------------------+
79+
| `sphinx_btd_theme <https://github.com/buildthedocs/sphinx.theme>`__ | | `MIT <https://github.com/buildthedocs/sphinx.theme/blob/master/LICENSE>`__ | *Not yet evaluated.* |
80+
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+----------------------+
81+
| `autoapi <https://github.com/carlos-jenkins/autoapi>`__ | | `Apache License, 2.0 <https://github.com/carlos-jenkins/autoapi/blob/master/LICENSE>`__ | *Not yet evaluated.* |
82+
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+----------------------+
83+
| !! `sphinx_fontawesome <https://github.com/fraoustin/sphinx_fontawesome>`__ | ≥0.0.6 | `GPL 2.0 <https://github.com/fraoustin/sphinx_fontawesome/blob/master/LICENSE>`__ | *Not yet evaluated.* |
84+
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+----------------------+
85+
| `sphinx_autodoc_typehints <https://github.com/agronholm/sphinx-autodoc-typehints>`__ | ≥1.12.0 | `MIT <https://github.com/agronholm/sphinx-autodoc-typehints/blob/master/LICENSE>`__ | *Not yet evaluated.* |
86+
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+----------------------+
87+
| `Pygments <https://github.com/pygments/pygments>`__ | ≥2.9.0 | `BSD 2-Clause <https://github.com/pygments/pygments/blob/master/LICENSE>`__ | *Not yet evaluated.* |
88+
+-------------------------------------------------------------------------------------------------+--------------+----------------------------------------------------------------------------------------------------------+----------------------+

0 commit comments

Comments
 (0)