mirror of
https://github.com/LCTT/TranslateProject.git
synced 2025-01-16 22:42:21 +08:00
commit
3605c225f8
@ -1,8 +1,8 @@
|
||||
Zukimac 主题使 Ubuntu 14.04 桌面变成 Mac 桌面
|
||||
在 Ubuntu 上体验 Mac 风格
|
||||
================================================================================
|
||||
![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/06/Make_Ubuntu_Look_Like_Mac_OS.jpeg)
|
||||
|
||||
虽然 Ubuntu Unity 本身已经是一款很漂亮的桌面了,但世界各地还是有很人被 Mac OS X 的外观所震撼。如果您恰好是其中之一,为了获得 OS X 的主题,是不需要换掉 Ubuntu 的,相反,您可以对它来个美化改造,**使 Ubuntu 14.04 看起来就像 Mac OS X**。
|
||||
虽然 Ubuntu Unity 本身已经是一款很漂亮的桌面了,但世界各地还是有很人被 Mac OS X 的外观所震撼。如果您恰好是其中之一,要获得 Mac OS X 一样外观体验,是不需要丢掉 Ubuntu 的,相反,您可以对它来个美化改造,**使 Ubuntu 14.04 看起来就像 Mac OS X**。
|
||||
|
||||
### 让 Ubuntu 14.04 看起来像 Mac OS X ###
|
||||
|
||||
@ -12,11 +12,11 @@ Zukimac 主题使 Ubuntu 14.04 桌面变成 Mac 桌面
|
||||
- 解压下载的 Zip 包,解压后会出现 Zukimac 和 Zukimac-ml 两个目录文件。把这些目录拷贝到您的 home 目录下的 .themes 文件夹中。进入 Home 目录中,按下快捷键 Ctrl+H 可以显示所有隐藏的文件,如果没有 .themes 文件夹,需要创建一个。
|
||||
- 使用 [Unity Tweak Tool 来改变主题][2].
|
||||
|
||||
就这些操作。Zukimac 提供了一些基本的 Mac OS 系统的外观和视窗感觉。下面是带有默认的 OS X MaVeric 壁纸的外观。
|
||||
就这些操作。Zukimac 提供了一些基本的 Mac OS 系统的外观和视窗感觉。下面是带有默认的 OS X Maveric 壁纸的外观。
|
||||
|
||||
![Make Ubuntu 14.04 look like Mac OS X](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/06/Ubuntu_MAC_OS_Looks.jpeg)
|
||||
|
||||
### Ubuntu 14.04 中获得 Mac 感觉更多的调整###
|
||||
### Ubuntu 14.04 中获得更多 Mac 体验 ###
|
||||
|
||||
通常,您可以**安装像 Plank 或 Docky 这样的 dock 启动面板**。在 Ubuntu 14.04 中要安装 Plank 可以使用下面的命令:
|
||||
|
||||
@ -42,7 +42,7 @@ Zukimac 主题使 Ubuntu 14.04 桌面变成 Mac 桌面
|
||||
|
||||
via: http://itsfoss.com/ubuntu-1404-mac-zukimac-theme/
|
||||
|
||||
译者:[runningwater](https://github.com/runningwater) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
译者:[runningwater](https://github.com/runningwater) 校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
@ -1,6 +1,6 @@
|
||||
Ubuntu 14.04 LTS: 定制 Unity
|
||||
================================================================================
|
||||
虽然Unity桌面管理器自从伴随 Ubuntu 11.01首次发布以来表现出了强劲的性能,并在可用性上迈进了一大步,但是有人对自定义其外观和行为所带的限制感到反感。我们现在来看看如何自定义Unity,让你重拾自己掌控桌面的感觉。
|
||||
虽然Unity桌面管理器自从伴随 Ubuntu 11.10首次发布以来表现出了强劲的性能,并在可用性上迈进了一大步,但是有人对自定义其外观和行为所带的限制感到反感。我们现在来看看如何自定义Unity,让你重拾自己掌控桌面的感觉。
|
||||
|
||||
### Unity中的可用定制项目 ###
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
如何在Ubuntu 14.04中添加多时区时间 [小技巧]
|
||||
[小白技巧]如何在Ubuntu 14.04中添加多个时区时间
|
||||
================================================================================
|
||||
如果你需要和多时区时间打交道的话,你一定希望你的电脑时钟可以显示多个时区的时间。作为一个移居国外的人,我需要关注法国和印度的时间。在Ubuntu系统中,你可以进行简易的设置来添加多时区时间。
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
|
||||
### 在Ubuntu 14.04系统中添加多时区时间 ###
|
||||
|
||||
打开系统设置(按下标有微软徽标的按键,在Dash中搜索“系统设置”),进入”时间&日期“选项。
|
||||
打开系统设置(按下标有微软徽标的按键,在Dash中搜索“系统设置”),进入“时间&日期”选项。
|
||||
|
||||
接下来,进入**时钟**标签页,找到**其他时区时间**选项,然后点击**选择地区**按钮。
|
||||
|
||||
@ -20,7 +20,7 @@
|
||||
|
||||
![multiple timezone displayed in Ubuntu 14.04](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/06/Multiple_Timezones_display_Ubuntu.png)
|
||||
|
||||
好好的感受Ubuntu多时区时钟给你带来的便捷吧。:)
|
||||
体验下Ubuntu多时区时钟给你带来的便捷吧。:)
|
||||
|
||||
----------
|
||||
|
||||
@ -34,7 +34,7 @@
|
||||
|
||||
via: http://itsfoss.com/add-multiple-timezones-ubuntu-1404/
|
||||
|
||||
译者:[JonathanKang](https://github.com/JonathanKang) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
译者:[JonathanKang](https://github.com/JonathanKang) 校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
@ -1,11 +1,10 @@
|
||||
如何在linux中创建sosreport(RHEL 5.X / RHEL 6.X)
|
||||
如何用sosreport在Linux上创建诊断信息
|
||||
================================================================================
|
||||
**Sosreport**是linux中的一个命令**RHEL / CentOS**),它会收集**系统配置**和你linux机器上如正在运行的内核版本、加载的模块和系统和服务配置文件之类的诊断信息。这个命令同样可以运行外部的程序来收集更多的信息,并存储这些输出到一个结论文档中。
|
||||
**Sosreport**是**RHEL / CentOS**上的一个命令,它会收集**系统配置**和你linux机器上的诊断信息,如正在运行的内核版本、加载的模块和系统和服务配置文件之类的信息。这个命令同样可以运行外部的程序来收集更多的信息,并存储这些输出到一个结论文档中。
|
||||
|
||||
Sosreport在你需要获得redhat的技术支持时需要它。Redhat的支持工程师会要求你服务器上的sosreport来用于故障排除。
|
||||
|
||||
To run sosreport , **sos** package should be installed. Sos package is part of default installation in most of linux. If for any reason this package is no installed , then use below yum command to install **sos package** :
|
||||
要运行sosreport,需要安装**sos** 包。Sos包是大多是linux的默认安装包中的一部分。如果有任何原因没有安装,那么运行下面的yum命令来安装**sos 包** :
|
||||
要运行sosreport,需要安装**sos** 包。sos包是大多是linux的默认安装包中的一部分。如果因为某种原因没有安装,那么运行下面的yum命令来安装**sos 包** :
|
||||
|
||||
# yum install sos
|
||||
|
||||
@ -15,7 +14,7 @@ To run sosreport , **sos** package should be installed. Sos package is part of d
|
||||
|
||||
# sosreport
|
||||
|
||||
这条命令正常情况下会在**几分钟**里完成。根据本地配置,在某些情况下,某些选项可能需要更长的时间才能完成。一旦完成,sosreport将在**/ tmp目录**目录中生成压缩文件。不同版本使用不同的压缩方案(** gz,bz2,或xz**)。该文件应提供给红帽的支持代表(在开放的情况下通常作为附件)。
|
||||
这条命令正常情况下会在**几分钟**里完成。根据本地配置,在某些情况下,某些选项可能需要更长的时间才能完成。一旦完成,sosreport将在**/ tmp目录**目录中生成一个压缩文件。不同版本使用不同的压缩方案(** gz,bz2,或xz**)。该文件应提供给红帽的支持代表(在开放的情况下通常作为附件)。
|
||||
|
||||
**注意**:sosreport需要root权限才能运行。
|
||||
|
||||
@ -38,6 +37,6 @@ sosreport命令有一个**模块化结构**,并允许用户启用和禁用模
|
||||
|
||||
via: http://www.linuxtechi.com/how-to-create-sosreport-in-linux/
|
||||
|
||||
译者:[geekpi](https://github.com/geekpi) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
译者:[geekpi](https://github.com/geekpi) 校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
@ -0,0 +1,34 @@
|
||||
Git 2.0.2版本控制系统现在可供下载使用了
|
||||
==================================================================================================================================================
|
||||
|
||||
![](http://i1-news.softpedia-static.com/images/news2/Git-2-0-2-Version-Control-System-Now-Available-for-Download-451147-2.jpg)
|
||||
|
||||
**Git 2.0.2如今已正式发布。这是一个免费和开源的分布式版本控制系统,因其处理速度和效率的优势,它可以处理大大小小各种项目。**
|
||||
|
||||
新的Git 2.0.x分支保持着带来大量更新的传统,它整合了大量的改变和修正。这个最新的更新只是维护版,但是它的功能特性的确有一些有趣的修改。
|
||||
|
||||
根据开发者的描述:"git submodule sync(git子模块的同步)"的文档中提到的子命令可以使用"--recursive"(递归)的选项;在.gitignore中跟踪引用反斜杠的空格的处理不当已经被纠正;对"git repack"命令的更新,将不再错误地复制那些被.keep标签标记的pack目录下的对象。
|
||||
|
||||
还有,"git clone -b brefs/tags/bar"不再认为git遵循一个单一的tag,尽管它是一个分支的名称;"%G(G后面没有跟任何东西)"是一个无效的漂亮的格式说明符,现在的解析器不再对它进行解析;用于避免增加相同替代对象的存储的代码经过了两次修正,而且其余的几个修正也已经完成。
|
||||
|
||||
想要查看完整的改变列表,查看[changelog][1]。
|
||||
|
||||
下载Git 2.0.2:
|
||||
|
||||
- [tar.gz][1][sources] [4.70 MB]
|
||||
- [Debian/Ubuntu DEB ALL][2][ubuntu_deb] [0 KB]
|
||||
- [Red Hat/Fedora/Mandriva/openSUSE RPM noarch][3][rh_rpm] [0 KB]
|
||||
|
||||
-------------------------------------------------------------------------------------
|
||||
|
||||
via: http://news.softpedia.com/news/Git-2-0-2-Version-Control-System-Now-Available-for-Download-451147.shtml
|
||||
|
||||
译者:[su-kaiyao](https://github.com/su-kaiyao) 校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
||||
[1]:https://github.com/git/git/blob/master/Documentation/RelNotes/2.0.2.txt
|
||||
[2]:https://github.com/git/git/archive/v2.0.2.tar.gz
|
||||
[3]:http://git-scm.com/download/linux
|
||||
[4]:http://git-scm.com/download/linux
|
||||
|
@ -1,7 +1,8 @@
|
||||
来自树莓派的Eben Upton:我们是怎么让大家都成为DIY黑客的。
|
||||
树莓派的联合创始人访谈——我们是怎么让大家都成为DIY黑客的
|
||||
================================================================================
|
||||
> 请记住它是为喜欢折腾的人准备的只要35美元的计算机
|
||||
|
||||
![](http://a2.files.readwrite.com/image/upload/c_fill,h_900,q_70,w_1600/MTIyMjkzMzI3NjMzNjA3OTYx.jpg)
|
||||
我永远不会忘记我第一次看到树莓派的情形。那个小巧的,信用卡大小的计算机,性能却足够强劲,可以作为一般家用PC,媒体中心,电视游戏机,或是其他任何你能够想像的东西。只有35美元的价格,它是任何年龄段的动手爱好者都可以拥有的小东西,可以在上面捣腾硬件和软件试验,而不用担心会弄坏昂贵的家庭电脑。
|
||||
|
||||
[Eben Upton][1],是树莓派基金会的共同创始人,通常被誉为这个神奇机器背后的魔法师。在剑桥大学的计算机实验室攻读哲学博士学位的时候,他费尽苦心地手工打造了树莓派的原型机。
|
||||
@ -14,17 +15,17 @@ ReadWrite网: 一开始是什么让你对技术这么感兴趣?它又是如何
|
||||
|
||||
**Eben Upton**: 在我还是孩子的时候就开始对技术感兴趣了。我有个对工程技术有很大兴趣的父亲,他自己不是工程师,而是一个英语老师。我们的房子里经常到处堆着各种电子器件,在还不知道这些东西是干嘛的时候,我就开始摆弄了。都是些小玩意,比如在床头装个灯,在“关灯”后还可以继续看书之类的。
|
||||
|
||||
![](http://readwrite.com/files/raspberry%20pi%20black-and-white%20flickr%20johan%20larsson.jpg)
|
||||
![](http://a5.files.readwrite.com/image/upload/c_fit,q_80,w_630/MTIyMzAxOTQxOTk1ODI2NDU3.jpg)
|
||||
|
||||
之后我有了一台计算机。在英国,我们把这种机器叫做[BBC微计算机][2],实际上是8位单片机,做教学用的。我们在学校的时候接触到这种机器,我之后就学会了编程,而且还蛮喜欢的。
|
||||
|
||||
这些机器在学校里并不一定是用来编程的,或者说他们根本不是用来编程的,一般都运行教学软件。但是我却给它编程,之后我还买了一台回家,在我买了这台BBC微机后,我就泡在了房间里,再没出来过。[笑]
|
||||
|
||||
编程对于小孩来说太神奇了。当你还是小孩的时候,并没有太多力量。没有听话的随从,反而身边有很多的限制。编程最伟大的地方在于,这是一个可以让你随喜所欲的小世界。而这当然让我无法抗拒。
|
||||
编程对于小孩来说太神奇了。当你还是小孩的时候,并没有太多力量。没有听话的随从,反而身边有很多的限制。编程最伟大的地方在于,这是一个可以让你随心所欲的小世界。而这当然让我无法抗拒。
|
||||
|
||||
我一直都对科学和数学,以及硬科学学科感兴趣。我在我的BBC微机上做了大量的计算和编程,之后我拥有了一台Commodore Amiga。
|
||||
我一直都对科学和数学,以及理科感兴趣。我在我的BBC微机上做了大量的计算和编程,之后我拥有了一台Commodore Amiga。
|
||||
|
||||
在大学里我学习了物理,工程和计算机科学。这是激发树莓派项目想法的原因,因为当我在学校呆了10年的时候[当时在读博士学位],我发现那些新来的孩子们在他们小时候并没有机会获得这方面的经验。你也许仍然能拥有乐高玩具,但是问题是梯子。
|
||||
在大学里我学习了物理,工程和计算机科学。这是激发树莓派项目想法的原因,因为当我在学校呆了10年的时候[当时在读博士学位],我发现那些新来的孩子们在他们小时候并没有机会获得这方面的经验。你也许仍然能拥有乐高玩具,但是它不是我们要的梯子。
|
||||
|
||||
在一定程度上我们把身后的梯子撤掉了。我们造出了这些非常复杂而且用户友好的计算机给小孩使用,或者不仅仅是计算机,还包括电视游戏机,电话和平板,以及一些家用电器。但是,人们却没有机会自己动手改一改。所以实际上,树莓派是回到最初的一种尝试,当然也不会过于原始,希望找到在过去25年里计算机发展中迷失掉的那种感觉。
|
||||
|
||||
@ -34,7 +35,7 @@ ReadWrite网: 一开始是什么让你对技术这么感兴趣?它又是如何
|
||||
|
||||
另外一件麻烦事是募集资金。我们是非营利组织,所以我们得去找人赞助,而这最后都变成了董事会中的几个人自掏腰包。我们有25万美元的启动资金是从我和其他几个成员自己借的。所以我觉得,当初这样做还挺有勇气。
|
||||
|
||||
![](http://readwrite.com/files/raspberry%20pi%20flickr%20clive%20darra.jpg)
|
||||
![](http://a4.files.readwrite.com/image/upload/c_fit,q_80,w_960/MTIyMzAxOTQzODc0ODgwMTAy.jpg)
|
||||
|
||||
### 从东方到西方 ###
|
||||
|
||||
@ -62,7 +63,7 @@ ReadWrite网: 一开始是什么让你对技术这么感兴趣?它又是如何
|
||||
|
||||
**EU:** 我们尝试过基于所谓的微控制器技术做了几台机器。不知道你有没有听过一个叫Arduino的[开源电子原型]平台?它们的性能跟Arduino是一个级别的,优点是很容易买到,是常用的元器件,非常便宜,也很容易掌握。
|
||||
|
||||
![](http://readwrite.com/files/raspberry%20pi%20pibow%20flickr%20peet%20sneekes.jpg)
|
||||
![](http://a2.files.readwrite.com/image/upload/c_fit,q_80,w_630/MTIyMzAxOTQ1NzU0MDUzOTEz.jpg)
|
||||
|
||||
所以我们试了一下。最后的成品只能从技术上来说还是计算机,你可以把它接到电视机或其他显示设备上。但是,它太原始了,很明显不能吸引孩子们的兴趣。这个是一号原型机,它在爱尔兰一家博物馆的叫“失败”的展览中展出[笑]。我下个月会去看看。它现在被装载一个玻璃盒子里,作为一次辉煌失败的典型。
|
||||
|
||||
@ -76,13 +77,13 @@ ReadWrite网: 一开始是什么让你对技术这么感兴趣?它又是如何
|
||||
|
||||
真正的突破是三号原型机。我们从Broadcom拿到了另一种应用了ARM处理器的芯片,可以直接运行标准Linux。我们意识到终于可以做出能够满足所有的需求的机器了,这就是我们推向市场的产品。
|
||||
|
||||
### 黑黑下一代黑客 ###
|
||||
### 黑一黑下一代黑客 ###
|
||||
|
||||
**RW:** 八岁的孩子就开始用树莓派做项目了。这在你意料中吗,还是说让你意外了?
|
||||
|
||||
**EU:** 八岁是很好的年纪。我想每个人都会把自己开始编程的年龄定义成合适的年龄。我就是八岁开始编程的。某种程度上来说,孩子们所需要的只是年龄大到拥有相对完整的认知技能,或者说是解决问题的技能。也许在学校学一点数学就够了。
|
||||
|
||||
![](http://readwrite.com/files/raspberry%20pi%20lego%20flickr%20luca%20sbardella.jpg)
|
||||
![](http://a2.files.readwrite.com/image/upload/c_fit,q_80,w_630/MTIyMzAxOTQ3MzY0NTQxMDMw.jpg)
|
||||
|
||||
年龄大到可以计划任务,编程就是终极的计划任务。还是得有一定的智力基础去做这个事情。八岁的时候,大多数孩子在自己的思维上已经非常成熟了。另外还需要敏捷的身手,对更小的孩子来说还存在一个问题就是,他们还不够灵巧去使用键盘。
|
||||
|
||||
@ -118,9 +119,9 @@ ReadWrite网: 一开始是什么让你对技术这么感兴趣?它又是如何
|
||||
|
||||
**RW:** 你怎么看现在出现的主流硬件黑客文化?
|
||||
|
||||
**EU:** 我觉得,这太美妙了,不是吗?这是在软件工程领域里完全无法想到的。我接触这些之前就有软件背景,所以,实际上人们用树莓派制作的多数很酷的东西都是硬件相关的,让我很惊讶。当然现在没那么吃惊了,不过一开始是有的。
|
||||
**EU:** 我觉得,这太美妙了,不是吗?这是在软件工程领域里完全无法想到的。我接触这些之前就有软件背景,所以,实际上人们用树莓派制作的大多数很酷的东西都是硬件相关的,让我很惊讶。当然现在没那么吃惊了,不过一开始是有的。
|
||||
|
||||
![](http://readwrite.com/files/raspberry%20pi%20robot%20flickr%20ashley%20basil.jpg)
|
||||
![](http://a3.files.readwrite.com/image/upload/c_fit,q_80,w_630/MTIyMzAxOTQ5NTEyMDI0Njc4.jpg)
|
||||
|
||||
我认为这是非常积极的趋势,基于所有这些因素。因为它给孩子们带来了相关的经验。在我看来,在屏幕上移动一下像素还是很酷的,不过事实上,它没有像80年代那样酷了。我觉得,在现实世界里移动一些物体,比如机器人,对于现在的孩子来说是非常酷的。
|
||||
|
||||
@ -152,11 +153,11 @@ ReadWrite网: 一开始是什么让你对技术这么感兴趣?它又是如何
|
||||
|
||||
显然,我们同时也必须做一点[硬件方面]的事情。我真的不知道具体在什么时候。如果到了2017,2018,我们还在销售树莓派B型的话,那也挺糟糕的。但是,我认为我们也许在一年后再认真考虑后面要做什么。
|
||||
|
||||
**RW:** 很多人的项目同时用到了派和Arduino,一个DIY电子调试工具套件。你在设计派的时候,有考虑类似Arduino的工具吗?
|
||||
**RW:** 很多人的项目同时用到了派和Arduino(一个DIY电子调试工具套件)。你在设计派的时候,有考虑类似Arduino的工具吗?
|
||||
|
||||
**EU:** 实际上没有,但是我们很早就意识到,媒体可能会倾向于把我们和Arduino看作竞争者。对于这件事情我们有点多疑,我觉得,因为我认为派和Arduino分别处理不同的事情,而且他们都做得很好。
|
||||
|
||||
我们并没有把它设计成配合Arduino工作,但是Arduino被设计成配合家用PC一起工作。所以,我们为Arduino制作了一台非常低功耗的家用PC。所以好吧,只是巧合,我猜。
|
||||
我们并没有把它设计成配合Arduino工作,但是Arduino被设计成配合家用PC一起工作。所以,我们实际上为Arduino制作了一台非常低功耗的家用PC。所以好吧,只是巧合,我猜。
|
||||
|
||||
**RW:** 你在家里用树莓派做什么?工作中呢?
|
||||
|
||||
@ -169,13 +170,14 @@ ReadWrite网: 一开始是什么让你对技术这么感兴趣?它又是如何
|
||||
不过,看到这么多的人喜欢它,看到它被出现在各种不同的地方,也是很开心的。我听说在《生活大爆炸》中提到了我们,我要去找找是哪一集。它出现在所有的这些不可思议的地方。真是非常开心,看到这么多人把它放在心上,开始用它做点事情。
|
||||
|
||||
承蒙树莓派基金会提供Eben Upton的图片;
|
||||
|
||||
树莓派图片来自Flickr用户:[Johan Larsson][5], [Clive Darra][6], [Pete Sneekes][7], [Luca Sbardella][8]和[Ashley Basil][9]
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: http://readwrite.com/2014/04/08/raspberry-pi-eben-upton-builders#awesm=~oBGnazhOCOfaUd
|
||||
via: http://readwrite.com/2014/04/08/raspberry-pi-eben-upton-builders
|
||||
|
||||
译者:[zpl1025](https://github.com/zpl1025) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
译者:[zpl1025](https://github.com/zpl1025) 校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
@ -1,32 +0,0 @@
|
||||
Git 2.0.2 Version Control System Now Available for Download
|
||||
================================================================================
|
||||
![](http://i1-news.softpedia-static.com/images/news2/Git-2-0-2-Version-Control-System-Now-Available-for-Download-451147-2.jpg)
|
||||
|
||||
**Git 2.0.2, a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency, has been officially released.**
|
||||
|
||||
The new Git 2.0.x branch continues the trend of large releases, integrating a big number of changes and fixes. This latest update may be just a maintenance one, but it does feature some interesting modifications.
|
||||
|
||||
According to the developers, the documentation for the "git submodule sync" mentions that the subcommand can take the "--recursive" option, the mishandling of patterns in .gitignore that had trailing SPs quoted with backslashes has been corrected, and the Recent updates to "git repack" no longer duplicate objects that are in the packfiles marked with .keep flag by mistake.
|
||||
|
||||
Also, "git clone -b brefs/tags/bar" no longer thinks that git follows a single tag, even though it was a name of the branch, "%G" (nothing after G) is an invalid pretty format specifier and now the parser knows that it's garbage, the code used to avoid adding the same alternate object store twice has been fixed, and a couple of other fixes have been implemented.
|
||||
|
||||
For a complete list of changes, check out the [changelog][1].
|
||||
|
||||
Download Git 2.0.2:
|
||||
|
||||
- [tar.gz][1][sources] [4.70 MB]
|
||||
- [Debian/Ubuntu DEB ALL][2][ubuntu_deb] [0 KB]
|
||||
- [Red Hat/Fedora/Mandriva/openSUSE RPM noarch][3][rh_rpm] [0 KB]
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: http://news.softpedia.com/news/Git-2-0-2-Version-Control-System-Now-Available-for-Download-451147.shtml
|
||||
|
||||
译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
||||
[1]:https://github.com/git/git/blob/master/Documentation/RelNotes/2.0.2.txt
|
||||
[2]:https://github.com/git/git/archive/v2.0.2.tar.gz
|
||||
[3]:http://git-scm.com/download/linux
|
||||
[4]:http://git-scm.com/download/linux
|
@ -1,59 +0,0 @@
|
||||
Love-xuan 翻译中
|
||||
How to Install Lightweight Budgie Desktop in Ubuntu 14.04
|
||||
================================================================================
|
||||
**If you follow us over on Twitter you may have caught a glimpse of a screenshot we shared recently, along with the invitation to name the desktop environment pictured. **
|
||||
|
||||
Did you guess correctly? The answer is [Budgie][1] — a simple desktop designed for, but not exclusive to, an openSUSE-based Linux distribution called Evolve OS.
|
||||
|
||||
![](http://www.omgubuntu.co.uk/wp-content/uploads/2014/07/BsCvTxJIcAAPjUR.png-large.png)
|
||||
|
||||
We first wrote about Budgie back in March and were suitably bowled over by both the clean, minimal aesthetic and nimble framework, but also by the decision to reuse common components and the standard stack of GNOME 3.10 technologies readily available in most modern distributions.
|
||||
|
||||
I’m a huge admirer of the development choices taken by the project lead, Ikey Doherty. There’s no denying that forking has its merits, but by deciding to favour upstream projects whole project is able to move faster, both development-wise (less technical debt) and in being available for users (easier to run on other distributions).
|
||||
|
||||
Politics of choice aside, the desktop is clean and minimal with a nod to the Ash desktop of Google’s Chrome OS. If you don’t mind a few rough edges, its well worth a play with. But how do you install Budgie on Ubuntu?
|
||||
|
||||
### Unofficial PPA is Unofficial ###
|
||||
|
||||
Open source being what it is means if you have a bit of terminal know-how you can grab the source and get it up and running with a bit of wily compiling.
|
||||
|
||||
But if you’re too lazy for that and happen to be running Ubuntu 14.04 LTS (or a distro based on it) you can get it the easy way.
|
||||
|
||||
Just add one **unofficial PPA**, refresh your Software Sources and then install. A few minutes later and you’ll have both a new uncle in the family by the [name of Bob][2] and a new desktop shell to play with.
|
||||
|
||||
### Add the Budgie PPA ###
|
||||
|
||||
With a terminal window open copy and paste the following commands carefully, entering your password when/if prompted:
|
||||
|
||||
sudo add-apt-repository ppa:sukso96100/budgie-desktop
|
||||
sudo apt-get update && sudo apt-get install budgie-desktop
|
||||
|
||||
### Log into the Budgie Session ###
|
||||
|
||||
After installation you’ll be able to select ‘Budgie’ from the session selector of the Unity Greeter. (Don’t forget to change this back to a stable DE at a later date.)
|
||||
|
||||
### Notes ###
|
||||
|
||||
**Budgie is not stable, finished nor is it officially supported on Ubuntu**. It is in active development and features remain missing, including, but not limited to: no network management support, no volume control applet (keyboard keys will work fine), no notification system and no way to ‘pin’ apps to the task bar.
|
||||
|
||||
It also doesn’t play too nicely with Ubuntu’s overlay scrollbars, some GTK themes, and session management (e.g., logout, restart, etc.) on distributions using Upstart (like Ubuntu, [though that’s changing][3]) does not work.
|
||||
|
||||
As a workaround you can disable overlay scrollbars, set a different default theme and quit a session from the terminal using the following command:
|
||||
|
||||
gnome-session-quit
|
||||
|
||||
With all of those caveats in mind, I’d suggest those whose sanity hinges on a stable, dependable system avoid using it for now.
|
||||
|
||||
But for the rest of you crazy folks? Well, let us know what you think of it in the comments below. I’m off to let Bob in.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: http://www.omgubuntu.co.uk/2014/07/install-budgie-evolve-os-desktop-ubuntu-14-04
|
||||
|
||||
译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
||||
[1]:http://www.omgubuntu.co.uk/2014/03/budgie-desktop-chrome-os-like
|
||||
[2]:http://en.wikipedia.org/wiki/Bob
|
||||
[3]:http://www.omgubuntu.co.uk/2014/02/ubuntu-debian-switching-systemd
|
@ -1,104 +0,0 @@
|
||||
How to simulate key press and mouse movement in Linux
|
||||
================================================================================
|
||||
Have you ever dreamed of your computer doing stuff automatically for you? Probably not if you just watched Terminator. But except for that, scripting and task automation are every power user's dreams. If a lot of solutions exist today to fit such goal, it is sometimes hard to pick the simple, smart, and efficient one out of the lot. I cannot pretend to have found it myself, but in the mean time, my preference goes to neat software called xdotool. Its approach is intuitive as it stands as an X11 automation tool. In other words, xdotool can simulate key presses and even mouse events from reading a text file.
|
||||
|
||||
### Installation of Xdotool on Linux ###
|
||||
|
||||
For Ubuntu, Debian or Linux Mint, you can just do:
|
||||
|
||||
$ sudo apt-get install xdotool
|
||||
|
||||
For Fedora, use yum command:
|
||||
|
||||
$ sudo yum install xdotool
|
||||
|
||||
For CentOS user, the package is available in [EPEL repo][1]. After enabling EPEL repo, simply use yum command as above.
|
||||
|
||||
For Arch user, the package is available in the Community repo:
|
||||
|
||||
$ sudo pacman -S xdotool
|
||||
|
||||
If you cannot find xdotool for your distribution, you can always download it from the [official website][2].
|
||||
|
||||
### Basic Usage of Xdotool ###
|
||||
|
||||
As intuitive as it is, xdotool remains a scripting application. Hence you have to know the syntax in order to use it properly. Rest assured though, the syntax is very simple and quick to pick up, relative to the extent of the program's features.
|
||||
|
||||
First, it is very easy to simulate key press. From the terminal, you can type the command:
|
||||
|
||||
$ xdotool key [name of the key]
|
||||
|
||||
If you want to chain two keys, use the "+" operator between them. So:
|
||||
|
||||
$ xdotool key alt+Tab
|
||||
|
||||
will switch window for you.
|
||||
|
||||
To have xdotool type for you, use the type command:
|
||||
|
||||
$ xdotool type ''
|
||||
|
||||
That's already enough for basic key pressing. But one of the many strengths of xdotool is its ability to put the focus on a particular window. It can fetch the right window, and then type in it, preventing all your recorded keystrokes to just vaporize in thin air. For this, the simplest command is:
|
||||
|
||||
$ xdotool search --name [name of the window] key [keys to press]
|
||||
|
||||
This will search through the opened window for one with the name matching the search, give it the focus, and then simulate the key pressing.
|
||||
|
||||
A bit more advanced, but very useful, xdotool can simulate mouse movement and click. With:
|
||||
|
||||
$ xdotool mousemove x y
|
||||
|
||||
you can place the cursor at coordinates (x,y) of your screen (in pixels). You can also combine it with the "click" argument:
|
||||
|
||||
$ xdotool mousemove x y click 1
|
||||
|
||||
This will move the mouse to (x,y), and click with the left button. The "1" represents the left button of the mouse, "2" would be the scroll wheel, "3" the right button, etc.
|
||||
|
||||
Finally, once you have your commands in mind, you might want to actually dump it in a file to edit and play. For that, there is more than one syntax. You can write is a bash script:
|
||||
|
||||
#!/bin/bash
|
||||
|
||||
xdotool [command 1]
|
||||
xdotool [command 2]
|
||||
etc
|
||||
|
||||
Or you can use:
|
||||
|
||||
$ xdotool [filename]
|
||||
|
||||
where you write your commands in a separate file and plug its name as the argument.
|
||||
|
||||
### Bonus ###
|
||||
|
||||
As a bonus to this post, here is a concrete example of xdotool in action. You may or may not have heard of Bing, the Microsoft's search engine. In the latter case, you have then never heard of Bing Rewards: a program that allows you to trade Bing points for Amazon's and other gift cards. To earn those points, you can do up to 30 searches a day on Bing, each search giving you 0.5 point. In other words, you have to make Bing your default search engine, and use it every day.
|
||||
|
||||
Or, you can use this xdotool script, which will automatically give focus to Firefox (replace it with your favorite navigator), and perform a search using the fortune command to generate some random words. In about 30 seconds, all your daily searches will be done.
|
||||
|
||||
#!/bin/bash
|
||||
|
||||
for i in {1..30}
|
||||
do
|
||||
WID=`xdotool search --title "Mozilla Firefox" | head -1`
|
||||
xdotool windowfocus $WID
|
||||
xdotool key ctrl+l
|
||||
xdotool key Tab
|
||||
SENTENCE="$(fortune | cut -d' ' -f1-3 | head -1)"
|
||||
xdotool type $SENTENCE
|
||||
xdotool key "Return"
|
||||
sleep 4
|
||||
done
|
||||
|
||||
To conclude, I really like xdotool even if its full capabilities extend way beyond the scope of this post. It is a really approachable way to scripting and task automation. The downside is that it probably is not the most efficient one. But again, it does the job, and isn't too much of a bother to learn.
|
||||
|
||||
What are your thoughts on xdotool? Do you prefer another automation tool to it? And why? Let us know in the comments.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: http://xmodulo.com/2014/07/simulate-key-press-mouse-movement-linux.html
|
||||
|
||||
译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
||||
[1]:http://xmodulo.com/2013/03/how-to-set-up-epel-repository-on-centos.html
|
||||
[2]:http://www.semicomplete.com/projects/xdotool/
|
@ -1,61 +0,0 @@
|
||||
Fix No Sound In Ubuntu 14.04 As HDMI Enabled BY Default
|
||||
================================================================================
|
||||
Sound problem is not new in Ubuntu. I have previously written on various ways to [fix “no sound” issue in Ubuntu][1]. But the soud issue I am going to discuss here is different than those mentioned in the other article.
|
||||
|
||||
So I installed Ubuntu 14.04, actually re-installed it. As always, I did all those [things to do after a fresh install of Ubuntu 14.04][2]. And than I realized that the system had no sound. While investigating the issue I found one strange thing. I checked [alsamixer][3] and it was in a weird state:
|
||||
|
||||
![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/06/alsamixer_Set_HDMI_Default.jpeg)
|
||||
|
||||
As you can see, **HDMI is set by default in alsamixer**. Which means by default HDMI output has been selected instead of the built in speakers. This is why I get no sound from the built in speakers in my system.
|
||||
|
||||
Use the following command to check the state of alsamixer:
|
||||
|
||||
alsamixer
|
||||
|
||||
If alsamixer is set by default to HDMI or some other audio output, continue this article to see how can we fix it.
|
||||
|
||||
### Fixing no sound in Ubuntu when HDMI is set as default ###
|
||||
|
||||
Now to force Ubuntu to use analog output instead of HDMI by default, we need a little information. Open a terminal and use the following command:
|
||||
|
||||
aplay -l
|
||||
|
||||
This will list the devices, card number etc. Note down the card and device number for analog output. For me the output was like this:
|
||||
|
||||
![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/07/AlsaMixer_List_Device.jpeg)
|
||||
|
||||
Once you have the required card and device number, make a new configuration file like this:
|
||||
|
||||
sudo gedit /etc/asound.conf
|
||||
|
||||
The above command will also open the file. Add the following lines to it, replacing with your card and device number of course:
|
||||
|
||||
defaults.pcm.card 1
|
||||
defaults.pcm.device 0
|
||||
|
||||
Save the file and restart the computer. You should hear the sound now. Just to mention, this will work for all the Linux distributions such as Linux Mint, Elementary OS, Fedora, Arch Linux etc. As I said previously, this “no sound fix” only works with the case where HDMI is set by default. For other cases, you can read [this article about fixing no sound issue in Ubuntu and Linux Mint][4].
|
||||
|
||||
Feel free to use the comment section to let me know if it worked or not or if you have some better trick to handle this such issue. Ciao ![](http://itsfoss.itsfoss.netdna-cdn.com/wp-includes/images/smilies/icon_smile.gif)
|
||||
|
||||
----------
|
||||
|
||||
![](http://1.gravatar.com/avatar/20749c268f5d3e4d2c785499eb6a17c0?s=100&r=pg&d=mm)
|
||||
|
||||
About Abhishek
|
||||
|
||||
I am Abhishek Prakash, 'creator' of It's F.O.S.S. I have a Masters in Communication System Engineering. I am an avid Linux lover and Open Source enthusiast. I use Ubuntu and believe in sharing knowledge. Apart from Linux, I love classic detective mystery. Huge fan of Agatha Christie work. Feel free to circle me on [Google Plus][g] and Follow [@abhishek_pc][t]
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: http://itsfoss.com/fix-sound-ubuntu-1404/
|
||||
|
||||
译者:[译者ID](https://github.com/译者ID) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
||||
[1]:http://itsfoss.com/fix-sound-ubuntu-1304-quick-tip/
|
||||
[2]:http://itsfoss.com/things-to-do-after-installing-ubuntu-14-04/
|
||||
[3]:http://en.wikipedia.org/wiki/Alsamixer
|
||||
[4]:http://itsfoss.com/fix-sound-ubuntu-1304-quick-tip/
|
||||
[g]:https://plus.google.com/u/0/110180944531110746460
|
||||
[t]:https://twitter.com/abhishek_pc
|
@ -1,3 +1,5 @@
|
||||
Translating by cvsher
|
||||
|
||||
7 ‘dmesg’ Commands for Troubleshooting and Collecting Information of Linux Systems
|
||||
================================================================================
|
||||
The ‘dmesg‘ command displays the messages from the kernel ring buffer. A system passes multiple runlevel from where we can get lot of information like system architecture, cpu, attached device, RAM etc. When computer boots up, a kernel (core of an operating system) is loaded into memory. During that period number of messages are being displayed where we can see hardware devices detected by kernel.
|
||||
@ -194,4 +196,4 @@ via: http://www.tecmint.com/dmesg-commands/
|
||||
[1]:http://www.tecmint.com/12-practical-examples-of-linux-grep-command/
|
||||
[t]:http://twitter.com/@nrdshrestha
|
||||
[f]:http://facebook.com/narad.shrestha.9
|
||||
[g]:http://plus.google.com/104542109955805873615?rel=author
|
||||
[g]:http://plus.google.com/104542109955805873615?rel=author
|
||||
|
@ -1,3 +1,6 @@
|
||||
Translating-----geekpi
|
||||
|
||||
|
||||
How to analyze Squid logs with SARG log analyzer on CentOS
|
||||
================================================================================
|
||||
In a [previous tutorial][1], we show how to configure a transparent proxy with Squid on CentOS. Squid provides many useful features, but analyzing a raw Squid log file is not straightfoward. For example, how could you analyze the time stamps and the number of hits in the following Squid log?
|
||||
@ -114,4 +117,4 @@ via: http://xmodulo.com/2014/07/analyze-squid-logs-sarg-log-analyzer-centos.html
|
||||
[1]:http://xmodulo.com/2014/06/squid-transparent-web-proxy-centos-rhel.html
|
||||
[w]:http://amar-linux.blogspot.com/
|
||||
[t]:http://twitter.com/SarmedRahman
|
||||
[l]:http://www.linkedin.com/in/sarmedrahman
|
||||
[l]:http://www.linkedin.com/in/sarmedrahman
|
||||
|
@ -1,3 +1,4 @@
|
||||
[let bazz2 try it]
|
||||
Linux Kernel Testing and Debugging
|
||||
================================================================================
|
||||
### Linux Kernel Testing Philosophy ###
|
||||
@ -73,4 +74,4 @@ via: http://www.linuxjournal.com/content/linux-kernel-testing-and-debugging?page
|
||||
[1]:http://events.linuxfoundation.org/images/stories/pdf/als2012_gregkh.pdf
|
||||
[2]:http://howtoubuntu.org/
|
||||
[3]:http://linuxdriverproject.org/mediawiki/index.php/Cross-compiling_Linux_kernel_on_x86_64
|
||||
[4]:https://www.kernel.org/
|
||||
[4]:https://www.kernel.org/
|
||||
|
@ -0,0 +1,131 @@
|
||||
在Linux中模拟击键和鼠标移动
|
||||
================================================================================
|
||||
你是否曾经拥有一个梦
|
||||
——你的计算机
|
||||
可以自动为你干活?
|
||||
或许,并非因为
|
||||
你刚看了终结者。
|
||||
然而,除此之外
|
||||
脚本和任务自动化
|
||||
是每个高级用户追寻的梦
|
||||
如果今天
|
||||
有许多的解决方案
|
||||
可以满足这个目标
|
||||
那么
|
||||
有时候
|
||||
就难以从那众多之中采撷那
|
||||
简洁、聪明而又高效的一个
|
||||
我
|
||||
不能假装
|
||||
是我自己发现了它
|
||||
而与此同时
|
||||
却偏爱着那个
|
||||
整洁的软体——xdotool
|
||||
其方法是如此直观
|
||||
正如它作为X11自动化工具的表露
|
||||
转换思想
|
||||
xdotool可以通过读取文本文件
|
||||
模拟击键的旋律
|
||||
以及鼠标的曼舞
|
||||
|
||||
|
||||
### 让Xdotool在Linux定居 ###
|
||||
对于Ubuntu,Debian或者Linux Mint,你能够只做:
|
||||
|
||||
$ sudo apt-get install xdotool
|
||||
|
||||
对于Fedora,请使用yum命令:
|
||||
|
||||
$ sudo yum install xdotool
|
||||
|
||||
对于CentOS用户,可以在[EPEL repo][1]中找到该包。在启用EPEL仓库后,只要使用上面的yum命令就可以达成你的愿望。
|
||||
|
||||
对于Arch用户,可在Community仓库中找到该包:
|
||||
|
||||
$ sudo pacman -S xdotool
|
||||
|
||||
如果你还是找不到你的发行版的对应xdotool,你可以从它的[官方站点][2]下载。
|
||||
|
||||
### Xdotool基本功 ###
|
||||
|
||||
虽然xdotool是那样的直观,但它仍然是个脚本程序。因此,为了要正确地使用它,你还是得了解它的语法。不过敬请放心,相对于程序的功能而言,语法还是比较简单易学的。
|
||||
|
||||
首先,模拟击键是很容易的。你可以从终端敲入下面的命令:
|
||||
|
||||
$ xdotool key [name of the key]
|
||||
|
||||
如果你想要连接两个键,可以在它们之间使用“+”操作符。它看起来像这样:
|
||||
|
||||
$ xdotool key alt+Tab
|
||||
|
||||
这两个组合键可以为你切换窗口。
|
||||
|
||||
要想让xdotool帮你输入,可以使用以下命令:
|
||||
|
||||
$ xdotool type ''
|
||||
|
||||
这些对于基本的击键而言已经足够了。但是,xdotool的众多长处之一,就是它可以获取特定窗口的焦点。它可以获取右边的窗口,然后在里面输入,同时阻止所有你记录的按键,让那些动作随风而逝吧。要获得该功能,一个简单的命令可以搞定:
|
||||
|
||||
$ xdotool search --name [name of the window] key [keys to press]
|
||||
|
||||
该命令将在打开的窗口中搜索对应名称的窗口,并聚焦于该窗口,然后模拟击键。
|
||||
|
||||
来点更高级的,但很有用哦,xdotool可以模拟鼠标移动和点击,看这命令:
|
||||
|
||||
$ xdotool mousemove x y
|
||||
|
||||
你可以将光标定位到屏幕坐标(x,y)(像素)。你也可以使用“click”参数来组合:
|
||||
|
||||
$ xdotool mousemove x y click 1
|
||||
|
||||
这会让鼠标移动到(x,y),然后点击鼠标左键。“1”代表鼠标左键,“2”则是滚轮,“3”则是右键。
|
||||
|
||||
最后,一旦你这些命令根植于你脑海,你也许想要实际转储于文件来编辑并试着玩玩。鉴于此,就会有超过一个语句以上的内容了。你可以写的就是一个bash脚本了:
|
||||
|
||||
#!/bin/bash
|
||||
|
||||
xdotool [command 1]
|
||||
xdotool [command 2]
|
||||
etc
|
||||
|
||||
或者你可以使用:
|
||||
|
||||
$ xdotool [filename]
|
||||
|
||||
这里你将命令写入到一个独立的文件中,然后通过将文件名作为xdotool命令的参数。
|
||||
|
||||
### 意外收获 ###
|
||||
|
||||
作为本文的一个意外收获,这里是xdotool的一个具体实例。你可能听说过,也可能没听说过Bing,微软的搜索引擎。在后面的实例中,你从没听过Bing奖励吧:一个程序,可以让你用Bing积分兑取亚马逊的礼物卡和其它的一些礼物卡。要赚取这些积分,你可以每天在Bing上搜索累计达30次,每次搜索你都会获得0.5个积分。换句话说,你必须把Bing设为默认搜索引擎,并每天使用它。
|
||||
|
||||
或者,你可以使用xdotool脚本,在这个脚本中,会自动聚焦到Firefox(你可以用你喜欢的浏览器来取代它),并使用fortune命令生成一些随机单词来实施搜索。大约30秒之内,你的日常搜索任务就完成了。
|
||||
|
||||
#!/bin/bash
|
||||
|
||||
for i in {1..30}
|
||||
do
|
||||
WID=`xdotool search --title "Mozilla Firefox" | head -1`
|
||||
xdotool windowfocus $WID
|
||||
xdotool key ctrl+l
|
||||
xdotool key Tab
|
||||
SENTENCE="$(fortune | cut -d' ' -f1-3 | head -1)"
|
||||
xdotool type $SENTENCE
|
||||
xdotool key "Return"
|
||||
sleep 4
|
||||
done
|
||||
|
||||
|
||||
下面来个小结吧:我真的很喜欢xdotool,即便它完整功能超越了本文涵盖的范围。这对于脚本和任务自动化而言,确实是种平易的方式。负面的问题是,它可能不是最有效率的一个。但我要再说一遍,它忠于职守了,而且学习起来也不是那么麻烦。
|
||||
|
||||
你对xdotool怎么看呢?你是否更喜欢另外一个自动化工具,而不是它呢?为什么呢?请在评论中告诉我们吧。
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: http://xmodulo.com/2014/07/simulate-key-press-mouse-movement-linux.html
|
||||
|
||||
译者:[GOLinux](https://github.com/GOLinux) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
||||
[1]:http://xmodulo.com/2013/03/how-to-set-up-epel-repository-on-centos.html
|
||||
[2]:http://www.semicomplete.com/projects/xdotool/
|
@ -0,0 +1,63 @@
|
||||
Ubuntu 14.04中修复默认启用HDMI后没有声音问题
|
||||
================================================================================
|
||||
声音问题在Ubuntu中是老生常谈了。先前我已经在[修复Ubuntu中的“无声”问题][1]一文中写到了多种方法,但是我在此正要谈及的声音问题跟在另外一篇文章中提到的不同。
|
||||
|
||||
因此,我安装了Ubuntu 14.04,实际上是重新安装了一遍。一如既往,我将[全新安装Ubuntu 14.04后要做的事][2]全部又重新做了一遍。然后,我意识到系统突然失声了。当我正侦查问题所在之时,我发现了一件奇怪的事情。我检查了[alsamixer][3],发现它的状况有点离奇:
|
||||
|
||||
![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/06/alsamixer_Set_HDMI_Default.jpeg)
|
||||
|
||||
正如你能看到的,**alsamixer中默认设置了HDMI**。这意味着默认情况下将使用HDMI输出,而不是内建扬声器。这就是我从系统上内建扬声器无法获得声音的原因。
|
||||
|
||||
使用下面的命令来检查alsamixer的状态:
|
||||
|
||||
alsamixer
|
||||
|
||||
如果alsamixer默认设置成了HDMI或者其它声音输出,那就继续读下去吧,看看我们是怎么来修复这个问题的。
|
||||
|
||||
### 修复默认设置成HDMI时Ubuntu的失声问题 ###
|
||||
|
||||
现在来强制Ubuntu使用模拟输出来取代默认的HDMI,但我们还需要一点点信息。打开终端,然后使用下列命令:
|
||||
|
||||
aplay -l
|
||||
|
||||
这会列出设备,卡号之类的东西。注意,向下检查模拟输出使用的卡和设备编号。对于我而言,输出看上去像这样:
|
||||
|
||||
![](http://itsfoss.itsfoss.netdna-cdn.com/wp-content/uploads/2014/07/AlsaMixer_List_Device.jpeg)
|
||||
|
||||
一旦你取得了所需的卡和设备编号,重新构建一个配置文件:
|
||||
|
||||
sudo gedit /etc/asound.conf
|
||||
|
||||
上面的命令也会打开文件,将下面的行添加进去,当然将卡和设备编号替换成你自己的:
|
||||
|
||||
defaults.pcm.card 1
|
||||
defaults.pcm.device 0
|
||||
|
||||
保存文件,并重启计算机。现在,你应该听到了声音了吧。需要提一下的是,这对所有的Linux发行版都有效,像Linux Mint,Elementary OS,Fedora,Arch Linux等等都行。正如我先前说的,该“失声疗法”仅针对HDMI被设置为默认设备的情况。对于其它情况,你可以阅读[关于在Ubuntu和Linux Mint中修复失声问题这篇文章][4]。
|
||||
|
||||
你可以尽情使用评论部分来告诉我这个方法是否有疗效,或者你有更好的方法来处理该问题,你也可以告诉我。再见了!
|
||||
|
||||
![](http://itsfoss.itsfoss.netdna-cdn.com/wp-includes/images/smilies/icon_smile.gif)
|
||||
|
||||
----------
|
||||
|
||||
![](http://1.gravatar.com/avatar/20749c268f5d3e4d2c785499eb6a17c0?s=100&r=pg&d=mm)
|
||||
|
||||
关于Abhishek
|
||||
|
||||
我是Abhishek Prakash,It's F.O.S.S.的“创立者”,我有一个通信系统工程的硕士学位。我酷爱Linux和开源。我使用Ubuntu,信奉知识分享。除了Linux之外,我也喜爱经典的侦探推理小说,是Agatha Christie作品的超级粉丝。大家尽可以在[Google+][g]上将我圈进去,并追随[@abhishek_pc][t]
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: http://itsfoss.com/fix-sound-ubuntu-1404/
|
||||
|
||||
译者:[GOLinux](https://github.com/GOLinux) 校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创翻译,[Linux中国](http://linux.cn/) 荣誉推出
|
||||
|
||||
[1]:http://itsfoss.com/fix-sound-ubuntu-1304-quick-tip/
|
||||
[2]:http://itsfoss.com/things-to-do-after-installing-ubuntu-14-04/
|
||||
[3]:http://en.wikipedia.org/wiki/Alsamixer
|
||||
[4]:http://itsfoss.com/fix-sound-ubuntu-1304-quick-tip/
|
||||
[g]:https://plus.google.com/u/0/110180944531110746460
|
||||
[t]:https://twitter.com/abhishek_pc
|
Loading…
Reference in New Issue
Block a user