tangled
alpha
login
or
join now
desertthunder.dev
/
noteleaf
cli + tui to publish to leaflet (wip) & manage tasks, notes & watch/read lists ๐
charm
leaflet
readability
golang
29
fork
atom
overview
issues
2
pulls
pipelines
build: update module path & add testing action
desertthunder.dev
5 months ago
2d5e38a8
24ab81bb
+106
-17
16 changed files
expand all
collapse all
unified
split
.github
workflows
test.yml
README.md
cmd
cli
main.go
handlers
handlers.go
handlers_test.go
codecov.yml
go.mod
internal
repo
book_repository.go
book_repository_test.go
movie_repository.go
movie_repository_test.go
repositories_test.go
task_repository.go
task_repository_test.go
tv_repository.go
tv_repository_test.go
+61
.github/workflows/test.yml
···
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
···
1
+
name: Test and Coverage
2
+
3
+
on:
4
+
push:
5
+
branches: [ main, master ]
6
+
pull_request:
7
+
branches: [ main, master ]
8
+
9
+
jobs:
10
+
test:
11
+
runs-on: ubuntu-latest
12
+
13
+
strategy:
14
+
matrix:
15
+
go-version: [1.24.x]
16
+
17
+
steps:
18
+
- uses: actions/checkout@v4
19
+
20
+
- name: Set up Go
21
+
uses: actions/setup-go@v5
22
+
with:
23
+
go-version: ${{ matrix.go-version }}
24
+
25
+
- name: Cache Go modules
26
+
uses: actions/cache@v4
27
+
with:
28
+
path: |
29
+
~/.cache/go-build
30
+
~/go/pkg/mod
31
+
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
32
+
restore-keys: |
33
+
${{ runner.os }}-go-
34
+
35
+
- name: Download dependencies
36
+
run: go mod download
37
+
38
+
- name: Verify dependencies
39
+
run: go mod verify
40
+
41
+
- name: Run tests
42
+
run: go test -v -race -coverprofile=coverage.out -covermode=atomic ./...
43
+
44
+
- name: Generate coverage report
45
+
run: go tool cover -html=coverage.out -o coverage.html
46
+
47
+
- name: Upload coverage reports to Codecov
48
+
uses: codecov/codecov-action@v4
49
+
with:
50
+
file: ./coverage.out
51
+
flags: unittests
52
+
name: codecov-umbrella
53
+
fail_ci_if_error: false
54
+
55
+
- name: Upload coverage artifact
56
+
uses: actions/upload-artifact@v4
57
+
with:
58
+
name: coverage-report
59
+
path: |
60
+
coverage.out
61
+
coverage.html
+5
README.md
···
1
# Noteleaf
2
0
0
0
0
0
3
```sh
4
,, ,...
5
`7MN. `7MF' mm `7MM .d' ""
···
1
# Noteleaf
2
3
+
[](https://codecov.io/gh/stormlightlabs/noteleaf)
4
+
[](https://goreportcard.com/report/github.com/stormlightlabs/noteleaf)
5
+
[](LICENSE)
6
+
[](go.mod)
7
+
8
```sh
9
,, ,...
10
`7MN. `7MF' mm `7MM .d' ""
+4
-4
cmd/cli/main.go
···
8
9
"github.com/charmbracelet/fang"
10
"github.com/spf13/cobra"
11
-
"stormlightlabs.org/noteleaf/cmd/handlers"
12
-
"stormlightlabs.org/noteleaf/internal/store"
13
-
"stormlightlabs.org/noteleaf/internal/ui"
14
-
"stormlightlabs.org/noteleaf/internal/utils"
15
)
16
17
// App represents the main CLI application
···
8
9
"github.com/charmbracelet/fang"
10
"github.com/spf13/cobra"
11
+
"github.com/stormlightlabs/noteleaf/cmd/handlers"
12
+
"github.com/stormlightlabs/noteleaf/internal/store"
13
+
"github.com/stormlightlabs/noteleaf/internal/ui"
14
+
"github.com/stormlightlabs/noteleaf/internal/utils"
15
)
16
17
// App represents the main CLI application
+2
-2
cmd/handlers/handlers.go
···
6
"os"
7
"path/filepath"
8
9
-
"stormlightlabs.org/noteleaf/internal/store"
10
-
"stormlightlabs.org/noteleaf/internal/utils"
11
)
12
13
// Setup initializes the application database and configuration
···
6
"os"
7
"path/filepath"
8
9
+
"github.com/stormlightlabs/noteleaf/internal/store"
10
+
"github.com/stormlightlabs/noteleaf/internal/utils"
11
)
12
13
// Setup initializes the application database and configuration
+1
-1
cmd/handlers/handlers_test.go
···
7
"testing"
8
"time"
9
10
-
"stormlightlabs.org/noteleaf/internal/store"
11
)
12
13
func createTestDir(t *testing.T) string {
···
7
"testing"
8
"time"
9
10
+
"github.com/stormlightlabs/noteleaf/internal/store"
11
)
12
13
func createTestDir(t *testing.T) string {
+23
codecov.yml
···
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
···
1
+
coverage:
2
+
status:
3
+
project:
4
+
default:
5
+
target: auto
6
+
threshold: 1%
7
+
informational: true
8
+
patch:
9
+
default:
10
+
target: auto
11
+
threshold: 1%
12
+
informational: true
13
+
14
+
comment:
15
+
layout: "reach,diff,flags,tree"
16
+
behavior: default
17
+
require_changes: false
18
+
19
+
ignore:
20
+
- "**/*_test.go"
21
+
- "**/testdata/**"
22
+
- "**/vendor/**"
23
+
- "cmd/cli/main.go" # Main entry point typically has minimal logic to test
+1
-1
go.mod
···
1
-
module stormlightlabs.org/noteleaf
2
3
go 1.24.5
4
···
1
+
module github.com/stormlightlabs/noteleaf
2
3
go 1.24.5
4
+1
-1
internal/repo/book_repository.go
···
7
"strings"
8
"time"
9
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
// BookRepository provides database operations for books
···
7
"strings"
8
"time"
9
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
// BookRepository provides database operations for books
+1
-1
internal/repo/book_repository_test.go
···
7
"time"
8
9
_ "github.com/mattn/go-sqlite3"
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
func createBookTestDB(t *testing.T) *sql.DB {
···
7
"time"
8
9
_ "github.com/mattn/go-sqlite3"
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
func createBookTestDB(t *testing.T) *sql.DB {
+1
-1
internal/repo/movie_repository.go
···
7
"strings"
8
"time"
9
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
// MovieRepository provides database operations for movies
···
7
"strings"
8
"time"
9
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
// MovieRepository provides database operations for movies
+1
-1
internal/repo/movie_repository_test.go
···
7
"time"
8
9
_ "github.com/mattn/go-sqlite3"
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
func createMovieTestDB(t *testing.T) *sql.DB {
···
7
"time"
8
9
_ "github.com/mattn/go-sqlite3"
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
func createMovieTestDB(t *testing.T) *sql.DB {
+1
-1
internal/repo/repositories_test.go
···
7
8
"github.com/google/uuid"
9
_ "github.com/mattn/go-sqlite3"
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
func createFullTestDB(t *testing.T) *sql.DB {
···
7
8
"github.com/google/uuid"
9
_ "github.com/mattn/go-sqlite3"
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
func createFullTestDB(t *testing.T) *sql.DB {
+1
-1
internal/repo/task_repository.go
···
7
"strings"
8
"time"
9
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
// TaskRepository provides database operations for tasks
···
7
"strings"
8
"time"
9
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
// TaskRepository provides database operations for tasks
+1
-1
internal/repo/task_repository_test.go
···
8
9
"github.com/google/uuid"
10
_ "github.com/mattn/go-sqlite3"
11
-
"stormlightlabs.org/noteleaf/internal/models"
12
)
13
14
func createTaskTestDB(t *testing.T) *sql.DB {
···
8
9
"github.com/google/uuid"
10
_ "github.com/mattn/go-sqlite3"
11
+
"github.com/stormlightlabs/noteleaf/internal/models"
12
)
13
14
func createTaskTestDB(t *testing.T) *sql.DB {
+1
-1
internal/repo/tv_repository.go
···
7
"strings"
8
"time"
9
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
// TVRepository provides database operations for TV shows
···
7
"strings"
8
"time"
9
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
// TVRepository provides database operations for TV shows
+1
-1
internal/repo/tv_repository_test.go
···
7
"time"
8
9
_ "github.com/mattn/go-sqlite3"
10
-
"stormlightlabs.org/noteleaf/internal/models"
11
)
12
13
func createTVTestDB(t *testing.T) *sql.DB {
···
7
"time"
8
9
_ "github.com/mattn/go-sqlite3"
10
+
"github.com/stormlightlabs/noteleaf/internal/models"
11
)
12
13
func createTVTestDB(t *testing.T) *sql.DB {