| 1 | package MT::Plugin::MTSuperBasicTemplateSets; |
|---|
| 2 | |
|---|
| 3 | use strict; |
|---|
| 4 | use base qw( MT::Plugin ); |
|---|
| 5 | our $VERSION = '0.2'; |
|---|
| 6 | my $plugin = MT::Plugin::MTSuperBasicTemplateSets->new({ |
|---|
| 7 | id => 'MTSuperBasicTemplateSest', |
|---|
| 8 | key => 'super-basic-template-sets', |
|---|
| 9 | name => 'Super Basic Template Sets', |
|---|
| 10 | description => "Super Basic Template Sets for learning Movable Type.", |
|---|
| 11 | version => $VERSION, |
|---|
| 12 | author_name => "Beau Smith", |
|---|
| 13 | author_link => "http://www.beausmith.com", |
|---|
| 14 | plugin_link => "http://plugins.movabletype.org", |
|---|
| 15 | }); |
|---|
| 16 | MT->add_plugin($plugin); |
|---|
| 17 | |
|---|
| 18 | sub init_registry { |
|---|
| 19 | my $plugin = shift; |
|---|
| 20 | $plugin->registry({ |
|---|
| 21 | callbacks => { |
|---|
| 22 | 'blog_template_set_change' => \&on_template_set_change, |
|---|
| 23 | }, |
|---|
| 24 | template_sets => { |
|---|
| 25 | basic1 => { |
|---|
| 26 | label => "SuperBasic - w/o Comments", |
|---|
| 27 | base_path => 'templates/basic1', |
|---|
| 28 | order => 600, |
|---|
| 29 | templates => { |
|---|
| 30 | index => { |
|---|
| 31 | 'index' => { |
|---|
| 32 | label => 'Index', |
|---|
| 33 | outfile => 'index.html', |
|---|
| 34 | rebuild_me => '1', |
|---|
| 35 | }, |
|---|
| 36 | 'archives' => { |
|---|
| 37 | label => 'Archives', |
|---|
| 38 | outfile => 'archives.html', |
|---|
| 39 | rebuild_me => '1', |
|---|
| 40 | }, |
|---|
| 41 | 'styles' => { |
|---|
| 42 | label => 'Styles', |
|---|
| 43 | outfile => 'styles.css', |
|---|
| 44 | rebuild_me => '1', |
|---|
| 45 | }, |
|---|
| 46 | }, |
|---|
| 47 | archive => { |
|---|
| 48 | 'monthly_entry_listing' => { |
|---|
| 49 | label => 'Monthly Archive', |
|---|
| 50 | mappings => { |
|---|
| 51 | monthly => { |
|---|
| 52 | archive_type => 'Monthly', |
|---|
| 53 | }, |
|---|
| 54 | }, |
|---|
| 55 | }, |
|---|
| 56 | 'category_entry_listing' => { |
|---|
| 57 | label => 'Category Archive', |
|---|
| 58 | mappings => { |
|---|
| 59 | category => { |
|---|
| 60 | archive_type => 'Category', |
|---|
| 61 | }, |
|---|
| 62 | }, |
|---|
| 63 | }, |
|---|
| 64 | }, |
|---|
| 65 | individual => { |
|---|
| 66 | 'entry' => { |
|---|
| 67 | label => 'Entry', |
|---|
| 68 | mappings => { |
|---|
| 69 | entry_archive => { |
|---|
| 70 | archive_type => 'Individual', |
|---|
| 71 | }, |
|---|
| 72 | }, |
|---|
| 73 | }, |
|---|
| 74 | 'page' => { |
|---|
| 75 | label => 'Page', |
|---|
| 76 | mappings => { |
|---|
| 77 | page_archive => { |
|---|
| 78 | archive_type => 'Page', |
|---|
| 79 | }, |
|---|
| 80 | }, |
|---|
| 81 | }, |
|---|
| 82 | }, |
|---|
| 83 | module => { |
|---|
| 84 | 'header' => { |
|---|
| 85 | label => 'Header', |
|---|
| 86 | }, |
|---|
| 87 | 'footer' => { |
|---|
| 88 | label => 'Footer', |
|---|
| 89 | }, |
|---|
| 90 | 'sidebar' => { |
|---|
| 91 | label => 'Sidebar', |
|---|
| 92 | }, |
|---|
| 93 | }, |
|---|
| 94 | }, |
|---|
| 95 | }, |
|---|
| 96 | }, |
|---|
| 97 | }); |
|---|
| 98 | } |
|---|
| 99 | |
|---|
| 100 | 1; |
|---|