Include support for imv-folder
This is a wrapper to open all images in a folder. Includes: - Script itself - Man page - Desktop file - Necessary Makefile changes Fix #223
This commit is contained in:
parent
eccd3cf912
commit
38eee61beb
36
doc/imv-folder.1.txt
Normal file
36
doc/imv-folder.1.txt
Normal file
|
@ -0,0 +1,36 @@
|
|||
/////
|
||||
vim:set ts=4 sw=4 tw=82 noet:
|
||||
/////
|
||||
:quotes.~:
|
||||
|
||||
imv (1)
|
||||
=======
|
||||
|
||||
Name
|
||||
----
|
||||
imv-folder - Open 'imv' for all images in a folder
|
||||
|
||||
Description
|
||||
-----------
|
||||
|
||||
'imv-folder' is a wrapper for 'imv' that auto-selects the folder where the image is located, so that the *next* and *previous* commands function in the same way as other image viewers.
|
||||
|
||||
Note that this wrapper supports only a single image. For opening multiple images, use plain `imv`.
|
||||
|
||||
Synopsis
|
||||
--------
|
||||
'imv-folder' path
|
||||
|
||||
Authors
|
||||
-------
|
||||
|
||||
imv is written and maintained by Harry Jeffery <me@harry.pm>
|
||||
with contributions from other developers.
|
||||
|
||||
Full source code and other information can be found at
|
||||
<https://github.com/eXeC64/imv>.
|
||||
|
||||
See Also
|
||||
--------
|
||||
|
||||
**imv**(1)
|
|
@ -330,4 +330,4 @@ Full source code and other information can be found at
|
|||
See Also
|
||||
--------
|
||||
|
||||
**imv**(5) **imv-msg**(1)
|
||||
**imv**(5) **imv-msg**(1) **imv-folder**(1)
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
#!/bin/sh
|
||||
|
||||
if [ -n "${WAYLAND_DISPLAY}" ]; then
|
||||
exec imv-wayland "$@"
|
||||
else
|
||||
|
|
3
files/imv-folder
Executable file
3
files/imv-folder
Executable file
|
@ -0,0 +1,3 @@
|
|||
#!/bin/sh
|
||||
image="$1"
|
||||
exec imv "$(dirname "$image")" -n "$image"
|
14
files/imv-folder.desktop
Normal file
14
files/imv-folder.desktop
Normal file
|
@ -0,0 +1,14 @@
|
|||
[Desktop Entry]
|
||||
Name=imv-folder
|
||||
Name[en_US]=imv
|
||||
GenericName=Image viewer
|
||||
GenericName[en_US]=Image viewer
|
||||
Comment=Fast freeimage-based Image Viewer | Open all images on a folder
|
||||
Exec=imv-folder %f
|
||||
NoDisplay=true
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=Graphics;2DGraphics;Viewer;
|
||||
MimeType=image/bmp;image/gif;image/jpeg;image/jpg;image/pjpeg;image/png;image/tiff;image/x-bmp;image/x-pcx;image/x-png;image/x-portable-anymap;image/x-portable-bitmap;image/x-portable-graymap;image/x-portable-pixmap;image/x-tga;image/x-xbitmap;
|
||||
Icon=multimedia-photo-viewer
|
||||
Keywords=photo;picture;
|
19
meson.build
19
meson.build
|
@ -155,6 +155,12 @@ foreach ws : ['wayland', 'x11']
|
|||
endif
|
||||
endforeach
|
||||
|
||||
install_data(
|
||||
files('files/imv-folder'),
|
||||
install_dir: get_option('bindir'),
|
||||
install_mode: 'rwxr-xr-x',
|
||||
)
|
||||
|
||||
if not target_single_ws
|
||||
install_data(
|
||||
files('files/imv'),
|
||||
|
@ -163,11 +169,13 @@ if not target_single_ws
|
|||
)
|
||||
endif
|
||||
|
||||
install_data(
|
||||
files('files/imv.desktop'),
|
||||
install_dir: '@0@/applications'.format(get_option('datadir')),
|
||||
install_mode: 'rw-r--r--',
|
||||
)
|
||||
foreach desktop: ['imv', 'imv-folder']
|
||||
install_data(
|
||||
files('files/@0@.desktop'.format(desktop)),
|
||||
install_dir: '@0@/applications'.format(get_option('datadir')),
|
||||
install_mode: 'rw-r--r--',
|
||||
)
|
||||
endforeach
|
||||
|
||||
install_data(
|
||||
files('files/imv_config'),
|
||||
|
@ -196,6 +204,7 @@ prog_a2x = find_program('a2x', required: get_option('man'))
|
|||
if prog_a2x.found()
|
||||
foreach man : [
|
||||
[1, 'imv'],
|
||||
[1, 'imv-folder'],
|
||||
[1, 'imv-msg'],
|
||||
[5, 'imv'],
|
||||
]
|
||||
|
|
Loading…
Reference in a new issue