随便下载一个后缀为coffee的文件,用文本编辑器打开直接修改就可以了!
# command后面跟shell命令,用引号引起来
command: "whoami"
# 刷新频率
refreshFrequency: 1000000
# render输出这个上面命令的结果。"""之内是输出的内容
render: (output) -> """
<h1>Hi, #{output}</h1>
<p>
Thanks for trying out Übersicht!
This is an example widget to get you started.
</p>
<p>
To view this example widget, choose <em>'Open Widgets Folder'</em>
from the status bar menu. Use it to create your own widget,
or simply delete it.
</p>
<p>
To download other widgets, choose <em>'Visit Widgets Gallery'</em>
from the status bar menu.
</p>
"""
# css文件规定样式
# (http://learnboost.github.io/stylus/)
style: """
background: rgba(#fff, 0.95) url('übersicht-logo.png') no-repeat 50% 20px
background-size: 176px 84px
-webkit-backdrop-filter: blur(20px)
border-radius: 1px
border: 2px solid #fff
box-sizing: border-box
color: #141f33
font-family: Helvetica Neue
font-weight: 300
left: 50%
line-height: 1.5
margin-left: -170px
padding: 120px 20px 20px
top: 10%
width: 340px
text-align: justify
h1
font-size: 20px
font-weight: 300
margin: 16px 0 8px
em
font-weight: 400
font-style: normal
"""