

    - name: Set up Python
      uses: actions/setup-python@v5
      with: { python-version: "3.13" }

    - name: Fetch Latest Gito Version
      id: gito-version
      run: pip index versions gito.bot 2>/dev/null | head -1 | sed -n 's/.* (\([^)]*\)).*/version=\1/p' >> $GITHUB_OUTPUT

    {% raw -%}
    - uses: actions/cache@v4
      id: cache
      with:
        path: |
          ${{ env.pythonLocation }}/lib/python3.13/site-packages
          ${{ env.pythonLocation }}/bin
        key: gito_v${{ steps.gito-version.outputs.version }}
    {%- endraw %}

    - name: Install Gito
      if: steps.cache.outputs.cache-hit != 'true'
      run: pip install gito.bot~={{ major }}.{{ minor }}
