Makefile
changeset 1909 6b76120bd2d3
parent 1908 0260f8ffef35
child 1912 8b81a8f0f692
equal deleted inserted replaced
1908:0260f8ffef35 1909:6b76120bd2d3
   195 	@sed -n -e '/^[[:alnum:]_-]*:/{s=^\(.*\):.*=  \1=;p;}' $(MAKEFILE_LIST)
   195 	@sed -n -e '/^[[:alnum:]_-]*:/{s=^\(.*\):.*=  \1=;p;}' $(MAKEFILE_LIST)
   196 
   196 
   197 .PHONY: check-format-policy
   197 .PHONY: check-format-policy
   198 check-format-policy:
   198 check-format-policy:
   199 	\
   199 	\
   200 for f in *.rst; do \
   200 for f in $(RST_FILES); do \
   201   if grep '.. -\*- coding: utf-8; -\*-' $$f >/dev/null; then :; else \
   201   if grep '^.. -\*- coding: utf-8; -\*-' $$f >/dev/null; then :; else \
   202     echo $$f:1:" Has no 'coding: utf-8' directive."; \
   202     echo $$f:1:" Has no 'coding: utf-8' directive."; \
   203   fi; \
   203   fi; \
   204   if grep '.. include:: HEADER.rst' $$f >/dev/null; then :; else \
   204   if grep '^.. include:: HEADER.rst' $$f >/dev/null; then :; else \
   205     echo $$f:2:" Has no 'include:: HEADER.rst' directive."; \
   205     echo $$f:2:" Has no 'include:: HEADER.rst' directive."; \
   206   fi; \
   206   fi; \
   207   if grep '.. contents::' $$f >/dev/null; then :; else \
   207   if grep '^.. contents::' $$f >/dev/null; then :; else \
   208     echo $$f:7:" Has no 'contents::' directive."; \
   208     echo $$f:7:" Has no 'contents::' directive."; \
   209   fi; \
   209   fi; \
       
   210   if grep '^   :local:' $$f >/dev/null; then :; else \
       
   211     echo $$f:7:" Has no ':local:' directive."; \
       
   212   fi; \
   210 done
   213 done
   211 
   214