diff --git a/Randsolid.hs b/Randsolid.hs
--- a/Randsolid.hs
+++ b/Randsolid.hs
@@ -1,6 +1,7 @@
 -- Change the root window background to a random solid colour.
 
 import System.Random
+import System.Environment (getArgs)
 import Control.Applicative
 import Data.Bits
 import Graphics.X11.Xlib.Window
@@ -84,4 +85,8 @@
 	closeDisplay dpy
 
 
-main = randsolid defaultValues
+main = do
+	args <- getArgs
+	if args == ["-p"] || args == ["--print"]
+		then putStrLn . show =<< randcolour defaultValues
+		else randsolid defaultValues
diff --git a/randsolid.cabal b/randsolid.cabal
--- a/randsolid.cabal
+++ b/randsolid.cabal
@@ -1,12 +1,12 @@
 Name:                randsolid
-Version:             0.1
+Version:             0.2
 Synopsis:            Set the background of your root window to a random colour.
-Description:         Set the background of your root window to a random colour.
+Description:         Set the background of your root window to a random colour (or just print the colour).
 Category:            System
 License:             PublicDomain
 License-file:        LICENSE
 Author:              Johannes Martinsson
-Maintainer:          w@antiklimax.se
+Maintainer:          w+randsolid@antiklimax.se
 Cabal-version:       >= 1.2
 Build-type:          Simple
 
