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

consolidate temp directory when generating openapi data (#35331)

This commit is contained in:
Rachael Sewell
2023-03-07 11:24:50 -08:00
committed by GitHub
parent 70a3b81d1c
commit fa84be7019
3 changed files with 7 additions and 3 deletions

View File

@@ -63,7 +63,6 @@ jobs:
git status git status
echo "Deleting the cloned github/rest-api-description repo..." echo "Deleting the cloned github/rest-api-description repo..."
rm -rf rest-api-description rm -rf rest-api-description
rm -rf openApiTemp
- name: Create pull request - name: Create pull request
env: env:

5
.gitignore vendored
View File

@@ -32,4 +32,9 @@ user-code/
# Logs from scripts # Logs from scripts
script/logs/ script/logs/
external-link-checker-db.json external-link-checker-db.json
# Automated content source
rest-api-description
.installed.package-lock.json .installed.package-lock.json

View File

@@ -24,10 +24,10 @@ import { syncGitHubAppsData } from '../../github-apps/scripts/sync.js'
import { syncRestRedirects } from './utils/get-redirects.js' import { syncRestRedirects } from './utils/get-redirects.js'
const __dirname = path.dirname(fileURLToPath(import.meta.url)) const __dirname = path.dirname(fileURLToPath(import.meta.url))
const TEMP_OPENAPI_DIR = path.join(__dirname, '../../../openApiTemp') const TEMP_OPENAPI_DIR = path.join(__dirname, '../../../rest-api-description/openApiTemp')
const TEMP_BUNDLED_OPENAPI_DIR = path.join(TEMP_OPENAPI_DIR, 'bundled') const TEMP_BUNDLED_OPENAPI_DIR = path.join(TEMP_OPENAPI_DIR, 'bundled')
const GITHUB_REP_DIR = '../github' const GITHUB_REP_DIR = '../github'
const REST_DESCRIPTION_DIR = path.join('rest-api-description/descriptions-next') const REST_DESCRIPTION_DIR = 'rest-api-description/descriptions-next'
const VERSION_NAMES = JSON.parse(await readFile('src/rest/data/meta.json', 'utf8')).versionMapping const VERSION_NAMES = JSON.parse(await readFile('src/rest/data/meta.json', 'utf8')).versionMapping
program program