Skip to content

Commit

Permalink
feat(cli): init app support sync data (#895)
Browse files Browse the repository at this point in the history
  • Loading branch information
skyoct authored Mar 13, 2023
1 parent 561fe7f commit 449abde
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion cli/src/action/application/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ import * as Table from 'cli-table3'
import { ApplicationConfig, existApplicationConfig, writeApplicationConfig } from '../../config/application'
import * as path from 'node:path'
import * as fs from 'node:fs'
import { pull as depPull } from '../dependency'
import { pullAll as policyPull } from '../policy'
import { pullAll as funcPull } from '../function'

import {
FUNCTIONS_DIRECTORY_NAME,
Expand Down Expand Up @@ -66,7 +69,12 @@ export async function init(appid: string, options: { sync: boolean }) {
refreshSecretConfig()

if (options.sync) {
// TODO: sync
// pull dependencies
depPull()
// pull policies
policyPull()
// pull functions
funcPull()
}
console.log(`${getEmoji('🚀')} application ${data.name} init success`)
}
Expand Down

0 comments on commit 449abde

Please sign in to comment.