rename applephotos to photoscli, update module path to gitea.k3s.k0.nu/tools/photocli

This commit is contained in:
Ein Anderssono
2026-06-11 20:29:06 +02:00
parent e48e20ad18
commit ca3a3e4a2a
6 changed files with 43 additions and 40 deletions
@@ -5,7 +5,7 @@ import (
"io"
"strings"
"github.com/einand/applephotos/internal/photos"
"gitea.k3s.k0.nu/tools/photocli/internal/photos"
)
func run(args []string, stdout, stderr io.Writer, bridge photos.Bridge) int {
@@ -37,14 +37,14 @@ func run(args []string, stdout, stderr io.Writer, bridge photos.Bridge) int {
}
func usage(w io.Writer) {
fmt.Fprintln(w, `applephotos export optimized images from Apple Photos
fmt.Fprintln(w, `photoscli export optimized images from Apple Photos
Usage:
applephotos albums
applephotos photos --album-id <id>
applephotos tree
applephotos backup-all --out <dir> [--size <px>] [--originals]
applephotos export --album-id <id> --out <dir> [--size <px>] [--originals]
photoscli albums
photoscli photos --album-id <id>
photoscli tree
photoscli backup-all --out <dir> [--size <px>] [--originals]
photoscli export --album-id <id> --out <dir> [--size <px>] [--originals]
Commands:
albums List user-created albums
@@ -5,7 +5,7 @@ import (
"os/signal"
"syscall"
"github.com/einand/applephotos/internal/photos"
"gitea.k3s.k0.nu/tools/photocli/internal/photos"
)
func main() {
@@ -8,7 +8,7 @@ import (
"strings"
"testing"
"github.com/einand/applephotos/internal/photos"
"gitea.k3s.k0.nu/tools/photocli/internal/photos"
)
type mockBridge struct {
@@ -89,7 +89,7 @@ func TestRunNoArgs(t *testing.T) {
if rc != 1 {
t.Errorf("rc = %d, want 1", rc)
}
if !strings.Contains(stderr, "applephotos") {
if !strings.Contains(stderr, "photoscli") {
t.Errorf("stderr should contain usage, got: %s", stderr)
}
}
@@ -100,7 +100,7 @@ func TestRunHelp(t *testing.T) {
if rc != 0 {
t.Errorf("%s: rc = %d, want 0", cmd, rc)
}
if !strings.Contains(stderr, "applephotos") {
if !strings.Contains(stderr, "photoscli") {
t.Errorf("%s: stderr should contain usage", cmd)
}
}