Add license check target and some bash utils
BREAKING CHANGES:
BINARIES_PATHmove from$(CURDIR)/binto$(CURDIR)/.bin
Please update your.gitignorefile from ignorebin/dir to.bin/!common/git/check/has-diff- now output new files not in index-tree, ifFILES_TO_CHECKandFILES_TO_SKIP
Add:
- Makefile variables:
GET_GIT_FILES_SEPARATOR- files list separator using to output in bash functionget_git_changed_files
- Next bash utils functions in includes defines:
INCLUDE_STRINGS- some string urilsappend_str_with_separator- append string to end with separator
prefix and returnappend_str_with_new_line- callappend_str_with_separatorwith new
line separatorshift_str_on- split string by new line and add prefix (shift) for
each lineshift_str_on_tab- callshift_str_onwith tab prefixescape_re_str- escape string as regexp string (to pass to grep)
INCLUDE_FS_CONSUME- call function with glob findtoggle_globs- enable/disable next globs paramsdotglobnullglob
globstaris_glob- check passed string is glob string
do_in_dir-cdto dir and do function, after call returns to
current dir.foreach_dir_by_glob- call function for each file found by glob
INCLUDE_GIT_OPS- some git operationsis_git_repo_has_not_changes- returns 1 if git repo has diff
(uncommit changes)get_git_changed_files- returns 1 and echo list of files have
changes in one string separated by$(GET_GIT_FILES_SEPARATOR)
- Targets:
common/git/check/no-changes- check that git repo has not
uncommitted changescommon/license/check- check that all files with extension have
license head
Changes:
common/git/check/has-diff- add paramSKIP_NEW_FILESto skip
adding new files to diff
Fix:
- remove
git pullin install/upgrade sections in README
Chore:
- move strings utils defines to
00-strings.mk - refact code to new bash utils functions
- upgrade
jqversion to1.8.2 - some formatting fixes in README