Skip to content

Commit

Permalink
Release v4.0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed May 1, 2020
1 parent 21d182b commit 18bf776
Show file tree
Hide file tree
Showing 72 changed files with 72 additions and 1,319 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: PHPUnit

on:
pull_request:
branches:
- develop

jobs:
main:
name: Build and test

strategy:
matrix:
php-versions: ['7.2', '7.3', '7.4']

runs-on: ubuntu-latest

if: "!contains(github.event.head_commit.message, '[ci skip]')"

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup PHP, with composer and extensions
uses: shivammathur/setup-php@master
with:
php-version: ${{ matrix.php-versions }}
tools: composer, pecl, phpunit
extensions: intl, json, mbstring, mysqlnd, xdebug, xml, sqlite3
coverage: xdebug

- name: Get composer cache directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

- name: Cache composer dependencies
uses: actions/cache@v1
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies
run: composer install --no-progress --no-suggest --no-interaction --prefer-dist --optimize-autoloader
# To prevent rate limiting you may need to supply an OAuth token in Settings > Secrets
# env:
# https://getcomposer.org/doc/articles/troubleshooting.md#api-rate-limit-and-oauth-tokens
# COMPOSER_AUTH: ${{ secrets.COMPOSER_AUTH }}

- name: Test with phpunit
run: vendor/bin/phpunit --coverage-text
21 changes: 0 additions & 21 deletions LICENSE

This file was deleted.

2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ This repository holds a composer-installable app starter.
It has been built from the
[development repository](https://github.com/codeigniter4/CodeIgniter4).

**This is pre-release code and should not be used in production sites.**

More information about the plans for version 4 can be found in [the announcement](http://forum.codeigniter.com/thread-62615.html) on the forums.

The user guide corresponding to this version of the framework can be found
Expand Down
2 changes: 1 addition & 1 deletion app/Config/Kint.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php namespace Config;

use Kint\Renderer\Renderer;
use CodeIgniter\Config\BaseConfig;
use Kint\Renderer\Renderer;

class Kint extends BaseConfig
{
Expand Down
17 changes: 8 additions & 9 deletions app/Config/Logger.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,6 @@ class Logger extends BaseConfig
*/
public $threshold = 3;

/*
|--------------------------------------------------------------------------
| Error Logging Directory Path
|--------------------------------------------------------------------------
| By default, logs are written to WRITEPATH . 'logs/'
| Specify a different destination here, if desired.
*/
public $path = '';

/*
|--------------------------------------------------------------------------
| Date Format for Logs
Expand Down Expand Up @@ -116,6 +107,14 @@ class Logger extends BaseConfig
* integer notation (i.e. 0700, 0644, etc.)
*/
'filePermissions' => 0644,

/*
* Logging Directory Path
*
* By default, logs are written to WRITEPATH . 'logs/'
* Specify a different destination here, if desired.
*/
'path' => '',
],

/**
Expand Down
6 changes: 1 addition & 5 deletions app/Config/Mimes.php
Original file line number Diff line number Diff line change
Expand Up @@ -516,11 +516,7 @@ public static function guessExtensionFromType(string $type, ?string $proposed_ex

foreach (static::$mimes as $ext => $types)
{
if (is_string($types) && $types === $type)
{
return $ext;
}
else if (is_array($types) && in_array($type, $types))
if ((is_string($types) && $types === $type) || (is_array($types) && in_array($type, $types)))
{
return $ext;
}
Expand Down
2 changes: 1 addition & 1 deletion app/Config/Routes.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php namespace Config;

// Create a new instance of our RouteCollection class.
$routes = Services::routes(true);
$routes = Services::routes();

// Load the system's routing file first, so that the app and ENVIRONMENT
// can override as needed.
Expand Down
1 change: 0 additions & 1 deletion app/Config/Services.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<?php namespace Config;

use CodeIgniter\Config\Services as CoreServices;
use CodeIgniter\Config\BaseConfig;

require_once SYSTEMPATH . 'Config/Services.php';

Expand Down
10 changes: 5 additions & 5 deletions app/Views/errors/html/error_exception.php
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@
<?php if (empty($GLOBALS[$var]) || ! is_array($GLOBALS[$var]))
{
continue;
} ?>
} ?>

<h3>$<?= $var ?></h3>

Expand Down Expand Up @@ -235,7 +235,7 @@
<?php if (empty($GLOBALS[$var]) || ! is_array($GLOBALS[$var]))
{
continue;
} ?>
} ?>

<?php $empty = false; ?>

Expand Down Expand Up @@ -287,15 +287,15 @@
</tr>
</thead>
<tbody>
<?php foreach ($headers as $name => $value) : ?>
<?php foreach ($headers as $value) : ?>
<?php if (empty($value))
{
continue;
} ?>
} ?>
<?php if (! is_array($value))
{
$value = [$value];
} ?>
} ?>
<?php foreach ($value as $h) : ?>
<tr>
<td><?= esc($h->getName(), 'html') ?></td>
Expand Down
5 changes: 3 additions & 2 deletions builds
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env php
<?php

define('LATEST_RELEASE', '^4@rc');
define('LATEST_RELEASE', '^4.0');
define('GITHUB_URL', 'https://github.com/codeigniter4/codeigniter4');

/*
Expand Down Expand Up @@ -41,6 +41,7 @@ if (is_file($file))
{
// Set 'minimum-stability'
$array['minimum-stability'] = 'dev';
$array['prefer-stable'] = true;

// Make sure the repo is configured
if (! isset($array['repositories']))
Expand Down Expand Up @@ -72,7 +73,7 @@ if (is_file($file))
$array['require']['codeigniter4/codeigniter4'] = 'dev-develop';
unset($array['require']['codeigniter4/framework']);
}

// Release
else
{
Expand Down
94 changes: 0 additions & 94 deletions contributing.md

This file was deleted.

2 changes: 1 addition & 1 deletion public/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

// Location of the Paths config file.
// This is the line that might need to be changed, depending on your folder structure.
$pathsPath = FCPATH . '../app/Config/Paths.php';
$pathsPath = realpath(FCPATH . '../app/Config/Paths.php');
// ^^^ Change this if you move your application folder

/*
Expand Down
5 changes: 0 additions & 5 deletions tests/_support/Autoloader/UnnamespacedClass.php

This file was deleted.

13 changes: 0 additions & 13 deletions tests/_support/Commands/AbstractInfo.php

This file was deleted.

36 changes: 0 additions & 36 deletions tests/_support/Commands/AppInfo.php

This file was deleted.

18 changes: 0 additions & 18 deletions tests/_support/Config/BadRegistrar.php

This file was deleted.

Loading

0 comments on commit 18bf776

Please sign in to comment.