Linux学习之路LinuxKali Linux

Kali Linux-美化与优化

2018-09-04  本文已影响1206人  M4K0

照理说,linux的桌面是不应当存在在这个世界上的,作为一个linux用户,一味捣鼓桌面显得hen不专业,.但是,虚拟机要用到,浏览器要用到...更何况,自己的老婆能不打扮一下么?

效果预览

V1.0版

图标制作

有的手动编译后,没有生成图标,启动后也无法加入左侧dash的收藏,启动不方便。
另外,有的应用关联设置,比如说想要双击打开JAR文件,环境应用没有图标的话,也不会出现在备选列表中。需要手动写一个启动方式,提高效率。
三种

  1. 命令行关联,在/usr/bin/目录下创建软连接,
cd /usr/bin/
sudo ln -s /opt/xxx/jadx jadx

或者导入/etc/profile,环境变量配置方法后续补充。

  1. 创建桌面或者程序图标,/usr/share/applications/xxx.desktop
    或者直接放到桌面上
    cat Desktop/010editor-desktop.desktop:
[Desktop Entry]
Version=1.0
Type=Application
Name=010 Editor
Exec=/opt/010editor/010editor 
Icon=/opt/010editor/010_icon_128x128.png
  1. 在cairo-dock中设置启动器,把启动应用所需执行的命令写进去,自己配个图标即可。甚至是简书url也可以。

顶部插件

  1. 火狐浏览器访问:https://extensions.gnome.org/
  2. 遇到提示Allow https://extensions.gnome.org/ to run "GNOME Shell Integration?",点击Allow and remember开启浏览器扩展支持。
  3. ,这样就可以从网页上直接安装其他插件了。
    推荐几个:

gnome-shell隐藏标题栏http://www.linuxdiyf.com/viewarticle.php?id=270522

修复ls

vi ~/.bashrc,按x键,把那几个注释去掉

bashrc.png

GRUB优化

sudo vi /etc/default/grub,修改后执行 sudo update-grub生效

解决中文乱码问题

快捷键

点击屏幕右上角菜单中的扳手图标,Settings->Devices->Keyboard,打开如下界面配置自定义快捷键。

key.png

皮肤更改

Conky配置

通过ConkyManager配置。找一个主题,解压后把文件夹放到~/.conky/中。
这里用的是Sidebar-Conky主题,做了一点修改,下面看看~/.conky/Sidebar-Conky/Sidebar-Conky_Rc代码。

############################################################################################
# Sidebar-Conky                                        #
# by wim66 https://www.google.com/+WillemO                         #
# 26-5-15                                          #
# "Inspired by" other people's code                            #
# Calendar, more great conky's http://erikdubois.be/category/conky             #
# Jesse Avalos http://speedracker.deviantart.com/                      #
# Weather font by Kelly Kretchek https://plus.google.com/u/0/103934698784251707937/posts   #
# Wallpaper http://0rax0.deviantart.com/art/Linux-2014-Wallpaper-457151439         #
# Use with Conky-Manager                                   #
# http://www.teejeetech.in/p/conky-manager.html                        #
#                                              #
############################################################################################

background yes
double_buffer yes
no_buffers yes
text_buffer_size 2048
imlib_cache_size 0
#刷新频率
update_interval 1
cpu_avg_samples 1
format_human_readable

alignment bottom_right
gap_x 11
gap_y -33
minimum_size 280 750
maximum_width 240

own_window yes
own_window_type desktop     # options are: normal/override/dock/desktop/panel
own_window_class Conky
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
own_window_transparent yes
own_window_colour 000000
own_window_argb_visual yes
own_window_argb_value 0

border_inner_margin 2
border_outer_margin 2

default_bar_size 100 6
draw_shades no
default_shade_color 000000
draw_outline no
default_outline_color 000000
draw_borders no
draw_graph_borders yes
default_graph_size 40,220
show_graph_scale no
show_graph_range no

override_utf8_locale yes
use_xft yes
xftfont Adele:size=13,weight:normal
xftalpha 1
uppercase no
max_text_width 40

default_color ffffff
color1 ffffff
color2 FF5A45
color3 81CAE0
color4 FF5A45
color5 00FF00

TEXT
#$sysname
${voffset 10}${font Adele:size=15,weight:normal}${color1}${alignc}[[ $kernel ]] ${font}
#${goto 10}Desktop:${alignr 5}$XDG_CURRENT_DESKTOP
#${goto 10}Installation date:${alignr 5}${exec ls -ld /lost+found | cut -d' ' -f 6-7 --output-delimiter=' - '}
${goto 10}Uptime:${alignr 5}$uptime
#
# cpu load/temp/graph
${goto 10}${voffset 5}CPU1: ${cpu cpu1}%${alignr 10}${exec sensors|grep 'Core 0'|awk '{print $3}'}
${goto 10}${voffset -5}${color2}${cpugraph cpu1 40,220 66241C FF5A45}
${goto 10}${voffset 0}${color1}CPU2: ${cpu cpu2}%${alignr 10}${exec sensors|grep 'Core 1'|awk '{print $3}'}
${goto 10}${voffset -5}${color2}${cpugraph cpu2 40,220 66241C FF5A45}
#
# top processes
${voffset -5}${font Adele:size=15,weight:normal}${color1}${alignc}Top Processes ${font}
${voffset 4}${goto 10}${top name 1}${alignr 10}${top cpu 1}%
${goto 10}${voffset -2}${top name 2}${alignr 10}${top cpu 2}%
${goto 10}${voffset -2}${top name 3}${alignr 10}${top cpu 3}%
${goto 10}${voffset -2}${top name 4}${alignr 10}${top cpu 4}%
#
# top memory
${goto 10}${voffset 10}${font Adele:size=15,weight:normal}Memory${goto 85}${color2}$membar${alignr 10}${color1}$memperc%
${goto 10}${color1}${voffset -2}${font}${top_mem name 1}${alignr 10}${top mem 1}%
${goto 10}${voffset -2}${top_mem name 2}${alignr 10}${top mem 2}%
${goto 10}${voffset -2}${top_mem name 3}${alignr 10}${top mem 3}%
${goto 10}${voffset -2}${top_mem name 4}${alignr 10}${top mem 4}%
#
#network
${voffset 10}${font Adele:size=15,weight:normal}${color1}${alignc}Network
${goto 10}SSID:${alignr 10}${wireless_essid wlan0}
${goto 10}Signal:${goto 85}${color2}${wireless_link_bar wlan0}${color1}${alignr 10}${wireless_link_qual_perc wlan0}%
${goto 10}eth0: ${alignr 10}${addr eth0}
${voffset 5}${goto 10}${color1}Upspeed:${alignr 10}${upspeed wlan0}
${goto 10}${voffset 0}Total up:${alignr 10}${totalup wlan0}
${goto 10}${color2}${upspeedgraph wlan0 40,220 66241C FF5A45 100 -l}
${goto 10}${color1}Down:$color1${alignr 10}${downspeed wlan0}
${goto 10}Total down:${alignr 10}${totaldown wlan0}
${goto 10}${color2}${downspeedgraph wlan0 40,220 66241C FF5A45 100 -l}
#
# weather
#
#------> Check Qaisar Nawaz' blog on how to change the weather location code: http://myconkys.blogspot.com.au/2014/04/weather-location-settings.html <-----#
#
#${execi 300 curl -s "http://weather.yahooapis.com/forecastrss?w=727232&u=c" -o ./weather/cache/weather.xml}\
#${font Adele:size=15,weight:normal}${goto 10}${color1}${voffset 0}${execi 300 grep "yweather:location" ./weather/cache/weather.xml | grep -o "city=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*"}, ${execi 300 grep "yweather:location" ./weather/cache/weather.xml | grep -o "country=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*"}
#
# weather discription
###${goto 10}${voffset 0}${color1}${font Adele:size=15,weight:normal}\
${execi 360 grep "yweather:condition" ~/.cache/weather.xml | grep -o "text=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*"}\
${font}
#
# temp
###${font LG Weather_Z:size=35}${goto 10}${voffset 0}${execi 300 grep "yweather:condition" ./weather/cache/weather.xml | grep -o "temp=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*"}°${font GeosansLight:normal:size=12}Celsius}
# high/low
###${font}${goto 30}${voffset 5}${execi 300 grep "yweather:forecast" ./weather/cache/weather.xml | grep -o "high=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==1'}°\
###${goto 85}${voffset 0}${execi 300 grep "yweather:forecast" ./weather/cache/weather.xml | grep -o "low=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==1'}°
#
# weather icons
#
###${font Scalable weather v12.0:size=90,weight:normal}${color3}${voffset -90}${goto 150}${execi 300 sh weather/weather_font $(grep "yweather:condition" ./weather/cache/weather.xml | grep -o "code=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*")}
#
###${image arrow-up.png -p 10,988 -s 15x15}
#
###${image arrow-down.png -p 65,988 -s 15x15}
#

#${goto 10}${exec whoami}:
#${exec ls ~/Desktop|awk -F '.' '{print $1}'}
#${exec date "+%H:%M:%S"}
${voffset -10}${font Adele:size=15,weight:normal}${color1}${alignc}Devices
#${color5}${exec adb devices}
#${voffset -10}${font Adele:size=15,weight:normal}${color1}${alignc}Devices List
${color5}${exec adb devices|grep -v devices}
#${goto 10}device ${color1}${alignr 10}${exec  adb devices|grep -v devices|awk -F " " '{print $1}'}

配置文件有其特定的语法,反复看几遍就能理解了。有时间再在下面补充一下语法细节。
另外有个小问题,启用这个主题后,wps中默认的英文字体也成了Adele,丑……原因还在排查中。

隐私策略

这部分打算另开文章说

上一篇下一篇

猜你喜欢

热点阅读