Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 4 #11

Merged
merged 36 commits into from
Aug 18, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
438e4d7
- cmd.php changed to be a *nix command line executable script (must r…
fernandoval Jan 19, 2018
07c4cb5
Code style adjustment
fernandoval Jan 19, 2018
c715502
Code style adjustment
fernandoval Jan 19, 2018
d598aac
Updating Travis configuration to downgrade PHPUnit to 5.7 version due…
fernandoval Jan 20, 2018
dfbc1fa
Vendor directory moved
fernandoval Jan 20, 2018
d36c505
Vendor and unit tests adjustment
fernandoval Jan 20, 2018
64ea964
- Configuration directory moved to root;
fernandoval Jan 20, 2018
9c63d60
- Kernel received the responsability to find controller and start the…
fernandoval Jan 20, 2018
c3ad9b5
Ajustments
fernandoval Jan 20, 2018
41cf89d
Migrator class moved to library directory.
fernandoval Jan 20, 2018
8e933db
Migration scripts directory moved to root
fernandoval Jan 21, 2018
e7e9710
Code styling adjustments
fernandoval Jan 21, 2018
8fb9785
- Created the var directory where system writes data during the cours…
fernandoval Jan 21, 2018
9762880
Application directory moved to project root and renamed from system t…
fernandoval Jan 21, 2018
18bc64e
Code styling adjustments
fernandoval Jan 21, 2018
10843d7
Bug fix
fernandoval Jan 21, 2018
057e23e
Documentation
fernandoval Jan 21, 2018
ccc827a
Documentation update
fernandoval Feb 6, 2018
2e011a1
Some adjustments
fernandoval Mar 6, 2018
58c9a2c
Documentations changes and other adjustments
fernandoval Mar 11, 2018
b2e4bdc
Code styling adjustment
fernandoval Mar 12, 2018
379283a
Code style adjustments
fernandoval Mar 12, 2018
d793d79
Code style adjustments
fernandoval Mar 12, 2018
27dadc9
Memorizing join property before queries
fernandoval May 24, 2018
cc228f5
Removing deprecated each function
fernandoval May 24, 2018
cbfeb23
Enhancements in AclManager
fernandoval Jul 19, 2018
e738372
Bug fix in UUID class
fernandoval Aug 15, 2018
b09d291
Style CI adjustments
fernandoval Aug 15, 2018
0bff9e0
StyleCI adjustment
fernandoval Aug 15, 2018
70ec675
Bug fix in component installer
fernandoval Aug 18, 2018
956187d
Style CI adjustments
fernandoval Aug 18, 2018
bd92d70
Version commit
fernandoval Aug 18, 2018
fc2bcb4
Removing support to HHVM
fernandoval Aug 18, 2018
dcdb98e
PHP 7 compatibility adjustment
fernandoval Aug 18, 2018
4df5050
PHPUnit 6 update test cases
fernandoval Aug 18, 2018
8446cf1
StyleCI adjustment
fernandoval Aug 18, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
composer.lock
10 changes: 7 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
language: php

php:
- '5.6'
- '7.0'
- '7.1'
- hhvm
- '7.2'

install:
- composer install
- composer install -n

script:
- vendor/bin/phpunit
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2007-2016 Fernando Val
Copyright (c) 2007 Fernando Val

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ It was created based upon the KISS principle in which the simplicity is the base

## Requirements

* PHP 5.5+
* PHP 5.6+
* [Composer](https://getcomposer.org/) Dependency Manager for PHP

## Language dependencies
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ public function getPermissionFor($aclObjectName)
/**
* \brief The valitation rules to save into table.
*/
public function validationRules()
protected function validationRules()
{
return [
'name' => 'required',
Expand All @@ -149,7 +149,7 @@ public function validationRules()
/**
* \brief Validation error messages.
*/
public function validationErrorMessages()
protected function validationErrorMessages()
{
return [
'name' => [
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
/** \file
* \brief Sample controller for the main page.
*
* \copyright ₢ 2007-2016 Fernando Val.
* \copyright ₢ 2007-2018 Fernando Val.
* \author Fernando Val - [email protected]
* \ingroup controllers
*/
use \Springy\Controller;
use Springy\Controller;

class Index_Controller extends Controller
{
Expand Down
File renamed without changes.
File renamed without changes.
63 changes: 41 additions & 22 deletions components.php
Original file line number Diff line number Diff line change
@@ -1,29 +1,24 @@
<?php
/** \file
* Springy.
*
* Post Install/Update Script for Composer
*
* \copyright Copyright (c) 2015-2016 Fernando Val
/**
* Post Install/Update Script for Composer.
*
* \brief Components - a post-install script for Composer
* \version 3.2.0.12
* \author Fernando Val - [email protected]
* @copyright 2015-2018 Fernando Val
* @author Fernando Val <[email protected]>
*
* This script is executed by Composer after the install/update process.
* @version 3.2.1.13
*
* The composer.json file is loaded and the "extra" section is used to it's configuration.
* This script is executed by Composer after the install/update process.
*
* If the script find a "post-install" section inside the "extra" section, it do a copy of files
* downloaded by Composer to the "target" defined for every "vendor/package" listed.
* The composer.json file is loaded and the "extra" section is used to it's configuration.
*
* If there is no "files" defined for every "vendor/package", their bower.json file is used by
* this script to decide which files will be copied.
* If the script find a "post-install" section inside the "extra" section, it do a copy of files
* downloaded by Composer to the "target" defined for every "vendor/package" listed.
*
* \note To minify CSS and JS files, is recommended the use of the Minify class by Matthias Mullie.
* https://github.com/matthiasmullie/minify
* If there is no "files" defined for every "vendor/package", their bower.json file is used by
* this script to decide which files will be copied.
*
* \ingroup framework
* NOTE: To minify CSS and JS files, is recommended the use of the Minify class by Matthias Mullie.
* https://github.com/matthiasmullie/minify
*/
define('DS', DIRECTORY_SEPARATOR);

Expand Down Expand Up @@ -220,7 +215,13 @@
continue;
}

copy_r($path.DS.$files, $destination.DS.$files, $minify, $components[$component]);
$dstFile = $files;
if ($noSubdirs) {
$dstFile = explode('/', $files);
$dstFile = array_pop($dstFile);
}

copy_r($path.DS.$files, $destination.DS.$dstFile, $minify, $components[$component]);
}

// Write the lock file
Expand All @@ -231,7 +232,14 @@
}

/**
* \brief Recursive Copy Function.
* Recursive Copy Function.
*
* @param string $path
* @param string $dest
* @param bool $minify
* @param array $cFiles
*
* @return void
*/
function copy_r($path, $dest, $minify, &$cFiles)
{
Expand Down Expand Up @@ -296,7 +304,12 @@ function copy_r($path, $dest, $minify, &$cFiles)
}

/**
* \brief Minify the file if turned on.
* Minify the file if turned on.
*
* @param string $buffer
* @param string $minify
*
* @return mixed
*/
function minify($buffer, $minify)
{
Expand Down Expand Up @@ -348,7 +361,13 @@ function minify($buffer, $minify)
}

/**
* \brief Copy file minifyint if necessary.
* Copy file minifyint if necessary.
*
* @param string $source
* @param string $destiny
* @param string $minify
*
* @return bool
*/
function realCopy($source, $destiny, $minify = 'auto')
{
Expand Down
16 changes: 8 additions & 8 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"license": "MIT",
"type": "project",
"config": {
"vendor-dir": "www/system/vendor"
"vendor-dir": "vendor"
},
"authors": [
{
Expand All @@ -15,7 +15,7 @@
],
"extra": {
"installer-paths": {
"www/system/vendor/{$name}": ["vendor/package"]
"vendor/{$name}": ["vendor/package"]
},
"post-install": {
"components/jquery": {
Expand All @@ -33,16 +33,16 @@
}
},
"require-dev": {
"phpunit/phpunit": "~4.8",
"mockery/mockery": "~0.9"
"phpunit/phpunit": "~6.0",
"mockery/mockery": "~1.0"
},
"require": {
"php": ">=5.6.0",

"smarty/smarty": "*",
"twig/twig": "*",
"ircmaxell/password-compat": "*",
"matthiasmullie/minify": "*",
"smarty/smarty": "3.1.*",
"twig/twig": "<2.5",
"ircmaxell/password-compat": "1.0.*",
"matthiasmullie/minify": "1.3.*",
"sendgrid/sendgrid": "~5.0",
"phpmailer/phpmailer": "~5.2",

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
$conf = [
'round_robin' => [
'type' => 'file',
'server_addr' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'tpl_comp',
'server_addr' => sysconf('VAR_PATH'),
'server_port' => 11211,
],
'cache' => [
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
/// Entradas para todos os ambientes
$conf = [
// Mail to notify system errors (used by framework)
'errors_go_to' => '[email protected]',
'errors_go_to' => '',

// System Admin (used by framework)
'system_adm_mail' => '[email protected]',
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@

/// Configurações para todos os ambientes
$conf = [
'debug' => false,
'debug' => true,
'ignore_deprecated' => false,
'rewrite_url' => true,
'cache' => false,
Expand All @@ -98,11 +98,11 @@
'developer_pass' => '',
'dba_user' => '',
'bug_authentication' => [],
'assets_source_path' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'assets',
'assets_path' => $GLOBALS['SYSTEM']['ROOT_PATH'].DIRECTORY_SEPARATOR.'assets',
'controller_path' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'controllers',
'css_path' => $GLOBALS['SYSTEM']['ROOT_PATH'].DIRECTORY_SEPARATOR.'css',
'js_path' => $GLOBALS['SYSTEM']['ROOT_PATH'].DIRECTORY_SEPARATOR.'js',
'assets_source_path' => sysconf('APP_PATH').DS.'assets',
'assets_path' => sysconf('ROOT_PATH').DS.'assets',
'controller_path' => sysconf('APP_PATH').DS.'controllers',
'css_path' => sysconf('ROOT_PATH').DS.'css',
'js_path' => sysconf('ROOT_PATH').DS.'js',
'session' => [
'type' => 'file', // 'file', 'memcached' or 'database'
'name' => 'SPRINGYSID', // The session cookie name
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,11 @@
'autoescape' => false,
'optimizations' => 1,
'debugging_ctrl' => 'NONE',
'default_template_path' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'templates_default',
'template_path' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'templates',
'template_config_path' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'templates_conf',
'compiled_template_path' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'tpl_comp',
'template_cached_path' => $GLOBALS['SYSTEM']['SYSTEM_PATH'].DIRECTORY_SEPARATOR.'tpl_cache',
'default_template_path' => sysconf('APP_PATH').DS.'templates_default',
'template_path' => sysconf('APP_PATH').DS.'templates',
'template_config_path' => sysconf('APP_PATH').DS.'templates_conf',
'compiled_template_path' => sysconf('VAR_PATH').DS.'compiled',
'template_cached_path' => sysconf('VAR_PATH').DS.'cache',
'use_sub_dirs' => false,
'errors' => [
404 => '_error404',
Expand Down
File renamed without changes.
Loading