summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--README.org9
-rw-r--r--pkg/unsplash/unsplash.go2
2 files changed, 9 insertions, 2 deletions
diff --git a/README.org b/README.org
index 8cc92cd..894c5e9 100644
--- a/README.org
+++ b/README.org
@@ -8,7 +8,7 @@ wallpapers.
 * Features
 - set a specific photo as wallpaper
 - customize wallpaper size
-* pppDemo
+* Demo
 I just run some cetus commands on my computer, nothing fancy. I'll make better
 demo videos someday.
 
@@ -17,3 +17,10 @@ demo videos someday.
 | v0.2.0  | https://diode.zone/videos/watch/12db31e1-3517-4888-ad06-55f3859447a1 |
 * Dependency
 - [[https://feh.finalrewind.org/][feh]]
+* Usage
+** photo-id
+photo-id flag can be used to set a specific photo as background.
+#+BEGIN_SRC sh
+cetus -width 1920 -height 1080 \
+      -photo-id=FzrjgIId6NU
+#+END_SRC
diff --git a/pkg/unsplash/unsplash.go b/pkg/unsplash/unsplash.go
index 3070716..e40503d 100644
--- a/pkg/unsplash/unsplash.go
+++ b/pkg/unsplash/unsplash.go
@@ -29,7 +29,7 @@ func SetFromID(photoID string, width int, height int) error {
 		err error
 	)
 
-	size = fmt.Sprintf("%sx%s", width, height)
+	size = fmt.Sprintf("%dx%d", width, height)
 	path = fmt.Sprintf("%s/%s/%s", "https://source.unsplash.com", photoID, size)
 	err = background.Set(path)