mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-24 10:32:13 +08:00
52 lines
1.6 KiB
Bash
52 lines
1.6 KiB
Bash
#
|
|
# Apps Packages for Chakra, part of chakra-project.org
|
|
#
|
|
# maintainer (i686): Phil Miller <philm[at]chakra-project[dog]org>
|
|
# maintainer (x86_64): Manuel Tortosa <manutortosa[at]chakra-project[dot]org>
|
|
|
|
pkgname=ccr
|
|
pkgver=20100927
|
|
pkgrel=2
|
|
pkgdesc="Bash wrapper for pacman and the CCR"
|
|
url="http://github.com/bruenig/ccr"
|
|
license="GPL"
|
|
arch=('any')
|
|
makedepends=('git')
|
|
depends=('grep' 'sed' 'coreutils' 'bash' 'wget' 'pacman')
|
|
optdepends=('sudo: install and update packages as non-root'
|
|
'pacman-color: colorized output'
|
|
'base-devel: for building packages from the ccr')
|
|
source=(http://chakra-project.org/sources/ccr/ccr-$pkgver.tar.xz)
|
|
md5sums=(3b831830867ef58f186f8c1a97c59147)
|
|
|
|
# source PKGBUILD && _create-tarball
|
|
_create-tarball() {
|
|
mkdir -p "ccr"
|
|
git clone git://github.com/bruenig/packer.git "ccr"
|
|
tar -cJf ccr-$pkgver-$pkgrel.tar.xz "ccr"
|
|
md5sum "ccr-$pkgver-$pkgrel.tar.xz"
|
|
rm -rf "ccr"
|
|
}
|
|
|
|
build() {
|
|
cd "$startdir/src/ccr"
|
|
|
|
# Change all the server references from http://aur.archlinux.org to http://chakra-project.org/ccr
|
|
cat packer | sed "s/aur\.archlinux\.org/chakra\-project\.org\/ccr/g" > step1
|
|
# Change all the aur references to ccr
|
|
cat step1 | sed "s/aur/ccr/g" > step2
|
|
# Change all the Aur references to Ccr
|
|
cat step2 | sed "s/Aur/Ccr/g" > ccr
|
|
|
|
install -m 755 -D ccr "$startdir/pkg/usr/bin/ccr"
|
|
|
|
# Do some sed-magic
|
|
sed -i -e "s~AUR~CCR~g" packer.8
|
|
sed -i -e "s~aur~ccr~g" packer.8
|
|
sed -i -e "s~packer~ccr~g" packer.8
|
|
sed -i -e "s~Packer~CCR~g" packer.8
|
|
sed -i -e "s~PACKER~CCR~g" packer.8
|
|
|
|
install -m 644 -D packer.8 "$startdir/pkg/usr/share/man/man8/ccr.8"
|
|
}
|