7 if [ ! -f "${FILE}" ]; then
8 echo 'Please provide a file as a first argument.'
12 FILE_LIST
="$(tar --list --file="${FILE}")"
16 echo 'Searching for files'
20 printf "Found: %s\n" "${filePath}"
25 printf "Found unexpected file: %s with extension %s\n" "${pathWithoutFirst}" "${extension}"
29 if [ "${filePath: -1}" = "/" ]; then
33 pathWithoutFirst
="$(echo "$filePath" | cut -d / -f 2-)"
35 filename
=$
(basename -- "$pathWithoutFirst")
36 extension
="${filename##*.}"
38 case $pathWithoutFirst in
41 "${extension}" != "png" -a "${extension}" != "txt" \
42 -a "${extension}" != "html" -a "${extension}" != "js" \
43 -a "${extension}" != "css" -a "${extension}" != "gif" \
50 "${extension}" != "js" -a "${extension}" != "map" \
51 -a "${extension}" != "css" -a "${filename}" != "LICENSE" \
52 -a "${extension}" != "txt" \
58 if [ "${extension}" != "js" ];then
63 if [ "${extension}" != "js" ];then
69 "${extension}" != "js" -a "${extension}" != "mjs" \
75 if [ "${extension}" != "sql" ]; then
80 if [ "${extension}" != "php" ]; then
85 if [ "${extension}" != "mo" ]; then
91 "${extension}" != "php" -a "${extension}" != "twig" \
92 -a "${extension}" != "css" \
93 -a "${extension}" != "scss" -a "${extension}" != "gif" -a "${extension}" != "map" \
99 if [ "${extension}" != "twig" ]; then
105 "${extension}" != "php" -a "${extension}" != "md" \
106 -a "${filename}" != "README" \
107 -a "${filename}" != "TEMPLATE" -a "${filename}" != "TEMPLATE_ABSTRACT" \
114 "${extension}" != "css" -a "${extension}" != "png" \
115 -a "${extension}" != "scss" -a "${extension}" != "map" \
116 -a "${extension}" != "svg" -a "${extension}" != "ico" \
117 -a "${extension}" != "gif" -a "${extension}" != "json" \
122 vendor
/phpmyadmin
/sql-parser
/locale
/*)
123 if [ "${extension}" != "mo" ]; then
127 vendor
/composer
/ca-bundle
/res
/cacert.pem
)
129 vendor
/pragmarx
/google2fa-qrcode
/composer.lock
)
131 vendor
/williamdes
/mariadb-mysql-kbs
/dist
/merged-ultraslim.json
)
133 vendor
/composer
/installed.json
)
135 vendor
/tecnickcom
/tcpdf
/*)
137 "${extension}" != "php" -a "${filename}" != "LICENSE.TXT" \
138 -a "${filename}" != "README.md" -a "${filename}" != "CHANGELOG.TXT" \
139 -a "${filename}" != "VERSION" -a "${filename}" != "composer.json" \
140 -a "${extension}" != "z" \
147 "${extension}" != "php" -a "${filename}" != "LICENSE" \
148 -a "${filename}" != "README" -a "${filename}" != "CHANGELOG" \
149 -a "${filename}" != "composer.json" -a "${filename}" != "CHANGELOG.md" \
150 -a "${filename}" != "README.md" -a "${filename}" != "BACKERS.md" \
151 -a "${filename}" != "LICENSE.md" -a "${filename}" != "ARCHITECTURE.md" \
152 -a "${filename}" != "LICENSE.txt" -a "${filename}" != "AUTHORS" \
153 -a "${filename}" != "LICENCE.md" -a "${filename}" != "LICENCE" \
162 RELEASE-DATE-
[1-9].
[0-9].
[0-9])
164 RELEASE-DATE-
[1-9].
[0-9].
[0-9]-dev)
166 RELEASE-DATE-
[1-9].
[0-9]+snapshot
)
194 config.sample.inc.php
)
196 show_config_errors.php
)
205 for filePath
in ${FILE_LIST}; do
210 */easy-coding-standard.neon
)
228 */phpbench.json.dist
)
230 */.php-cs-fixer.dist.php
)
256 */infection.json.dist
)
260 */infection.json.dist
)
266 */.phpunit.result.cache
)
270 */phpstan-baseline.neon
)
282 */twig
/twig
/lib
/Twig
/Node
/Expression
/Test
/*)
284 */twig
/twig
/lib
/Twig
/Test
/*)
286 *twig
/twig
/src
/Node
/Expression
/Test
/*)
324 *vendor
/*CONTRIBUTING.md
*)
326 *CODE_OF_CONDUCT.md
*)
336 if [ ${found} -gt 0 ]; then
337 echo 'Some new files to be excluded where found.'
338 echo 'Please update create-release.sh'
341 echo 'Everything looks okay'