Skip to content

Commit

Permalink
Merge pull request #40 from PrestaShop/dev
Browse files Browse the repository at this point in the history
Release 2.0.1
  • Loading branch information
Progi1984 authored Jan 12, 2021
2 parents 9d1b101 + 63a6722 commit 37b3613
Show file tree
Hide file tree
Showing 27 changed files with 2,516 additions and 310 deletions.
19 changes: 19 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
<!-----------------------------------------------------------------------------
Thank you for contributing to the PrestaShop project!
Please take the time to edit the "Answers" rows below with the necessary information.
Check out our contribution guidelines to find out how to complete it:
https://devdocs.prestashop.com/1.7/contribute/contribution-guidelines/#pull-requests
------------------------------------------------------------------------------>

| Questions | Answers
| ------------- | -------------------------------------------------------
| Description? | Please be specific when describing the PR. <br> Every detail helps: versions, browser/server configuration, specific module/theme, etc. Feel free to add more information below this table.
| Type? | bug fix / improvement / new feature / refacto / critical
| BC breaks? | yes / no
| Deprecations? | yes / no
| Fixed ticket? | Fixes PrestaShop/Prestashop#{issue number here}.
| How to test? | Please indicate how to best verify that this PR is correct.

<!-- Click the form's "Preview" button to make sure the table is functional in GitHub. Thank you! -->
16 changes: 16 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
schedule:
interval: daily
time: "04:00"
open-pull-requests-limit: 10
target-branch: dev
- package-ecosystem: composer
directory: "/"
schedule:
interval: daily
time: "04:00"
open-pull-requests-limit: 10
target-branch: dev
14 changes: 14 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
branches:
- master
name-template: v$NEXT_PATCH_VERSION
tag-template: v$NEXT_PATCH_VERSION
categories:
- title: 🚀 Improvements
label: enhancement
- title: 🐛 Bug Fixes
label: bug
change-template: '- #$NUMBER: $TITLE by @$AUTHOR'
template: |
# Changes
$CHANGES
25 changes: 25 additions & 0 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Build
on: [push, pull_request]

jobs:
deploy:
name: build dependencies & create artifact
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]

# Install PHP dependencies (Production ONLY)
- name: Install composer dependencies
run: composer install --no-dev -o

# Remove development files
- name: Clean-up project
uses: PrestaShopCorp/[email protected]

# Zip files and upload to artifacts list
- name: Create & upload artifact
uses: actions/upload-artifact@v1
with:
name: ${{ github.event.repository.name }}
path: ../
66 changes: 66 additions & 0 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: PHP tests
on: [push, pull_request]
jobs:
# Check there is no syntax errors in the project
php-linter:
name: PHP Syntax check 5.6|7.2|7.3
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]

- name: PHP syntax checker 5.6
uses: prestashop/github-action-php-lint/5.6@master

- name: PHP syntax checker 7.2
uses: prestashop/github-action-php-lint/7.2@master

- name: PHP syntax checker 7.3
uses: prestashop/github-action-php-lint/7.3@master

# Check the PHP code follow the coding standards
php-cs-fixer:
name: PHP-CS-Fixer
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]

- name: Run PHP-CS-Fixer
uses: prestashopcorp/github-action-php-cs-fixer@master

# Run PHPStan against the module and a PrestaShop release
phpstan:
name: PHPStan
runs-on: ubuntu-latest
strategy:
matrix:
presta-versions: ['1.7.1.0', 'latest']
steps:
- name: Checkout
uses: actions/[email protected]

# Add vendor folder in cache to make next builds faster
- name: Cache vendor folder
uses: actions/cache@v1
with:
path: vendor
key: php-${{ hashFiles('composer.lock') }}

# Add composer local folder in cache to make next builds faster
- name: Cache composer folder
uses: actions/cache@v1
with:
path: ~/.composer/cache
key: php-composer-cache

- run: composer install

# Docker images prestashop/prestashop may be used, even if the shop remains uninstalled
- name: Pull PrestaShop files (Tag ${{ matrix.presta-versions }})
run: docker run -tid --rm -v ps-volume:/var/www/html --name temp-ps prestashop/prestashop:${{ matrix.presta-versions }}

# Run a container for PHPStan, having access to the module content and PrestaShop sources.
# This tool is outside the composer.json because of the compatibility with PHP 5.6
- name : Run PHPStan
run: docker run --rm --volumes-from temp-ps -v $PWD:/web/module -e _PS_ROOT_DIR_=/var/www/html --workdir=/web/module phpstan/phpstan:0.12 analyse --configuration=/web/module/tests/phpstan/phpstan.neon
6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
/config_*.xml
/translations/*.php
config_*.xml
translations/
vendor/
.php_cs.cache
11 changes: 11 additions & 0 deletions .php_cs.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?php

$config = new PrestaShop\CodingStandards\CsFixer\Config();

$config
->setUsingCache(true)
->getFinder()
->in(__DIR__)
->exclude('vendor');

return $config;
26 changes: 26 additions & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
GitHub contributors:
--------------------------------
- Alex Even
- AlexEven
- DevNet
- Eolia
- Francois Gaillard
- Gregory Roussac
- Jerome Nadaud
- Jérôme Nadaud
- Maxime Biloé
- Quetzacoalt91
- ZiZuu.com
- aleeks
- antoin-m
- djfm
- eternoendless
- gRoussac
- gaillafr
- julienbourdeau
- marionf
- maximebiloe
- mickaelandrieu
- sfroment
- tchauviere
- xBorderie
9 changes: 8 additions & 1 deletion Readme.md → README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,19 @@

## About

Adds a block featuring product categories.
Help navigation on your store, show your visitors current category and subcategories.

## Reporting issues

You can report issues with this module in the main PrestaShop repository. [Click here to report an issue][report-issue].

## Multistore compatibility

This module is compatible with the multistore :heavy_check_mark: <br/>
It can be configured differently from one store to another.<br/>
It can be configured quickly in the same way on all stores thanks to the all shops context or the group of shops.<br/>
It can be activated on one store and deactivated on another

## Contributing

PrestaShop modules are open source extensions to the [PrestaShop e-commerce platform][prestashop]. Everyone is welcome and even encouraged to contribute with their own improvements!
Expand Down
48 changes: 24 additions & 24 deletions category-tree-branch.tpl
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
{*
* 2007-2016 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to [email protected] so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <[email protected]>
* @copyright 2007-2016 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
{**
* Copyright since 2007 PrestaShop SA and Contributors
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License 3.0 (AFL-3.0)
* that is bundled with this package in the file LICENSE.md.
* It is also available through the world-wide-web at this URL:
* https://opensource.org/licenses/AFL-3.0
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to [email protected] so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to https://devdocs.prestashop.com/ for more information.
*
* @author PrestaShop SA and Contributors <[email protected]>
* @copyright Since 2007 PrestaShop SA and Contributors
* @license https://opensource.org/licenses/AFL-3.0 Academic Free License 3.0 (AFL-3.0)
*}

<li class="category_{$node.id}{if isset($last) && $last == 'true'} last{/if}">
<a href="{$node.link|escape:'html':'UTF-8'}" {if isset($currentCategoryId) && $node.id == $currentCategoryId}class="selected"{/if}
Expand Down
15 changes: 13 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,21 @@
}
],
"require": {
"php": ">=5.4.0"
"php": ">=5.4"
},
"require-dev": {
"prestashop/php-dev-tools": "~3.0"
},
"config": {
"preferred-install": "dist"
"preferred-install": "dist",
"classmap-authoritative": true,
"optimize-autoloader": true,
"prepend-autoloader": false
},
"autoload": {
"classmap": [
"ps_categorytree.php"
]
},
"type": "prestashop-module"
}
Loading

0 comments on commit 37b3613

Please sign in to comment.