You are not logged in.
The configuration I made is really simple:
xmobar ~/.xmonad/xmobar2.hs
xmobar: /home/vohof/.xmonad/xmobar2.hs: configuration file contains errors at:
"Config" (line 15, column 5):
unexpected "s"
expecting space or "Run"I also installed xmobar-git and haskell-libmpd from AUR already so I can't guess anything else that could be wrong.
Config {
font = "xft:Fira Mono:size=8",
bgColor = "#2B303B",
fgColor = "#D8D4D4",
position = Bottom,
lowerOnStart = True,
commands = [
Run MPD ["-t", "<state>: <artist> - <track>"] 10
],
sepChar = "%",
alignSep = "}{",
template = "%mpd% }{ %date% "
}Last edited by vohof (2014-11-20 00:36:38)
Offline
Are you going to paste the actual config?
# edit: that isn't 15 lines...
Offline
@jasonwryan sorry I stripped off the comments.
-- xmobar config used by Vic Fryzel
-- Author: Vic Fryzel
-- http://github.com/vicfryzel/xmonad-config
-- This is setup for dual 1920x1080 monitors, with the right monitor as primary
Config {
font = "xft:Fira Mono:size=8",
bgColor = "#2B303B",
fgColor = "#D8D4D4",
position = Bottom,
lowerOnStart = True,
commands = [
Run MPD ["-t", "<state>: <artist> - <track>"] 10
],
sepChar = "%",
alignSep = "}{",
template = "%mpd% }{ %date% "
}Offline
I don't know how picky Haskell is about whitespace etc, but shouldn't it look more like:
Config { font = "xft:Fira Mono:size=8"
, bgColor = "#2B303B"
, fgColor = "#D8D4D4"
, position = Bottom
, lowerOnStart = True
, commands = [
Run MPD ["-t", "<state>: <artist> - <track>"] 10
]
, sepChar = "%"
, alignSep = "}{"
, template = "%mpd% }{ %date% "
}Offline
@jasonwryan I tried but I do still get the error.
Offline
Layout should be fine. Did a quick test and changing MPD to another command eliminates the parse error. I don't have haskell-libmpd installed, so that might explain it. Do you have it?
Offline
@Raynman Yes I have haskell-libmpd. What another command did you use?
The wiki says I need xmobar-git and haskell-libmpd.
Offline
You don't need xmobar-git, but you do need haskell-libmpd.
*** EDIT: I totally forgot that I'm using my own version of xmobar. You will need a version that has MPD capabilities compiled in and xmobar-git does. See my note at the bottom.***
I was able to get your exact configuration running. The things that I would check is -- along the lines of what Jason said -- check for whitespace. Haskell is very picky with whitespace and xmobar seems to be even more so. This includes emtpy lines at the bottom (Haskell wouldn't care about that though). The other thing to check is whether all of your Haskell libraries are functioning properly.
First, double check that haskell-libmpd is installed and that mpd is actually running. If both are true, see if the output of this returns anything:
ghc-pkg check* It looks like that mpd is not enabled by default in the PKGBUILD for xmobar-git. Try to comment out the "Default setup" line and uncomment the "MPD Support" line. That may be your problem.
Last edited by skottish (2014-11-19 20:58:17)
Offline
@skottish A very big thank you! Next time I'm make sure to check the PKGBUILD file first.
First I changed the version and checksum of haskell-alsa-mixer and haskell-libmpd from the AUR because they were out of date.
Then I modified the flags for xmobar-git
Thank you all for your help! Weeeeee.
Last edited by vohof (2014-11-20 00:37:19)
Offline
You're welcome.
Always check all of the build files from AUR packages and make sure that the upstream sources seem legitimate. Packages in the AUR are not managed by Arch as a distro and can very well contain malicious and really badly written code that can damage your system.
Last edited by skottish (2014-11-20 02:58:14)
Offline