Linux系统下便捷使用中国知网的方式
2017-01-07 00:02
597 查看
本篇文章讲解在linux平台下合理使用中国知网的方式,包括:论文下载,文件名乱码处理等内容,并提供相应代码。
(1)论文下载
背景:由于cnki并未提供linux平台下的caj阅读器,同时使用模拟器运行caj阅读器则可能造成程序崩溃和内容乱码等的问题,使广大使用者深感痛楚,接下来讲解如何快捷下载pdf格式文档,而非cnki推荐的caj格式文档的方法。
1)进入浏览器插件管理页面,搜索:Greasemonkey,下载并安装油猴子浏览器插件。安装后请重启浏览器。
2)点击下方链接进入Greasemonkey脚本下载页面,浏览器将自动安装脚本。
https://greasyfork.org/scripts/18841-cnki-%E4%B8%AD%E5%9B%BD%E7%9F%A5%E7%BD%91-pdf-%E5%85%A8%E6%96%87%E4%B8%8B%E8%BD%BD/code/CNKI%20%E4%B8%AD%E5%9B%BD%E7%9F%A5%E7%BD%91%20PDF%20%E5%85%A8%E6%96%87%E4%B8%8B%E8%BD%BD.user.js
3)点击下载图标,可直接下载pdf格式文档,而非cnki所默认的caj格式文档。同时博硕士论文下载选项处出现PDF下载选项。
(2)文件名称乱码处理
Linux系统下可推荐 convmv 程序进行文件名编码格式转换。
首先安装并安装 convmv 程序,方式为:
注:该方式适用于Ubuntu系统,其他Linux系统的下载方式与此类似。
以下为convmv的帮助文档:
CONVMV(1)
NAME
convmv -converts filenames from one encoding to another
SYNOPSIS
convmv[options] FILE(S) ... DIRECTORY(S)
OPTIONS
-f ENCODING
specifythe current encoding of the filename(s) from which should beconverted
-t ENCODING
specifythe encoding to which the filename(s) should be converted
--nosmart
bydefault convmv will detect if a filename is already UTF8 encoded andwill skip this file if conversion from some charset to UTF8 should beperformed. "--nosmart" will also force conversion to UTF-8for such files,
which might result in "double encoded UTF-8"(see section below).
--nosmart
bydefault convmv will detect if a filename is already UTF8 encoded andwill skip this file if conversion from some charset to UTF8 should beperformed. "--nosmart" will also force conversion to UTF-8for such files,
which might result in "double encoded UTF-8"(see section below).
使用方式较简单,可将大部分cnki下载文文件名进行编码转换。
使用方式为:
1)到达文件所在目录。
2) 运行代码:
以测试能够进行转化操作,同时在操作3进行之前请备份文件。
3)运行代码:
以非测试的方式进行转化,注意这种方式可能会破坏文件。
以Ubuntu 16.04系统convmv 2.0程序下的使用方式为例:
aro@ZAKER:~$cd ./filearo@ZAKER:~/file$ls2_5_7_9_ËÄÏõ»ù_2_5__Ê¡ÂÔ__8µÄ·ÅÈȷֽⷴӦ¶¯Á¦Ñ§_Ó¢ÎÄ_ÕÔ·ïÆð.pdfaro@ZAKER:~/file$convmv -r -f utf8 -t iso88591 * --nosmart&& convmv -r -f gbk -t utf8 * --nosmartStarting a dry run without changes...mv"./ÐÂÒ»´ú¸ßËÙI_O»¥Á¬PCIExpress½Ó¿ÚÉè¼Æ_ºúÅô.2.pdf"
"./��һ������I_O����PCIExpress�ӿ�����_����.2.pdf"No changes to your files done. Would have converted 1 files in 0 seconds.Use --notest to finally rename the files.Starting a dry run without changes...Skipping, already UTF-8: ./ÐÂÒ»´ú¸ßËÙI_O»¥Á¬PCIExpress½Ó¿ÚÉè¼Æ_ºúÅô.2.pdfNo
changes to your filesdone. Would have converted 0 files in0 seconds.Use --notest to finally rename the files.aro@ZAKER:~/file$convmv -r -f utf8 -t iso88591 * --notest --nosmart&& convmv -r -f gbk -t utf8 * --notest --nosmartmv "./2_5_7_9_ËÄÏõ»ù_2_5__Ê¡ÂÔ__8µÄ·ÅÈȷֽⷴӦ¶¯Á¦Ñ§_Ó¢ÎÄ_ÕÔ·ïÆð.pdf"
"./2_5_7_9_������_2_5__ʡ��__8�ķ��ȷֽⷴӦ����ѧ_Ӣ��_�Է���.pdf"Ready! I converted1 files in 0 seconds.mv "./2_5_7_9_������_2_5__ʡ��__8�ķ��ȷֽⷴӦ����ѧ_Ӣ��_�Է���.pdf" "./2_5_7_9_四硝基_2_5__省略__8的放热分解反应动力学_英文_赵凤起.pdf"Ready! I converted 1 files in 0 seconds.aro@ZAKER:~/file$ls2_5_7_9_四硝基_2_5__省略__8的放热分解反应动力学_英文_赵凤起.pdf
同时注意单纯使用convmv -r -f gbk -t utf8 * --notest –nosmart或convmv -r -f utf8 -t iso88591 * --notest--nosmart命令并不能实现乱码问题的解决。
(1)论文下载
背景:由于cnki并未提供linux平台下的caj阅读器,同时使用模拟器运行caj阅读器则可能造成程序崩溃和内容乱码等的问题,使广大使用者深感痛楚,接下来讲解如何快捷下载pdf格式文档,而非cnki推荐的caj格式文档的方法。
1)进入浏览器插件管理页面,搜索:Greasemonkey,下载并安装油猴子浏览器插件。安装后请重启浏览器。
2)点击下方链接进入Greasemonkey脚本下载页面,浏览器将自动安装脚本。
https://greasyfork.org/scripts/18841-cnki-%E4%B8%AD%E5%9B%BD%E7%9F%A5%E7%BD%91-pdf-%E5%85%A8%E6%96%87%E4%B8%8B%E8%BD%BD/code/CNKI%20%E4%B8%AD%E5%9B%BD%E7%9F%A5%E7%BD%91%20PDF%20%E5%85%A8%E6%96%87%E4%B8%8B%E8%BD%BD.user.js
3)点击下载图标,可直接下载pdf格式文档,而非cnki所默认的caj格式文档。同时博硕士论文下载选项处出现PDF下载选项。
(2)文件名称乱码处理
Linux系统下可推荐 convmv 程序进行文件名编码格式转换。
首先安装并安装 convmv 程序,方式为:
aro@ZAKER:~$sudo apt install convmv
注:该方式适用于Ubuntu系统,其他Linux系统的下载方式与此类似。
以下为convmv的帮助文档:
CONVMV(1)
NAME
convmv -converts filenames from one encoding to another
SYNOPSIS
convmv[options] FILE(S) ... DIRECTORY(S)
OPTIONS
-f ENCODING
specifythe current encoding of the filename(s) from which should beconverted
-t ENCODING
specifythe encoding to which the filename(s) should be converted
--nosmart
bydefault convmv will detect if a filename is already UTF8 encoded andwill skip this file if conversion from some charset to UTF8 should beperformed. "--nosmart" will also force conversion to UTF-8for such files,
which might result in "double encoded UTF-8"(see section below).
--nosmart
bydefault convmv will detect if a filename is already UTF8 encoded andwill skip this file if conversion from some charset to UTF8 should beperformed. "--nosmart" will also force conversion to UTF-8for such files,
which might result in "double encoded UTF-8"(see section below).
使用方式较简单,可将大部分cnki下载文文件名进行编码转换。
使用方式为:
1)到达文件所在目录。
aro@ZAKER:~$cd ./file
2) 运行代码:
aro@ZAKER:~/file$convmv -r -f utf8 -t iso88591 * --nosmart && convmv -r -f gbk -t utf8 * --nosmart
以测试能够进行转化操作,同时在操作3进行之前请备份文件。
3)运行代码:
aro@ZAKER:~/file$convmv -r -f utf8 -t iso88591 * --notest --nosmart && convmv -r -f gbk -t utf8 * --notest --nosmart
以非测试的方式进行转化,注意这种方式可能会破坏文件。
以Ubuntu 16.04系统convmv 2.0程序下的使用方式为例:
aro@ZAKER:~$cd ./filearo@ZAKER:~/file$ls2_5_7_9_ËÄÏõ»ù_2_5__Ê¡ÂÔ__8µÄ·ÅÈȷֽⷴӦ¶¯Á¦Ñ§_Ó¢ÎÄ_ÕÔ·ïÆð.pdfaro@ZAKER:~/file$convmv -r -f utf8 -t iso88591 * --nosmart&& convmv -r -f gbk -t utf8 * --nosmartStarting a dry run without changes...mv"./ÐÂÒ»´ú¸ßËÙI_O»¥Á¬PCIExpress½Ó¿ÚÉè¼Æ_ºúÅô.2.pdf"
"./��һ������I_O����PCIExpress�ӿ�����_����.2.pdf"No changes to your files done. Would have converted 1 files in 0 seconds.Use --notest to finally rename the files.Starting a dry run without changes...Skipping, already UTF-8: ./ÐÂÒ»´ú¸ßËÙI_O»¥Á¬PCIExpress½Ó¿ÚÉè¼Æ_ºúÅô.2.pdfNo
changes to your filesdone. Would have converted 0 files in0 seconds.Use --notest to finally rename the files.aro@ZAKER:~/file$convmv -r -f utf8 -t iso88591 * --notest --nosmart&& convmv -r -f gbk -t utf8 * --notest --nosmartmv "./2_5_7_9_ËÄÏõ»ù_2_5__Ê¡ÂÔ__8µÄ·ÅÈȷֽⷴӦ¶¯Á¦Ñ§_Ó¢ÎÄ_ÕÔ·ïÆð.pdf"
"./2_5_7_9_������_2_5__ʡ��__8�ķ��ȷֽⷴӦ����ѧ_Ӣ��_�Է���.pdf"Ready! I converted1 files in 0 seconds.mv "./2_5_7_9_������_2_5__ʡ��__8�ķ��ȷֽⷴӦ����ѧ_Ӣ��_�Է���.pdf" "./2_5_7_9_四硝基_2_5__省略__8的放热分解反应动力学_英文_赵凤起.pdf"Ready! I converted 1 files in 0 seconds.aro@ZAKER:~/file$ls2_5_7_9_四硝基_2_5__省略__8的放热分解反应动力学_英文_赵凤起.pdf
同时注意单纯使用convmv -r -f gbk -t utf8 * --notest –nosmart或convmv -r -f utf8 -t iso88591 * --notest--nosmart命令并不能实现乱码问题的解决。
相关文章推荐
- linux下收集系统硬盘,内存使用情况以定时邮件方式发给root的一个脚本
- 关于linux - Centos 7 系统下使用PXE网络的方式(pxe+dhcpd+tftp+httpd)安装操作系统
- Linux crontab的使用方式,sh脚本的编写,sh脚本自动启动tomcat服务器,sh监控系统运行情况
- 如何在 Ubuntu 上使用 ZFS 文件系统 | Linux 中国
- 实战Nagios NSCA方式监控Linux系统资源使用情况 -- Nagios配置篇 -- 被监控端
- python-hwinfo:使用 Linux 系统工具展示硬件信息概况 | Linux 中国
- 使用库函数API和C代码中嵌入汇编代码两种方式使用同一个系统调用(Linux)
- linux 使用PXE方式,kickstar网络安装系统
- Linux内核分析:使用库函数API和C代码中嵌入汇编代码两种方式使用同一个系统调用
- Linux 系统使用 iso 镜像文件或光盘配置本地YUM 源的最简单方式
- 在 RHEL/CentOS 系统上使用 YUM history 命令回滚升级操作 | Linux 中国
- 大公司使用Linux系统的使用方式
- 使用 Ansible 在树莓派上构建一个基于 Linux 的高性能计算系统 | Linux 中国
- 使用 Ansible 让你的系统管理自动化 | Linux 中国
- Linux系统如何使用SFTP方式传输文件具体图解
- 实战Nagios NSCA方式监控Linux系统资源使用情况 -- Nagios配置篇 -- Nagios Server端
- 使用密钥验证方式登录linux系统
- D-Chip i.MX6使用TFTP NFS方式挂载linux系统的方法
- Linux 查看磁盘分区、文件系统、使用情况的命令和相关工具介绍
- LINUX系统中动态链接库的创建与使用