Browse Source

Add kde-servicemenus-flif-webp

master
Pekka Helenius 5 years ago
parent
commit
da706966c8
6 changed files with 43 additions and 28 deletions
  1. +3
    -3
      Readme.md
  2. +25
    -0
      kde-servicemenus-flif-webp/PKGBUILD
  3. +0
    -0
      kde-servicemenus-flif-webp/flif-conversion.sh
  4. +7
    -3
      kde-servicemenus-flif-webp/flif-webp-conv.desktop
  5. +8
    -0
      kde-servicemenus-flif-webp/webp-conversion.sh
  6. +0
    -22
      kde-servicemenus-flifconversion/PKGBUILD

+ 3
- 3
Readme.md View File

@ -66,11 +66,11 @@ Plasma 5 Dolphin service menu script for cr2hdr package.
**FORMAT:** Arch Linux PKGBUILD script. **FORMAT:** Arch Linux PKGBUILD script.
## [kde-servicemenus-flifconversion](kde-servicemenus-flifconversion)
## [kde-servicemenus-flif-webp](kde-servicemenus-flif-webp)
Plasma 5 Dolphin service menu script for converting images to FLIF format.
Plasma 5 Dolphin service menu script for converting images to FLIF & WebP formats.
Requirements: FLIF libraries ([GitHub source](https://github.com/FLIF-hub/FLIF) or [AUR Package](https://aur.archlinux.org/packages/flif-git/))
**Requirements:** FLIF libraries ([GitHub source](https://github.com/FLIF-hub/FLIF) or [AUR Package](https://aur.archlinux.org/packages/flif-git/))
It is recommended that you add FLIF mimetype (as `image/x-flif`) in system-wide. It is recommended that you add FLIF mimetype (as `image/x-flif`) in system-wide.


+ 25
- 0
kde-servicemenus-flif-webp/PKGBUILD View File

@ -0,0 +1,25 @@
# Maintainer: Pekka Helenius <fincer89 [at] hotmail [dot] com>
pkgname=kde-servicemenus-flif-webp
pkgver=1
pkgrel=1
pkgdesc="Convert image files to FLIF/WebP formats with Dolphin or Konqueror (KDE5 Dolphin actions)"
arch=('any')
license=('GPL')
source=(
'flif-webp-conv.desktop'
'flif-conversion.sh'
'webp-conversion.sh'
)
md5sums=('dfe8688e4c2f9a7318a5ac6efb43ceb3'
'b67c8ad9e57580a0e21cc585f8aa93ed'
'5a61d02b4f2ce9eb6a77fc4788a0b93c')
depends=('flif' 'dolphin')
package() {
mkdir -p ${pkgdir}/usr/share/kservices5/ServiceMenus/
cp ${srcdir}/{flif-webp-conv.desktop,flif-conversion.sh,webp-conversion.sh} ${pkgdir}/usr/share/kservices5/ServiceMenus/
chmod 755 ${pkgdir}/usr/share/kservices5/ServiceMenus/{flif-webp-conv.desktop,flif-conversion.sh,webp-conversion.sh}
}

kde-servicemenus-flifconversion/flif-conversion.sh → kde-servicemenus-flif-webp/flif-conversion.sh View File


kde-servicemenus-flifconversion/flif-conversion.desktop → kde-servicemenus-flif-webp/flif-webp-conv.desktop View File

@ -1,14 +1,18 @@
[Desktop Entry] [Desktop Entry]
Type=Service Type=Service
ServiceTypes=KonqPopupMenu/Plugin ServiceTypes=KonqPopupMenu/Plugin
MimeType=image/png
MimeType=image/*
Icon=image Icon=image
Actions=flif_conversion;
Actions=flif_conversion;webp_conversion;
X-KDE-StartupNotify=false X-KDE-StartupNotify=false
X-KDE-Priority=TopLevel X-KDE-Priority=TopLevel
TryExec=flif
[Desktop Action flif_conversion] [Desktop Action flif_conversion]
Name=Convert to FLIF format Name=Convert to FLIF format
Icon=image Icon=image
Exec=/usr/share/kservices5/ServiceMenus/flif-conversion.sh Exec=/usr/share/kservices5/ServiceMenus/flif-conversion.sh
[Desktop Action webp_conversion]
Name=Convert to WebP format
Icon=image
Exec=/usr/share/kservices5/ServiceMenus/webp-conversion.sh

+ 8
- 0
kde-servicemenus-flif-webp/webp-conversion.sh View File

@ -0,0 +1,8 @@
#!/bin/env bash
while [ $# -gt 0 ]; do
OLDFORMAT=$1
NEWFORMAT=$(echo " $OLDFORMAT" | sed 's/\.\w*$/.webp/')
convert $OLDFORMAT $NEWFORMAT
shift
done

+ 0
- 22
kde-servicemenus-flifconversion/PKGBUILD View File

@ -1,22 +0,0 @@
# Maintainer: Pekka Helenius <fincer89 [at] hotmail [dot] com>
pkgname=kde-servicemenus-flifconversion
pkgver=1
pkgrel=1
pkgdesc="Convert image files to FLIF format with Dolphin or Konqueror (KDE5 Dolphin action)"
arch=('any')
license=('GPL')
source=(
'flif-conversion.desktop'
'flif-conversion.sh'
)
depends=('flif' 'dolphin')
md5sums=('148108447aecfb7e7d60ce15a937d140'
'b67c8ad9e57580a0e21cc585f8aa93ed')
package() {
mkdir -p ${pkgdir}/usr/share/kservices5/ServiceMenus/
cp ${srcdir}/{flif-conversion.desktop,flif-conversion.sh} ${pkgdir}/usr/share/kservices5/ServiceMenus/
chmod 755 ${pkgdir}/usr/share/kservices5/ServiceMenus/{flif-conversion.desktop,flif-conversion.sh}
}

Loading…
Cancel
Save