Skip to content

Commit 542228e

Browse files
authored
fix(deploy): revert "feat(deploy): copy local git config to tmp repo (#7702)" (#7750)
1 parent a4b4a7f commit 542228e

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

packages/docusaurus/src/commands/deploy.ts

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -183,9 +183,6 @@ You can also set the deploymentBranch property in docusaurus.config.js .`);
183183
// Save the commit hash that triggers publish-gh-pages before checking
184184
// out to deployment branch.
185185
const currentCommit = shellExecLog('git rev-parse HEAD').stdout.trim();
186-
const currentGitRootDir = shellExecLog(
187-
'git rev-parse --show-toplevel',
188-
).stdout.trim();
189186

190187
const runDeploy = async (outputDirectory: string) => {
191188
const fromPath = outputDirectory;
@@ -216,16 +213,6 @@ You can also set the deploymentBranch property in docusaurus.config.js .`);
216213
logger.error`Copying build assets from path=${fromPath} to path=${toPath} failed.`;
217214
throw err;
218215
}
219-
220-
const gitConfigFromPath = path.join(currentGitRootDir, `.git`, `config`);
221-
const gitConfigToPath = path.join(toPath, `.git`, `config`);
222-
try {
223-
await fs.copy(gitConfigFromPath, gitConfigToPath);
224-
} catch (err) {
225-
logger.error`Copying git config from path=${gitConfigFromPath} to path=${gitConfigToPath} failed.`;
226-
throw err;
227-
}
228-
229216
shellExecLog('git add --all');
230217

231218
const commitMessage =

0 commit comments

Comments
 (0)