mirror of
https://github.com/Neur0toxine/bash.im-telegram-bot.git
synced 2024-11-28 08:06:06 +03:00
Added clean goal
This commit is contained in:
parent
37d6d7baf7
commit
04e287ee17
6
Makefile
6
Makefile
@ -9,7 +9,11 @@ BIN=$(PROJECT_DIR)/bin/bash_im_bot
|
|||||||
build: fmt deps
|
build: fmt deps
|
||||||
@echo "- Building"
|
@echo "- Building"
|
||||||
@cd $(SRC) && $(GO) build -o $(BIN)
|
@cd $(SRC) && $(GO) build -o $(BIN)
|
||||||
@echo Built "$(BIN)"
|
@echo - Built "$(BIN)"
|
||||||
|
|
||||||
|
clean:
|
||||||
|
@echo Cleaning...
|
||||||
|
@rm -rf $(dir ${BIN})
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@$(BIN)
|
@$(BIN)
|
||||||
|
@ -46,11 +46,11 @@ func LoadConfig() (BotConfig, error) {
|
|||||||
dir, err := filepath.Abs(filepath.Dir(os.Args[0]))
|
dir, err := filepath.Abs(filepath.Dir(os.Args[0]))
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Fatal(err)
|
log.Print(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if err := godotenv.Load(filepath.Join(filepath.Dir(dir), ".env")); err != nil {
|
if err := godotenv.Load(filepath.Join(filepath.Dir(dir), ".env")); err != nil {
|
||||||
return cfg, err
|
log.Print(err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user