Fix hang when wallpaper isn't found
This commit is contained in:
18
README.md
18
README.md
@@ -80,7 +80,7 @@ All OS:
|
|||||||
|
|
||||||
Linux | BSD:
|
Linux | BSD:
|
||||||
|
|
||||||
- Display Wallpaper: `feh`
|
- Display Wallpaper: `feh` or `nitrogen`
|
||||||
|
|
||||||
|
|
||||||
<!-- }}} -->
|
<!-- }}} -->
|
||||||
@@ -299,22 +299,6 @@ $gtk_shorthand on
|
|||||||
* Resizing the terminal so that the lines don't wrap.
|
* Resizing the terminal so that the lines don't wrap.
|
||||||
|
|
||||||
|
|
||||||
#### [Linux] The script hangs and doesn't display anything
|
|
||||||
|
|
||||||
This is caused by the getwallpaper function failing to find your current wallpaper and <br \>
|
|
||||||
imagemagick trying to crop a nonexistent image. You can fix this by installing feh and using it<br \>
|
|
||||||
to set your wallpaper or by changing the image source.
|
|
||||||
|
|
||||||
You can change the source by editing the `$image` variable or by launching the script with `--image`.
|
|
||||||
|
|
||||||
The possible values are:
|
|
||||||
|
|
||||||
* **wall** - Use the current wallpaper. (Default)
|
|
||||||
* **shuffle** - Shuffle through images in a directory. See `$shuffledir`
|
|
||||||
* **path/to/img.png** - Select an image to display.
|
|
||||||
* **off** - Disable images
|
|
||||||
|
|
||||||
|
|
||||||
#### getgpu doesn't show my exact video card name
|
#### getgpu doesn't show my exact video card name
|
||||||
|
|
||||||
If you're output looks like this:
|
If you're output looks like this:
|
||||||
|
|||||||
3
fetch
3
fetch
@@ -1030,6 +1030,9 @@ getimage () {
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
# If $img is empty, reset padding to 0 and exit the function
|
||||||
|
[ -z "$img" ] && padding="\e[0C"; return
|
||||||
|
|
||||||
# Get name of image and prefix it with it's crop mode and offset
|
# Get name of image and prefix it with it's crop mode and offset
|
||||||
imgname="$crop_mode-$crop_offset-$imgsize-${img##*/}"
|
imgname="$crop_mode-$crop_offset-$imgsize-${img##*/}"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user