Skip to content

Commit

Permalink
Merged "20.0.14" release into "20.0" branch
Browse files Browse the repository at this point in the history
With normal merge to keep all the commits
  • Loading branch information
fballiano authored May 19, 2022
2 parents 19cd891 + 20c5c55 commit ae2520c
Show file tree
Hide file tree
Showing 580 changed files with 7,177 additions and 4,087 deletions.
21 changes: 20 additions & 1 deletion .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"imageSize": 100,
"commit": true,
"commitConvention": "none",
"contributorTemplate": "<a href=\"<%= contributor.profile %>\"><img src=\"<%= contributor.avatar_url %>\" loading=\"lazy\" width=\"<%= options.imageSize %>\" alt=\"\"/><br /><sub><b><%= contributor.name %></b></sub></a>",
"contributors": [
{
"login": "sreichel",
Expand Down Expand Up @@ -1308,7 +1309,25 @@
"contributions": [
"code"
]
},
{
"login": "nimasan",
"name": "Benjamin MARROT",
"avatar_url": "https://avatars.githubusercontent.com/u/5030086?v=4",
"profile": "https://www.developpeur-web-tlse.fr/",
"contributions": [
"doc"
]
},
{
"login": "tmewes",
"name": "Tino Mewes",
"avatar_url": "https://avatars.githubusercontent.com/u/12640514?v=4",
"profile": "https://github.com/tmewes",
"contributions": [
"code"
]
}
],
"contributorsPerLine": 7
}
}
1,157 changes: 1,157 additions & 0 deletions .github/phpstan-baseline.neon

Large diffs are not rendered by default.

103 changes: 103 additions & 0 deletions .github/phpstan.neon
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
includes:
- ../vendor/macopedia/phpstan-magento1/extension.neon
- phpstan-baseline.neon
parameters:
magentoRootPath: %currentWorkingDirectory%
paths:
#lets start small with just few modules
- %currentWorkingDirectory%/app/code/core/Mage/Admin
- %currentWorkingDirectory%/app/code/core/Mage/Adminhtml
- %currentWorkingDirectory%/app/code/core/Mage/AdminNotification
- %currentWorkingDirectory%/app/code/core/Mage/Api
- %currentWorkingDirectory%/app/code/core/Mage/Api2
- %currentWorkingDirectory%/app/code/core/Mage/Authorizenet
- %currentWorkingDirectory%/app/code/core/Mage/Backup
- %currentWorkingDirectory%/app/code/core/Mage/Bundle
- %currentWorkingDirectory%/app/code/core/Mage/Captcha
- %currentWorkingDirectory%/app/code/core/Mage/Catalog
- %currentWorkingDirectory%/app/code/core/Mage/CatalogIndex
- %currentWorkingDirectory%/app/code/core/Mage/CatalogInventory
- %currentWorkingDirectory%/app/code/core/Mage/CatalogRule
- %currentWorkingDirectory%/app/code/core/Mage/CatalogSearch
# - %currentWorkingDirectory%/app/code/core/Mage/Centinel
- %currentWorkingDirectory%/app/code/core/Mage/Checkout
- %currentWorkingDirectory%/app/code/core/Mage/Cms
- %currentWorkingDirectory%/app/code/core/Mage/ConfigurableSwatches
- %currentWorkingDirectory%/app/code/core/Mage/Contacts
- %currentWorkingDirectory%/app/code/core/Mage/Core
- %currentWorkingDirectory%/app/code/core/Mage/Cron
- %currentWorkingDirectory%/app/code/core/Mage/CurrencySymbol
- %currentWorkingDirectory%/app/code/core/Mage/Customer
- %currentWorkingDirectory%/app/code/core/Mage/Dataflow
- %currentWorkingDirectory%/app/code/core/Mage/Directory
- %currentWorkingDirectory%/app/code/core/Mage/Downloadable
- %currentWorkingDirectory%/app/code/core/Mage/Eav
- %currentWorkingDirectory%/app/code/core/Mage/GiftMessage
- %currentWorkingDirectory%/app/code/core/Mage/GoogleAnalytics
- %currentWorkingDirectory%/app/code/core/Mage/GoogleCheckout
- %currentWorkingDirectory%/app/code/core/Mage/ImportExport
- %currentWorkingDirectory%/app/code/core/Mage/Index
- %currentWorkingDirectory%/app/code/core/Mage/Install
- %currentWorkingDirectory%/app/code/core/Mage/Log
- %currentWorkingDirectory%/app/code/core/Mage/Media
- %currentWorkingDirectory%/app/code/core/Mage/Newsletter
- %currentWorkingDirectory%/app/code/core/Mage/Oauth
- %currentWorkingDirectory%/app/code/core/Mage/Page
- %currentWorkingDirectory%/app/code/core/Mage/PageCache
- %currentWorkingDirectory%/app/code/core/Mage/Paygate
- %currentWorkingDirectory%/app/code/core/Mage/Payment
- %currentWorkingDirectory%/app/code/core/Mage/Paypal
# - %currentWorkingDirectory%/app/code/core/Mage/PaypalUk
- %currentWorkingDirectory%/app/code/core/Mage/Persistent
- %currentWorkingDirectory%/app/code/core/Mage/Poll
- %currentWorkingDirectory%/app/code/core/Mage/ProductAlert
- %currentWorkingDirectory%/app/code/core/Mage/Rating
- %currentWorkingDirectory%/app/code/core/Mage/Reports
- %currentWorkingDirectory%/app/code/core/Mage/Review
- %currentWorkingDirectory%/app/code/core/Mage/Rss
- %currentWorkingDirectory%/app/code/core/Mage/Rule
- %currentWorkingDirectory%/app/code/core/Mage/Sales
- %currentWorkingDirectory%/app/code/core/Mage/SalesRule
- %currentWorkingDirectory%/app/code/core/Mage/Sendfriend
- %currentWorkingDirectory%/app/code/core/Mage/Shipping
- %currentWorkingDirectory%/app/code/core/Mage/Sitemap
- %currentWorkingDirectory%/app/code/core/Mage/Tag
- %currentWorkingDirectory%/app/code/core/Mage/Tax
- %currentWorkingDirectory%/app/code/core/Mage/Uploader
# - %currentWorkingDirectory%/app/code/core/Mage/Usa
- %currentWorkingDirectory%/app/code/core/Mage/Widget
# - %currentWorkingDirectory%/app/code/core/Mage/Weee
- %currentWorkingDirectory%/app/code/core/Mage/Wishlist
excludePaths:
#incompatible interfaces
- */app/code/core/Mage/Admin/Model/Acl/Assert/Ip.php
- */app/code/core/Mage/Admin/Model/Acl/Assert/Time.php
- */app/code/core/Mage/Api/Model/Acl/Assert/Ip.php
- */app/code/core/Mage/Api/Model/Acl/Assert/Time.php
- */app/code/core/Mage/Adminhtml/Block/Widget/Grid/Block.php
- */app/code/core/Mage/Core/Model/Mysql4/Design/Theme/Collection.php
# deprecated _getHelper()
- */app/code/core/Mage/Adminhtml/Controller/Rss/Abstract.php
- */app/code/core/Mage/Adminhtml/controllers/Rss/OrderController.php
- */app/code/core/Mage/Adminhtml/controllers/Rss/CatalogController.php

# contains 1 abstract method and must therefore be declared abstract or implement the remaining methods
- */app/code/core/Mage/Dataflow/Model/Session/Adapter/Http.php
- */app/code/core/Mage/Dataflow/Model/Convert/Iterator/Http.php
- */app/code/core/Mage/Dataflow/Model/Convert/Iterator/File/Csv.php

# Cannot declare class Varien_Date, because the name is already in use
- */app/code/core/Mage/Catalog/Model/Product/Option/Type/Date.php

# Class phpseclib\Net\SSH2 not found.
- */Paypal/Model/Report/Settlement.php

# Class backup/db was not found while trying to analyse it
- */Adminhtml/controllers/System/BackupController.php

# Dataflow/Model/Convert/Iterator.php
- */Dataflow/Model/Convert/Iterator.php

level: 0
# universalObjectCratesClasses:
# - Varien_Object
4 changes: 4 additions & 0 deletions .github/phpstan_experimental_level.neon
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
includes:
- ./phpstan.neon
parameters:
level: 1
58 changes: 58 additions & 0 deletions .github/workflows/sonar.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: OpenMage LTS - Sonar - Full Analyses

on:
push:
pull_request:
types: [opened, synchronize, reopened]



jobs:
unit:
name: Unit Tests on ${{ matrix.php-versions }}
runs-on: ${{ matrix.operating-system }}
strategy:
max-parallel: 5
matrix:
operating-system: [ubuntu-latest]
php-versions: ['7.4', '8.1']
steps:
- uses: actions/checkout@v1
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: mbstring
tools: composer, pecl, phpcs, phpstan, phpunit:9.5
ini-values-csv: pcov.directory=api, post_max_size=256M, short_open_tag=On #optional, setup php.ini configuration
coverage: pcov #optional, setup coverage driver
env:
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Prepare
run: |
php -v
composer --version
composer install --dev -n --prefer-source --ignore-platform-req=php
- name: Run Unit Tests
run: phpunit --configuration ./dev/phpunit.xml.dist --testsuite=Unit;
- name: prepare SonarCloud Scan Data
continue-on-error: true
if: ${{ matrix.php-versions == '8.1' }}
run: |
echo $PWD
ls -la
head ./dev/tests/clover.xml
sed -i 's@'$GITHUB_WORKSPACE'/@/github/workspace/@g' ./dev/tests/junit.xml
sed -i 's@'$GITHUB_WORKSPACE'/@/github/workspace/@g' ./dev/tests/clover.xml
head ./dev/tests/clover.xml
ls -la
- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
continue-on-error: true
if: ${{ matrix.php-versions == '8.1' }} && SONAR_TOKEN
with:
args: >
-Dproject.settings=dev/sonar-project.properties
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
51 changes: 50 additions & 1 deletion .github/workflows/static-code-analyses.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,28 @@ jobs:
- name: Check .phtml files
run: '! find app/design -type f -name "*.phtml" -exec php -d error_reporting=32767 -l {} \; 2>&1 1> /dev/null | grep "^"'

php_stan:
name: PHP Stan ${{ matrix.directories }} - ${{ matrix.config_files }}
runs-on: [ubuntu-latest]
strategy:
max-parallel: 2
matrix:
directories: [
'',
#'lib/',
]
config_files: [
'.github/phpstan.neon',
]
steps:
- uses: actions/checkout@v2
- name: Install dependencies
run: composer install --prefer-dist --no-progress --no-suggest --ignore-platform-reqs
- name: ensure existance of ./app/code/local
run: mkdir -p app/code/local
- name: PHPStan Static Analysis
run: php vendor/bin/phpstan.phar analyze -c ${{ matrix.config_files }} ${{ matrix.directories }}

php_syntax_experimental:
name: PHP Syntax ${{ matrix.php-versions }} - experimental
runs-on: ${{ matrix.operating-system }}
Expand All @@ -39,7 +61,7 @@ jobs:
fail-fast: false
matrix:
operating-system: [ubuntu-latest]
php-versions: ['8.0']
php-versions: ['8.0','8.1']
steps:
- uses: actions/checkout@v1
- name: Setup PHP
Expand All @@ -59,3 +81,30 @@ jobs:
continue-on-error: true
run: '! find app/design -type f -name "*.phtml" -exec php -d error_reporting=32767 -l {} \; 2>&1 1> /dev/null | grep "^"'


php_stan_experimental:
name: PHP Stan ${{ matrix.directories }} - ${{ matrix.config_files }} - experimental
runs-on: [ubuntu-latest]
needs: php_stan
strategy:
max-parallel: 1
fail-fast: false
matrix:
directories: [
''
]
config_files: [
'.github/phpstan_experimental_level.neon',
]
include:
- directories: 'lib/'
config_files: '.github/phpstan.neon'
steps:
- uses: actions/checkout@v2
- name: Install dependencies
run: composer install --prefer-dist --no-progress --no-suggest --ignore-platform-reqs
- name: ensure existance of ./app/code/local
run: mkdir -p app/code/local
- name: PHPStan Static Analysis
continue-on-error: true
run: php vendor/bin/phpstan.phar analyze --error-format=raw -c ${{ matrix.config_files }} ${{ matrix.directories }}
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
/app/etc/local.xml
/media/catalog
/media/captcha
/media/css
/media/css_secure
/media/email/logo
/media/favicon
/media/js
/media/sales/store/logo
/media/sales/store/logo_html
/media/wysiwyg
/dev/tests/functional/generated
/dev/tests/functional/vendor
22 changes: 22 additions & 0 deletions .gitpod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# List the start up tasks. Learn more https://www.gitpod.io/docs/config-start-tasks/
tasks:
- init: echo 'init script' # runs during prebuild
command: echo 'start script'
- name: Install OpenMage
init: |
BASE_URL="$(echo "$GITPOD_WORKSPACE_URL" | sed s~https://~https://8000-~)"
HOST_PORT=8000 BASE_URL=$BASE_URL bash dev/gitpod/install.sh
command: docker ps
openMode: tab-after
- name: prepare git
init: git config core.fileMode false

vscode:
extensions:
- bmewburn.vscode-intelephense-client

# List the ports to expose. Learn more https://www.gitpod.io/docs/config-ports/
ports:
- port: 8000
visibility: public
onOpen: open-preview
Loading

0 comments on commit ae2520c

Please sign in to comment.