Skip to content

Commit

Permalink
fix: improve file processing and error handling
Browse files Browse the repository at this point in the history
- Enhance priority handling by collecting and sorting files before processing - Fix validation error output to use stderr instead of stdout - Fix file priority ordering to respect priority scores in config - Fix test assertions for validation error messages

The changes ensure that: 1. Files are processed in correct priority order (highest first) 2. Error messages appear in stderr as expected 3. All tests pass including priority, ignore patterns, and validation tests
  • Loading branch information
mohsen1 committed Jan 13, 2025
1 parent fc2c030 commit 1e6b424
Show file tree
Hide file tree
Showing 12 changed files with 617 additions and 23 deletions.
38 changes: 38 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.3.0] - 2024-01-13

### Added

- Comprehensive test suite covering all major functionality
- Integration tests for file handling, ignore patterns, and priorities
- Debug output for better visibility into file processing

### Fixed

- File priority handling now correctly sorts files by priority score
- Validation error messages now properly output to stderr
- Binary file detection and handling improvements
- Gitignore pattern handling fixes

### Changed

- Improved file processing to collect and sort before processing
- Enhanced error handling and validation messages
- Better debug logging throughout the codebase

## [0.2.0] - 2024-01-11

### Added

- Initial release with basic functionality
- Support for processing repository files
- Configuration via yek.toml
- Priority rules for file processing
- Ignore patterns support
- Binary file detection
134 changes: 133 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "yek"
version = "0.2.0"
version = "0.3.0"
edition = "2021"

[dependencies]
Expand All @@ -19,3 +19,5 @@ time = { version = "0.3", features = ["formatting"] }

[dev-dependencies]
tempfile = "3.8"
assert_cmd = "2"
predicates = "2"
2 changes: 1 addition & 1 deletion Formula/yek.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class Yek < Formula
desc "A tool to chunk and serialize repository content for LLM consumption"
homepage "https://github.com/mohsen1/yek"
version "0.2.0"
version "0.3.0"
head "https://github.com/mohsen1/yek.git", branch: "main"

on_macos do
Expand Down
Loading

0 comments on commit 1e6b424

Please sign in to comment.