mirror of
https://github.com/actions/checkout.git
synced 2025-07-05 01:04:48 +02:00
Compare commits
5 Commits
v2.3.3
...
ericsciple
Author | SHA1 | Date | |
---|---|---|---|
d668097b24 | |||
4edfe9f331 | |||
25a956c84d | |||
5a4ac9002d | |||
c952173edf |
@ -27,6 +27,7 @@
|
|||||||
"@typescript-eslint/no-empty-interface": "error",
|
"@typescript-eslint/no-empty-interface": "error",
|
||||||
"@typescript-eslint/no-explicit-any": "error",
|
"@typescript-eslint/no-explicit-any": "error",
|
||||||
"@typescript-eslint/no-extraneous-class": "error",
|
"@typescript-eslint/no-extraneous-class": "error",
|
||||||
|
"@typescript-eslint/no-floating-promises": "error",
|
||||||
"@typescript-eslint/no-for-in-array": "error",
|
"@typescript-eslint/no-for-in-array": "error",
|
||||||
"@typescript-eslint/no-inferrable-types": "error",
|
"@typescript-eslint/no-inferrable-types": "error",
|
||||||
"@typescript-eslint/no-misused-new": "error",
|
"@typescript-eslint/no-misused-new": "error",
|
||||||
|
1
CODEOWNERS
Normal file
1
CODEOWNERS
Normal file
@ -0,0 +1 @@
|
|||||||
|
* @actions/actions-runtime
|
@ -2,5 +2,5 @@
|
|||||||
mkdir override-git-version
|
mkdir override-git-version
|
||||||
cd override-git-version
|
cd override-git-version
|
||||||
echo @echo override git version 1.2.3 > git.cmd
|
echo @echo override git version 1.2.3 > git.cmd
|
||||||
echo ::add-path::%CD%
|
echo "%CD%" >> $GITHUB_PATH
|
||||||
cd ..
|
cd ..
|
||||||
|
@ -5,5 +5,5 @@ cd override-git-version
|
|||||||
echo "#!/bin/sh" > git
|
echo "#!/bin/sh" > git
|
||||||
echo "echo override git version 1.2.3" >> git
|
echo "echo override git version 1.2.3" >> git
|
||||||
chmod +x git
|
chmod +x git
|
||||||
echo "::add-path::$(pwd)"
|
echo "$(pwd)" >> $GITHUB_PATH
|
||||||
cd ..
|
cd ..
|
||||||
|
7
dist/index.js
vendored
7
dist/index.js
vendored
@ -3286,6 +3286,7 @@ function run() {
|
|||||||
try {
|
try {
|
||||||
// Register problem matcher
|
// Register problem matcher
|
||||||
coreCommand.issueCommand('add-matcher', {}, path.join(__dirname, 'problem-matcher.json'));
|
coreCommand.issueCommand('add-matcher', {}, path.join(__dirname, 'problem-matcher.json'));
|
||||||
|
console.log(JSON.stringify(process.env, null, ' '));
|
||||||
// Get sources
|
// Get sources
|
||||||
yield gitSourceProvider.getSource(sourceSettings);
|
yield gitSourceProvider.getSource(sourceSettings);
|
||||||
}
|
}
|
||||||
@ -5498,7 +5499,7 @@ class GitAuthHelper {
|
|||||||
const configPaths = output.match(/(?<=(^|\n)file:)[^\t]+(?=\tremote\.origin\.url)/g) || [];
|
const configPaths = output.match(/(?<=(^|\n)file:)[^\t]+(?=\tremote\.origin\.url)/g) || [];
|
||||||
for (const configPath of configPaths) {
|
for (const configPath of configPaths) {
|
||||||
core.debug(`Replacing token placeholder in '${configPath}'`);
|
core.debug(`Replacing token placeholder in '${configPath}'`);
|
||||||
this.replaceTokenPlaceholder(configPath);
|
yield this.replaceTokenPlaceholder(configPath);
|
||||||
}
|
}
|
||||||
if (this.settings.sshKey) {
|
if (this.settings.sshKey) {
|
||||||
// Configure core.sshCommand
|
// Configure core.sshCommand
|
||||||
@ -9594,7 +9595,7 @@ function downloadRepository(authToken, owner, repo, ref, commit, repositoryPath)
|
|||||||
else {
|
else {
|
||||||
yield toolCache.extractTar(archivePath, extractPath);
|
yield toolCache.extractTar(archivePath, extractPath);
|
||||||
}
|
}
|
||||||
io.rmRF(archivePath);
|
yield io.rmRF(archivePath);
|
||||||
// Determine the path of the repository content. The archive contains
|
// Determine the path of the repository content. The archive contains
|
||||||
// a top-level folder and the repository content is inside.
|
// a top-level folder and the repository content is inside.
|
||||||
const archiveFileNames = yield fs.promises.readdir(extractPath);
|
const archiveFileNames = yield fs.promises.readdir(extractPath);
|
||||||
@ -9613,7 +9614,7 @@ function downloadRepository(authToken, owner, repo, ref, commit, repositoryPath)
|
|||||||
yield io.mv(sourcePath, targetPath);
|
yield io.mv(sourcePath, targetPath);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
io.rmRF(extractPath);
|
yield io.rmRF(extractPath);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
exports.downloadRepository = downloadRepository;
|
exports.downloadRepository = downloadRepository;
|
||||||
|
@ -148,7 +148,7 @@ class GitAuthHelper {
|
|||||||
output.match(/(?<=(^|\n)file:)[^\t]+(?=\tremote\.origin\.url)/g) || []
|
output.match(/(?<=(^|\n)file:)[^\t]+(?=\tremote\.origin\.url)/g) || []
|
||||||
for (const configPath of configPaths) {
|
for (const configPath of configPaths) {
|
||||||
core.debug(`Replacing token placeholder in '${configPath}'`)
|
core.debug(`Replacing token placeholder in '${configPath}'`)
|
||||||
this.replaceTokenPlaceholder(configPath)
|
await this.replaceTokenPlaceholder(configPath)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.settings.sshKey) {
|
if (this.settings.sshKey) {
|
||||||
|
@ -47,7 +47,7 @@ export async function downloadRepository(
|
|||||||
} else {
|
} else {
|
||||||
await toolCache.extractTar(archivePath, extractPath)
|
await toolCache.extractTar(archivePath, extractPath)
|
||||||
}
|
}
|
||||||
io.rmRF(archivePath)
|
await io.rmRF(archivePath)
|
||||||
|
|
||||||
// Determine the path of the repository content. The archive contains
|
// Determine the path of the repository content. The archive contains
|
||||||
// a top-level folder and the repository content is inside.
|
// a top-level folder and the repository content is inside.
|
||||||
@ -70,7 +70,7 @@ export async function downloadRepository(
|
|||||||
await io.mv(sourcePath, targetPath)
|
await io.mv(sourcePath, targetPath)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
io.rmRF(extractPath)
|
await io.rmRF(extractPath)
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -16,6 +16,8 @@ async function run(): Promise<void> {
|
|||||||
{},
|
{},
|
||||||
path.join(__dirname, 'problem-matcher.json')
|
path.join(__dirname, 'problem-matcher.json')
|
||||||
)
|
)
|
||||||
|
|
||||||
|
console.log(JSON.stringify(process.env, null, ' '))
|
||||||
|
|
||||||
// Get sources
|
// Get sources
|
||||||
await gitSourceProvider.getSource(sourceSettings)
|
await gitSourceProvider.getSource(sourceSettings)
|
||||||
|
Reference in New Issue
Block a user