summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorKyle Sferrazza2017-07-21 22:28:02 -0400
committerKyle Sferrazza2017-07-21 22:28:02 -0400
commit4b80425e318a8330c3d70522b5a4618ade0a9146 (patch)
tree703b5fd589f4b1b3223fe7a517fdd30d5f2d62ea
parent43bd3fb17d7710ff36cd2942657cda5b4cd6bb27 (diff)
downloadaur-4b80425e318a8330c3d70522b5a4618ade0a9146.tar.gz
powershell is now added to /etc/shells
-rw-r--r--.SRCINFO3
-rw-r--r--PKGBUILD3
-rw-r--r--powershell.install11
3 files changed, 15 insertions, 2 deletions
diff --git a/.SRCINFO b/.SRCINFO
index d60353ae627..991fcd895ad 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,8 +1,9 @@
pkgbase = powershell
pkgdesc = A cross-platform automation and configuration tool/framework (latest release)
pkgver = 6.0.0.beta.3
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/PowerShell/PowerShell
+ install = powershell.install
arch = x86_64
license = MIT
makedepends = git
diff --git a/PKGBUILD b/PKGBUILD
index 2fdc5059d51..d3ac2890644 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,7 +3,7 @@
pkgname=powershell
_pkgver=6.0.0-beta.3
pkgver=${_pkgver/-/.}
-pkgrel=1
+pkgrel=2
pkgdesc="A cross-platform automation and configuration tool/framework (latest release)"
arch=('x86_64')
url="https://github.com/PowerShell/PowerShell"
@@ -19,6 +19,7 @@ md5sums=('SKIP'
'SKIP'
'SKIP'
'f5841baa62b1322c07f9394940cec818')
+install=powershell.install
prepare() {
cd $pkgname
diff --git a/powershell.install b/powershell.install
new file mode 100644
index 00000000000..53cc793aab9
--- /dev/null
+++ b/powershell.install
@@ -0,0 +1,11 @@
+post_install() {
+ grep -qe '^/usr/bin/powershell$' etc/shells || echo '/usr/bin/powershell' >> etc/shells
+}
+
+post_upgrade() {
+ post_install
+}
+
+pre_remove() {
+ sed -ri '\|^/usr/bin/powershell$|d' etc/shells
+}