Skip to content

v38

Compare
Choose a tag to compare
@github-actions github-actions released this 10 Jul 11:38
· 35 commits to main since this release
09dcf5d

Changelog

09dcf5d Merge pull request #38 from codecrafters-io/file-search
ff184fe refactor: enhance vegetable selection in file search tests for improved test diversity
19a5b95 refactor: enhance random fruit selection in file search tests for better test coverage
f6991a0 refactor: replace matcher interface with backrefMatcher pointer in grep implementation for improved type safety
20c8bad refactor: adjust random element selection in file search tests for more controlled test scenarios
3d1574d chore: add test_all target to run multiple grep tests sequentially
0ac4ca7 refactor: update test fixture logs for consistency in output and error reporting
80430fb refactor: optimize error message handling in file search tests for clarity and efficiency
32b1d17 refactor: simplify error message construction in file search tests for improved readability
351bddd refactor: update error handling in file creation tests to use panic for internal errors
5ae83aa refactor: improve regex patterns in stages tests for enhanced output matching and flexibility
49dd0c3 refactor: remove sudo from system grep relocation commands for improved portability
f5b37ff ci: add regenerated fixtures
a9c33e3 refactor: update system grep relocation commands to use sudo for proper permissions
c963312 refactor: refine regex patterns in stages tests for better output normalization and flexibility
fad9bc9 refactor: adjust regex patterns in stages tests to accommodate varying output formats for improved normalization
70defb7 refactor: enhance regex patterns in stages tests to improve output normalization and validation
ae61690 refactor: update success logging in test cases to use checkmark symbol for consistency and improved readability
e028b9e refactor: standardize log output messages in test fixtures for consistency and clarity
4a261dc refactor: enhance FileTestCase structure by adding recursive flag for improved search functionality in grep tests
01df3a0 refactor: simplify stdout validation in grep tests by comparing entire output strings instead of line-by-line checks
b08136b refactor: update success logging in test cases to use checkmark symbol for improved readability
59e37f8 refactor: replace SearchStdin and SearchFiles with EmulateGrep for improved test consistency and functionality
ac84d39 test: implement comprehensive test suite for grep functionality, covering stdin and file search scenarios with various regex patterns and expected results
32600b4 refactor: remove unused grep dependency and streamline exit code validation in AntiCheatTestCase
b960a97 test: add new scenarios for handling extra and missing logs in stages tests with appropriate configurations
f788760 refactor: improve logging messages in FileSearchTestCase for clarity and consistency in output validation
0313948 feat: add scenarios for handling missing and extra logs with updated test scripts and configuration
c0b92a1 refactor: update output validation in FileSearchTestCase to use slices for improved line comparison and reporting
e3e21e7 refactor: add ExpectedExitCode to anti-cheat test cases and improve exit code validation logic
60b1c91 fix: correct ExpectedExitCode for zero-or-one quantifier test case to reflect accurate validation
037d812 refactor: add ExpectedExitCode to test cases across various stages for enhanced validation
5994179 refactor: enhance StdinTestCase with ExpectedExitCode and improve exit code validation logic
8554a99 refactor: add ExpectedExitCode field to test cases in stage file search functions for improved validation
a8b3c46 refactor: add ExpectedExitCode field to FileSearchTestCase and improve exit code validation in test cases
b6acccf refactor: unify test case collection variable naming for consistency across test functions
13fd2b7 refactor: simplify searchDirectory function by removing unnecessary options parameter for improved clarity
b3fc070 refactor: remove grep_test.go file to streamline test cases and improve code organization
f851f98 refactor: replace SearchStdin and SearchFiles with EmulateGrep in test cases for improved consistency and clarity
2e5d220 refactor: enhance grep functionality by updating Result structure and simplifying argument parsing in EmulateGrep
ac0b897 refactor: simplify grep options in search functions and update test cases for consistency
acc14ff refactor: update Run method signatures in test case collections for improved clarity and consistency
2d7b0a1 chore: update .gitignore to remove internal-docs and cmd/mygrep, and add .claude for better file management
2e9d161 refactor: improve error messages in file search tests for better clarity and add utility function to map lines to indices
3613421 docs: add comments to FRUITS and VEGETABLES constants and randomFilePrefix function for better understanding of their usage
a0085db docs: add comments to CreateTestFiles and writeFiles functions for improved clarity and understanding of their purpose
8cdd6ba refactor: remove runtime check for Darwin in RelocateSystemGrep function, simplifying the code logic
c082aea refactor: rename TestCase interface to TestCaseCollection for improved clarity and consistency in test case management
8192583 feat: add RelocateSystemGrep and restoreSystemGrep functions to manage system grep binary relocation, enhancing test case harness functionality
cbb2f2c refactor: replace strconv with randomFilePrefix function for generating file names in search tests, improving code clarity and consistency
7c78f4f refactor: remove unused options and related logic from grep implementation, streamlining the codebase
5e10580 refactor: clean up comments in test cases for clarity and maintainability
30be206 chore: remove grep tool, we have moved to an internal package
2f51c5e test: update file search test fixtures to use new fruit and vegetable files, enhancing test coverage and accuracy
462ee19 refactor: enhance file search tests by generating random file names and contents for improved test variability
78b125b test: implement dedicated file test function for grep, enhancing test organization and clarity
cc36c11 refactor: restructure grep test cases to use dedicated test case types for stdin and file searches, enhancing readability and maintainability
65e5ff2 test: add comprehensive test suite for grep functionality covering stdin and file search with various regex patterns and options
805ed28 refactor: update anti-cheat test case structure to use a collection method for improved readability and execution
62a504e refactor: consolidate anti-cheat test case execution into a collection method for improved structure and error handling
4eeff10 refactor: integrate internal grep implementation for expected results in anti-cheat test case
634cd41 fix: update expected exit code for anti cheat test case
2701399 refactor: update test fixtures to replace 'apple' with 'banana' and adjust grep commands for improved test accuracy
1cd48be feat: add initial grep binaries and shell script for platform-specific execution
3b67a58 feat: implement core grep functionality with support for regex matching, backreferences, and file search capabilities
b2173ac refactor: clean up test case formatting and remove unnecessary expected exit codes for improved readability and maintainability
239eecb refactor: update test cases to utilize internal grep implementation for expected results in file and stdin tests
6d603cd refactor: streamline matcher and configuration by removing unused options and simplifying match logic
6142f4c refactor: simplify matcher implementation by removing invertMatch logic and consolidating scanning functionality
99859ee feat: refactor grep functionality to use matcher interface for improved extensibility and maintainability
7733327 feat: add support for backreferences in grep functionality with new search methods for stdin and files
b26623a feat: implement base stages in grep-go
8e767d2 feat: introduce dynamic test file generation with random fruits and vegetables for enhanced test coverage in file search functionality
cb6fbb2 refactor: clean up whitespace and improve test case formatting in stage_match_alphanumeric and stage_positive_character_groups for better readability
484dd0d refactor: remove success test fixture for backreferences_multiple to streamline test cases and improve maintainability
b8675b4 Merge branch 'main' into file-search
a542222 refactor: remove unused logger parameter from CreateTestFiles calls in file search test functions for improved clarity
b8a374f refactor: enhance file search test case structure by introducing ShouldEnableRecursiveFlag for improved clarity and consistency
c098b51 refactor: update test case structures to use StdinTestCaseCollection and FileSearchTestCaseCollection for consistency across all test functions
0b81a1b refactor: consolidate test case structures by introducing FileSearchTestCaseCollection and StdinTestCaseCollection for improved consistency and maintainability
90d3a72 chore: update .gitignore to exclude docs/ and include internal-docs/; remove outdated documentation files for cleaner project structure
79f0d0b chore: improve comments in find_grep_linux.sh and update docker run commands in test.sh for clarity
6febba5 refactor: clarify error message in file search test case for improved readability
5e2e158 refactor: update fruit and vegetable setup commands in test fixtures for consistency
7716a3c refactor: update regex in normalizeTesterOutput for improved output matching in stages tests
3d82a95 refactor: replace MoveGrepToTemp with RelocateSystemGrep in multiple test functions for improved clarity and consistency
2bf7cf5 refactor: rename and enhance grep relocation functions for clarity and improved teardown handling
5c4cef3 refactor: update test case structure to use StdinTestCases and FileSearchTestCases for consistency across multiple test functions
4a14705 chore: update .gitignore to include .idea/, dist/, and docs/ directories for better project management
f359872 refactor: enhance test case structure by implementing Run methods for FileSearchTestCase and StdinTestCase, and introduce TestCase interface for consistency
995536a feat: introduce find_grep_linux.sh for improved grep execution on Linux systems
987e311 refactor: move grep execution to temporary directory in multiple test functions for improved isolation and consistency
b814981 ci: update test workflow to use sudo for running tests
5f677d3 refactor: simplify grep movement logic by removing sudo and correcting path handling in temporary directory operations
614c3c3 fix: enhance grep execution logic in your_grep.sh to check for binary availability and support temporary directory usage
6449586 refactor: streamline file search test functions by introducing logger and moving grep to a temporary directory
d637002 refactor: replace TestCase with StdinTestCase in various test functions to standardize input handling and improve test case structure
1ef3d14 feat: add new test cases for file search and stdin input handling with validation of expected outputs and exit codes
bd28017 refactor: update regex in normalizeTesterOutput to accommodate variable output line order
5845a45 ci: add regenerated fixtures
be77cb4 feat: add regex replacements in normalizeTesterOutput function to standardize tester output formatting
e834966 fix: standardize error message formatting in file search test cases
1b6515b fix: improve error message consistency in file search test cases and sort output lines for comparison
ee67c46 feat: update course definition to enhance regex challenge descriptions, add new programming languages, and introduce file search stages
759bbd7 test: add new test cases for file search and backreferences, including success scenarios and expected outputs
3f7b64d chore: update .gitignore to include docs directory and modify Makefile to add new test cases for backreferences and file search
51244cf refactor: enhance test file creation by ensuring directory structure is created and adding cleanup functions for better resource management
581baf4 Revert "refactor: update file paths in test cases to use centralized test file structure for consistency and maintainability"
f9efefa fix: improve error message formatting in test case execution and enhance directory creation error handling
ee8dd5f refactor: update file paths in test cases to use centralized test file structure for consistency and maintainability
a291e48 feat: centralize test file creation for multi-line, multi-file, and recursive file search test cases to improve maintainability and error handling
9b850c4 feat: enhance single-line file search test case by centralizing test file creation and improving error handling
360aaf0 refactor: streamline file search test case execution by removing test file setup and cleanup, and enhancing output logging
82f5c11 feat: refactor writeFiles function to accept a slice of TestFile structs for improved file handling
9ab4067 feat: add utility functions for file handling and temporary directory creation in internal package
b20c07f feat: implement file search test cases for single-line, multi-line, multi-file, and recursive searches with test file setup and cleanup
92eb5d4 feat: add new test cases for single-line, multi-line, multi-file, and recursive file searches in the Makefile and tester definition
0b8406e feat: add Dockerfile and test script for local testing environment setup
d421164 docs: refine grep breakdown documentation for improved clarity on multi-line and multi-file search behavior, and enhance test file creation instructions
72d4695 docs: enhance grep breakdown documentation by clarifying multi-line and multi-file search behavior, refining test examples, and improving exit code explanations
7ee9b0e docs: enhance grep breakdown documentation by refining stage descriptions for single-line and multi-line file searches, improving clarity on search behavior and test examples
4bc28dd docs: update grep breakdown documentation to correct log messages and improve formatting for ignored features and future extensions
c7c7ca6 docs: update grep breakdown documentation to correct log message examples and enhance clarity on file search behavior
56179cc docs: refine grep breakdown documentation to clarify search terminology and enhance multi-file search examples with detailed usage instructions
2cdd5ae docs: update grep breakdown documentation to enhance clarity on multi-line file search, improve test file creation instructions, and refine stage descriptions for recursive search
f8f3f36 docs: enhance grep breakdown documentation by refining stage descriptions and clarifying pattern matching behavior for single-line file searches
9fb6e57 docs: refine grep breakdown documentation for improved clarity on file handling and matching behavior
deae155 docs: clarify exit codes and matching behavior in grep breakdown documentation for improved accuracy
9a9c1a6 docs: improve clarity in grep breakdown documentation by refining sentence structure and ensuring consistent phrasing throughout
d138dae docs: add note on GNU Grep output order and its implications for chronological sorting
09996fb docs: update grep breakdown documentation to correct log message formatting and improve output path clarity
4976355 docs: expand grep breakdown documentation to include detailed instructions for multiple-directory recursive search, emphasizing output formatting and testing procedures
e9b2aea docs: refine grep breakdown documentation to update stage descriptions, enhance clarity on recursive search functionality, and improve error handling notes
b7314e8 docs: update grep breakdown documentation to correct stage numbering and enhance clarity on multi-file search behavior and exit code logic
002be32 docs: revise grep breakdown documentation to clarify stages of file search, pattern matching, and expected behaviors for single and multiple files
fd14f3c docs: update grep breakdown documentation to clarify recursive search behavior and add future extension notes
f306ee9 docs: enhance grep breakdown documentation with consistent formatting and improved clarity on error handling and matching behavior
ea17ccd docs: remove outdated sections on include/exclude patterns and special character handling for grep
507b2ee docs: add comprehensive stages for grep functionality, including error handling, pattern matching, and recursive search options
9c23d1f chore: add new test cases for various regex patterns and remove obsolete test fixtures
520f610 fix: enhance your_grep.sh for macOS compatibility by using ggrep and improve pattern search handling
459aee9 refactor: update test cases to use StageSlugs instead of UntilStageSlug and remove obsolete tests
22e8223 docs: expand stage notes with additional grep usage examples and error handling scenarios
eeeab9f docs: add stage notes for grep usage and examples
aa39b78 chore: update test cases in Makefile to include additional backreference stages
8728eeb chore: rename grep scripts
3df90e5 chore: rename your_grep.sh scripts
af3c9eb chore: remove obsolete setup script and update your_grep.sh to use grep instead of rg
fe60754 chore: simplify CI setup
9c49afe refactor: modify your_grep.sh to switch from extended to Perl regex and ensure compatibility with macOS and Linux environments
15e7eed feat: add man page outputs to your_grep.sh for improved documentation and usage guidance
65571e8 refactor: enhance your_grep.sh to improve grep command usage and add regex behavior tests
90e89e8 fix: update your_grep.sh to explicitly use /usr/local/bin/grep for consistent behavior across environments
4aea554 fix: update setup_bsdgrep target to use sudo for all commands, ensuring proper permissions during bsdgrep installation
c7d4dec fix: streamline setup_bsdgrep target by consolidating commands for bsdgrep installation
64cd115 fix: enhance setup_bsdgrep target with additional debugging output for bsdgrep directory
2962a7d fix: refine setup_bsdgrep target by ensuring correct directory navigation and adding update script execution
22568a0 fix: update setup_bsdgrep target to include debugging output for bsdgrep installation
c585036 fix: use sudo for package installation in setup_bsdgrep target of Makefile
79b5e98 feat: add setup script for bsdgrep installation and configuration
ee06299 feat: add setup_bsdgrep target in Makefile and update GitHub Actions workflow to use it; introduce ggrep.sh for Perl regex support
c992efd fix: update your_grep.sh to use grep instead of ggrep for Perl regex support
0356540 fix: modify your_grep.sh to use Perl regex with ggrep when -E option is specified
c43df86 enhance: add debugging information to your_grep.sh script
9a9f78d refactor: replace ripgrep with grep in your_grep.sh script