Retrieve git sha from a remote repository
uses: mego22/actions-git-sha@main
with:
repo: "https://github.com/mego22/dotfiles.git"
uses: mego22/actions-git-sha@main
with:
username: "${{ github.actor }}"
password: "${{ secrets.TOKEN }}"
repo: "https://github.com/mego22/git-sha-test.git"
uses: mego22/actions-git-sha@main
with:
repo: "https://github.com/mego22/dotfiles.git"
branch: "git-sha-test"
- name: Retrieve sha from a repo
id: remote_sha
uses: mego22/actions-git-sha@main
with:
repo: "https://github.com/mego22/dotfiles.git"
- name: Print sha
run: echo "The sha is ${{ steps.remote_sha.outputs.sha }}"
repo
- The remote repository you want the sha frombranch
- (optional) the branch you want the sha fromusername
- (optional) the username for a private repositorypassword
- (optional) the password or token for a private repository
sha
- The git sha