Commit Graph

7732 Commits

Author SHA1 Message Date
Fabien Potencier 94ca4e993e updated CHANGELOG 2016-09-29 20:57:16 -07:00
Fabien Potencier 91d2adc061 bug #2152 normalizePath: Do not mangle phar URLs. (apapsch)
This PR was squashed before being merged into the 1.x branch (closes #2152).

Discussion
----------

normalizePath: Do not mangle phar URLs.

Removing consecutive slashes breaks phar URLs. Example:
phar:///foo/bar is turned into phar:/foo/bar.

This change preserves the three slashes if path starts with phar://.

Commits
-------

7dd63fc normalizePath: Do not mangle phar URLs.
2016-09-29 20:46:34 -07:00
Aljosha Papsch 7dd63fc087 normalizePath: Do not mangle phar URLs. 2016-09-29 20:46:32 -07:00
Fabien Potencier 32d3cc90e7 Merge branch '1.x'
* 1.x:
  added missing var decl
  allowed filters/functions/tests implementation to use a different class than the extension they belong to
2016-09-29 13:51:46 -07:00
Fabien Potencier a0971db72b added missing var decl 2016-09-29 13:02:49 -07:00
Fabien Potencier 1704c48ff7 feature #1913 added runtime extensions (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

added runtime extensions

Commits
-------

9cb6860 allowed filters/functions/tests implementation to use a different class than the extension they belong to
2016-09-29 12:51:18 -07:00
Fabien Potencier 9cb6860e53 allowed filters/functions/tests implementation to use a different class than the extension they belong to 2016-09-29 11:43:35 -07:00
Fabien Potencier e54e0d4748 removed obsolete getName() methods on built-in extensions 2016-09-28 18:02:49 -07:00
Fabien Potencier 1093622914 Merge branch '1.x'
* 1.x:
  fixed profiler extension name
2016-09-28 18:00:42 -07:00
Fabien Potencier c8e96e8c89 fixed profiler extension name 2016-09-28 17:59:53 -07:00
Fabien Potencier 94586346be removed obsolete features 2016-09-28 10:49:38 -07:00
Fabien Potencier df9a1151ee Merge branch '1.x'
* 1.x:
  deprecated Twig_ExtensionInterface::getName()
  added some missing tests for functions/filters as static calls
  added missing information in deprecatd.rst
2016-09-28 10:45:26 -07:00
Fabien Potencier f58cce77d7 feature #2148 deprecated Twig_ExtensionInterface::getName() (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

deprecated Twig_ExtensionInterface::getName()

see #2147

Commits
-------

71f03df deprecated Twig_ExtensionInterface::getName()
2016-09-28 10:18:54 -07:00
Fabien Potencier 71f03df011 deprecated Twig_ExtensionInterface::getName() 2016-09-28 10:05:09 -07:00
Fabien Potencier 52e9e01353 minor #2150 added some missing tests for functions/filters as static calls (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

added some missing tests for functions/filters as static calls

Commits
-------

c73e97e added some missing tests for functions/filters as static calls
2016-09-27 10:24:00 -07:00
Fabien Potencier c73e97ece4 added some missing tests for functions/filters as static calls 2016-09-27 10:19:55 -07:00
Fabien Potencier 0f5d115253 fixed method signature 2016-09-27 08:25:12 -07:00
Fabien Potencier 48a6df29e8 added missing information in deprecatd.rst 2016-09-26 21:10:54 -07:00
Fabien Potencier 9f60646612 fixed CS 2016-09-26 21:02:44 -07:00
Fabien Potencier 105924b822 Merge branch '1.x'
* 1.x:
  fixed CS
  added a recipe about how to use Twig and AngularJS together
2016-09-26 21:01:42 -07:00
Fabien Potencier c96ffc314f fixed CS 2016-09-26 21:00:51 -07:00
Fabien Potencier 86e4c0d484 minor #2140 added a recipe about how to use Twig and AngularJS together (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

added a recipe about how to use Twig and AngularJS together

Commits
-------

b162a91 added a recipe about how to use Twig and AngularJS together
2016-09-26 14:01:40 -07:00
Fabien Potencier b162a91eeb added a recipe about how to use Twig and AngularJS together 2016-09-26 14:01:23 -07:00
Fabien Potencier 80518a195b adding missing dots to some exception messages 2016-09-24 12:24:21 -07:00
Fabien Potencier ac14b063b8 Merge branch '1.x'
* 1.x:
  adding missing dots to some exception messages
  fixed error message
2016-09-24 12:23:33 -07:00
Fabien Potencier 9ee6fe3380 adding missing dots to some exception messages 2016-09-24 12:21:25 -07:00
Fabien Potencier 0980fe0871 fixed error message 2016-09-24 12:10:10 -07:00
Fabien Potencier ea53a6b264 fixed phpdocs 2016-09-24 12:05:59 -07:00
Fabien Potencier 07ea466848 feature #2142 removed code that deal with potential null nodes (not possible anymore) (fabpot)
This PR was merged into the 2.0-dev branch.

Discussion
----------

removed code that deal with potential null nodes (not possible anymore)

Commits
-------

e50a84c removed code that deal with potential null nodes (not possible anymore)
2016-09-24 12:05:21 -07:00
Fabien Potencier 859297251c removed deprecation notice 2016-09-24 12:04:21 -07:00
Fabien Potencier 7187f2cf51 Merge branch '1.x'
* 1.x:
  fixed error message
  Improved the error message when a child template defines contents outside parent blocks
  adding missing dots to some exception messages
  fixed exception message that might end with a ?
  added a missing deprecation notice
  removed obsolete comment
  bumped version to 1.25.1-DEV
  prepared the 1.25.0 release
  fixed docs
  Expanded definition of empty
2016-09-24 12:03:36 -07:00
Fabien Potencier af2e1111ae bug #2141 added a missing deprecation notice (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

added a missing deprecation notice

Commits
-------

9c27479 added a missing deprecation notice
2016-09-24 12:01:42 -07:00
Fabien Potencier 73d029b212 minor #2143 fixed exception message that might end with a ? (fabpot)
This PR was merged into the 1.x branch.

Discussion
----------

fixed exception message that might end with a ?

Commits
-------

5c43548 adding missing dots to some exception messages
fbf99fc fixed exception message that might end with a ?
2016-09-24 12:00:56 -07:00
Fabien Potencier b2a1805146 fixed error message 2016-09-24 12:00:09 -07:00
Fabien Potencier a80ec1728c minor #2139 Improved the error message when a child template defines contents outside parent blocks (javiereguiluz)
This PR was squashed before being merged into the 1.x branch (closes #2139).

Discussion
----------

Improved the error message when a child template defines contents outside parent blocks

### Context

When using template inheritance, you cannot put template contents outside Twig blocks (except some special tags (form_theme), macros, etc.) Sadly, making this mistake is very common when learning Twig.

### Problem

The error message associated to this issue is cryptic and "impossible to understand" for newcomers:

```
A template that extends another one cannot have a body.
```

I recently delivered a Symfony training and nobody was able to understand what the error was. They didn't have the slightest clue. I explained it to them ... and a few days latter they had the same problem and again they couldn't remember what this error was related to.

### Solution

Most of the Twig/Symfony errors are very helpful. Let's improve this one to make it useful too.

Two years ago I tried to fix this error message (see #1396). Let's see if this new PR is accepted.

Commits
-------

23f53d5 Improved the error message when a child template defines contents outside parent blocks
2016-09-24 11:56:15 -07:00
Javier Eguiluz 23f53d5968 Improved the error message when a child template defines contents outside parent blocks 2016-09-24 11:56:13 -07:00
Fabien Potencier 5c43548dde adding missing dots to some exception messages 2016-09-24 11:53:49 -07:00
Fabien Potencier fbf99fce69 fixed exception message that might end with a ? 2016-09-24 11:34:11 -07:00
Fabien Potencier 9c2747996a added a missing deprecation notice 2016-09-24 11:30:39 -07:00
Fabien Potencier e50a84c78d removed code that deal with potential null nodes (not possible anymore) 2016-09-24 11:26:50 -07:00
Fabien Potencier 498dcf4129 removed Xdebug on Travis 2016-09-22 09:49:38 -07:00
Fabien Potencier bba5e1a1b3 removed obsolete comment 2016-09-22 08:15:13 -07:00
Fabien Potencier c9aac2403c bumped version to 1.25.1-DEV 2016-09-21 16:20:10 -07:00
Fabien Potencier f16a634ab0 prepared the 1.25.0 release v1.25.0 2016-09-21 16:05:12 -07:00
Fabien Potencier 349b0885cd fixed docs 2016-09-21 13:27:56 -07:00
Fabien Potencier cc9e6c41f7 minor #2134 Expanded definition of empty (servel333)
This PR was submitted for the master branch but it was merged into the 1.x branch instead (closes #2134).

Discussion
----------

Expanded definition of empty

Based on the [source](https://github.com/twigphp/Twig/blob/f61bc838a97c26e2952af09070d1c4847eeedbe7/lib/Twig/Extension/Core.php#L1405), defined 'empty'. The comment in the code block is too subtle and I didn't notice it until I got to the edit page, and it also does not fully describe the definition of empty based on what the code does.

Commits
-------

9c6b8cb Expanded definition of empty
2016-09-21 13:27:28 -07:00
Nathan Perry 9c6b8cb3e4 Expanded definition of empty 2016-09-21 13:27:28 -07:00
Fabien Potencier fc9dd3cad6 made getSource() abstract 2016-09-20 14:35:52 -07:00
Fabien Potencier c5b5f4540f Merge branch '1.x'
* 1.x:
  made the getSource() method non-abstract for BC
2016-09-20 14:35:30 -07:00
Fabien Potencier f2a9ef3579 made the getSource() method non-abstract for BC 2016-09-20 14:35:26 -07:00