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:
@@ -52,7 +52,7 @@ func TestCleanupMergeArtifacts_CommandInjectionPrevention(t *testing.T) {
|
||||
},
|
||||
{
|
||||
name: "normal backup file",
|
||||
filename: "beads.jsonl.backup",
|
||||
filename: "issues.jsonl.backup",
|
||||
wantSafe: true,
|
||||
},
|
||||
{
|
||||
@@ -89,7 +89,7 @@ func TestCleanupMergeArtifacts_CommandInjectionPrevention(t *testing.T) {
|
||||
}
|
||||
|
||||
// Create output path
|
||||
outputPath := filepath.Join(beadsDir, "beads.jsonl")
|
||||
outputPath := filepath.Join(beadsDir, "issues.jsonl")
|
||||
if err := os.WriteFile(outputPath, []byte("{}"), 0644); err != nil {
|
||||
t.Fatalf("Failed to create output file: %v", err)
|
||||
}
|
||||
@@ -129,14 +129,14 @@ func TestCleanupMergeArtifacts_OnlyBackupFiles(t *testing.T) {
|
||||
|
||||
// Create various files
|
||||
files := map[string]bool{
|
||||
"beads.jsonl": false, // Should NOT be removed
|
||||
"issues.jsonl": false, // Should NOT be removed
|
||||
"beads.db": false, // Should NOT be removed
|
||||
"backup.jsonl": true, // Should be removed
|
||||
"beads.jsonl.backup": true, // Should be removed
|
||||
"issues.jsonl.backup": true, // Should be removed
|
||||
"BACKUP_FILE": true, // Should be removed (case-insensitive)
|
||||
"my_backup_2024.txt": true, // Should be removed
|
||||
"important_data.jsonl": false, // Should NOT be removed
|
||||
"beads.jsonl.bak": false, // Should NOT be removed (no "backup")
|
||||
"issues.jsonl.bak": false, // Should NOT be removed (no "backup")
|
||||
}
|
||||
|
||||
for filename := range files {
|
||||
@@ -147,7 +147,7 @@ func TestCleanupMergeArtifacts_OnlyBackupFiles(t *testing.T) {
|
||||
}
|
||||
|
||||
// Create output path
|
||||
outputPath := filepath.Join(beadsDir, "beads.jsonl")
|
||||
outputPath := filepath.Join(beadsDir, "issues.jsonl")
|
||||
|
||||
// Run cleanup
|
||||
cleanupMergeArtifacts(outputPath, false)
|
||||
@@ -192,7 +192,7 @@ func TestCleanupMergeArtifacts_GitRmSafety(t *testing.T) {
|
||||
t.Fatalf("Failed to create backup file: %v", err)
|
||||
}
|
||||
|
||||
outputPath := filepath.Join(beadsDir, "beads.jsonl")
|
||||
outputPath := filepath.Join(beadsDir, "issues.jsonl")
|
||||
if err := os.WriteFile(outputPath, []byte("{}"), 0644); err != nil {
|
||||
t.Fatalf("Failed to create output file: %v", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user