Skip to content
This repository has been archived by the owner on Dec 5, 2023. It is now read-only.

Commit

Permalink
Rename go module
Browse files Browse the repository at this point in the history
  • Loading branch information
dcdunkan authored and Satont committed Oct 5, 2022
1 parent 30e6d71 commit df1cf64
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ TODO: Release executables
Install using [Go](https://go.dev).

```shell
go install github.com/grammyjs/gmy@latest
go install github.com/grammyjs/create-grammy@latest
```

After installation, run **gmy** command to use the tool. You can provide a
Expand Down
12 changes: 6 additions & 6 deletions cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ import (
"fmt"
"os"

"github.com/grammyjs/gmy/internal/files"
"github.com/grammyjs/gmy/internal/prompts/additional"
"github.com/grammyjs/gmy/internal/prompts/name"
"github.com/grammyjs/gmy/internal/prompts/platform"
template_ "github.com/grammyjs/gmy/internal/prompts/template"
"github.com/grammyjs/create-grammy/internal/files"
"github.com/grammyjs/create-grammy/internal/prompts/additional"
"github.com/grammyjs/create-grammy/internal/prompts/name"
"github.com/grammyjs/create-grammy/internal/prompts/platform"
template_ "github.com/grammyjs/create-grammy/internal/prompts/template"

"github.com/spf13/cobra"
)
Expand Down Expand Up @@ -59,7 +59,7 @@ This application is a tool to generate the needed files to quickly
create a Telegram bot from several templates powered by grammY.
Feel free to add more templates to our template registry:
https://github.com/grammyjs/gmy#templates
https://github.com/grammyjs/create-grammy#templates
https://grammy.dev`,
Args: cobra.ArbitraryArgs,
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/grammyjs/gmy
module github.com/grammyjs/create-grammy

go 1.19

Expand Down
2 changes: 1 addition & 1 deletion internal/files/setup_files.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"

"github.com/cavaliergopher/grab/v3"
t "github.com/grammyjs/gmy/internal/templates"
t "github.com/grammyjs/create-grammy/internal/templates"
)

func SetupFiles(projectName string, template t.Template) {
Expand Down
8 changes: 4 additions & 4 deletions internal/prompts/additional/additional.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ import (
"github.com/cavaliergopher/grab/v3"
"github.com/erikgeiser/promptkit/confirmation"
"github.com/erikgeiser/promptkit/selection"
"github.com/grammyjs/gmy/internal/files"
"github.com/grammyjs/gmy/internal/utils"
"github.com/grammyjs/create-grammy/internal/files"
"github.com/grammyjs/create-grammy/internal/utils"

t "github.com/grammyjs/gmy/internal/templates"
t "github.com/grammyjs/create-grammy/internal/templates"
)

func Prompt(name string, platform string, template t.Template) {
Expand All @@ -29,7 +29,7 @@ func Prompt(name string, platform string, template t.Template) {
tscPrompt := confirmation.New(" ? Would you like to add TypeScript configuration file", confirmation.No)
tsc, err := tscPrompt.RunPrompt()
if err != nil && tsc {
_, err := grab.Get(name, "https://raw.githubusercontent.com/grammyjs/cli/main/configs/tsconfig.json")
_, err := grab.Get(name, "https://raw.githubusercontent.com/grammyjs/create-grammy/main/configs/tsconfig.json")
if err != nil {
fmt.Println(" - Skipping... Failed to add a tsconfig.json.")
}
Expand Down
2 changes: 1 addition & 1 deletion internal/prompts/name/name.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"strings"

"github.com/erikgeiser/promptkit/textinput"
"github.com/grammyjs/gmy/internal/files"
"github.com/grammyjs/create-grammy/internal/files"
)

func Prompt() string {
Expand Down
2 changes: 1 addition & 1 deletion internal/prompts/template/template.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"

"github.com/erikgeiser/promptkit/selection"
t "github.com/grammyjs/gmy/internal/templates"
t "github.com/grammyjs/create-grammy/internal/templates"
)

func Prompt(platform string) t.Template {
Expand Down
4 changes: 2 additions & 2 deletions internal/templates/templates.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"fmt"
"strings"

"github.com/grammyjs/gmy/internal/utils"
"github.com/grammyjs/create-grammy/internal/utils"
)

type Template struct {
Expand All @@ -25,7 +25,7 @@ type Template struct {

func GetTemplates(platform string) ([]Template, error) {
var results map[string][]Template
url := "https://raw.githubusercontent.com/dcdunkan/gmy/main/templates.json"
url := "https://raw.githubusercontent.com/grammyjs/create-grammy/main/templates.json"
err := utils.FetchJson(url, &results)
if err != nil {
return nil, errors.New("failed to fetch templates")
Expand Down

0 comments on commit df1cf64

Please sign in to comment.