Skip to content

Commit 41302a6

Browse files
committed
refactor: restructure project to follow Go conventions
1 parent 06457ae commit 41302a6

15 files changed

Lines changed: 18 additions & 18 deletions

File tree

File renamed without changes.
File renamed without changes.

src/main.go renamed to cmd/commit-msg/main.go

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,14 @@ import (
55
"os"
66

77
"github.com/atotto/clipboard"
8-
"github.com/dfanso/commit-msg/src/chatgpt"
9-
"github.com/dfanso/commit-msg/src/claude"
10-
"github.com/dfanso/commit-msg/src/gemini"
11-
"github.com/dfanso/commit-msg/src/grok"
12-
"github.com/dfanso/commit-msg/src/internal/display"
13-
"github.com/dfanso/commit-msg/src/internal/git"
14-
"github.com/dfanso/commit-msg/src/internal/stats"
15-
"github.com/dfanso/commit-msg/src/types"
8+
"github.com/dfanso/commit-msg/internal/chatgpt"
9+
"github.com/dfanso/commit-msg/internal/claude"
10+
"github.com/dfanso/commit-msg/internal/display"
11+
"github.com/dfanso/commit-msg/internal/gemini"
12+
"github.com/dfanso/commit-msg/internal/git"
13+
"github.com/dfanso/commit-msg/internal/grok"
14+
"github.com/dfanso/commit-msg/internal/stats"
15+
"github.com/dfanso/commit-msg/pkg/types"
1616
"github.com/pterm/pterm"
1717
)
1818

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
openai "github.com/openai/openai-go/v3"
88
"github.com/openai/openai-go/v3/option"
99

10-
"github.com/dfanso/commit-msg/src/types"
10+
"github.com/dfanso/commit-msg/pkg/types"
1111
)
1212

1313
func GenerateCommitMessage(config *types.Config, changes string, apiKey string) (string, error) {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
"fmt"
88
"net/http"
99

10-
"github.com/dfanso/commit-msg/src/types"
10+
"github.com/dfanso/commit-msg/pkg/types"
1111
)
1212

1313
type ClaudeRequest struct {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
"github.com/google/generative-ai-go/genai"
88
"google.golang.org/api/option"
99

10-
"github.com/dfanso/commit-msg/src/types"
10+
"github.com/dfanso/commit-msg/pkg/types"
1111
)
1212

1313
func GenerateCommitMessage(config *types.Config, changes string, apiKey string) (string, error) {
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ import (
77
"path/filepath"
88
"strings"
99

10-
"github.com/dfanso/commit-msg/src/internal/scrubber"
11-
"github.com/dfanso/commit-msg/src/internal/utils"
12-
"github.com/dfanso/commit-msg/src/types"
10+
"github.com/dfanso/commit-msg/internal/scrubber"
11+
"github.com/dfanso/commit-msg/internal/utils"
12+
"github.com/dfanso/commit-msg/pkg/types"
1313
)
1414

1515
// IsRepository checks if a directory is a git repository
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99
"net/http"
1010
"time"
1111

12-
"github.com/dfanso/commit-msg/src/types"
12+
"github.com/dfanso/commit-msg/pkg/types"
1313
)
1414

1515
func GenerateCommitMessage(config *types.Config, changes string, apiKey string) (string, error) {

0 commit comments

Comments
 (0)