Skip to content

Commit

Permalink
echo dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
CM000n committed Dec 14, 2023
1 parent 3f1c568 commit 87ddfab
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions .github/workflows/check-versions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,20 @@ jobs:
run: poetry install
- name: 🚀 Check Manifest.json
run: |
current_version=$(poetry version | awk '{print $2}')
pyproject_version=$(poetry version | awk '{print $2}')
echo "pyproject.toml version: $pyproject_version"
manifest_version=$(jq -r '.version' custom_components/qss/manifest.json)
if [[ "$current_version" != "$manifest_version" ]]; then
echo "Error: Version mismatch between pyproject.toml ($current_version) and manifest.json ($manifest_version)"
echo "manifest.json version: $manifest_version"
if [[ "$pyproject_version" != "$manifest_version" ]]; then
echo "Error: Version mismatch between pyproject.toml ($pyproject_version) and manifest.json ($manifest_version)"
exit 1
fi
current_dependencies=$(poetry show --only main | awk -F' ' '{print $1}')
pyproject_dependencies=$(poetry show --only main | awk -F' ' '{print $1}')
echo "pyproject.toml dependecies: $pyproject_dependencies"
manifest_dependencies=$(jq -r '.requirements[]' custom_components/qss/manifest.json)
for dependency in $current_dependencies; do
echo "manifest.json dependecies: $manifest_dependencies"
for dependency in $pyproject_dependencies; do
matching_dependency=$(echo "$manifest_dependencies" | grep "$dependency")
if [[ -z "$matching_dependency" ]]; then
echo "Error: Missing dependency $dependency in manifest.json"
Expand Down

0 comments on commit 87ddfab

Please sign in to comment.