name: Checkout description: Clone repository with configurable depth inputs: repository: description: Repository to clone (owner/repo) default: ${{ github.repository }} ref: description: Branch, tag, or SHA to checkout default: ${{ github.ref_name }} depth: description: Clone depth (0 for full history) default: '1' token: description: Token for private repositories default: ${{ github.token }} runs: using: composite steps: - shell: bash run: | if [ "${{ inputs.depth }}" = "0" ]; then git clone "https://oauth2:${{ inputs.token }}@git.flowmade.one/${{ inputs.repository }}.git" . else git clone --depth "${{ inputs.depth }}" --branch "${{ inputs.ref }}" \ "https://oauth2:${{ inputs.token }}@git.flowmade.one/${{ inputs.repository }}.git" . fi