Import other modules into monorepo
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
22
src/cli/templates/config.ts
Normal file
22
src/cli/templates/config.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
import {Template} from "../Template"
|
||||
import {UniversalPath} from "../../util"
|
||||
|
||||
/**
|
||||
* A template that generates a new configuration file in the app/configs directory.
|
||||
*/
|
||||
const config_template: Template = {
|
||||
name: 'config',
|
||||
fileSuffix: '.config.ts',
|
||||
description: 'Create a new config file.',
|
||||
baseAppPath: ['configs'],
|
||||
render(name: string, fullCanonicalName: string, targetFilePath: UniversalPath) {
|
||||
return `import { env } from '@extollo/lib'
|
||||
|
||||
export default {
|
||||
key: env('VALUE_ENV_VAR', 'default value'),
|
||||
}
|
||||
`
|
||||
}
|
||||
}
|
||||
|
||||
export { config_template }
|
||||
Reference in New Issue
Block a user