首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >错误编译xmonad.hs

错误编译xmonad.hs
EN

Unix & Linux用户
提问于 2020-07-04 21:04:06
回答 1查看 404关注 0票数 0

我试图使不同的工作区有不同的布局,我发现了这个模块- https://hackage.haskell.org/package/xmonad-contrib-0.15/docs/XMonad-Layout-PerWorkspace.html

我在我的XMonad.Layout.PerWorkspace中导入了xmonad.hs并添加了这些行-

代码语言:javascript
复制
onWorkspace ["2"] noBorders monocle $  -- layout l1 will be used on workspace "2".
onWorkspace ["9"] smartBorders Full $  -- layout l2 will be used on workspace "6".

myLayoutHook

代码语言:javascript
复制
-- The layout hook
myLayoutHook = avoidStruts $ mouseResize $ windowArrange $ T.toggleLayouts floats $
               mkToggle (NBFULL ?? NOBORDERS ?? EOT) myDefaultLayout

               onWorkspace ["2"] noBorders monocle $  -- layout l1 will be used on workspace "2".
               onWorkspace ["9"] smartBorders Full $  -- layout l2 will be used on workspace "6".

             where
               -- I've commented out the layouts I don't use.
               myDefaultLayout =     tall
                                 ||| noBorders monocle
                                 ||| floats
                                 ||| grid
                                 ||| smartBorders Full

但是我在重新编译xmonad时出错了

代码语言:javascript
复制
> xmonad --recompile                                                                                                                         
XMonad will use ghc to recompile, because "/home/apoorv/.xmonad/build" does not exist.
Error detected while loading xmonad configuration file: /home/apoorv/.xmonad/xmonad.hs
xmonad.hs:620:14: error: parse error on input ‘where’
    |
620 |              where
    |              ^^^^^
Please check the file for errors.
Warning: Missing charsets in String to FontSet conversion
EN

回答 1

Unix & Linux用户

发布于 2020-07-08 11:24:27

你错过了一个$..。

一般格式如下:

代码语言:javascript
复制
abc
$ xyz123 
$ xyz456

而你似乎有:

代码语言:javascript
复制
abc
xyz123 $
xyz456 $
票数 0
EN
页面原文内容由Unix & Linux提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://unix.stackexchange.com/questions/596747

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档