<commit_before>#!/usr/bin/env bash
set -e 

# call ? /cre/php-entrypoint.sh # later maybe php-dev-entrypoint.sh

# https://www.yiiframework.com/wiki/2547/draft-understanding-yii-3

composer create-project --prefer-dist --stability=dev yiisoft/yii-project-template /cre/tmp/yii
#instead: git clone, composer config repositories path /cre/..., composer install


cd /cre/tmp/yii
composer config minimum-stability dev
composer config prefer-stable true
composer config repositories.cre  '{"type:" "path", "url:" "/cre/tmp/php/packages"}' 
composer config repositories.npm '{"type": "composer", "url": "https://asset-packagist.org"}'
composer require "foxy/foxy:^1.0.0"
composer require php-extended/php-http-message-factory-psr17
composer require yiisoft/yii-base-web
composer install

##rsync -rl /cre/tmp/yii/ /cre/www/yii
rsync -r /cre/tmp/yii/ /cre/www/yii
# later use --exclude /dir1/ --exclude /dir2/
##rm -rf /cre/tmp/yii

##chmod -R 774 /cre/www/yii/web/assets 
##chown -R www-data:www-data /cre/www/yii/web/assets

exec "$@"
<commit_msg>Add packages<commit_after>#!/usr/bin/env bash
set -e 

# call ? /cre/php-entrypoint.sh # later maybe php-dev-entrypoint.sh

# https://www.yiiframework.com/wiki/2547/draft-understanding-yii-3

composer create-project --prefer-dist --stability=dev yiisoft/yii-project-template /cre/tmp/yii
#instead: git clone, composer config repositories path /cre/..., composer install


cd /cre/tmp/yii
composer config minimum-stability dev
composer config prefer-stable true
composer config repositories.cre  '{"type:" "path", "url:" "/cre/tmp/php/packages"}' 
composer config repositories.npm '{"type": "composer", "url": "https://asset-packagist.org"}'
composer require "foxy/foxy:^1.0.0"
composer require php-extended/php-http-message-factory-psr17

composer require yiisoft/log
composer require yiisoft/cache
composer require yiisoft/di
composer require yiisoft/rbac
composer require yiisoft/view   
composer require yiisoft/db


composer require yiisoft/yii-base-web
composer install

##rsync -rl /cre/tmp/yii/ /cre/www/yii
rsync -r /cre/tmp/yii/ /cre/www/yii
# later use --exclude /dir1/ --exclude /dir2/
##rm -rf /cre/tmp/yii

##chmod -R 774 /cre/www/yii/web/assets 
##chown -R www-data:www-data /cre/www/yii/web/assets

exec "$@"

{'fraction_non_alphanumeric': 0.15350683722981914, 'fraction_numerical': 0.013233348037053375, 'mean_word_length': 3.973684210526316, 'pattern_counts': {'":': 4, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 14, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4605227', 'n_tokens_mistral': 891, 'n_tokens_neox': 839, 'n_words': 193}