mirror of
https://code.forgejo.org/actions/checkout.git
synced 2025-04-21 17:12:03 +03:00
Add ref output to action
This value is the SHA1 commit of the repository ref that was actually checked out.
This commit is contained in:
parent
c5ef344f79
commit
dbd025a70e
4 changed files with 10 additions and 3 deletions
|
@ -278,7 +278,8 @@ export async function getSource(settings: IGitSourceSettings): Promise<void> {
|
|||
const commitInfo = await git.log1()
|
||||
|
||||
// Log commit sha
|
||||
await git.log1("--format='%H'")
|
||||
const commit = await git.log1("--format='%H'")
|
||||
core.setOutput('ref', commit.replaceAll("'", '').trim())
|
||||
|
||||
// Check for incorrect pull request merge commit
|
||||
await refHelper.checkCommitInfo(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue