Compare commits

..

2 Commits

Author SHA1 Message Date
Cory Miller a5ac7e51b4
Update for 4.1.6 release (#1733) 2024-05-16 14:08:36 -04:00
Cory Miller 24ed1a3528
Check platform for extension (#1732) 2024-05-16 13:40:36 -04:00
5 changed files with 18 additions and 4 deletions

View File

@ -1,5 +1,15 @@
# Changelog # Changelog
## v4.1.6
* Check platform to set archive extension appropriately by @cory-miller in https://github.com/actions/checkout/pull/1732
## v4.1.5
* Update NPM dependencies by @cory-miller in https://github.com/actions/checkout/pull/1703
* Bump github/codeql-action from 2 to 3 by @dependabot in https://github.com/actions/checkout/pull/1694
* Bump actions/setup-node from 1 to 4 by @dependabot in https://github.com/actions/checkout/pull/1696
* Bump actions/upload-artifact from 2 to 4 by @dependabot in https://github.com/actions/checkout/pull/1695
* README: Suggest `user.email` to be `41898282+github-actions[bot]@users.noreply.github.com` by @cory-miller in https://github.com/actions/checkout/pull/1707
## v4.1.4 ## v4.1.4
- Disable `extensions.worktreeConfig` when disabling `sparse-checkout` by @jww3 in https://github.com/actions/checkout/pull/1692 - Disable `extensions.worktreeConfig` when disabling `sparse-checkout` by @jww3 in https://github.com/actions/checkout/pull/1692
- Add dependabot config by @cory-miller in https://github.com/actions/checkout/pull/1688 - Add dependabot config by @cory-miller in https://github.com/actions/checkout/pull/1688

4
dist/index.js vendored
View File

@ -1574,7 +1574,9 @@ function downloadRepository(authToken, owner, repo, ref, commit, repositoryPath,
// Write archive to disk // Write archive to disk
core.info('Writing archive to disk'); core.info('Writing archive to disk');
const uniqueId = (0, uuid_1.v4)(); const uniqueId = (0, uuid_1.v4)();
const archivePath = path.join(repositoryPath, `${uniqueId}.tar.gz`); const archivePath = IS_WINDOWS
? path.join(repositoryPath, `${uniqueId}.zip`)
: path.join(repositoryPath, `${uniqueId}.tar.gz`);
yield fs.promises.writeFile(archivePath, archiveData); yield fs.promises.writeFile(archivePath, archiveData);
archiveData = Buffer.from(''); // Free memory archiveData = Buffer.from(''); // Free memory
// Extract archive // Extract archive

2
package-lock.json generated
View File

@ -1,6 +1,6 @@
{ {
"name": "checkout", "name": "checkout",
"version": "4.1.4", "version": "4.1.6",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {

View File

@ -1,6 +1,6 @@
{ {
"name": "checkout", "name": "checkout",
"version": "4.1.4", "version": "4.1.6",
"description": "checkout action", "description": "checkout action",
"main": "lib/main.js", "main": "lib/main.js",
"scripts": { "scripts": {

View File

@ -35,7 +35,9 @@ export async function downloadRepository(
// Write archive to disk // Write archive to disk
core.info('Writing archive to disk') core.info('Writing archive to disk')
const uniqueId = uuid() const uniqueId = uuid()
const archivePath = path.join(repositoryPath, `${uniqueId}.tar.gz`) const archivePath = IS_WINDOWS
? path.join(repositoryPath, `${uniqueId}.zip`)
: path.join(repositoryPath, `${uniqueId}.tar.gz`)
await fs.promises.writeFile(archivePath, archiveData) await fs.promises.writeFile(archivePath, archiveData)
archiveData = Buffer.from('') // Free memory archiveData = Buffer.from('') // Free memory