package kr.lunaticbum.back.lun import org.springframework.beans.factory.annotation.Value import org.springframework.boot.autoconfigure.SpringBootApplication import org.springframework.boot.runApplication import org.springframework.context.EnvironmentAware import org.springframework.core.env.Environment import org.springframework.scheduling.annotation.EnableScheduling import org.springframework.stereotype.Component @EnableScheduling // 추가 @SpringBootApplication class LunApplication() { } //@Component //class GEnv : EnvironmentAware { // @Value("\${telegram.bot.key}") // var telegramBotKey: String? = "" // // @Value("\${telegram.my.id}") // var telegramMyId: String? = "" // // @Value("\${weather.api.key}") // var weatherApiKey: String? = "" // // // override fun setEnvironment(environment: Environment) { // println ("telegramBotKey $telegramBotKey") // println("telegramMyId $telegramMyId") // println("weatherApiKey $weatherApiKey") // } //} fun main(args: Array) { // val props = System.getProperties() // val enumerator = props.keys() // while (enumerator.hasMoreElements()) { // val ele = enumerator.nextElement() // val key = ele.toString() // println(key + ": " + System.getProperty(key)) // } args.forEach { println("main ARG >> $it") } runApplication(*args) } // //@SpringBootApplication //class Application { // @Bean // fun commandLineRunner(ctx: ApplicationContext): CommandLineRunner { // return CommandLineRunner { args: Array? -> // println("Let's inspect the beans provided by Spring Boot:") // val beanNames: Array = ctx.getBeanDefinitionNames() // Arrays.sort(beanNames) // for (beanName in beanNames) { // println(beanName) // } // } // } // // companion object { // @JvmStatic // fun main(args: Array) { // SpringApplication.run(Application::class.java, *args) // } // } //}