Skip to content

Commit 592ce00

Browse files
committed
Lint and remove use doc.
1 parent 353b721 commit 592ce00

File tree

3 files changed

+15
-33
lines changed

3 files changed

+15
-33
lines changed

.scaffold/tests/bats/_assert_init.bash

+15-15
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ assert_files_present_extension_type_theme() {
118118
popd >/dev/null || exit 1
119119
}
120120

121-
assert_workflow_php() {
121+
assert_workflow() {
122122
local dir="${1:-$(pwd)}"
123123

124124
pushd "${dir}" >/dev/null || exit 1
@@ -127,20 +127,20 @@ assert_workflow_php() {
127127
./.devtools/start-server.sh
128128
./.devtools/provision.sh
129129

130-
# # Lint.
131-
# pushd "build" >/dev/null || exit 1
132-
# vendor/bin/phpcs
133-
# vendor/bin/phpstan
134-
# vendor/bin/rector --clear-cache --dry-run
135-
# vendor/bin/phpmd . text phpmd.xml
136-
# vendor/bin/twigcs
137-
# popd >/dev/null || exit 1
138-
#
139-
# # Test.
140-
# ./.devtools/test.sh
141-
#
142-
# # Change mode to make bats have enough permission to clean tmp test directory.
143-
# chmod -R 777 "build/web/sites/default"
130+
# # Lint.
131+
# pushd "build" >/dev/null || exit 1
132+
# vendor/bin/phpcs
133+
# vendor/bin/phpstan
134+
# vendor/bin/rector --clear-cache --dry-run
135+
# vendor/bin/phpmd . text phpmd.xml
136+
# vendor/bin/twigcs
137+
# popd >/dev/null || exit 1
138+
#
139+
# # Test.
140+
# ./.devtools/test.sh
141+
#
142+
# # Change mode to make bats have enough permission to clean tmp test directory.
143+
# chmod -R 777 "build/web/sites/default"
144144

145145
popd >/dev/null || exit 1
146146
}

.scaffold/tests/bats/functional.init.bats

-2
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ export SCRIPT_FILE="init.sh"
2727
"nothing" # use GitHub funding
2828
"nothing" # use GitHub PR template
2929
"nothing" # use Renovate
30-
"nothing" # remove docs
3130
"nothing" # remove init script
3231
"nothing" # proceed with init
3332
)
@@ -52,7 +51,6 @@ export SCRIPT_FILE="init.sh"
5251
"nothing" # use GitHub funding
5352
"nothing" # use GitHub PR template
5453
"nothing" # use Renovate
55-
"nothing" # remove docs
5654
"nothing" # remove init script
5755
"nothing" # proceed with init
5856
)

init.sh

-16
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,6 @@ remove_nodejs() {
139139
rm -f package.lock >/dev/null || true
140140
rm -f yarn.lock >/dev/null || true
141141
rm -Rf node_modules >/dev/null || true
142-
rm -Rf docs/nodejs || true
143142

144143
remove_string_content_line "\/.npmignore" ".gitattributes"
145144

@@ -153,12 +152,10 @@ remove_release_drafter() {
153152
rm -f .github/workflows/draft-release-notes.yml || true
154153
rm -f .github/release-drafter.yml
155154
remove_tokens_with_content "RELEASEDRAFTER"
156-
rm -Rf docs/content/ci/release-drafter.mdx || true
157155
}
158156

159157
remove_pr_autoassign() {
160158
rm -f .github/workflows/assign-author.yml || true
161-
rm -Rf docs/content/ci/auto-assign-pr.mdx || true
162159
}
163160

164161
remove_funding() {
@@ -171,14 +168,6 @@ remove_pr_template() {
171168

172169
remove_renovate() {
173170
rm -f renovate.json || true
174-
rm -Rf docs/content/ci/renovate.mdx || true
175-
}
176-
177-
remove_docs() {
178-
rm -Rf docs || true
179-
rm -f .github/workflows/test-docs.yml || true
180-
rm -f .github/workflows/release-docs.yml || true
181-
remove_string_content_line "\/docs" ".gitattributes"
182171
}
183172

184173
process_readme() {
@@ -249,8 +238,6 @@ process_internal() {
249238
rm -f ".github/workflows/test-scaffold.yml" >/dev/null || true
250239
rm -Rf .scaffold >/dev/null || true
251240

252-
rm -f "docs/static/img/init.gif" >/dev/null || true
253-
254241
remove_tokens_with_content "META"
255242
remove_special_comments
256243

@@ -284,7 +271,6 @@ main() {
284271
use_funding="$(ask_yesno "Use GitHub funding")"
285272
use_pr_template="$(ask_yesno "Use GitHub PR template")"
286273
use_renovate="$(ask_yesno "Use Renovate")"
287-
use_docs="$(ask_yesno "Use docs")"
288274
remove_self="$(ask_yesno "Remove this script")"
289275

290276
echo
@@ -301,7 +287,6 @@ main() {
301287
echo "Use GitHub funding : ${use_funding}"
302288
echo "Use GitHub PR template : ${use_pr_template}"
303289
echo "Use Renovate : ${use_renovate}"
304-
echo "Use Docs : ${use_docs}"
305290
echo "Remove this script : ${remove_self}"
306291
echo "---------------------------------"
307292
echo
@@ -330,7 +315,6 @@ main() {
330315
[ "${use_funding}" != "y" ] && remove_funding
331316
[ "${use_pr_template}" != "y" ] && remove_pr_template
332317
[ "${use_renovate}" != "y" ] && remove_renovate
333-
[ "${use_docs}" != "y" ] && remove_docs
334318

335319
process_readme "${extension_name}"
336320

0 commit comments

Comments
 (0)