After the new feature is done, if you added a new commitType
, make sure to update gbc.conf
and add it to update.go
, for example:
// updateCmd represents the update command
var updateCmd = &cobra.Command{
Use: "update",
Short: "Update gbc to the latest version available.",
Long: `Update gbc to the latest version available.`,
Run: func(cmd *cobra.Command, args []string) {
if !config.IsLatestVersion(GBC_VERSION) {
option := config.Option{Type: "rebuild", Value: ":eyes:"}
config.UpdateEmojiSettings("gbc.conf", option, true)
fmt.Println("It is not the latest version")
} else {
fmt.Println("It is the latest version")
}
},
}
If you add a new config
, also make sure you also update the gbc.conf
and add it to update.go
, for example:
// updateCmd represents the update command
var updateCmd = &cobra.Command{
Use: "update",
Short: "Update gbc to the latest version available.",
Long: `Update gbc to the latest version available.`,
Run: func(cmd *cobra.Command, args []string) {
if !config.IsLatestVersion(GBC_VERSION) {
option := config.Option{Comment: "Testing", Type: "hello", Value: "world"}
config.AddNewSetting("gbc.conf", option, true)
fmt.Println("It is not the latest version")
} else {
fmt.Println("It is the latest version")
}
},
}