From 3632f8c4d167c4eb57fc71cd0d9fcdc451bca039 Mon Sep 17 00:00:00 2001 From: Sam Carlton Date: Thu, 19 May 2022 10:49:50 -0500 Subject: [PATCH] Track kind list build time --- build-lists.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/build-lists.js b/build-lists.js index 5662f1a..c3519b5 100644 --- a/build-lists.js +++ b/build-lists.js @@ -301,6 +301,12 @@ class BuildLists { saveKind = async function ( list, kindSlug ) { const apiKindListDirectory = `${ apiDirectory }/kind/${ kindSlug }` + console.log('\n', `-- Starting kind lists for /${ apiKindListDirectory }`) + + const endpointMethodName = `Finished kind lists for /${ listOptions.name } endpoints` + console.time(endpointMethodName) + + const paginatedList = new PaginatedList({ list, }) @@ -315,6 +321,9 @@ class BuildLists { await this.saveToJson( kindPage.items, kindPagePath ) } + + console.timeEnd(endpointMethodName) + console.log( '\n\n' ) } saveApiEndpoints = async ( listOptions ) => {