Skip to content

Commit

Permalink
dev-php/Text_Template: Version bump and use composer autoloading
Browse files Browse the repository at this point in the history
Package-Manager: Portage-2.3.4, Repoman-2.3.2
  • Loading branch information
Brian Evans committed Mar 9, 2017
1 parent a710038 commit b7346b7
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 0 deletions.
1 change: 1 addition & 0 deletions dev-php/Text_Template/Manifest
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
DIST Text_Template-1.1.1.tgz 3444 SHA256 1d21e556407441cbe81bbb32e34a78c3eaacb98def3e1d7ea3fa8a2b584ff207 SHA512 0eaf43ab8c0810f63d81ddaf62a5e81b2e244161fe79fe09bec05ef732ee07012a1c6c3711885a118cf38334131c57ac1d326e0a711eb3e6d3099c5475f80e7f WHIRLPOOL c64fbe8bf7574142b2d6bbaa60e62802d09f1a7a8d050543bc58921e83e8bcffd2575e1f14142805b38f0a4418f63011311986b07ae2e12d15b634dc07db5d47
DIST Text_Template-1.2.1.tar.gz 2561 SHA256 007a9251c688951cadcb3476f23c652ecd97086a14d0d6291f7d01ad9f80f1fc SHA512 d8277f24782d0897b26d2e4922c2658047c484cb86f477916d6ad6dad3e5150bfa0a1ad38c79463a3fde97702bc65edb207a481b6f6cd8346c5fcc33b4cff8ca WHIRLPOOL 864f910e8b94b366989a434c0f9f1df6afd2f12c3e3e6976720888f3180b63f171c6c1d83640884637c89c9cbef996949d5f34163f83f2dc804484935bccfd8c
31 changes: 31 additions & 0 deletions dev-php/Text_Template/Text_Template-1.2.1.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=6

MY_PN="php-text-template"

DESCRIPTION="A simple template engine"
HOMEPAGE="http://phpunit.de"
SRC_URI="https://github.com/sebastianbergmann/${MY_PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"

LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""

S="${WORKDIR}/${MY_PN}-${PV}"

RDEPEND="dev-php/fedora-autoloader
>=dev-lang/php-5.6:*"

src_install() {
insinto /usr/share/php/Text/Template
doins -r src/*
doins "${FILESDIR}/autoload.php"
}

pkg_postinst() {
ewarn "This library now loads via /usr/share/php/Text/Template/autoload.php"
ewarn "Please update any scripts to require the autoloader"
}
13 changes: 13 additions & 0 deletions dev-php/Text_Template/files/autoload.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php
/* Autoloader for dev-php/Text_Template */

if (!class_exists('Fedora\\Autoloader\\Autoload', false)) {
require_once '/usr/share/php/Fedora/Autoloader/autoload.php';
}

\Fedora\Autoloader\Autoload::addClassMap(
array(
'text_template' => '/Template.php',
),
__DIR__
);

0 comments on commit b7346b7

Please sign in to comment.