Repository: nao1215/sqluv
Pull request #25: feat: support http/https protocol
Author: login: nao1215
Created: 2025-03-21T14:01:11Z | Merged: 2025-03-21T14:09:07Z



<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
## Summary by CodeRabbit

- **Documentation**
  - Enhanced the user guide to clearly outline file handling, now supporting local, HTTP, and HTTPS formats with updated usage warnings.

- **New Features**
  - Improved file viewing capabilities by enabling protocol-based file access and seamless URL generation for a streamlined experience.

- **Tests**
  - Expanded test coverage to ensure robust file reading operations and correct behavior across multiple protocols.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->


Diff:
diff --git a/README.md b/README.md
index 58de195..7391f57 100644
--- a/README.md
+++ b/README.md
@@ -1,11 +1,11 @@
 ![dbms_demo](doc/image/dbms_demo.gif)
 
-The **sqluv (sql + love)** provides a simple text user interface for multiple DBMSs and local CSV/TSV/LTSV files. You execute SQL queries for the connected DBMS or local files. The sqluv has the color theme feature, so you can change the color theme to your liking.
+The **sqluv (sql + love)** provides a simple text user interface for multiple DBMSs and local/http/https CSV/TSV/LTSV files. You execute SQL queries for the connected DBMS or local/http/https files. The sqluv has the color theme feature, so you can change the color theme to your liking.
 
 The sqluv is a command derived from [nao1215/sqly](https://github.com/nao1215/sqly). Its starting point is to provide a more user-friendly interface for writing SQL compared to sqly.
 
 >[!WARNING]
-> sqluv is under development. Do not execute UPDATE or DELETE in the production environment. sqluv can not update or delete data in the local file, but it can update or delete data in the connected DBMS.
+> sqluv is under development. You use sqluv for **viewer**. Do not execute UPDATE or DELETE in the production environment. sqluv can not update or delete data in the local file, but it can update or delete data in the connected DBMS.
 
 ## How to install
 ### Use "go install"
@@ -20,15 +20,11 @@ go install github.com/nao1215/sqluv@latest
 brew install nao1215/tap/sqluv
 ```
 
-## Supported OS, DBMS, go version
+## Supported OS, File Format, DBMS, go version
 
-- Windows
-- macOS
-- Linux
-- MySQL
-- PostgreSQL
-- SQLite3
-- SQL Server
+- Windows/macOS/Linux
+- CSV/TSV/LTSV (file://, http://, https://)
+- MySQL/PostgreSQL/SQLite3/SQL Server
 - go1.24 or later
 
 ## How to use
@@ -36,11 +32,9 @@ brew install nao1215/tap/sqluv
 ### Syntax
 
 ```shell
-sqluv [FILE_PATHS]
+sqluv [FILE_PATHS/HTTP URL/HTTPS URL]  ※ Supported file formats: CSV, TSV, LTSV
 ```
 
-※ Supported file formats: CSV, TSV, LTSV
-
 ### Connect to DBMS
 
 When you start the sqluv command without specifying a file path, the following screen will appear. 
@@ -70,8 +64,7 @@ If you select a history, the SQL query will be copied to the query text area.
 
 ### Read from a file
 
-Please specify a file path when executing the sqluv command. The file will be loaded before launching the TUI.
-If you start the sqluv command without specifying a file path, it will enter DBMS connection mode, and local files cannot be loaded.
+Please specify a file path (or url) when executing the sqluv command. The file will be loaded before launching the TUI. When the sqluv import csv/tsv/ltsv, the sqluv checks the file extension and determines the file format. If the file extension is not csv/tsv/ltsv, the sqluv will display an error message. The sqluv does not automatically detect the file format.
 
 ![sqluv_demo](./doc/image/demo.gif)
 
diff --git a/domain/model/file.go b/domain/model/file.go
index cb02b70..0d460a7 100644
--- a/domain/model/file.go
+++ b/domain/model/file.go
@@ -11,17 +11,31 @@ import (
 type File struct {
 	// path is file path.
 	path string
+	// protocol is file protocol.
+	protocol string
 }
 
 // NewFile create new File.
+// If path is empty, return error.
+// If path does not contain protocol, add file:// protocol.
 func NewFile(
 	path string,
 ) (*File, error) {
 	if path == "" {
 		return nil, errors.New("file path is empty")
 	}
+
+	protocol := ""
+	if !strings.Contains(path, "://") {
+		protocol = "file://"
+	} else {
+		protocol = strings.Split(path, "://")[0] + "://"
+		path = strings.Split(path, "://")[1]
+	}
+
 	return &File{
-		path: path,
+		path:     path,
+		protocol: protocol,
 	}, nil
 }
 
@@ -59,3 +73,18 @@ func (f *File) NameWithoutExt() string {
 	}
 	return strings.TrimSuffix(filename, ext)
 }
+
+// IsFileProtocol return true if file protocol is file://.
+func (f *File) IsFileProtocol() bool {
+	return f.protocol == "file://"
+}
+
+// IsHTTPProtocol return true if file protocol is http:// or https://.
+func (f *File) IsHTTPProtocol() bool {
+	return f.protocol == "http://" || f.protocol == "https://"
+}
+
+// FullURL return full URL.
+func (f *File) FullURL() string {
+	return f.protocol + f.path
+}
diff --git a/domain/model/file_test.go b/domain/model/file_test.go
index 9b6b421..7102cd5 100644
--- a/domain/model/file_test.go
+++ b/domain/model/file_test.go
@@ -22,6 +22,26 @@ func TestNewFile(t *testing.T) {
 		if f.path != path {
 			t.Errorf("path is wrong. got: %s, want: %s", f.path, path)
 		}
+		if f.protocol != "file://" {
+			t.Errorf("protocol is wrong. got: %s, want: file://", f.protocol)
+		}
+	})
+
+	t.Run("success to create File with protocol", func(t *testing.T) {
+		t.Parallel()
+
+		path := "file:///path/to/file"
+		f, err := NewFile(path)
+		if err != nil {
+			t.Errorf("error should be nil. got: %v", err)
+		}
+
+		if f.path != "/path/to/file" {
+			t.Errorf("path is wrong. got: %s, want: %s", f.path, path)
+		}
+		if f.protocol != "file://" {
+			t.Errorf("protocol is wrong. got: %s, want: ", f.protocol)
+		}
 	})
 
 	t.Run("fail to create File", func(t *testing.T) {
@@ -247,3 +267,115 @@ func TestFileNameWithoutExt(t *testing.T) {
 		})
 	}
 }
+
+func TestFile_IsFileProtocol(t *testing.T) {
+	t.Parallel()
+
+	type fields struct {
+		path     string
+		protocol string
+	}
+	tests := []struct {
+		name   string
+		fields fields
+		want   bool
+	}{
+		{
+			name: "file protocol",
+			fields: fields{
+				path:     "path/to/file",
+				protocol: "file://",
+			},
+			want: true,
+		},
+		{
+			name: "not file protocol",
+			fields: fields{
+				path:     "path/to/file",
+				protocol: "http://",
+			},
+			want: false,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			t.Parallel()
+
+			f := &File{
+				path:     tt.fields.path,
+				protocol: tt.fields.protocol,
+			}
+			if got := f.IsFileProtocol(); got != tt.want {
+				t.Errorf("File.IsFileProtocol() = %v, want %v", got, tt.want)
+			}
+		})
+	}
+}
+
+func TestFile_IsHTTPProtocol(t *testing.T) {
+	t.Parallel()
+
+	type fields struct {
+		path     string
+		protocol string
+	}
+	tests := []struct {
+		name   string
+		fields fields
+		want   bool
+	}{
+		{
+			name: "http protocol",
+			fields: fields{
+				path:     "path/to/file",
+				protocol: "http://",
+			},
+			want: true,
+		},
+		{
+			name: "https protocol",
+			fields: fields{
+				path:     "path/to/file",
+				protocol: "https://",
+			},
+			want: true,
+		},
+		{
+			name: "not http protocol",
+			fields: fields{
+				path:     "path/to/file",
+				protocol: "file://",
+			},
+			want: false,
+		},
+	}
+	for _, tt := range tests {
+		t.Run(tt.name, func(t *testing.T) {
+			t.Parallel()
+			f := &File{
+				path:     tt.fields.path,
+				protocol: tt.fields.protocol,
+			}
+			if got := f.IsHTTPProtocol(); got != tt.want {
+				t.Errorf("File.IsHTTPProtocol() = %v, want %v", got, tt.want)
+			}
+		})
+	}
+}
+
+func TestFile_FullURL(t *testing.T) {
+	t.Parallel()
+
+	t.Run("get full URL", func(t *testing.T) {
+		t.Parallel()
+
+		f := &File{
+			path:     "/path/to/file",
+			protocol: "http://",
+		}
+		want := "http:///path/to/file"
+		if got := f.FullURL(); got != want {
+			t.Errorf("File.FullURL() = %v, want %v", got, want)
+		}
+	})
+}
diff --git a/domain/repository/file.go b/domain/repository/file.go
index 268f385..656cb4b 100644
--- a/domain/repository/file.go
+++ b/domain/repository/file.go
@@ -2,6 +2,8 @@
 package repository
 
 import (
+	"context"
+
 	"github.com/nao1215/sqluv/domain/model"
 )
 
@@ -10,16 +12,16 @@ import (
 type (
 	// CSVReader is an interface for reading records from CSV files and returning them as model.Table.
 	CSVReader interface {
-		ReadCSV(file *model.File) (*model.Table, error)
+		ReadCSV(ctx context.Context, file *model.File) (*model.Table, error)
 	}
 
 	// TSVReader is an interface for reading records from TSV files and returning them as model.Table.
 	TSVReader interface {
-		ReadTSV(file *model.File) (*model.Table, error)
+		ReadTSV(ctx context.Context, file *model.File) (*model.Table, error)
 	}
 
 	// LTSVReader is an interface for reading records from LTSV files and returning them as model.Table.
 	LTSVReader interface {
-		ReadLTSV(file *model.File) (*model.Table, error)
+		ReadLTSV(ctx context.Context, file *model.File) (*model.Table, error)
 	}
 )
diff --git a/infrastructure/mock/file.go b/infrastructure/mock/file.go
index fad153c..acf463a 100644
--- a/infrastructure/mock/file.go
+++ b/infrastructure/mock/file.go
@@ -10,6 +10,7 @@
 package mock
 
 import (
+	context "context"
 	reflect "reflect"
 
 	model "github.com/nao1215/sqluv/domain/model"
@@ -41,18 +42,18 @@ func (m *MockCSVReader) EXPECT() *MockCSVReaderMockRecorder {
 }
 
 // ReadCSV mocks base method.
-func (m *MockCSVReader) ReadCSV(file *model.File) (*model.Table, error) {
+func (m *MockCSVReader) ReadCSV(ctx context.Context, file *model.File) (*model.Table, error) {
 	m.ctrl.T.Helper()
-	ret := m.ctrl.Call(m, "ReadCSV", file)
+	ret := m.ctrl.Call(m, "ReadCSV", ctx, file)
 	ret0, _ := ret[0].(*model.Table)
 	ret1, _ := ret[1].(error)
 	return ret0, ret1
 }
 
 // ReadCSV indicates an expected call of ReadCSV.
-func (mr *MockCSVReaderMockRecorder) ReadCSV(file any) *MockCSVReaderReadCSVCall {
+func (mr *MockCSVReaderMockRecorder) ReadCSV(ctx, file any) *MockCSVReaderReadCSVCall {
 	mr.mock.ctrl.T.Helper()
-	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadCSV", reflect.TypeOf((*MockCSVReader)(nil).ReadCSV), file)
+	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadCSV", reflect.TypeOf((*MockCSVReader)(nil).ReadCSV), ctx, file)
 	return &MockCSVReaderReadCSVCall{Call: call}
 }
 
@@ -68,13 +69,13 @@ func (c *MockCSVReaderReadCSVCall) Return(arg0 *model.Table, arg1 error) *MockCS
 }
 
 // Do rewrite *gomock.Call.Do
-func (c *MockCSVReaderReadCSVCall) Do(f func(*model.File) (*model.Table, error)) *MockCSVReaderReadCSVCall {
+func (c *MockCSVReaderReadCSVCall) Do(f func(context.Context, *model.File) (*model.Table, error)) *MockCSVReaderReadCSVCall {
 	c.Call = c.Call.Do(f)
 	return c
 }
 
 // DoAndReturn rewrite *gomock.Call.DoAndReturn
-func (c *MockCSVReaderReadCSVCall) DoAndReturn(f func(*model.File) (*model.Table, error)) *MockCSVReaderReadCSVCall {
+func (c *MockCSVReaderReadCSVCall) DoAndReturn(f func(context.Context, *model.File) (*model.Table, error)) *MockCSVReaderReadCSVCall {
 	c.Call = c.Call.DoAndReturn(f)
 	return c
 }
@@ -104,18 +105,18 @@ func (m *MockTSVReader) EXPECT() *MockTSVReaderMockRecorder {
 }
 
 // ReadTSV mocks base method.
-func (m *MockTSVReader) ReadTSV(file *model.File) (*model.Table, error) {
+func (m *MockTSVReader) ReadTSV(ctx context.Context, file *model.File) (*model.Table, error) {
 	m.ctrl.T.Helper()
-	ret := m.ctrl.Call(m, "ReadTSV", file)
+	ret := m.ctrl.Call(m, "ReadTSV", ctx, file)
 	ret0, _ := ret[0].(*model.Table)
 	ret1, _ := ret[1].(error)
 	return ret0, ret1
 }
 
 // ReadTSV indicates an expected call of ReadTSV.
-func (mr *MockTSVReaderMockRecorder) ReadTSV(file any) *MockTSVReaderReadTSVCall {
+func (mr *MockTSVReaderMockRecorder) ReadTSV(ctx, file any) *MockTSVReaderReadTSVCall {
 	mr.mock.ctrl.T.Helper()
-	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadTSV", reflect.TypeOf((*MockTSVReader)(nil).ReadTSV), file)
+	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadTSV", reflect.TypeOf((*MockTSVReader)(nil).ReadTSV), ctx, file)
 	return &MockTSVReaderReadTSVCall{Call: call}
 }
 
@@ -131,13 +132,13 @@ func (c *MockTSVReaderReadTSVCall) Return(arg0 *model.Table, arg1 error) *MockTS
 }
 
 // Do rewrite *gomock.Call.Do
-func (c *MockTSVReaderReadTSVCall) Do(f func(*model.File) (*model.Table, error)) *MockTSVReaderReadTSVCall {
+func (c *MockTSVReaderReadTSVCall) Do(f func(context.Context, *model.File) (*model.Table, error)) *MockTSVReaderReadTSVCall {
 	c.Call = c.Call.Do(f)
 	return c
 }
 
 // DoAndReturn rewrite *gomock.Call.DoAndReturn
-func (c *MockTSVReaderReadTSVCall) DoAndReturn(f func(*model.File) (*model.Table, error)) *MockTSVReaderReadTSVCall {
+func (c *MockTSVReaderReadTSVCall) DoAndReturn(f func(context.Context, *model.File) (*model.Table, error)) *MockTSVReaderReadTSVCall {
 	c.Call = c.Call.DoAndReturn(f)
 	return c
 }
@@ -167,18 +168,18 @@ func (m *MockLTSVReader) EXPECT() *MockLTSVReaderMockRecorder {
 }
 
 // ReadLTSV mocks base method.
-func (m *MockLTSVReader) ReadLTSV(file *model.File) (*model.Table, error) {
+func (m *MockLTSVReader) ReadLTSV(ctx context.Context, file *model.File) (*model.Table, error) {
 	m.ctrl.T.Helper()
-	ret := m.ctrl.Call(m, "ReadLTSV", file)
+	ret := m.ctrl.Call(m, "ReadLTSV", ctx, file)
 	ret0, _ := ret[0].(*model.Table)
 	ret1, _ := ret[1].(error)
 	return ret0, ret1
 }
 
 // ReadLTSV indicates an expected call of ReadLTSV.
-func (mr *MockLTSVReaderMockRecorder) ReadLTSV(file any) *MockLTSVReaderReadLTSVCall {
+func (mr *MockLTSVReaderMockRecorder) ReadLTSV(ctx, file any) *MockLTSVReaderReadLTSVCall {
 	mr.mock.ctrl.T.Helper()
-	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadLTSV", reflect.TypeOf((*MockLTSVReader)(nil).ReadLTSV), file)
+	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadLTSV", reflect.TypeOf((*MockLTSVReader)(nil).ReadLTSV), ctx, file)
 	return &MockLTSVReaderReadLTSVCall{Call: call}
 }
 
@@ -194,13 +195,13 @@ func (c *MockLTSVReaderReadLTSVCall) Return(arg0 *model.Table, arg1 error) *Mock
 }
 
 // Do rewrite *gomock.Call.Do
-func (c *MockLTSVReaderReadLTSVCall) Do(f func(*model.File) (*model.Table, error)) *MockLTSVReaderReadLTSVCall {
+func (c *MockLTSVReaderReadLTSVCall) Do(f func(context.Context, *model.File) (*model.Table, error)) *MockLTSVReaderReadLTSVCall {
 	c.Call = c.Call.Do(f)
 	return c
 }
 
 // DoAndReturn rewrite *gomock.Call.DoAndReturn
-func (c *MockLTSVReaderReadLTSVCall) DoAndReturn(f func(*model.File) (*model.Table, error)) *MockLTSVReaderReadLTSVCall {
+func (c *MockLTSVReaderReadLTSVCall) DoAndReturn(f func(context.Context, *model.File) (*model.Table, error)) *MockLTSVReaderReadLTSVCall {
 	c.Call = c.Call.DoAndReturn(f)
 	return c
 }
diff --git a/infrastructure/persistence/file.go b/infrastructure/persistence/file.go
index 07a6fd2..a656828 100644
--- a/infrastructure/persistence/file.go
+++ b/infrastructure/persistence/file.go
@@ -1,8 +1,11 @@
 package persistence
 
 import (
+	"context"
 	"encoding/csv"
+	"fmt"
 	"io"
+	"net/http"
 	"path/filepath"
 	"strings"
 
@@ -22,14 +25,14 @@ func NewCSVReader() repository.CSVReader {
 }
 
 // ReadCSV read records from CSV files and return them as model.CSV.
-func (c *csvReader) ReadCSV(file *model.File) (*model.Table, error) {
-	f, err := file.Open()
+func (c *csvReader) ReadCSV(ctx context.Context, file *model.File) (*model.Table, error) {
+	ioReader, closer, err := ioReader(ctx, file)
 	if err != nil {
 		return nil, err
 	}
-	defer f.Close()
+	defer closer()
 
-	r := csv.NewReader(f)
+	r := csv.NewReader(ioReader)
 	header := model.Header{}
 	records := []model.Record{}
 	for {
@@ -59,14 +62,14 @@ func NewTSVReader() repository.TSVReader {
 }
 
 // ReadTSV read records from TSV files and return them as model.TSV.
-func (t *tsvReader) ReadTSV(file *model.File) (*model.Table, error) {
-	f, err := file.Open()
+func (t *tsvReader) ReadTSV(ctx context.Context, file *model.File) (*model.Table, error) {
+	ioReader, closer, err := ioReader(ctx, file)
 	if err != nil {
 		return nil, err
 	}
-	defer f.Close()
+	defer closer()
 
-	r := csv.NewReader(f)
+	r := csv.NewReader(ioReader)
 	r.Comma = '\t'
 
 	header := model.Header{}
@@ -98,14 +101,14 @@ func NewLTSVReader() repository.LTSVReader {
 }
 
 // ReadLTSV read records from LTSV files and return them as model.LTSV.
-func (l *ltsvReader) ReadLTSV(file *model.File) (*model.Table, error) {
-	f, err := file.Open()
+func (l *ltsvReader) ReadLTSV(ctx context.Context, file *model.File) (*model.Table, error) {
+	ioReader, closer, err := ioReader(ctx, file)
 	if err != nil {
 		return nil, err
 	}
-	defer f.Close()
+	defer closer()
 
-	r := csv.NewReader(f)
+	r := csv.NewReader(ioReader)
 	r.Comma = '\t'
 
 	label := model.Label{}
@@ -146,3 +149,30 @@ func (l *ltsvReader) labelAndData(s string) (string, string, error) {
 	}
 	return s[:idx], s[idx+1:], nil
 }
+
+// ioReader returns io.Reader, closer and error.
+// If file is HTTP protocol, it returns io.Reader from HTTP response body.
+// If file is not HTTP protocol, it returns io.Reader from file.
+func ioReader(ctx context.Context, file *model.File) (io.Reader, func() error, error) {
+	if file.IsHTTPProtocol() {
+		// Assume FullURL returns the full URL (e.g. "https://example.com/path/to/file").
+		req, err := http.NewRequestWithContext(ctx, http.MethodGet, file.FullURL(), nil)
+		if err != nil {
+			return nil, nil, err
+		}
+		resp, err := http.DefaultClient.Do(req)
+		if err != nil {
+			return nil, nil, err
+		}
+		if resp.StatusCode != http.StatusOK {
+			resp.Body.Close()
+			return nil, nil, fmt.Errorf("remote file request failed with status: %s", resp.Status)
+		}
+		return resp.Body, resp.Body.Close, nil
+	}
+	f, err := file.Open()
+	if err != nil {
+		return nil, nil, err
+	}
+	return f, f.Close, nil
+}
diff --git a/infrastructure/persistence/file_test.go b/infrastructure/persistence/file_test.go
index e0618a8..ac7eae5 100644
--- a/infrastructure/persistence/file_test.go
+++ b/infrastructure/persistence/file_test.go
@@ -2,7 +2,9 @@ package persistence
 
 import (
 	"errors"
+	"io"
 	"path/filepath"
+	"strings"
 	"testing"
 
 	"github.com/google/go-cmp/cmp"
@@ -22,7 +24,7 @@ func TestCSVReaderReadCSV(t *testing.T) {
 		}
 
 		c := NewCSVReader()
-		got, err := c.ReadCSV(file)
+		got, err := c.ReadCSV(t.Context(), file)
 		if err != nil {
 			t.Fatal(err)
 		}
@@ -54,7 +56,7 @@ func TestTSVReaderReadTSV(t *testing.T) {
 		}
 
 		c := NewTSVReader()
-		got, err := c.ReadTSV(file)
+		got, err := c.ReadTSV(t.Context(), file)
 		if err != nil {
 			t.Fatal(err)
 		}
@@ -86,7 +88,7 @@ func TestLTSVReaderReadLTSV(t *testing.T) {
 		}
 
 		c := NewLTSVReader()
-		got, err := c.ReadLTSV(file)
+		got, err := c.ReadLTSV(t.Context(), file)
 		if err != nil {
 			t.Fatal(err)
 		}
@@ -114,8 +116,41 @@ func TestLTSVReaderReadLTSV(t *testing.T) {
 		}
 
 		c := NewLTSVReader()
-		if _, err = c.ReadLTSV(file); !errors.Is(err, infrastructure.ErrNoLabel) {
+		if _, err = c.ReadLTSV(t.Context(), file); !errors.Is(err, infrastructure.ErrNoLabel) {
 			t.Errorf("error is wrong. got: %v, want: %v", err, infrastructure.ErrNoLabel)
 		}
 	})
 }
+
+func TestIOReaderHTTPS(t *testing.T) {
+	t.Parallel()
+
+	t.Run("success to read data from HTTPS", func(t *testing.T) {
+		t.Parallel()
+
+		file, err := model.NewFile("https://raw.githubusercontent.com/nao1215/sqluv/refs/heads/main/testdata/actor.csv")
+		if err != nil {
+			t.Fatalf("failed to create file: %v", err)
+		}
+
+		reader, cleanup, err := ioReader(t.Context(), file)
+		if err != nil {
+			t.Fatalf("ioReader returned error: %v", err)
+		}
+		defer func() {
+			if err := cleanup(); err != nil {
+				t.Errorf("cleanup returned error: %v", err)
+			}
+		}()
+
+		data, err := io.ReadAll(reader)
+		if err != nil {
+			t.Fatalf("failed to read data from reader: %v", err)
+		}
+
+		content := string(data)
+		if !strings.HasPrefix(content, "actor,total_gross") {
+			t.Errorf("unexpected file format, got: %v", content[:20])
+		}
+	})
+}
diff --git a/interactor/file.go b/interactor/file.go
index ee8ea17..717ef8f 100644
--- a/interactor/file.go
+++ b/interactor/file.go
@@ -1,6 +1,8 @@
 package interactor
 
 import (
+	"context"
+
 	"github.com/nao1215/sqluv/domain/model"
 	"github.com/nao1215/sqluv/domain/repository"
 	"github.com/nao1215/sqluv/usecase"
@@ -29,14 +31,14 @@ func NewFileReader(
 }
 
 // Read read records from CSV/TSV/LTSV files and return them as model.Table.
-func (r *fileReader) Read(file *model.File) (*model.Table, error) {
+func (r *fileReader) Read(ctx context.Context, file *model.File) (*model.Table, error) {
 	switch {
 	case file.IsCSV():
-		return r.CSVReader.ReadCSV(file)
+		return r.CSVReader.ReadCSV(ctx, file)
 	case file.IsTSV():
-		return r.TSVReader.ReadTSV(file)
+		return r.TSVReader.ReadTSV(ctx, file)
 	case file.IsLTSV():
-		return r.LTSVReader.ReadLTSV(file)
+		return r.LTSVReader.ReadLTSV(ctx, file)
 	default:
 		return nil, usecase.ErrNotSupportedFileFormat
 	}
diff --git a/interactor/file_test.go b/interactor/file_test.go
index a063386..eaa8105 100644
--- a/interactor/file_test.go
+++ b/interactor/file_test.go
@@ -22,7 +22,7 @@ func TestFileReaderRead(t *testing.T) {
 		csvReader := infrastructure.NewMockCSVReader(ctrl)
 
 		// Set up the expected behavior of the mock.
-		csvReader.EXPECT().ReadCSV(gomock.Any()).Return(
+		csvReader.EXPECT().ReadCSV(gomock.Any(), gomock.Any()).Return(
 			model.NewTable(
 				"test",
 				model.Header([]string{"id", "name"}),
@@ -38,7 +38,7 @@ func TestFileReaderRead(t *testing.T) {
 		if err != nil {
 			t.Errorf("unexpected error: %v", err)
 		}
-		got, err := fileReader.Read(file)
+		got, err := fileReader.Read(t.Context(), file)
 		if err != nil {
 			t.Errorf("unexpected error: %v", err)
 		}
@@ -63,7 +63,7 @@ func TestFileReaderRead(t *testing.T) {
 		tsvReader := infrastructure.NewMockTSVReader(ctrl)
 
 		// Set up the expected behavior of the mock.
-		tsvReader.EXPECT().ReadTSV(gomock.Any()).Return(
+		tsvReader.EXPECT().ReadTSV(gomock.Any(), gomock.Any()).Return(
 			model.NewTable(
 				"test",
 				model.Header([]string{"id", "name"}),
@@ -79,7 +79,7 @@ func TestFileReaderRead(t *testing.T) {
 		if err != nil {
 			t.Errorf("unexpected error: %v", err)
 		}
-		got, err := fileReader.Read(file)
+		got, err := fileReader.Read(t.Context(), file)
 		if err != nil {
 			t.Errorf("unexpected error: %v", err)
 		}
@@ -104,7 +104,7 @@ func TestFileReaderRead(t *testing.T) {
 		ltsvReader := infrastructure.NewMockLTSVReader(ctrl)
 
 		// Set up the expected behavior of the mock.
-		ltsvReader.EXPECT().ReadLTSV(gomock.Any()).Return(
+		ltsvReader.EXPECT().ReadLTSV(gomock.Any(), gomock.Any()).Return(
 			model.NewTable(
 				"test",
 				model.Header([]string{"id", "name"}),
@@ -120,7 +120,7 @@ func TestFileReaderRead(t *testing.T) {
 		if err != nil {
 			t.Errorf("unexpected error: %v", err)
 		}
-		got, err := fileReader.Read(file)
+		got, err := fileReader.Read(t.Context(), file)
 		if err != nil {
 			t.Errorf("unexpected error: %v", err)
 		}
@@ -146,7 +146,7 @@ func TestFileReaderRead(t *testing.T) {
 		if err != nil {
 			t.Errorf("unexpected error: %v", err)
 		}
-		if _, err := fileReader.Read(file); !errors.Is(err, usecase.ErrNotSupportedFileFormat) {
+		if _, err := fileReader.Read(t.Context(), file); !errors.Is(err, usecase.ErrNotSupportedFileFormat) {
 			t.Errorf("unexpected error: %v", err)
 		}
 	})
diff --git a/interactor/mock/file.go b/interactor/mock/file.go
index 172596c..79f23f4 100644
--- a/interactor/mock/file.go
+++ b/interactor/mock/file.go
@@ -10,6 +10,7 @@
 package mock
 
 import (
+	context "context"
 	reflect "reflect"
 
 	model "github.com/nao1215/sqluv/domain/model"
@@ -41,18 +42,18 @@ func (m *MockFileReader) EXPECT() *MockFileReaderMockRecorder {
 }
 
 // Read mocks base method.
-func (m *MockFileReader) Read(file *model.File) (*model.Table, error) {
+func (m *MockFileReader) Read(ctx context.Context, file *model.File) (*model.Table, error) {
 	m.ctrl.T.Helper()
-	ret := m.ctrl.Call(m, "Read", file)
+	ret := m.ctrl.Call(m, "Read", ctx, file)
 	ret0, _ := ret[0].(*model.Table)
 	ret1, _ := ret[1].(error)
 	return ret0, ret1
 }
 
 // Read indicates an expected call of Read.
-func (mr *MockFileReaderMockRecorder) Read(file any) *MockFileReaderReadCall {
+func (mr *MockFileReaderMockRecorder) Read(ctx, file any) *MockFileReaderReadCall {
 	mr.mock.ctrl.T.Helper()
-	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Read", reflect.TypeOf((*MockFileReader)(nil).Read), file)
+	call := mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Read", reflect.TypeOf((*MockFileReader)(nil).Read), ctx, file)
 	return &MockFileReaderReadCall{Call: call}
 }
 
@@ -68,13 +69,13 @@ func (c *MockFileReaderReadCall) Return(arg0 *model.Table, arg1 error) *MockFile
 }
 
 // Do rewrite *gomock.Call.Do
-func (c *MockFileReaderReadCall) Do(f func(*model.File) (*model.Table, error)) *MockFileReaderReadCall {
+func (c *MockFileReaderReadCall) Do(f func(context.Context, *model.File) (*model.Table, error)) *MockFileReaderReadCall {
 	c.Call = c.Call.Do(f)
 	return c
 }
 
 // DoAndReturn rewrite *gomock.Call.DoAndReturn
-func (c *MockFileReaderReadCall) DoAndReturn(f func(*model.File) (*model.Table, error)) *MockFileReaderReadCall {
+func (c *MockFileReaderReadCall) DoAndReturn(f func(context.Context, *model.File) (*model.Table, error)) *MockFileReaderReadCall {
 	c.Call = c.Call.DoAndReturn(f)
 	return c
 }
diff --git a/tui/connection_modal.go b/tui/connection_modal.go
index 3d8b2bf..bc105f1 100644
--- a/tui/connection_modal.go
+++ b/tui/connection_modal.go
@@ -334,5 +334,4 @@ func (cm *connectionModal) applyTheme(theme *Theme) {
 	cm.Modal.SetButtonStyle(tcell.StyleDefault.
 		Background(colors.Button).
 		Foreground(colors.ButtonText))
-
 }
diff --git a/tui/tui.go b/tui/tui.go
index c2c1657..3b4dc65 100644
--- a/tui/tui.go
+++ b/tui/tui.go
@@ -136,7 +136,6 @@ func (t *TUI) Run() error {
 	})
 	t.home.historyButton.SetSelectedFunc(func() {
 		t.showHistoryList()
-
 	})
 	t.refreshAllComponents()
 	return t.app.Run()
@@ -293,7 +292,7 @@ func (t *TUI) importFiles(ctx context.Context) error {
 	}()
 
 	for _, file := range t.files {
-		table, err := t.localUsecases.fileReader.Read(file)
+		table, err := t.localUsecases.fileReader.Read(ctx, file)
 		if err != nil {
 			return err
 		}
diff --git a/usecase/file.go b/usecase/file.go
index 890777d..3f41cbd 100644
--- a/usecase/file.go
+++ b/usecase/file.go
@@ -2,6 +2,8 @@
 package usecase
 
 import (
+	"context"
+
 	"github.com/nao1215/sqluv/domain/model"
 )
 
@@ -10,6 +12,6 @@ import (
 type (
 	// FileReader is an interface for reading records from CSV/TSV/LTSV files and returning them as model.Table.
 	FileReader interface {
-		Read(file *model.File) (*model.Table, error)
+		Read(ctx context.Context, file *model.File) (*model.Table, error)
 	}
 )


Reviews:
user: login: github-actions[bot]
state: COMMENTED
author_association: NONE
submitted_at: 2025-03-21T14:02:24Z

Review comments:
diff_hunk: @@ -11,17 +11,31 @@ import (
 type File struct {
 	// path is file path.
 	path string
+	// protocol is file protocol.
+	protocol string
 }
 
 // NewFile create new File.
+// If path is empty, return error.
+// If path does not contain protocol, add file:// protocol.
 func NewFile(
 	path string,
 ) (*File, error) {
 	if path == "" {
 		return nil, errors.New("file path is empty")
 	}
+
+	protocol := ""
+	if !strings.Contains(path, "://") {
+		protocol = "file://"
path: domain/model/file.go
user: login: github-actions[bot]
body: 🚫 **[golangci]** <sub>reported by [reviewdog](https://github.com/reviewdog/reviewdog) :dog:</sub><br>string `file://` has 4 occurrences, make it a constant (goconst)
<!-- __reviewdog__:ChBmMDQ1ZjY0MDRkNDlmYTE4Eghnb2xhbmdjaQ== -->

created_at: 2025-03-21T14:02:23Z
author_association: NONE
diff_hunk: @@ -11,17 +11,31 @@ import (
 type File struct {
 	// path is file path.
 	path string
+	// protocol is file protocol.
+	protocol string
 }
 
 // NewFile create new File.
+// If path is empty, return error.
+// If path does not contain protocol, add file:// protocol.
 func NewFile(
 	path string,
 ) (*File, error) {
 	if path == "" {
 		return nil, errors.New("file path is empty")
 	}
+
+	protocol := ""
path: domain/model/file.go
user: login: github-actions[bot]
body: 🚫 **[golangci]** <sub>reported by [reviewdog](https://github.com/reviewdog/reviewdog) :dog:</sub><br>assigned to protocol, but reassigned without using the value (wastedassign)
<!-- __reviewdog__:ChBmY2M5YzBmYzRhZjY5NGNiEghnb2xhbmdjaQ== -->

created_at: 2025-03-21T14:02:23Z
author_association: NONE

PR comments:
user: login: coderabbitai[bot]
created_at: 2025-03-21T14:01:20Z
body: <!-- This is an auto-generated comment: summarize by coderabbit.ai -->
<!-- This is an auto-generated comment: failure by coderabbit.ai -->

> [!CAUTION]
> ## Review failed
> 
> The pull request is closed.

<!-- end of auto-generated comment: failure by coderabbit.ai -->
<!-- walkthrough_start -->

## Walkthrough

This update improves the file handling capabilities and context management across the application. The documentation now clearly states that the tool supports local, HTTP, and HTTPS CSV/TSV/LTSV files while warning against production DML operations. The core `File` model is enhanced with protocol information and helper methods. Multiple layers—including repository, persistence, interactor, mocks, and UI—have been revised to pass a context parameter for better cancellation and timeout support. Minor formatting changes in the UI files were also applied.

## Changes

| File(s) | Change Summary |
|---------|----------------|
| `README.md` | Enhanced docs for `sqluv`: clarified file format support (local, HTTP, HTTPS), usage guidelines, and file extension handling. |
| `domain/model/file.go`, `domain/model/file_test.go` | Added a new `protocol` field and helper methods (`IsFileProtocol`, `IsHTTPProtocol`, `FullURL`); introduced tests for protocol extraction and URL construction. |
| `domain/repository/file.go`, `usecase/file.go` | Updated file reader interface methods to include a new `context.Context` parameter for improved cancellation and timeout management. |
| `infrastructure/persistence/file.go`, `infrastructure/persistence/file_test.go` | Refactored file reading by introducing an `ioReader` helper that handles HTTP and local file access using context; added HTTPS reading tests. |
| `infrastructure/mock/file.go`, `interactor/file.go`, `interactor/file_test.go`, `interactor/mock/file.go`, `tui/tui.go`, `tui/connection_modal.go` | Revised mocks, interactor, and TUI methods to accept a `context.Context` in file reading functions and made minor formatting adjustments. |

## Sequence Diagram(s)

```mermaid
sequenceDiagram
    participant U as User
    participant FR as FileReader (Interactor)
    participant R as Repository
    participant P as Persistence (ioReader)
    participant FS as File System / HTTP Client

    U->>FR: Read(ctx, file)
    FR->>R: Read(ctx, file)
    R->>P: ioReader(ctx, file)
    alt File is HTTP/HTTPS
        P->>FS: Create HTTP request with ctx
        FS-->>P: Return response body
    else Local File
        P->>FS: Open file from filesystem
        FS-->>P: Return file handle
    end
    P-->>R: Return io.Reader and closer
    R-->>FR: Return parsed Table
    FR-->>U: Return final Table
```

## Poem

> Hop along, dear friend, in code so light,  
> Context now flows with every file in sight.  
> Protocols dance from HTTP to local glee,  
> Tests and mocks join the jubilee.  
> I nibble on carrots, my changes are grand—  
> A rabbit’s delight in this refined land!  
> 🥕🐇

<!-- walkthrough_end -->
<!-- internal state start -->


<!-- DwQgtGAEAqAWCWBnSTIEMB26CuAXA9mAOYCmGJATmriQCaQDG+Ats2bgFyQAOFk+AIwBWJBrngA3EsgEBPRvlqU0AgfFwA6NPEgQAfACgjoCEejqANiS4AzEtS6Js3bvgq5IsXLm4B6Lz7IvPgETBYGAHLYzAKUXABMAKwGAKqIcZAYaPgAjPE5yQb6xuBQZPT4NjgExGTKNPRMrOxcvPzCouJSMvJMSlSq6lo6xSZQcKiomNWEpORUDQrNGJyQVADukE6saBTycgr9Kmqa2rpghiWmBgBKAKIAggAiALJ3Gsy0HAYARH8GAGIAZAHgBJWrzah0LbRZi7eSVRiwTCkRBmWAkJEo6QoLC4DGQAAG92ebw+tEJkBs8CskDIyIwDEx+MxSkQDAo8G44nwWERLKJiAAjhZsBJKQR8BYAOTIBhobgqGnqeDSAA0PF24gY2Asuws8goJCIu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jDKGsFgnoLQipc9VEznTBHUjoRp+jka7lH68j0gHzYQIZWstCjboB0CUZtakyKjL2jZUYC/D1ipJ3uj+MDr92g6A9/uCWf7irHqSaxMBijrcu32LZTJUa2dP0oEKWyxY5eqtYYaSbwr81tcZFZAbiO8U5jHhLIGwFMKuVgiMlW6pjKhLEHZoaRUOcUSJCgNS1VqiVZX2hFuSGZvwpmelv/Zz8xdhi5iDRhPkAzJUQGnOKBqT7nh653RAPpzC8JbH5AtonKChpEg5TphXkAqXho5jFTwurXcqZVIpo1TqaHNNDuLusMUbTF1u6jcjMcOPEHdLhuLZkZhYf6tazMldazN7JrHWSKxhtP0fkxUyLSsRkiXJv36eSVWgJnk1gELKRp1NgpgAxeNjYu6LgVwMoMpHvJKwRj0IUqC0DWB0L5JIGA4BdwGAnBhg5wPQEAA -->

<!-- internal state end -->

---

<details>
<summary>📜 Recent review details</summary>

**Configuration used: CodeRabbit UI**
**Review profile: CHILL**
**Plan: Pro**

<details>
<summary>📥 Commits</summary>

Reviewing files that changed from the base of the PR and between 23a2e06e06f7c929c51a79b487387c9e0c70d7ec and 12819ffaf95a9d683015217e00b9e67e2bb8dc0f.

</details>

<details>
<summary>📒 Files selected for processing (13)</summary>

* `README.md` (3 hunks)
* `domain/model/file.go` (2 hunks)
* `domain/model/file_test.go` (2 hunks)
* `domain/repository/file.go` (2 hunks)
* `infrastructure/mock/file.go` (7 hunks)
* `infrastructure/persistence/file.go` (5 hunks)
* `infrastructure/persistence/file_test.go` (5 hunks)
* `interactor/file.go` (2 hunks)
* `interactor/file_test.go` (7 hunks)
* `interactor/mock/file.go` (3 hunks)
* `tui/connection_modal.go` (0 hunks)
* `tui/tui.go` (1 hunks)
* `usecase/file.go` (2 hunks)

</details>

</details>
<!-- finishing_touch_checkbox_start -->

<details>
<summary>✨ Finishing Touches</summary>

- [ ] <!-- {"checkboxId": "7962f53c-55bc-4827-bfbf-6a18da830691"} --> 📝 Generate Docstrings

</details>

<!-- finishing_touch_checkbox_end -->
<!-- tips_start -->

---

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

<details>
<summary>❤️ Share</summary>

- [X](https://twitter.com/intent/tweet?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A&url=https%3A//coderabbit.ai)
- [Mastodon](https://mastodon.social/share?text=I%20just%20used%20%40coderabbitai%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20the%20proprietary%20code.%20Check%20it%20out%3A%20https%3A%2F%2Fcoderabbit.ai)
- [Reddit](https://www.reddit.com/submit?title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&text=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code.%20Check%20it%20out%3A%20https%3A//coderabbit.ai)
- [LinkedIn](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fcoderabbit.ai&mini=true&title=Great%20tool%20for%20code%20review%20-%20CodeRabbit&summary=I%20just%20used%20CodeRabbit%20for%20my%20code%20review%2C%20and%20it%27s%20fantastic%21%20It%27s%20free%20for%20OSS%20and%20offers%20a%20free%20trial%20for%20proprietary%20code)

</details>

<details>
<summary>🪧 Tips</summary>

### Chat

There are 3 ways to chat with [CodeRabbit](https://coderabbit.ai?utm_source=oss&utm_medium=github&utm_campaign=nao1215/sqluv&utm_content=25):

- Review comments: Directly reply to a review comment made by CodeRabbit. Example:
  - `I pushed a fix in commit <commit_id>, please review it.`
  - `Generate unit testing code for this file.`
  - `Open a follow-up GitHub issue for this discussion.`
- Files and specific lines of code (under the "Files changed" tab): Tag `@coderabbitai` in a new review comment at the desired location with your query. Examples:
  - `@coderabbitai generate unit testing code for this file.`
  -	`@coderabbitai modularize this function.`
- PR comments: Tag `@coderabbitai` in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
  - `@coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.`
  - `@coderabbitai read src/utils.ts and generate unit testing code.`
  - `@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.`
  - `@coderabbitai help me debug CodeRabbit configuration file.`

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

### CodeRabbit Commands (Invoked using PR comments)

- `@coderabbitai pause` to pause the reviews on a PR.
- `@coderabbitai resume` to resume the paused reviews.
- `@coderabbitai review` to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
- `@coderabbitai full review` to do a full review from scratch and review all the files again.
- `@coderabbitai summary` to regenerate the summary of the PR.
- `@coderabbitai generate docstrings` to [generate docstrings](https://docs.coderabbit.ai/finishing-touches/docstrings) for this PR.
- `@coderabbitai resolve` resolve all the CodeRabbit review comments.
- `@coderabbitai configuration` to show the current CodeRabbit configuration for the repository.
- `@coderabbitai help` to get help.

### Other keywords and placeholders

- Add `@coderabbitai ignore` anywhere in the PR description to prevent this PR from being reviewed.
- Add `@coderabbitai summary` to generate the high-level summary at a specific location in the PR description.
- Add `@coderabbitai` anywhere in the PR title to generate the title automatically.

### CodeRabbit Configuration File (`.coderabbit.yaml`)

- You can programmatically configure CodeRabbit by adding a `.coderabbit.yaml` file to the root of your repository.
- Please see the [configuration documentation](https://docs.coderabbit.ai/guides/configure-coderabbit) for more information.
- If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: `# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json`

### Documentation and Community

- Visit our [Documentation](https://docs.coderabbit.ai) for detailed information on how to use CodeRabbit.
- Join our [Discord Community](http://discord.gg/coderabbit) to get help, request features, and share feedback.
- Follow us on [X/Twitter](https://twitter.com/coderabbitai) for updates and announcements.

</details>

<!-- tips_end -->
author_association: NONE
user: login: github-actions[bot]
created_at: 2025-03-21T14:01:45Z
body: ## Code Metrics Report
|                         | [main](https://github.com/nao1215/sqluv/tree/main) ([23a2e06](https://github.com/nao1215/sqluv/commit/23a2e06e06f7c929c51a79b487387c9e0c70d7ec)) | [#25](https://github.com/nao1215/sqluv/pull/25) ([d4f3e99](https://github.com/nao1215/sqluv/commit/d4f3e99d0dac19dab21b581b179a887f5f645bd2)) |  +/-  |
|-------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------:|----------------------------------------------------------------------------------------------------------------------------------------------:|------:|
| **Coverage**            |                                                                                                                                            32.5% |                                                                                                                                         33.8% | +1.3% |
| **Test Execution Time** |                                                                                                                                               2s |                                                                                                                                            4s |   +2s |

<details>

<summary>Details</summary>

``` diff
  |                     | main (23a2e06) | #25 (d4f3e99) |  +/-  |
  |---------------------|----------------|---------------|-------|
+ | Coverage            |          32.5% |         33.8% | +1.3% |
  |   Files             |             25 |            25 |     0 |
  |   Lines             |            783 |           806 |   +23 |
+ |   Covered           |            255 |           273 |   +18 |
- | Test Execution Time |             2s |            4s |   +2s |
```

</details>


### Code coverage of files in pull request scope (93.2% → 90.1%)

|                                                                            Files                                                                            | Coverage |  +/-  |
|-------------------------------------------------------------------------------------------------------------------------------------------------------------|---------:|------:|
| [domain/model/file.go](https://github.com/nao1215/sqluv/blob/b4d158808ec86dfe1dd153cf191005b34170405c/domain%2Fmodel%2Ffile.go)                             | 100.0%   | 0.0%  |
| [infrastructure/persistence/file.go](https://github.com/nao1215/sqluv/blob/b4d158808ec86dfe1dd153cf191005b34170405c/infrastructure%2Fpersistence%2Ffile.go) | 87.0%    | -4.4% |
| [interactor/file.go](https://github.com/nao1215/sqluv/blob/b4d158808ec86dfe1dd153cf191005b34170405c/interactor%2Ffile.go)                                   | 100.0%   | 0.0%  |

---
Reported by [octocov](https://github.com/k1LoW/octocov)
<!-- octocov -->
author_association: NONE
user: login: github-actions[bot]
created_at: 2025-03-21T14:03:18Z
body: ## Code Metrics Report
|                         | [main](https://github.com/nao1215/sqluv/tree/main) ([23a2e06](https://github.com/nao1215/sqluv/commit/23a2e06e06f7c929c51a79b487387c9e0c70d7ec)) | [#25](https://github.com/nao1215/sqluv/pull/25) ([14a974f](https://github.com/nao1215/sqluv/commit/14a974f4557655604c0e65768dd6535e176c5311)) |  +/-  |
|-------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------:|----------------------------------------------------------------------------------------------------------------------------------------------:|------:|
| **Coverage**            |                                                                                                                                            32.5% |                                                                                                                                         33.8% | +1.3% |
| **Test Execution Time** |                                                                                                                                               2s |                                                                                                                                            4s |   +2s |

<details>

<summary>Details</summary>

``` diff
  |                     | main (23a2e06) | #25 (14a974f) |  +/-  |
  |---------------------|----------------|---------------|-------|
+ | Coverage            |          32.5% |         33.8% | +1.3% |
  |   Files             |             25 |            25 |     0 |
  |   Lines             |            783 |           806 |   +23 |
+ |   Covered           |            255 |           273 |   +18 |
- | Test Execution Time |             2s |            4s |   +2s |
```

</details>


### Code coverage of files in pull request scope (93.2% → 90.1%)

|                                                                            Files                                                                            | Coverage |  +/-  |
|-------------------------------------------------------------------------------------------------------------------------------------------------------------|---------:|------:|
| [domain/model/file.go](https://github.com/nao1215/sqluv/blob/83f8ef68e71e45722d6f4b2aa58b5270eabd6adb/domain%2Fmodel%2Ffile.go)                             | 100.0%   | 0.0%  |
| [infrastructure/persistence/file.go](https://github.com/nao1215/sqluv/blob/83f8ef68e71e45722d6f4b2aa58b5270eabd6adb/infrastructure%2Fpersistence%2Ffile.go) | 87.0%    | -4.4% |
| [interactor/file.go](https://github.com/nao1215/sqluv/blob/83f8ef68e71e45722d6f4b2aa58b5270eabd6adb/interactor%2Ffile.go)                                   | 100.0%   | 0.0%  |

---
Reported by [octocov](https://github.com/k1LoW/octocov)
<!-- octocov -->
author_association: NONE
user: login: github-actions[bot]
created_at: 2025-03-21T14:05:42Z
body: ## Code Metrics Report
|                         | [main](https://github.com/nao1215/sqluv/tree/main) ([23a2e06](https://github.com/nao1215/sqluv/commit/23a2e06e06f7c929c51a79b487387c9e0c70d7ec)) | [#25](https://github.com/nao1215/sqluv/pull/25) ([3ef8537](https://github.com/nao1215/sqluv/commit/3ef85373a1cc2c5e894eb4f5921411b7c2f6f23c)) |  +/-  |
|-------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------:|----------------------------------------------------------------------------------------------------------------------------------------------:|------:|
| **Coverage**            |                                                                                                                                            32.5% |                                                                                                                                         33.8% | +1.3% |
| **Test Execution Time** |                                                                                                                                               2s |                                                                                                                                            4s |   +2s |

<details>

<summary>Details</summary>

``` diff
  |                     | main (23a2e06) | #25 (3ef8537) |  +/-  |
  |---------------------|----------------|---------------|-------|
+ | Coverage            |          32.5% |         33.8% | +1.3% |
  |   Files             |             25 |            25 |     0 |
  |   Lines             |            783 |           806 |   +23 |
+ |   Covered           |            255 |           273 |   +18 |
- | Test Execution Time |             2s |            4s |   +2s |
```

</details>


### Code coverage of files in pull request scope (93.2% → 90.1%)

|                                                                            Files                                                                            | Coverage |  +/-  |
|-------------------------------------------------------------------------------------------------------------------------------------------------------------|---------:|------:|
| [domain/model/file.go](https://github.com/nao1215/sqluv/blob/12819ffaf95a9d683015217e00b9e67e2bb8dc0f/domain%2Fmodel%2Ffile.go)                             | 100.0%   | 0.0%  |
| [infrastructure/persistence/file.go](https://github.com/nao1215/sqluv/blob/12819ffaf95a9d683015217e00b9e67e2bb8dc0f/infrastructure%2Fpersistence%2Ffile.go) | 87.0%    | -4.4% |
| [interactor/file.go](https://github.com/nao1215/sqluv/blob/12819ffaf95a9d683015217e00b9e67e2bb8dc0f/interactor%2Ffile.go)                                   | 100.0%   | 0.0%  |

---
Reported by [octocov](https://github.com/k1LoW/octocov)
<!-- octocov -->
author_association: NONE