-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]> style: fix template syntax Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]> tests: github ci Signed-off-by: Jérôme Engeln <[email protected]>
- Loading branch information
1 parent
86fa888
commit 40b9dc3
Showing
33 changed files
with
4,364 additions
and
190 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{ "extends": ["stylelint-config-standard"] } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,22 +17,22 @@ PLUGIN_NAME=agence-adeliom/sylius-tailwindcss-theme | |
### DEVELOPMENT | ||
### ¯¯¯¯¯¯¯¯¯¯¯ | ||
|
||
install: sylius ## Install Plugin on Sylius [SYLIUS_VERSION=1.12.13] [SYMFONY_VERSION=6.4] | ||
.PHONY: install | ||
install-project: sylius ## Install Plugin on Sylius [SYLIUS_VERSION=1.12.13] [SYMFONY_VERSION=6.4] | ||
.PHONY: install-project | ||
|
||
halt: | ||
cd install/Application && $(DDEV) stop | ||
|
||
start: | ||
cd install/Application && $(DDEV) start | ||
|
||
reset: ## Remove dependencies | ||
remove-project: ## Remove dependencies | ||
ifneq ("$(wildcard install/Application/bin/console)","") | ||
${CONSOLE} doctrine:database:drop --force --if-exists || true | ||
endif | ||
cd install/Application && $(DDEV) stop | ||
$(DDEV) clean sylius-tailwindcss-theme | ||
rm -rf install/Application | ||
.PHONY: reset | ||
.PHONY: remove-project | ||
|
||
phpunit: phpunit-configure phpunit-run ## Run PHPUnit | ||
.PHONY: phpunit | ||
|
@@ -112,3 +112,112 @@ help: ## Dislay this help | |
echo $$line | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m%s\n", $$1, $$2}'; fi; \ | ||
done; unset IFS; | ||
.PHONY: help | ||
|
||
apply-changes: | ||
cp -r assets ${TEST_DIRECTORY}/themes/TailwindTheme | ||
cp -r templates ${TEST_DIRECTORY}/themes/TailwindTheme | ||
|
||
build-changes: | ||
${NPM} install | ||
${NPM} run build | ||
|
||
watch-changes: | ||
${NPM} install | ||
${NPM} run watch | ||
|
||
lint-changes: | ||
$(DDEV) composer install | ||
$(DDEV) exec vendor/bin/twigcs templates/ --severity error --display blocking --reporter githubAction | ||
|
||
### | ||
### CI TEST | ||
### ¯¯¯¯¯¯¯¯¯¯¯ | ||
### ¯¯¯¯¯¯¯¯¯¯¯ | ||
### ¯¯¯¯¯¯¯¯¯¯¯ | ||
### ¯¯¯¯¯¯¯¯¯¯¯ | ||
### ¯¯¯¯¯¯¯¯¯¯¯ | ||
|
||
|
||
|
||
|
||
COMPOSER_CI_ROOT=composer | ||
TEST_DIRECTORY_CI=./install/Application | ||
CONSOLE_CI=cd ./install/Application && php bin/console -e test | ||
COMPOSER_CI=cd ./install/Application && composer | ||
NPM_CI=cd ./install/Application && npm | ||
|
||
|
||
install-ci: sylius-ci ## Install Plugin on Sylius [SYLIUS_VERSION=1.12.13] [SYMFONY_VERSION=6.4] | ||
.PHONY: install | ||
|
||
reset-ci: ## Remove dependencies | ||
ifneq ("$(wildcard install/Application/bin/console)","") | ||
${CONSOLE_CI} doctrine:database:drop --force --if-exists || true | ||
endif | ||
rm -rf install/Application | ||
.PHONY: reset-ci | ||
|
||
phpunit-ci: phpunit-configure phpunit-run ## Run PHPUnit | ||
.PHONY: phpunit | ||
|
||
### | ||
### OTHER | ||
### ¯¯¯¯¯¯ | ||
|
||
sylius-ci: sylius-standard-ci update-dependencies-ci install-plugin-ci install-theme-ci install-sylius-ci | ||
.PHONY: sylius-ci | ||
|
||
sylius-standard-ci: | ||
${COMPOSER_CI_ROOT} create-project sylius/sylius-standard ${TEST_DIRECTORY_CI} "~${SYLIUS_VERSION}" --no-install --no-scripts | ||
${COMPOSER_CI} config allow-plugins true | ||
${COMPOSER_CI} require sylius/sylius:"~${SYLIUS_VERSION}" | ||
|
||
update-dependencies-ci: | ||
${COMPOSER_CI} config extra.symfony.require "~${SYMFONY_VERSION}" | ||
${COMPOSER_CI} update --no-progress -n | ||
|
||
install-plugin-ci: | ||
${COMPOSER_CI} config repositories.plugin '{"type": "path", "url": "../../"}' | ||
${COMPOSER_CI} config repositories.adeliom '{"type":"vcs","url":"[email protected]:agence-adeliom/sylius-tailwindcss-theme.git"}' | ||
${COMPOSER_CI} config extra.symfony.allow-contrib true | ||
${COMPOSER_CI} config minimum-stability "dev" | ||
${COMPOSER_CI} config prefer-stable true | ||
${COMPOSER_CI} req ${PLUGIN_NAME}:* --prefer-source --no-scripts | ||
|
||
install-theme-ci: | ||
ifneq ("$(wildcard install/Application)","") | ||
cp -r install/Application tests | ||
endif | ||
mkdir ${TEST_DIRECTORY_CI}/themes/TailwindTheme | ||
cp -r assets ${TEST_DIRECTORY_CI}/themes/TailwindTheme | ||
cp -r templates ${TEST_DIRECTORY_CI}/themes/TailwindTheme | ||
cp composer.json ${TEST_DIRECTORY_CI}/themes/TailwindTheme | ||
cp webpack.config.js ${TEST_DIRECTORY_CI}/themes/TailwindTheme | ||
cp tailwind.config.js ${TEST_DIRECTORY_CI} | ||
cp postcss.config.js ${TEST_DIRECTORY_CI} | ||
echo "const tailwindTheme = require('./themes/TailwindTheme/webpack.config');" >> ${TEST_DIRECTORY_CI}/webpack.config.js | ||
echo "module.exports = [shopConfig, adminConfig, appShopConfig, appAdminConfig, tailwindTheme];" >> ${TEST_DIRECTORY_CI}/webpack.config.js | ||
echo " tailwindTheme:" >> ${TEST_DIRECTORY_CI}/config/packages/assets.yaml | ||
echo " json_manifest_path: '%kernel.project_dir%/public/themes/tailwind-theme/manifest.json'" >> ${TEST_DIRECTORY_CI}/config/packages/assets.yaml | ||
echo " tailwindTheme: '%kernel.project_dir%/public/themes/tailwind-theme'" >> ${TEST_DIRECTORY_CI}/config/packages/webpack_encore.yaml | ||
|
||
install-sylius-ci: | ||
${CONSOLE_CI} doctrine:database:create --if-not-exists | ||
${CONSOLE_CI} doctrine:migrations:migrate -n | ||
${CONSOLE_CI} sylius:fixtures:load default -n | ||
${NPM_CI} install | ||
${NPM_CI} install tailwindcss | ||
${NPM_CI} install daisyui | ||
${NPM_CI} install axios | ||
${NPM_CI} install postcss-loader@^7.0.0 --save-dev | ||
${NPM_CI} install autoprefixer --save-dev | ||
${NPM_CI} run build | ||
${CONSOLE_CI} cache:clear | ||
|
||
|
||
phpunit-configure-ci: | ||
cp phpunit.xml.dist ${TEST_DIRECTORY_CI}/phpunit.xml | ||
|
||
phpunit-run-ci: | ||
cd ${TEST_DIRECTORY_CI} && ./vendor/bin/phpunit --testdox | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
@import './Button/index.css'; | ||
@import './Dropdown/index.css'; | ||
@import url('./Button/index.css'); | ||
@import url('./Dropdown/index.css'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
@import "./Loading/index.css"; | ||
@import url("./Loading/index.css"); |
Oops, something went wrong.