From 7b96fdb377666b45a9951ef936aaa9c2297f7041 Mon Sep 17 00:00:00 2001 From: Robert Winkler Date: Sun, 30 Jun 2019 00:30:47 -0700 Subject: [PATCH] Update packaging script and man page --- build_package.sh | 4 ++-- sdl_img.1 | 31 +++++++++++++++++++++++-------- 2 files changed, 25 insertions(+), 10 deletions(-) diff --git a/build_package.sh b/build_package.sh index e692f01..5c0b747 100755 --- a/build_package.sh +++ b/build_package.sh @@ -9,7 +9,7 @@ mkdir -p package_linux/usr/local/share/man/man1 cp ./sdl_img ./package_linux/usr/local/bin cp sdl_img.1 ./package_linux/usr/local/share/man/man1 -fpm -s dir -t deb -v 0.96 -n sdl_img -C package_linux \ +fpm -s dir -t deb -v 0.97 -n sdl_img -C package_linux \ --log info --verbose \ -d "libsdl2-2.0-0 >= 2.0.5" -d "libsdl2-gfx-1.0-0" -d "libcurl3" \ -m "Robert Winkler " \ @@ -17,7 +17,7 @@ fpm -s dir -t deb -v 0.96 -n sdl_img -C package_linux \ --url "https://github.com/rswinkle/sdl_img" -fpm -s dir -t tar -v 0.96 -n sdl_img -C package_linux \ +fpm -s dir -t tar -v 0.97 -n sdl_img_0.97 -C package_linux \ --log info --verbose \ -d "libsdl2-2.0-0 >= 2.0.5" -d "libsdl2-gfx-1.0-0" -d "libcurl3" \ -m "Robert Winkler " \ diff --git a/sdl_img.1 b/sdl_img.1 index d04e0e9..ff350c2 100644 --- a/sdl_img.1 +++ b/sdl_img.1 @@ -1,21 +1,25 @@ .\" Man page for SDL_IMG -.TH SDL_IMG 1 "31 June 2019" "0.96" "The SDL2 and stb_image based image viewer" +.TH SDL_IMG 1 "30 June 2019" "0.97" "The SDL2 and stb_image based image viewer" .\" Please adjust this date when revising the manpage. .\" .SH "NAME" sdl_img \- A simple but unique image viewer based on stb_image and SDL2 .SH "SYNOPSIS" -.B ./sdl_img [-f] [-s [delay]] [files] [-l text_list] +.B ./sdl_img [-f] [-R] [-s [delay]] [-r dir] [files/dirs] [-l text_list] -.B ./sdl_img -l list_of_images (urls or local paths or mixed, doesn't matter) +.B ./sdl_img image1.jpg (will open all images in same dir) -.B ./sdl_img image1.jpg image2.png +.B ./sdl_img -l list_of_imgs (urls or local paths or both) -.B ./sdl_img image.jpg -l list1 example.com/image.jpg -l list3 image4.gif +.B ./sdl_img . (will open all images in .) + +.B ./sdl_img image1.jpg somedir/* otherdir/image2.png + +.B ./sdl_img -l list1 example.com/image.jpg -l list3 -r ~/somedir .SH "DESCRIPTION" \fBsdl_img\fR is designed to be simple, easy to use image viewer that implements -some unique features while still having a short (~1500 SLOC not including +some unique features while still having a short (~2200 SLOC not including libraries) simple codebase. It handles all the normal functions of an image viewer (browsing through directories, zoom, pan, rotate, delete, slideshow). .TS @@ -31,6 +35,8 @@ Mouse Wheel Zoom in/out Left click + drag Pan around a zoomed in image A Actual size F Toggle fill screen mode +M Shuffle (Mix) the images (only in single mode) +O Sort (Order) the images (only in single mode) ALT + F or F11 Toggle Fullscreen ESC Exit (or exit Slideshow mode then fullscreen) L/R Rotate the current image left/right, prompts for saving appropriately @@ -71,8 +77,9 @@ the entire set of images or an individual selected from the group. .PP .SH "OPTIONS" .TP -\fBfilename(s)...\fR -Specifies the image to open when \fBsdl_img\fR starts. \fBsdl_img\fR also supports handling of remote files. +\fBfilename/directory(s)...\fR +Specifies the image to open when \fBsdl_img\fR starts. If a directory is given +it is scanned for images. \fBsdl_img\fR also supports handling of remote files. .TP \fB\-f, \-\-fullscreen\fR Start \fBsdl_img\fR in fullscreen mode. @@ -80,6 +87,14 @@ Start \fBsdl_img\fR in fullscreen mode. \fB\-s, \-\-slide-show [delay=3]\fR Open in slideshow mode. .TP +\fB\-r, \-\-recursive dir\fR +Scan dir recursively for images to add to the list +.TP +\fB\-R\fR +Scan all directories that come after recursively (-r after -R is redundant). +You can mix them, with -r and non -r dirs before -R but you might as well +move the -r dirs after -R to make your life easier. +.TP \fB\-c, \-\-cache ./your_cache\fR Use specified directory as cache. .TP