fixed update_version.sh #14
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Ansible Galaxy Collection | |
on: | |
push: | |
branches: | |
- main # Ändern Sie dies entsprechend Ihrem Hauptbranch | |
jobs: | |
uild-and-publish: | |
runs-on: ubuntu-latest | |
permissions: write-all | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Check if requirements have changed | |
id: check_changes | |
run: | | |
CHANGED=$(git diff --name-only HEAD^ HEAD | grep -q 'plugin_requirements.yml' && echo "true" || echo "false") | |
if [ "$CHANGED" = "true" ]; then | |
PLUGIN_REQS=$(cat plugin_requirements.yml) | |
APT_PKG_LIST=$(cat .github/workflows/apt-packages.yml) | |
echo "::set-output name=plugin_reqs::$PLUGIN_REQS" | |
echo "::set-output name=apt_pkg_list::$APT_PKG_LIST" | |
else | |
echo "::set-output name=changed::false" | |
fi | |
# - name: Build collection | |
# run: ansible-galaxy collection build -vvv --output-path . --requirements-file requirements.txt --force | |
# env: | |
# ANSIBLE_GALAXY_API_KEY: ${{ secrets.GALAXY_API_KEY }} # Stellen Sie sicher, dass GALAXY_API_KEY in Ihren Secrets gesetzt ist | |
# | |
# - name: Publish collection | |
# run: ansible-galaxy collection publish --api-key ${{ secrets.GALAXY_API_KEY }} ./ji_podhead-ilohelper-*.tar.gz | |
# env: | |
# ANSIBLE_GALAXY_API_KEY: ${{ secrets.GALAXY_API_KEY }} |