1
0
mirror of synced 2025-12-19 18:10:59 -05:00

Remove remaining .js in package.json scripts (#57114)

This commit is contained in:
Kevin Heis
2025-08-18 15:48:33 -07:00
committed by GitHub
parent bb58717a48
commit ad5157764d
9 changed files with 42 additions and 35 deletions

View File

@@ -1,3 +1,4 @@
// @ts-nocheck
// [start-readme]
//
// Use this script to help you move or rename a single file or a folder. The script will move or rename the file or folder for you, update relevant `children` in the index.md file(s), and add a `redirect_from` to frontmatter in the renamed file(s). Note: You will still need to manually update the `title` if necessary.
@@ -507,7 +508,7 @@ function editFiles(files, updateParent, opts) {
// Add contentType frontmatter to moved files
if (files.length > 0) {
const filePaths = files.map(([oldPath, newPath, oldHref, newHref]) => newPath)
const filePaths = files.map(([, newPath]) => newPath)
try {
const cmd = ['run', 'add-content-type', '--', '--paths', ...filePaths]
const result = execFileSync('npm', cmd, { cwd: process.cwd(), encoding: 'utf8' })