File tree Expand file tree Collapse file tree 4 files changed +11
-286
lines changed Expand file tree Collapse file tree 4 files changed +11
-286
lines changed Original file line number Diff line number Diff line change 7
7
* GH #530: Make data censoring configurable (Yanick Champoux, David
8
8
Precious)
9
9
* GH #1512: Log hook entries as they are executed (Yanick Champoux)
10
+ * GH #1615: Remove Dancer2::Template::Simple from Dancer2 core (Jason
11
+ A. Crome)
10
12
* GH #1723: Enable use of a different Template Toolkit base class
11
13
(Andy Beverley)
12
14
* PR #1727: Don't create CPAN package files when generating new apps
Original file line number Diff line number Diff line change 6
6
use HTTP::Tiny;
7
7
use Path::Tiny;
8
8
use JSON::MaybeXS;
9
- use Dancer2::Template::Simple ;
9
+ use Dancer2::Template::Tiny ;
10
10
use Module::Runtime qw( use_module is_module_name ) ;
11
11
use CLI::Osprey
12
12
desc => ' Helper script to create new Dancer2 applications' ;
@@ -111,6 +111,13 @@ option no_package_files => (
111
111
default => 0,
112
112
);
113
113
114
+ has _engine => (
115
+ is => ' ro' ,
116
+ default => sub {
117
+ return Dancer2::Template::Tiny-> new( config => { start_tag => ' [d2%' , end_tag => ' %2d]' } );
118
+ },
119
+ );
120
+
114
121
# Last chance to validate args before we attempt to do something with them
115
122
sub BUILD {
116
123
my ( $self , $args ) = @_ ;
@@ -384,10 +391,7 @@ sub _add_to_manifest_skip {
384
391
sub _process_template {
385
392
my ( $self , $template , $tokens ) = @_ ;
386
393
387
- my $engine = Dancer2::Template::Simple-> new;
388
- $engine -> { start_tag } = ' [d2%' ;
389
- $engine -> { stop_tag } = ' %2d]' ;
390
- return $engine -> render( \$template , $tokens );
394
+ return $self -> _engine-> render( \$template , $tokens );
391
395
}
392
396
393
397
# These are good candidates to move to Dancer2::CLI if other commands
Load Diff This file was deleted.
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments