Fix: Change default JSONL filename from beads.jsonl to issues.jsonl
The canonical beads database name is issues.jsonl. Tens of thousands of users have issues.jsonl, and beads.jsonl was only used by the Beads project itself due to git history pollution. Changes: - Updated bd doctor to warn about beads.jsonl instead of issues.jsonl - Changed default config from beads.jsonl to issues.jsonl - Reversed precedence in checkGitForIssues to prefer issues.jsonl - Updated git merge driver config to use issues.jsonl - Updated all tests to expect issues.jsonl as the default issues.jsonl is now the canonical default; beads.jsonl is legacy 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -242,8 +242,8 @@ func FindJSONLPath(dbPath string) string {
|
||||
return matches[0]
|
||||
}
|
||||
|
||||
// Default to beads.jsonl
|
||||
return filepath.Join(dbDir, "beads.jsonl")
|
||||
// Default to issues.jsonl
|
||||
return filepath.Join(dbDir, "issues.jsonl")
|
||||
}
|
||||
|
||||
// DatabaseInfo contains information about a discovered beads database
|
||||
|
||||
@@ -168,9 +168,9 @@ func TestFindJSONLPathDefault(t *testing.T) {
|
||||
// Create a fake database path (no .jsonl files exist)
|
||||
dbPath := filepath.Join(tmpDir, "test.db")
|
||||
|
||||
// Should return default beads.jsonl
|
||||
// Should return default issues.jsonl
|
||||
result := FindJSONLPath(dbPath)
|
||||
expected := filepath.Join(tmpDir, "beads.jsonl")
|
||||
expected := filepath.Join(tmpDir, "issues.jsonl")
|
||||
if result != expected {
|
||||
t.Errorf("Expected '%s', got '%s'", expected, result)
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ type Config struct {
|
||||
func DefaultConfig() *Config {
|
||||
return &Config{
|
||||
Database: "beads.db",
|
||||
JSONLExport: "beads.jsonl",
|
||||
JSONLExport: "issues.jsonl",
|
||||
}
|
||||
}
|
||||
|
||||
@@ -89,7 +89,7 @@ func (c *Config) DatabasePath(beadsDir string) string {
|
||||
|
||||
func (c *Config) JSONLPath(beadsDir string) string {
|
||||
if c.JSONLExport == "" {
|
||||
return filepath.Join(beadsDir, "beads.jsonl")
|
||||
return filepath.Join(beadsDir, "issues.jsonl")
|
||||
}
|
||||
return filepath.Join(beadsDir, c.JSONLExport)
|
||||
}
|
||||
|
||||
@@ -12,9 +12,9 @@ func TestDefaultConfig(t *testing.T) {
|
||||
if cfg.Database != "beads.db" {
|
||||
t.Errorf("Database = %q, want beads.db", cfg.Database)
|
||||
}
|
||||
|
||||
if cfg.JSONLExport != "beads.jsonl" {
|
||||
t.Errorf("JSONLExport = %q, want beads.jsonl", cfg.JSONLExport)
|
||||
|
||||
if cfg.JSONLExport != "issues.jsonl" {
|
||||
t.Errorf("JSONLExport = %q, want issues.jsonl", cfg.JSONLExport)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -84,8 +84,8 @@ func TestJSONLPath(t *testing.T) {
|
||||
}{
|
||||
{
|
||||
name: "default",
|
||||
cfg: &Config{JSONLExport: "beads.jsonl"},
|
||||
want: filepath.Join(beadsDir, "beads.jsonl"),
|
||||
cfg: &Config{JSONLExport: "issues.jsonl"},
|
||||
want: filepath.Join(beadsDir, "issues.jsonl"),
|
||||
},
|
||||
{
|
||||
name: "custom",
|
||||
@@ -95,7 +95,7 @@ func TestJSONLPath(t *testing.T) {
|
||||
{
|
||||
name: "empty falls back to default",
|
||||
cfg: &Config{JSONLExport: ""},
|
||||
want: filepath.Join(beadsDir, "beads.jsonl"),
|
||||
want: filepath.Join(beadsDir, "issues.jsonl"),
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user