Skip to content

Commit

Permalink
Improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
Paebbels authored Aug 14, 2023
2 parents 645e27a + b325a9f commit 1fda0fc
Show file tree
Hide file tree
Showing 21 changed files with 836 additions and 223 deletions.
41 changes: 28 additions & 13 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,30 @@
version: 2
updates:
- package-ecosystem: pip
directory: "/"
target-branch: dev
commit-message:
prefix: "[Dependabot]"
labels:
- Dependencies
assignees:
- Paebbels
reviewers:
- Paebbels
schedule:
interval: daily
# Maintain Python packages
- package-ecosystem: "pip"
directory: "/"
target-branch: dev
commit-message:
prefix: "[Dependabot]"
labels:
- Dependencies
reviewers:
- Paebbels
- Umarcor
- StefanUnrein
schedule:
interval: "daily" # Checks on Monday trough Friday.

# Maintain GitHub Action runners
- package-ecosystem: "github-actions"
directory: "/"
target-branch: dev
commit-message:
prefix: "[Dependabot]"
labels:
- Dependencies
reviewers:
- Paebbels
- Umarcor
schedule:
interval: "weekly"
3 changes: 2 additions & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@
* tbd

----------
Related PRs:
# Related PRs:

* tbd
89 changes: 35 additions & 54 deletions .github/workflows/Pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,63 +9,59 @@ on:
jobs:

Params:
uses: pyTooling/Actions/.github/workflows/Parameters.yml@r0
uses: pyTooling/Actions/.github/workflows/Parameters.yml@dev
with:
name: pyEDAA.Launcher

UnitTesting:
uses: pyTooling/Actions/.github/workflows/UnitTesting.yml@r0
uses: pyTooling/Actions/.github/workflows/UnitTesting.yml@dev
needs:
- Params
with:
jobs: ${{ needs.Params.outputs.python_jobs }}
pacboy: >-
msys/git
python-pip:p
python-wheel:p
python-coverage:p
python-lxml:p
artifact: ${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}
artifact: ${{ fromJson(needs.Params.outputs.artifact_names).unittesting_xml }}

Coverage:
uses: pyTooling/Actions/.github/workflows/CoverageCollection.yml@r0
uses: pyTooling/Actions/.github/workflows/CoverageCollection.yml@dev
needs:
- Params
with:
python_version: ${{ fromJson(needs.Params.outputs.params).python_version }}
artifact: ${{ fromJson(needs.Params.outputs.params).artifacts.coverage }}
python_version: ${{ needs.Params.outputs.python_version }}
artifact: ${{ fromJson(needs.Params.outputs.artifact_names).codecoverage_html }}
secrets:
codacy_token: ${{ secrets.CODACY_PROJECT_TOKEN }}

StaticTypeCheck:
uses: pyTooling/Actions/.github/workflows/StaticTypeCheck.yml@r0
uses: pyTooling/Actions/.github/workflows/StaticTypeCheck.yml@dev
needs:
- Params
with:
python_version: ${{ fromJson(needs.Params.outputs.params).python_version }}
python_version: ${{ needs.Params.outputs.python_version }}
requirements: '-r tests/requirements.txt'
commands: |
cd pyEDAA
mypy --html-report ../htmlmypy -p Launcher
report: 'htmlmypy'
artifact: ${{ fromJson(needs.Params.outputs.params).artifacts.typing }}
mypy --junit-xml ../StaticTypingSummary.xml --html-report ../htmlmypy -p Launcher
html_artifact: ${{ fromJson(needs.Params.outputs.artifact_names).statictyping_html }}
junit_report: 'StaticTypingSummary.xml'
junit_artifact: ${{ fromJson(needs.Params.outputs.artifact_names).statictyping_junit }}

PublishTestResults:
uses: pyTooling/Actions/.github/workflows/PublishTestResults.yml@r0
uses: pyTooling/Actions/.github/workflows/PublishTestResults.yml@dev
needs:
- UnitTesting
- StaticTypeCheck

Package:
uses: pyTooling/Actions/.github/workflows/Package.yml@isolation-modes
uses: pyTooling/Actions/.github/workflows/Package.yml@dev
needs:
- Params
- Coverage
with:
python_version: ${{ fromJson(needs.Params.outputs.params).python_version }}
artifact: ${{ fromJson(needs.Params.outputs.params).artifacts.package }}
python_version: ${{ needs.Params.outputs.python_version }}
artifact: ${{ fromJson(needs.Params.outputs.artifact_names).package_all }}

Release:
uses: pyTooling/Actions/.github/workflows/Release.yml@r0
uses: pyTooling/Actions/.github/workflows/Release.yml@dev
if: startsWith(github.ref, 'refs/tags')
needs:
- UnitTesting
Expand All @@ -74,48 +70,48 @@ jobs:
- Package

PublishOnPyPI:
uses: pyTooling/Actions/.github/workflows/PublishOnPyPI.yml@r0
uses: pyTooling/Actions/.github/workflows/PublishOnPyPI.yml@dev
if: startsWith(github.ref, 'refs/tags')
needs:
- Params
- Release
- Package
with:
python_version: ${{ fromJson(needs.Params.outputs.params).python_version }}
python_version: ${{ needs.Params.outputs.python_version }}
requirements: -r dist/requirements.txt
artifact: ${{ fromJson(needs.Params.outputs.params).artifacts.package }}
artifact: ${{ fromJson(needs.Params.outputs.artifact_names).package_all }}
secrets:
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}

# VerifyDocs:
# uses: pyTooling/Actions/.github/workflows/VerifyDocs.yml@r0
# uses: pyTooling/Actions/.github/workflows/VerifyDocs.yml@dev
# needs:
# - Params
# with:
# python_version: ${{ fromJson(needs.Params.outputs.params).python_version }}
# python_version: ${{ needs.Params.outputs.python_version }}

BuildTheDocs:
uses: pyTooling/Actions/.github/workflows/BuildTheDocs.yml@r0
uses: pyTooling/Actions/.github/workflows/BuildTheDocs.yml@dev
needs:
- Params
# - VerifyDocs
with:
artifact: ${{ fromJson(needs.Params.outputs.params).artifacts.doc }}
artifact: ${{ fromJson(needs.Params.outputs.artifact_names).documentation_html }}

PublishToGitHubPages:
uses: pyTooling/Actions/.github/workflows/PublishToGitHubPages.yml@r0
uses: pyTooling/Actions/.github/workflows/PublishToGitHubPages.yml@dev
needs:
- Params
- BuildTheDocs
- Coverage
- StaticTypeCheck
with:
doc: ${{ fromJson(needs.Params.outputs.params).artifacts.doc }}
coverage: ${{ fromJson(needs.Params.outputs.params).artifacts.coverage }}
typing: ${{ fromJson(needs.Params.outputs.params).artifacts.typing }}
doc: ${{ fromJson(needs.Params.outputs.artifact_names).documentation_html }}
coverage: ${{ fromJson(needs.Params.outputs.artifact_names).codecoverage_html }}
typing: ${{ fromJson(needs.Params.outputs.artifact_names).statictyping_html }}

ArtifactCleanUp:
uses: pyTooling/Actions/.github/workflows/ArtifactCleanUp.yml@r0
uses: pyTooling/Actions/.github/workflows/ArtifactCleanUp.yml@dev
needs:
- Params
- UnitTesting
Expand All @@ -125,24 +121,9 @@ jobs:
- PublishToGitHubPages
- PublishTestResults
with:
package: ${{ fromJson(needs.Params.outputs.params).artifacts.package }}
package: ${{ fromJson(needs.Params.outputs.artifact_names).package_all }}
remaining: |
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-ubuntu-3.6
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-ubuntu-3.7
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-ubuntu-3.8
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-ubuntu-3.9
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-ubuntu-3.10
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-windows-3.6
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-windows-3.7
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-windows-3.8
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-windows-3.9
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-windows-3.10
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-msys2-3.9
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-macos-3.6
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-macos-3.7
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-macos-3.8
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-macos-3.9
${{ fromJson(needs.Params.outputs.params).artifacts.unittesting }}-macos-3.10
${{ fromJson(needs.Params.outputs.params).artifacts.coverage }}
${{ fromJson(needs.Params.outputs.params).artifacts.typing }}
${{ fromJson(needs.Params.outputs.params).artifacts.doc }}
${{ fromJson(needs.Params.outputs.artifact_names).unittesting_xml }}-*
${{ fromJson(needs.Params.outputs.artifact_names).codecoverage_html }}
${{ fromJson(needs.Params.outputs.artifact_names).statictyping_html }}
${{ fromJson(needs.Params.outputs.artifact_names).documentation_html }}
4 changes: 3 additions & 1 deletion .idea/pyEDAA.Launcher.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

42 changes: 29 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,23 +25,39 @@
[![Libraries.io SourceRank](https://img.shields.io/librariesio/sourcerank/pypi/pyEDAA.Launcher?longCache=true&style=flat-square)](https://libraries.io/github/edaa-org/pyEDAA.Launcher/sourcerank)
-->

**pyEDAA.Launcher** starts the correct Xilinx Vivado version based on the version number written into the ``*.xpr`` file.
If no suitable version was found, an error message is shown.

# Main Goals
If one is using the Xilinx Vivado IDE, you will know that you can't just open the xpr project file with a double click if you have installed more then one Vivado version. This is because Xilinx has no Launcher which is checking the version of the project and passing the xpr to the correct Vivado Version. This project addresses exactly this problem.

1. Check with which Vivado Version a xpr was created
1. and pass the xpr to the correct Version.
1. Now you can open every xpr just with a simple double click!
1. It behaves exactly as you would open the xpr directly with Vivado itself. **With one exeption**:
The working dir in Vivado is set to the xpr path and not to AppData, like it should be!
When opening Xilinx Vivado by double-clicking an ``*.xpr`` file in the Windows Explorer, a default Vivado version is
launched by Windows. In many cases, this is the first Vivado version that was installed on a system, but not the latest
version. Anyhow, in most cases, Windows starts the wrong Vivado version, which leeds to a project upgrade question, or a
rejection, because the project file is too new.

# Installation
* Copy the executable from the releases to the Vivado installation Path. For me its `C:\Xilinx\Vivado\`.
* In this Path you should see the installation-folders of all Vivado Versions. E.g: 2018.3, 2019.1, ...
* Change File-association: Right click on `*.xpr` -> open with -> choose another app -> and select the `VivadoLauncher.exe`
* That's it.
**pyEDAA.Launcher** addresses exactly this problem. It will start the correct Xilinx Vivado installation with correct
working directory settings, if that requested Vivado version is found on the system.

Note for Xilinx: Feel free to include this in the next release to stop this version madness. Please inform us then.
## How does it work?

1. Check with which Vivado version was used to save the ``*.xpr`` file.
2. Scan the Xilinx installation directory for available Vivado versions.
3. If a matching version was found, start Vivado and pass the ``*.xpr`` as a parameter.

## Differences to opening the ``*.xpr`` from GUI?

By default, Xilinx Vivado has its working directory in ``AppData``, but the working directory should be in the directory
where the ``*.xpr`` file is located. This is fixed by **pyEDAA.Launcher** as a side effect. Now, Vivado saves log and
journal files to the correct locations.


> # Installation
> * Copy the executable from the releases to the Vivado installation Path. For me its `C:\Xilinx\Vivado\`.
> * In this Path you should see the installation-folders of all Vivado Versions. E.g: 2018.3, 2019.1, ...
> * Change File-association: Right click on `*.xpr` -> open with -> choose another app -> and select the `VivadoLauncher.exe`
> * That's it.
> Note for Xilinx: Feel free to include this in the next release to stop this version madness. Please inform us then.
# Contributors

Expand All @@ -56,4 +72,4 @@ This Python package (source code) licensed under [Apache License 2.0](LICENSE.md
The accompanying documentation is licensed under [Creative Commons - Attribution 4.0 (CC-BY 4.0)](doc/Doc-License.rst).

-------------------------
SPDX-License-Identifier: Apache-2.0
SPDX-License-Identifier: Apache-2.0
Loading

0 comments on commit 1fda0fc

Please sign in to comment.