@@ -265,8 +265,27 @@ stats:
265265# Update README badges with current problem counts
266266.PHONY : update-badges
267267update-badges :
268- @echo " $( call color_green, Updating README badges...) "
268+ @echo " Updating README badges..."
269269 @./scripts/update_badges.sh
270+ @echo " $( call color_green,README badges updated.) "
271+
272+ # README Generation
273+ .PHONY : readme
274+ readme : # # Generate README from problem configurations
275+ @$(PYTHON ) scripts/generate_readme.py
276+
277+ .PHONY : readme-check
278+ readme-check : # # Check if README is up to date
279+ @echo " Checking if README is up to date..."
280+ @cp README.md README.md.backup
281+ @$(PYTHON ) scripts/generate_readme.py > /dev/null
282+ @if ! diff -q README.md README.md.backup > /dev/null; then \
283+ echo " $( call color_yellow,README is out of date. Run ' make readme' to update.) " ; \
284+ mv README.md.backup README.md; \
285+ else \
286+ echo " $( call color_green,README is up to date.) " ; \
287+ rm README.md.backup; \
288+ fi
270289
271290# Debug Google Test configuration
272291.PHONY : debug-gtest
@@ -334,6 +353,8 @@ help:
334353 @echo " $( call color_yellow,Utility Targets:) "
335354 @echo " clean - Clean build artifacts"
336355 @echo " stats - Show project statistics"
356+ @echo " readme - Generate README from problem configurations"
357+ @echo " readme-check - Check if README is up to date"
337358 @echo " update-badges - Update README badges with current problem counts"
338359 @echo " debug-gtest - Debug Google Test configuration"
339360 @echo " help - Show this help message"
0 commit comments