File tree Expand file tree Collapse file tree 2 files changed +5
-0
lines changed
Expand file tree Collapse file tree 2 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -50,6 +50,7 @@ program
5050 branch : options . branch ,
5151 } ,
5252 version : options . branch ,
53+ latest : true ,
5354 api : {
5455 endpoint : `https://${ subdomain } .cfdata.org/api/v1/templates` ,
5556 clientId,
Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ export type UploadConfig = {
1111 templateDirectory : string ;
1212 seedRepo : SeedRepo ;
1313 version : string ;
14+ latest ?: boolean ;
1415 api : {
1516 endpoint : string ;
1617 clientId : string ;
@@ -43,6 +44,9 @@ export async function upload(config: UploadConfig) {
4344async function uploadTemplates ( body : FormData , config : UploadConfig ) {
4445 const queryParams = new URLSearchParams ( config . seedRepo ) ;
4546 queryParams . set ( "version" , config . version ) ;
47+ if ( config . latest ) {
48+ queryParams . set ( "latest" , `${ true } ` ) ;
49+ }
4650 const response = await fetchWithRetries (
4751 `${ config . api . endpoint } ?${ queryParams } ` ,
4852 {
You can’t perform that action at this time.
0 commit comments