mirror of
https://github.com/actions/checkout.git
synced 2025-08-23 10:48:01 +03:00
Compare commits
3 commits
c64b8cbdb8
...
9dbd65c315
Author | SHA1 | Date | |
---|---|---|---|
|
9dbd65c315 | ||
|
ff7abcd0c3 | ||
|
38cc68387c |
3 changed files with 17 additions and 2 deletions
|
@ -2,7 +2,11 @@
|
|||
|
||||
# Checkout V5
|
||||
|
||||
Checkout v5 now supports Node.js 24
|
||||
## What's new
|
||||
|
||||
- Updated to the node24 runtime
|
||||
- This requires a minimum Actions Runner version of [v2.327.1](https://github.com/actions/runner/releases/tag/v2.327.1) to run.
|
||||
|
||||
|
||||
# Checkout V4
|
||||
|
||||
|
@ -154,9 +158,10 @@ Please refer to the [release page](https://github.com/actions/checkout/releases/
|
|||
# Scenarios
|
||||
|
||||
- [Checkout V5](#checkout-v5)
|
||||
- [What's new](#whats-new)
|
||||
- [Checkout V4](#checkout-v4)
|
||||
- [Note](#note)
|
||||
- [What's new](#whats-new)
|
||||
- [What's new](#whats-new-1)
|
||||
- [Usage](#usage)
|
||||
- [Scenarios](#scenarios)
|
||||
- [Fetch only the root files](#fetch-only-the-root-files)
|
||||
|
|
|
@ -44,6 +44,7 @@ export interface IGitCommandManager {
|
|||
getWorkingDirectory(): string
|
||||
init(): Promise<void>
|
||||
isDetached(): Promise<boolean>
|
||||
lfsCheckout(): Promise<void>
|
||||
lfsFetch(ref: string): Promise<void>
|
||||
lfsInstall(): Promise<void>
|
||||
log1(format?: string): Promise<string>
|
||||
|
@ -340,6 +341,10 @@ class GitCommandManager {
|
|||
return !output.stdout.trim().startsWith('refs/heads/')
|
||||
}
|
||||
|
||||
async lfsCheckout(): Promise<void> {
|
||||
await this.execGit(['lfs', 'checkout'])
|
||||
}
|
||||
|
||||
async lfsFetch(ref: string): Promise<void> {
|
||||
const args = ['lfs', 'fetch', 'origin', ref]
|
||||
|
||||
|
|
|
@ -232,6 +232,11 @@ export async function getSource(settings: IGitSourceSettings): Promise<void> {
|
|||
await git.checkout(checkoutInfo.ref, checkoutInfo.startPoint)
|
||||
core.endGroup()
|
||||
|
||||
// LFS checkout
|
||||
core.startGroup('Checking out LFS objects')
|
||||
await git.lfsCheckout()
|
||||
core.endGroup()
|
||||
|
||||
// Submodules
|
||||
if (settings.submodules) {
|
||||
// Temporarily override global config
|
||||
|
|
Loading…
Add table
Reference in a new issue