Skip to content
This repository has been archived by the owner on Jul 20, 2024. It is now read-only.

Commit

Permalink
trying to fix botway init command
Browse files Browse the repository at this point in the history
  • Loading branch information
abdfnx committed Sep 18, 2022
1 parent 3bb88a3 commit 93de2e5
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 25 deletions.
36 changes: 16 additions & 20 deletions botway.json
Original file line number Diff line number Diff line change
@@ -1,22 +1,18 @@
{
"version": "0.1.95",
"architecture": {
"32bit": {
"url": "https://github.com/abdfnx/botway/releases/download/v0.1.95/botway_windows_v0.1.95_386.zip",
"bin": [
"bin/botway.exe"
],
"hash": "d25820adbc7f8ac55a287ea82615cfe6019a7a5642be4203404295ce4202f69d"
},
"64bit": {
"url": "https://github.com/abdfnx/botway/releases/download/v0.1.95/botway_windows_v0.1.95_amd64.zip",
"bin": [
"bin/botway.exe"
],
"hash": "386d276ad5c8f3f6ac87ba5f4ea09c3b3033967a61d5c735659fa35b308bcb07"
}
"version": "0.1.95",
"architecture": {
"32bit": {
"url": "https://github.com/abdfnx/botway/releases/download/v0.1.95/botway_windows_v0.1.95_386.zip",
"bin": ["bin/botway.exe"],
"hash": "d25820adbc7f8ac55a287ea82615cfe6019a7a5642be4203404295ce4202f69d"
},
"homepage": "https://botway.web.app",
"license": "MIT",
"description": "🤖 Generate, build, handle and deploy your own bot with your favorite language, for Discord, or Telegram, or Slack"
}
"64bit": {
"url": "https://github.com/abdfnx/botway/releases/download/v0.1.95/botway_windows_v0.1.95_amd64.zip",
"bin": ["bin/botway.exe"],
"hash": "386d276ad5c8f3f6ac87ba5f4ea09c3b3033967a61d5c735659fa35b308bcb07"
}
},
"homepage": "https://botway.web.app",
"license": "MIT",
"description": "🤖 Generate, build, handle and deploy your own bot with your favorite language, for Discord, or Telegram, or Slack"
}
12 changes: 7 additions & 5 deletions cmd/app/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,13 @@ func InitCMD() *cobra.Command {
Aliases: []string{"."},
}

if botwaygo.GetBotInfo("bot.host") == "railway.app" {
cmd.RunE = Contextualize(handler.DockerInit, handler.Panic)
} else if botwaygo.GetBotInfo("bot.host") == "render.com" {
cmd.Run = func(cmd *cobra.Command, args []string) {
initx.DockerInit()
if opts.Docker {
if botwaygo.GetBotInfo("bot.host") == "railway.app" {
cmd.RunE = Contextualize(handler.DockerInit, handler.Panic)
} else if botwaygo.GetBotInfo("bot.host") == "render.com" {
cmd.Run = func(cmd *cobra.Command, args []string) {
initx.DockerInit()
}
}
} else {
cmd.Run = func(cmd *cobra.Command, args []string) {
Expand Down

0 comments on commit 93de2e5

Please sign in to comment.