Linux软件配置

本文详述了Linux系统的备份方法,通过rsync实现增量备份。还介绍了如何配置磁盘开机自动挂载,以及连接联想M7650DNF打印机的步骤。此外,文章提到了文献管理软件Zotero的安装与设置,并分享了Shell脚本学习的基础知识,包括for循环的使用。同时,文章推荐了软件启动工具Albert和文件同步工具Syncthing,并给出了在Manjaro系统中遇到的问题及解决方案。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Linux软件配置

Linux系统备份

利用rsync来增量备份系统

sudo rsync -avzue ssh / --exclude={"dev/*", "proc/*", "sys/*", "tmp/*", "run/*", "mnt/*", "media/*", "lost+found"} user@⬇️0.0.0.253::backup/manjaro/

Linux系统配置

设置磁盘开机自动mount

sudo nano /etc/fstab

配置模板:

UUID=*************  /mnt/data  ext4  defaults,noatime  0  1

M7650DNF

CentOS 连接联想打印机,联想Lenovo M7650DNF打印机Linux下驱动很难找,看到一篇日志说是联想的打印机可能跟brother的驱动相似。

设置过程是:系统-管理-打印-新建,在网络打印机中选择Lenovo M7650DNF型号,然后就是选择驱动,选brother的,HL-8050N。完成。打印测试页,可以打印

Zotero

  • 下载地址

    https://www.zotero.org/download/

  • 软件设置

  1. 安装
  2. 更改目录, 建立符号链接, 删除zotero目录下storage目录.
cd zotero目录
ls -s D:\Individual\reference\  storage 
  1. 设置
  • 同步账号为: (自己的账号)
  • File Syncing勾去掉
  • 插件
  1. Better BibTeX

https://github.com/retorquere/zotero-better-bibtex/releases/tag/v5.1.45

  • Citation key Format: [auth][year]P[firstpage]
  • Field to omit form export: abstract,keywords,file

Shell脚本学习

与其他编程语言类似,Shell支持for循环。for循环一般格式:

for var in item1 item2 ... itemN
do
    command1
    ...
done

写成一行:

for var in item_list; do command1; command2… done;

例子:转换ape格式flac格式,同时去除metadata里的comment.

分析:由于文件名里有空格,所以$file都加入双引号。

# for file in `ls | grep .ape`
for file in *.wma
do
    newfile=`echo "$file" | sed 's/_/ /g' | sed 's/ape/flac/g'`
    ffmpeg -i "$file" -y -metadata comment= "$newfile"
done

yay

安装

sudo pacman -S yay base-devel

Albert 软件启动神器

sudo pacman -S albert

syncthing

sudo pacman -S syncthing

Enable and start the service. Replace “myuser” with the actual Syncthing user after the

systemctl enable syncthing@myuser.service
systemctl start syncthing@myuser.service

FAQ

  1. 在Manjaro使用Python自带的IDLE,出现以下问题
[user@user-pc ~]$ idle
IDLE can't import Tkinter.
Your Python may not be configured for Tk. **

尝试用pip安装Tkinter,不过失败了,出现了错误

[user@user-pc ~]$ pip install Tkinter
Defaulting to user installation because normal site-packages is not writeable
ERROR: Could not find a version that satisfies the requirement Tkinter (from versions: none)
ERROR: No matching distribution found for Tkinter

无意中发现居然可以这么简单的解决了[1]

sudo pacman -S python-pmw
  1. VirtualBox虚拟机窗口半透明,彻底解决方法如下:
sudo vim /usr/bin/VirtualBox

在PATH=……一行前加入:

export XLIB_SKIP_ARGB_VISUALS=1

添加完保存之后正常启动VirtualBox,虚拟机画面正常

[1] https://www.cnblogs.com/xavier-wang/p/12409345.html

[2] http://www.seebit.org/2009/04/virtualbox-window-translucent/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值