Merge remote-tracking branch 'LCTT/master'

This commit is contained in:
Xingyu Wang 2020-08-10 22:35:17 +08:00
commit 8b7ff52c01
7 changed files with 294 additions and 359 deletions

View File

@ -1,8 +1,8 @@
[#]: collector: (lujun9972)
[#]: translator: (silentdawn-zz)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: reviewer: (wxy)
[#]: publisher: (wxy)
[#]: url: (https://linux.cn/article-12502-1.html)
[#]: subject: (Tiny Yet Useful: 13 Raspberry Pi Zero Alternatives That Cost Less Than $20)
[#]: via: (https://itsfoss.com/raspberry-pi-zero-alternatives/)
[#]: author: (Chinmay https://itsfoss.com/author/chinmay/)
@ -10,92 +10,82 @@
个头小本事大13 种 20 美元以下的树莓派 Zero 替代品
======
最近两年,[树莓派 Zero][1] 和 [树莓派 Zero W][2] 作为新成员出现在树莓派产品线中。从制造者和 DIY 社区的角度,这些超小型的单板计算机带来了巨大震撼,而且作为 [树莓派计划][3] 的一部分将持续相当一段时间
最近两年,[树莓派 Zero][1] 和 [树莓派 Zero W][2] 作为新成员出现在树莓派产品线中。这些超小型的单板计算机大受欢迎,而且会在相当长的一段时间内成为创客和 DIY 社区的 [树莓派项目][3] 的一部分
为了实现更小尺寸和有效控制价位,他们不得不在许多特性上做出让步,如放弃专用网口、采用更慢的处理器等(与其对应的全功能版相比)。
为了实现更小尺寸和有效地控制价位,它们不得不在许多特性上做出让步,如放弃专用网口、采用更慢的处理器等(与其它们同族的全功能版相比)。
早先的一篇文章中,我们罗列了 [树莓派的最佳替代品][4]。这里,我将给出树莓派 Zero 和树莓派 Zero W 的一些替代选项。
预览 | 产品 | 价格 |
---|---|---|---
![CanaKit Raspberry Pi Zero W \(Wireless\) Complete Starter Kit - 16 GB Edition][5] ![CanaKit Raspberry Pi Zero W \(Wireless\) Complete Starter Kit - 16 GB Edition][5] | [CanaKit Raspberry Pi Zero W (Wireless) Complete Starter Kit - 16 GB Edition][6] | $34.99[][7] | [Buy on Amazon][8]
早先的一篇文章中,我们罗列了 [树莓派的最佳替代品][4]。这里,我将给出树莓派 Zero 和树莓派 Zero W 的一些替代品。
### 树莓派 Zero 替代品:应用于物联网和嵌入式项目的超小单板计算机
![][9]
受益于开源设计和开源软件栈,在满足各式项目需求的过程中,我们都有大量的各样特性的现成产品可用。所有这些板子运行的都是嵌入式 Linux 的各种变体。
受益于开源设计和开源软件栈,我们有为不同项目提供的具有各种功能集的优秀替代品。所有这些板子运行的都是嵌入式 Linux 的各种变体。
尽管树莓派 Zero 和树莓派 Zero W 发布价格分别是 5 美元和 10 美元,但即使是在美国境内,也很难以发布价买到成品。在美国之外,更是要花 12 和 20 美元才有可能买到。
尽管树莓派 Zero 和树莓派 Zero W 发布价格分别是 5 美元和 10 美元,但即使是在美国境内,也很难按这个价格买到。在美国之外,更是要花 12 和 20 美元才有可能买到。
先记着这些,然后看看一些 20 美元以下的树莓派 Zero 替代品。
知道了这些,让我们看看一些 20 美元以下的树莓派 Zero 替代品。
#### 1\. 香蕉派 BPI M2 Zero
#### 1香蕉派 BPI M2 Zero
![][10]
香蕉派 M2 Zero 售价 **$18**,与树莓派 Zero W 拥有相同的布局。它看起来像是树莓派 Zero W 的复制品,但也仅仅是外形像而已。它使用的是更快的全志 H2+ SOC 处理器,而且可以外挂网络模块。它还可以运行多种基于 Linux 的操作系统。
香蕉派 M2 Zero 售价 **18 美元**,与树莓派 Zero W 拥有相同的布局。它看起来像是树莓派 Zero W 的复制品,但也仅仅是外形像而已。它使用的是更快的全志 H2+ SOC 芯片,而且可以外接网络模块。它还可以运行多种基于 Linux 的操作系统。
**主要参数**
* 全志 H2+ 四核 Cortex-A7 处理器,具有 H265/HEVC 1080P 能力的 Mali400MP2 GPU
* 全志 H2+ 四核 Cortex-A7 处理器,Mali400MP2 GPUH265/HEVC 1080P
* 512M DDR3 内存(与 GPU 共享)
* 40 针接口,与树莓派 3 兼容
* 板载 WiFi (AP6212) 、蓝牙和外部天线连接口
* CSI 摄像头接口
* 板载 WiFiAP6212、蓝牙外部天线连接口
* CSI 摄像头输入接口
* 电源及复位按钮
* Mini HDMI 视频输出
详情可参阅 [Banana Pi Wiki][11]。
详情可参阅 [Banana Pi Wiki][11],可从 [此处][12] 购买。
#### 2\. 香蕉派 BPI-M2 Magic (BPi-M2M)
#### 2、香蕉派 BPI-M2 MagicBPi-M2M
![][13]
这个型号有 2 个变体,无板载 eMMC 闪存的标价 **20美元**。这是相对其尺寸而言拥有更大处理能力的小型单板计算机。我觉得这毫无疑问是制作物联网和自动家居中作为触控面板和显示面板的很好的选择。其板载电源管理系统也很有吸引力。
这个型号有 2 个变体,无板载 eMMC 闪存的标价 **20 美元**。这是相对其尺寸而言拥有更大处理能力的小型单板计算机。我觉得毫无疑问它很适合作为物联网和自动家居中的触控面板和显示面板。其板载电源管理系统也很有吸引力。
**主要参数**
* 全志 A33/R16 四核 ARM Cortex-A7 处理器MALI 400 MP2 GPU
* 板载 802.11 b/g/n 2.4GHz (AP6212) WiFi蓝牙4.0 with BLE
* 512MB DDR3 (shared with GPU)
* MIPI 串行显示接口 (DSI) (4 数据通道)
* 板载 802.11 b/g/n 2.4GHz WiFiAP6212蓝牙 4.0,支持 BLE
* 512MB DDR3(与 GPU 共享)
* MIPI 串行显示接口DSI4 数据通道
* CSI 摄像头输入接口,最大分辨率 1080p 时可达 30 帧/秒
* 板载麦克和电池管理
* 板载话筒和电池管理
* 无 HDMI 输出
详情可参阅 [Banana Pi Wiki][14]。
详情可参阅 [Banana Pi Wiki][14],可从 [此处][15] 购买。
#### 3\. 香蕉派 BPI-P2 Maker
#### 3、香蕉派 BPI-P2 Maker
![][16]
此板售价 **13 美元**(带有 POE 模块的版本售价 **19 美元**是带有板载网络模块及支持网口供电POE的最小的单板计算机之一。和香蕉派 M2 Zero 一样,使用的是全志 H2+ SOC 处理器,是块非常有趣的板子。它具有板载 8 GB eMMC 存储空间及摄像头接口,同时具有 POE 功能,可用于 DIY 监控摄像,也可以作为基本的机器学习处理器使用。
它是带有板载网络模块及支持网口供电POE的最小的单板计算机之一此板售价 **13 美元**(带有 POE 模块的版本售价 **19 美元**)。和香蕉派 M2 Zero 一样,使用的是全志 H2+ SOC 芯片,是块非常有趣的板子。它具有板载 8 GB eMMC 存储空间及摄像头接口,同时具有 POE 功能,可用于 DIY 监控摄像,也可以作为基本的机器学习处理器使用。
**主要参数**
* 处理器:全志 H2+四核Cortex-A7 架构
* 512MB DDR 3 同步动态随机存取内存
* 板载 WiFi (AP6212) 和蓝牙
* 板载 WiFiAP6212和蓝牙
* 板载 8G eMMC 闪存
* 100M 网络
* Mini HDMI
* CSI 摄像头接口
* 具有 POE 模块,支持 IEEE 802.3af PoE 标准
详情可参阅 [Banana Pi Wiki][17]。
详情可参阅 [Banana Pi Wiki][17],可从 [此处][18] 购买。
#### 4\. 桔子派 Zero LTS
#### 4、桔子派 Zero LTS
![][19]
当前支持板载网络及 POE 的最小且最便宜的单板计算机,售价仅为 **11.49 美元** 256 MB 内存版本 售价 **9.49 美元**)。其采用非常常见的全志 H2+ 处理器,具有可通过通用输入输出端设定的硬扩展选项,还有一个 13 脚的外接功能端口
当前支持板载网络及 POE 的最小且最便宜的单板计算机,售价仅为 **11.49 美元**256 MB 内存版本售价 **9.49 美元**)。其采用非常常见的全志 H2+ 处理器,并通过 GPIO 和 13 针功能头提供可靠的扩展方式
**主要参数**
@ -104,22 +94,16 @@
* 256MB/512MB DDR3 SDRAM与 GPU 共用256 MB 版为标准版)
* 10/100M 自适应网络RJ45 网口POE 功能默认关闭
* WiFi 使用 XR819 方案,支持 IEEE 802.11 b/g/n
* 26 GPIO 连接头
* 13 脚硬扩展功能连接头,包含 2 路 USB、红外线接口和声音端口MIC、AV
* 26 GPIO 连接头
* 13 连接头,包含 2 路 USB、红外线接口和声音端口MIC、AV
详情可参阅 [官方网站][20]。
详情可参阅 [官方网站][20],可从亚马逊购买。
预览 | 产品 | 价格 |
---|---|---|---
![Orange Pi Zero Single Board Computer Quad Core Open-Source Development Board 512MB with WiFi Antenna][21] ![Orange Pi Zero Single Board Computer Quad Core Open-Source Development Board 512MB with WiFi Antenna][21] | [Orange Pi Zero Single Board Computer Quad Core Open-Source Development Board 512MB with WiFi Antenna][22] | $11.99 | [Buy on Amazon][23]
#### 5\. 桔子派 i96
#### 5、桔子派 i96
![][24]
尺寸仅有 6 cm × 3 cm,个头最小的型号之一,售价 **8.8 美元**。该板使用 [RDA8810PL 处理器][25],可作为相当先进的功能手机,适合摄像应用(有处理器厂商背书),最高可以 30 帧/秒的速率采集 1080p 分辨率的图像。在同等价位产品中,输入输出功能出色。
尺寸仅有 6×3 平方厘米,个头最小的型号之一,售价 **8.8 美元**。该板使用 [RDA8810PL 处理器][25],可作为相当先进的功能手机,(据厂商称)适合摄像应用,最高可以 30 帧/秒的速率采集 1080p 分辨率的图像。在同等价位产品中,输入输出功能出色。
**主要参数**
@ -128,37 +112,33 @@
* 集成 256MB LPDDR2 SDRAM
* RDA5991 方案的 WiFi 和蓝牙
* CSI 摄像头输入接口
* 40 GPIO 头
* 40 GPIO 头
详情可参阅 [官方网站][26]。
详情可参阅 [官方网站][26],可从 [此处][27] 购买。
#### 6\. 桔子派 PC
#### 6、桔子派 PC
![][28]
该板售价 **15 美元**继承了很多功能。在同等价位板子中少有的集成了 1 GB 内存的型号之一。采用全志 H3 处理器,可解码 4K HEVC/H.265 视频。具有 HDMI 输出口并支持 HDCP 和 CEC。该单板计算机可以通过安装软件成为一个很好用的媒体盒子。它竟然还配备了板载红外接收器和麦克
该板售价 **15 美元**包含了很多功能。是在同等价位板子中少有的集成了 1 GB 内存的型号之一。采用全志 H3 SoC 芯片,可解码 4K HEVC/H.265 视频。具有 HDMI 输出口并支持 HDCP 和 CEC。该单板计算机可以通过安装软件成为一个很好用的媒体盒子。它竟然还配备了板载红外接收器和话筒
**主要参数**
* 全志 H3 四核 Cortex-A7 架构处理器,主频 1.6 GHz
* 1GB DDR3 内存( GPU 共享)
* 1GB DDR3 内存( GPU 共享)
* 支持 4K 输出的 HDMI
* CSI 摄像头接口,板载麦克
* CSI 摄像头接口,板载话筒
* SD 卡槽
* IR 接收器
* 3.5mm 音频接口
* 网口
* 网络接
* 板上无 WiFi 和蓝牙
桔子派 PC 还有一种减配版,使用的是同样的处理器,只是内存容量要小。
详情可参阅 [官方网站][29],可从 [此处][30] 购买
详情可参阅 [官方网站][29]。
#### 7\. 桔子派 One 和桔子派 Lite
#### 7桔子派 One 和桔子派 Lite
这两种板子与桔子派 PC 一样,使用的是全志 H3 处理器,但配备的是 512MB 内存。
@ -170,30 +150,26 @@
* 512 MB DDR3 内存
* CSI 摄像头接口
![Orange Pi Lite][31]
![Orange Pi One][32]
桔子派 Lite 售价 **12 美元**,不支持板载有线网络,但提供了 WiFi 联网功能。其具有板载麦克和红外接收器。详情可参阅 [官方网站][33],可从 [此处][34] 购买
桔子派 Lite 售价 **12 美元**,不支持板载有线网络,但提供了 WiFi 联网功能。其具有板载话筒和红外接收器。详情可参阅 [官方网站][33]。
桔子派 One 售价 **11 美元**,具有板载有线网络,但不支持 WiFi。详情可参阅 [官方网站][35],可从 [此处][36] 购买
桔子派 One 售价 **11 美元**,具有板载有线网络,但不支持 WiFi。详情可参阅 [官方网站][35]。
在桔子派相关内容的最后,我想简单提一下他们提供的几种适合自定义应用的板子。
* 桔子派 R1 具有双有线网口的小板子,可用于构建网络设备。
* Orange Pi 2G IOT 和 Orange Pi 3G IOT - 这些板子分别提供了 2G 和 3G 蜂窝网络连接能力,适合作为物联网设备。
这些板子都不超过 **20 美元**,详情可参阅 [官方网站][37]。
#### 8\. NanoPi Neo LTS
#### 8NanoPi Neo LTS
![][38]
起步价 **9.99 美元**,该板非常袖珍( 4 cm x 4 cm与桔子派 Zero 规格相似。不同的是,它使用的是更为强悍的全志 H3 处理器和高达 512MB 的内存。虽然无任何板载 WiFi 和蓝牙芯片,但可以通过 USB 接口外接相关器件获得相应功能。该板非常适合作为类似 Pi-Hole 的无显示器的 Linux 服务器、DNS 过滤器运行,同时也很适合作为物联网应用的边缘器件使用。通过 GPIO 可以扩展出你需要的很多功能。
起步价 **9.99 美元**,该板非常袖珍(4x4 平方厘米),与桔子派 Zero 规格相似。不同的是,它使用的是更为强悍的全志 H3 SoC 芯片和高达 512MB 的内存。虽然无任何板载 WiFi 和蓝牙芯片,但可以通过 USB 接口外接相关器件获得相应功能。该板非常适合作为无显示器的 Linux 服务器、DNS 过滤器(如 Pi-Hole同时也很适合作为物联网应用的边缘设备使用。通过 GPIO 可以扩展出你需要的很多功能。
**主要参数**
@ -201,9 +177,7 @@
* 512 MB 内存
* Micro SD 卡槽(最高支持 128 GB
* 10/100 Mbps 网口
* 冗余 GPIO 脚可实现其它所需功能
* 冗余 GPIO 针可实现其它所需功能
可从 [官方网站][39] 了解详情及购买。
@ -215,7 +189,7 @@ NanoPi NEO 的极简版称为 NanoPi NEO Core LTS该极简版为满足工业
Nano NEO Air 的 WiFi/蓝牙版称为 NanoPi NEO Air提供了 eMMC 存储和摄像头输入接口,提供了板载 USB 接口和板载网络接口。详情参阅 [这里][43].
#### 9\. Zero Pi
#### 9Zero Pi
![][44]
@ -228,11 +202,9 @@ Nano NEO Air 的 WiFi/蓝牙版称为 NanoPi NEO Air提供了 eMMC 存储和
* USB 2.0 接口
* 可运行 OpenWRT
可从 [官方网站][45] 了解详情及下单购买。
#### 10\. NanoPi NEO 2
#### 10NanoPi NEO 2
![][46]
@ -244,35 +216,31 @@ NanoPi NEO 2 售价 **19.99 美元**,是 NanoPi NEO 的 2 倍。其外形尺
* Hexacore Mali450 GPU
* 512MB 内存
* 1Gbps 板载网络
* 24 GPIO
* 24 GPIO
* 包含音频及红外之类功能的外接口
可从 [官方网站][47] 了解详情及下单购买。
上面的链接是关于 NanoPi 系列板子的。除此之外,还有一些其它有趣的板子,如配备双千兆网口的,以及针对摄像头应用的。
#### 11\. La Frite
#### 11La Frite
![][48]
出品商是 [Le Potato][49],售价 **20 美元**,主要面向消费媒体及流媒体。它通过 HDMI 2.0 接口以 HDR 方式实现 1080p 视频播放,支持最新的安卓 9 /电视、Linux upstream、u-boot、Kodi等。
出品商是 [Le Potato][49],售价 **20 美元**,主要面向媒体消费及流媒体。它通过 HDMI 2.0 接口以 HDR 方式实现 1080p 视频播放,支持最新的安卓 9 /电视、上游的 Linux、u-boot、Kodi 等。
**主要参数**
* 晶晨 S805X 处理器四核Cortex-A53 架构,主频 1.2GHz
* Amlogic S805X 处理器四核Cortex-A53 架构,主频 1.2GHz
* 最大 1GB DDR4 SDRAM
* 晶晨视频引擎 10支持 H.264、H.265 和 VP9 解码,最高能以 60 帧/秒的速率实现 1080p 高清
* Amlogic 视频引擎 10支持 H.264、H.265 和 VP9 解码,最高能以 60 帧/秒的速率实现 1080p 高清
* 百兆网
* 红外接
* 40 GPIO
* 红外接
* 40 GPIO
详情可参阅 [官方网站][50]。
详情可参阅 [官方网站][50] .
#### 12\. Onion Omega2+
#### 12、Onion Omega2+
![][51]
@ -280,23 +248,21 @@ NanoPi NEO 2 售价 **19.99 美元**,是 NanoPi NEO 的 2 倍。其外形尺
**主要参数**
* MT7688 处理器
* MT7688 SoC 芯片
* 2.4 GHz WiFi支持 IEEE 802.11 b/g/n
* 128 MB DDR2 内存
* 32 MB 板载闪存
* MicroSD 卡槽
* USB 2.0
* 12 个 GPIO 引脚
* 12 个 GPIO 引针
你可以 **13 美元** 的单价从 [官方网站][54] 购买其极简版,并可以选配各种附件。
#### 13\. VoCore2
#### 13VoCore2
![][55]
VoCore2 肯定是类似产品中最小的一,极简版尺寸只有 1 英寸见方,售价 **17.99 美元**。小巧的尺寸使得其能方便的嵌入到不同的应用场合,而且允许根据需要扩充不同的特性。该板使用过的是联发科针对中低端路由器的处理器 MT7628 处理器。生产商声明该型号板子将持续供应至 2025 年,这是个不错的消息。
VoCore2 肯定是类似产品中最小的一,极简版尺寸只有 1 英寸见方,售价 **17.99 美元**。小巧的尺寸使得其能方便的嵌入到不同的应用场合,而且允许根据需要扩充不同的特性。该板使用过的是联发科针对中低端路由器的处理器 MT7628 处理器。生产商声明将持续供应至 2025 年,这是个不错的消息。
**主要参数**
@ -307,11 +273,9 @@ VoCore2 肯定是类似产品中最小的一种,极简版尺寸只有 1 英寸
* 板载 16M NOR 存储器,支持最大 2TB SDXC 卡
* 一个板载 U.FL 槽(天线接口)
你可以从 [此处][56] 了解更多细节。
你可以从 [此处][56] 了解更多细节,可以从 [官方网站][57] 下单购买。
**结束语**
### 结束语
无可否认,不同规格和特性的各种单板计算机可以满足千变万化的使用需求。另外,绝大部分此类产品都基于开源设计,运行着开源软件。这绝对是硬核玩家不可多得的乐园。
@ -325,8 +289,8 @@ via: https://itsfoss.com/raspberry-pi-zero-alternatives/
作者:[Chinmay][a]
选题:[lujun9972][b]
译者:[silentdawn-zz](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
译者:[silentdawn-zz](https://github.com/silentdawn-zz)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
@ -335,9 +299,9 @@ via: https://itsfoss.com/raspberry-pi-zero-alternatives/
[1]: https://www.raspberrypi.org/products/raspberry-pi-zero/
[2]: https://itsfoss.com/raspberry-pi-zero-w/
[3]: https://itsfoss.com/raspberry-pi-projects/
[4]: https://itsfoss.com/raspberry-pi-alternatives/
[4]: https://linux.cn/article-10823-1.html
[5]: https://i1.wp.com/m.media-amazon.com/images/I/517BwcAPmTL._SL160_.jpg?ssl=1
[6]: https://www.amazon.com/dp/B072N3X39J?tag=chmod7mediate-20&linkCode=ogi&th=1&psc=1 (CanaKit Raspberry Pi Zero W (Wireless) Complete Starter Kit - 16 GB Edition)
[6]: https://www.amazon.com/dp/B072N3X39J?tag=chmod7mediate-20&linkCode=ogi&th=1&psc=1
[7]: https://www.amazon.com/gp/prime/?tag=chmod7mediate-20 (Amazon Prime)
[8]: https://www.amazon.com/dp/B072N3X39J?tag=chmod7mediate-20&linkCode=ogi&th=1&psc=1 (Buy on Amazon)
[9]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2020/07/raspberry-pi-zero-alterantives.png?ssl=1

View File

@ -0,0 +1,108 @@
[#]: collector: (lujun9972)
[#]: translator: (wxy)
[#]: reviewer: (wxy)
[#]: publisher: (wxy)
[#]: url: (https://linux.cn/article-12501-1.html)
[#]: subject: (Open Source Drawing App Pinta Sees New Release After 5 Years. Heres How to Get it!)
[#]: via: (https://itsfoss.com/pinta-new-release/)
[#]: author: (Abhishek Prakash https://itsfoss.com/author/abhishek/)
开源绘画应用 Pinta 在 5 年后迎来新版本
======
> 开源绘画应用 Pinta 时隔 5 年多迎来新版本。新版本修复了众多 BUG并增加了新功能。
[Pinta][1] 是一款[开源绘画应用,适用于 Linux][2]、Windows 和 macOS。你可以用它来进行自由手绘/素描。你也可以用它在现有的图片上添加箭头、方框、文字等。
![][3]
日前Pinta 1.7 版本在时隔近 5 年后发布。让我们来看看新版本中都有哪些功能。
### Pinta 1.7 的新功能
以下是最新版本的 Pinta 带来的新功能:
* 可以在图片之间切换的标签视图
* 增加了一个平滑擦除工具
* 拖放 URL 以在 Pinta 中下载并打开图像进行编辑
* 铅笔工具可以在不同的混合模式之间切换
* 按住 Ctrl 键可以缩放“选定移动”工具
* 矩形选择工具现在在选区的每个角落显示不同的箭头光标
* 提高了与选区互动时的性能,特别是对大图像而言
还有许多 bug 修复,这应该会改善整个 Pinta 的体验。你可以在[官方发布说明][4]中了解更多变化。
### 在 Ubuntu 和其他 Linux 发行版上安装 Pinta 1.7
对于 Ubuntu 和基于 Ubuntu 的 Linux 发行版,有一个[官方 PPA 可用][5]。如果你使用的是 Ubuntu 18.04 或 20.04,可以使用这个 PPA。
打开一个终端,使用下面的命令来添加新的仓库。你会被要求输入你的密码。你可能已经知道,当你在终端中输入密码时,不会有任何显示。只要输入密码,然后按回车键就可以了。
```
sudo add-apt-repository ppa:pinta-maintainers/pinta-stable
```
在 Ubuntu 18.04 和更高版本上已不再需要,但其他一些发行版可能需要更新缓存:
```
sudo apt update
```
现在用这个命令安装最新版本的 Pinta
```
sudo apt install pinta
```
好的是,如果你之前安装了 Pinta 1.6,它就会更新到新版本。
#### 移除 Pinta
要删除通过 PPA 安装的 Pinta请使用此命令
```
sudo apt remove pinta
```
你还应该[删除此 PPA][6]
```
sudo add-apt-repository -r ppa:pinta-maintainers/pinta-stable
```
#### 在其他发行版上安装 Pinta
在我上次检查时Pinta 1.7 还没有在 Fedora 或 AUR 上出现。你可以等待一段时间,或者下载源码自己试试。
- [下载 Pinta 1.7][7]
Pinta 团队也更新了用户指南,提供了详细的文档。如果你是新手或者想深入使用 Pinta可以参考[本用户指南][8]进行参考。
### 结束语
我很高兴能看到 Pinta 的新版本。它是我编辑图像的常用工具,可以为教程添加箭头、方框和文字。最近我使用 [Shutter][9] 来达到这个目的,但有了这个新版本,我也许会再次改用 Pinta。
你呢?你使用 Pinta 吗,或者你过去用过它吗?你期待使用新版本吗?
--------------------------------------------------------------------------------
via: https://itsfoss.com/pinta-new-release/
作者:[Abhishek Prakash][a]
选题:[lujun9972][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/abhishek/
[b]: https://github.com/lujun9972
[1]: https://www.pinta-project.com/
[2]: https://itsfoss.com/open-source-paint-apps/
[3]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/08/pinta-1-7.png?resize=800%2C517&ssl=1
[4]: https://www.pinta-project.com/releases/1-7
[5]: https://launchpad.net/~pinta-maintainers/+archive/ubuntu/pinta-stable
[6]: https://itsfoss.com/how-to-remove-or-delete-ppas-quick-tip/
[7]: https://www.pinta-project.com/releases/
[8]: https://www.pinta-project.com/user-guide/
[9]: https://itsfoss.com/install-shutter-ubuntu/

View File

@ -1,5 +1,5 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: translator: (silentdawn-zz)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )

View File

@ -1,143 +0,0 @@
[#]: collector: (lujun9972)
[#]: translator: (geekpi)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Analyze your web server log files with this Python tool)
[#]: via: (https://opensource.com/article/20/7/python-lars)
[#]: author: (Ben Nuttall https://opensource.com/users/bennuttall)
Analyze your web server log files with this Python tool
======
This Python module can collect website usage logs in multiple formats
and output well structured data for analysis.
![Person standing in front of a giant computer screen with numbers, data][1]
Ever wanted to know how many visitors you've had to your website? Or which pages, articles, or downloads are the most popular? If you're self-hosting your blog or website, whether you use Apache, Nginx, or even Microsoft IIS (yes, really), [lars][2] is here to help.
Lars is a web server-log toolkit for [Python][3]. That means you can use Python to parse log files retrospectively (or in real time) using simple code, and do whatever you want with the data—store it in a database, save it as a CSV file, or analyze it right away using more Python.
Lars is another hidden gem written by [Dave Jones][4]. I first saw Dave present lars at a local Python user group. Then a few years later, we started using it in the [piwheels][5] project to read in the Apache logs and insert rows into our Postgres database. In real time, as Raspberry Pi users download Python packages from [piwheels.org][6], we log the filename, timestamp, system architecture (Arm version), distro name/version, Python version, and so on. Since it's a relational database, we can join these results on other tables to get more contextual information about the file.
You can install lars with:
```
`$ pip install lars`
```
On some systems, the right route will be [ `sudo` ] `pip3 install lars`.
To get started, find a single web access log and make a copy of it. You'll want to download the log file onto your computer to play around with it. I'm using Apache logs in my examples, but with some small (and obvious) alterations, you can use Nginx or IIS. On a typical web server, you'll find Apache logs in `/var/log/apache2/` then usually `access.log` , `ssl_access.log` (for HTTPS), or gzipped rotated logfiles like `access-20200101.gz` or `ssl_access-20200101.gz` .
First of all, what does a log entry look like?
```
81.174.152.222 - - [30/Jun/2020:23:38:03 +0000] "GET / HTTP/1.1" 200 6763 "-" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:77.0) Gecko/20100101 Firefox/77.0"
```
This is a request showing the IP address of the origin of the request, the timestamp, the requested file path (in this case / , the homepage, the HTTP status code, the user agent (Firefox on Ubuntu), and so on.
Your log files will be full of entries like this, not just every single page hit, but every file and resource served—every CSS stylesheet, JavaScript file and image, every 404, every redirect, every bot crawl. To get any sensible data out of your logs, you need to parse, filter, and sort the entries. That's what lars is for. This example will open a single log file and print the contents of every row:
[code]
```
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            print(row)
```
```
Which will show results like this for every log entry:
```
```
Row(remote_host=IPv4Address('81.174.152.222'), ident=None, remote_user=None, time=DateTime(2020, 6, 30, 23, 38, 3), request=Request(method='GET', url=Url(scheme='', netloc='', path_str='/', params='', query_str='', fragment=''), protocol='HTTP/1.1'), status=200, size=6763)
```
It's parsed the log entry and put the data into a structured format. The entry has become a namedtuple with attributes relating to the entry data, so for example, you can access the status code with row.status and the path with row.request.url.path_str:
[code]
```
```
```
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            print(f'hit {row.request.url.path_str} with status code {row.status}')
```
```
If you wanted to show only the 404s, you could do:
[code]
```
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            if row.status == 404:
                print(row.request.url.path_str)
```
```
You might want to de-duplicate these and print the number of unique pages with 404s:
[code]
```
s = set()
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            if row.status == 404:
                s.add(row.request.url.path_str)
print(len(s))
```
```
Dave and I have been working on expanding piwheels' logger to include web-page hits, package searches, and more, and it's been a piece of cake, thanks to lars. It's not going to tell us any answers about our users—we still have to do the data analysis, but it's taken an awkward file format and put it into our database in a way we can make use of it.
Check out lars' documentation to see how to read Apache, Nginx, and IIS logs, and learn what else you can do with it. Thanks, yet again, to Dave for another great tool!
```
* * *
```
This originally appeared on Ben Nuttall's Tooling Blog and is republished with permission.
```
--------------------------------------------------------------------------------
via: https://opensource.com/article/20/7/python-lars
作者:[Ben Nuttall][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/bennuttall
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/data_metrics_analytics_desktop_laptop.png?itok=9QXd7AUr (Person standing in front of a giant computer screen with numbers, data)
[2]: https://lars.readthedocs.io/en/latest/
[3]: https://opensource.com/resources/python
[4]: https://twitter.com/waveform80/
[5]: https://opensource.com/article/18/10/piwheels-python-raspberrypi
[6]: http://piwheels.org

View File

@ -1,5 +1,5 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: translator: (geekpi)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )

View File

@ -1,110 +0,0 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Open Source Drawing App Pinta Sees New Release After 5 Years. Heres How to Get it!)
[#]: via: (https://itsfoss.com/pinta-new-release/)
[#]: author: (Abhishek Prakash https://itsfoss.com/author/abhishek/)
Open Source Drawing App Pinta Sees New Release After 5 Years. Heres How to Get it!
======
_**Brief: Open source painting and drawing application has a new release after more than 5 years. The new release fixes numerous bugs and adds new features.**_
[Pinta][1] is an [open source drawing application for Linux][2], Windows and macOS. You can use it for freehand drawing/sketching. You may also use it to add arrows, boxes, text etc on an existing image.
![][3]
Pinta version 1.7 was released a few days ago after a gap of almost five years. Lets see what do we have in the new version.
### New features in Pinta 1.7
Here are the new features the latest version of Pinta brings:
* Tab view to switch between images
* Addition of a Smooth Erase tool
* Drag and drop URL to download and open the image in Pinta for editing
* The Pencil tool can switch between different blend modes
* Move Selected tool can be scaled by holding Ctrl
* The Rectangle Select tool now shows different arrow cursors at each corner of the selection
* Performance improvements when interacting with selections, particularly for large images
There are numerous bug fixes as well and this should improve the overall Pinta experience. You can learn about more changes in the [official release note][4].
### Installing Pinta 1.7 on Ubuntu and other Linux distributions
For Ubuntu and Ubuntu-based Linux distributions, there is an [official PPA available][5]. If you are using Ubuntu 18.04 or 20.04, you can use this PPA.
Open a terminal and use the following command to add the new repository. Youll be asked to enter your password. You probably already know that when you type password in terminal, nothing is displayed. Just type the password and press enter.
```
sudo add-apt-repository ppa:pinta-maintainers/pinta-stable
```
Not required on Ubuntu 18.04 and higher version anymore but some other distributions may need to update the cache:
```
sudo apt update
```
Now install the latest version of Pinta using this command.
```
sudo apt install pinta
```
Good thing here is that if you had Pinta 1.6 installed previously, it gets updated to the new version.
#### Removing Pinta
To remove Pinta installed via PPA, use this command:
```
sudo apt remove pinta
```
You should also [delete the PPA][6]:
```
sudo add-apt-repository -r ppa:pinta-maintainers/pinta-stable
```
#### Installing Pinta on other distributions
When I last checked Pinta 1.7 wasnt available for Fedora or AUR yet. You may wait for some time or download the source code and try it on your own.
[Download Pinta 1.7][7]
Pinta team has also refreshed its user guide with detailed documentation. If you are new to Pinta or if you want to use it extensively, you may refer to [this user guide][8] for reference.
**Conclusion**
I am happy to see a new release of Pinta. It was my go-to tool for editing images to add arrows, boxes and text for tutorials on Its FOSS. I use [Shutter][9] for this purpose these days but with this new release, I might perhaps switch to Pinta again.
What about you? Do you use Pinta or have you used it in the past? Are you looking forward to use the new version?
--------------------------------------------------------------------------------
via: https://itsfoss.com/pinta-new-release/
作者:[Abhishek Prakash][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/abhishek/
[b]: https://github.com/lujun9972
[1]: https://www.pinta-project.com/
[2]: https://itsfoss.com/open-source-paint-apps/
[3]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/08/pinta-1-7.png?resize=800%2C517&ssl=1
[4]: https://www.pinta-project.com/releases/1-7
[5]: https://launchpad.net/~pinta-maintainers/+archive/ubuntu/pinta-stable
[6]: https://itsfoss.com/how-to-remove-or-delete-ppas-quick-tip/
[7]: https://www.pinta-project.com/releases/
[8]: https://www.pinta-project.com/user-guide/
[9]: https://itsfoss.com/install-shutter-ubuntu/

View File

@ -0,0 +1,116 @@
[#]: collector: (lujun9972)
[#]: translator: (geekpi)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Analyze your web server log files with this Python tool)
[#]: via: (https://opensource.com/article/20/7/python-lars)
[#]: author: (Ben Nuttall https://opensource.com/users/bennuttall)
使用这个 Python 工具分析你的 Web 服务器日志文件
======
这个 Python 模块可以以多种格式收集网站使用日志并输出良好结构化数据进行分析。
![Person standing in front of a giant computer screen with numbers, data][1]
是否曾经想知道有多少访问者访问过你的网站?或哪个页面、文章或下载最受欢迎?如果你是自托管的博客或网站,那么无论你使用的是 Apache、Nginx 还是 Microsoft IIS是的没错[lars][2]都可以为你提供帮助。
Lars 是 [Python][3] 写的 Web 服务器日志工具包。这意味着你可以使用 Python 通过简单的代码回溯(或实时)解析日志,并对数据做任何你想做的事:将它存储在数据库中、另存为 CSV 文件,或者立即使用 Python 进行更多分析。
Lars 是 [Dave Jones][4] 写的另一个隐藏的宝石。我第一次在本地 Python 用户中看到 Dave 演示 lars。几年后我们开始在 [piwheels][5] 项目中使用它来读取 Apache 日志并将行插入到我们的 Postgres 数据库中。当树莓派用户从 [piwheels.org][6] 下载 Python 包时我们会记录文件名、时间戳、系统架构Arm 版本)、发行版名称/版本Python 版本等。由于它是一个关系数据库,因此我们可以将这些结果加入其他表中以获得有关文件的更多上下文信息。
你可以使用以下方法安装lars
```
`$ pip install lars`
```
在某些系统上,正确的方式是 [ `sudo` ] `pip3 install lars`.
首先,找到一个 Web 访问日志并制作一个副本。你需要将日志文件下载到计算机上进行操作。我在示例中使用的是 Apache 日志,但是经过一些小(且明显)的更改,你可以使用 Nginx 或 IIS。在典型的 Web 服务器上,你会在 `/var/log/apache2/` 中找到 Apache 日志,通常是 access.log、ssl_access.log对于 HTTPS或 gzip 压缩后的轮转日志文件,如 `access-20200101.gz` 或者 `ssl_access-20200101.gz`
首先,日志是什么样的?
```
81.174.152.222 - - [30/Jun/2020:23:38:03 +0000] "GET / HTTP/1.1" 200 6763 "-" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:77.0) Gecko/20100101 Firefox/77.0"
```
这是一个显示了请求源 IP 地址、时间戳、请求文件路径(在本例中是主页 /、HTTP 状态代码用户代理Ubuntu 上的 Firefox等的请求。
你的日志文件将充满这样的条目,不仅是每个打开的页面,还包括返回的每个文件和资源:每个 CSS 样式表、JavaScript 文件和图像,每个 404、每个重定向、每个爬虫。要从日志中获取有意义的数据你需要对条目进行解析、过滤和排序。这就是 Lars 的用处。本示例将打开一个日志文件并打印每一行的内容:
```
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            print(row)
```
它会为每条日志显示如下结果:
```
Row(remote_host=IPv4Address('81.174.152.222'), ident=None, remote_user=None, time=DateTime(2020, 6, 30, 23, 38, 3), request=Request(method='GET', url=Url(scheme='', netloc='', path_str='/', params='', query_str='', fragment=''), protocol='HTTP/1.1'), status=200, size=6763)
```
它解析了日志条目,并将数据放入结构化格式中。该条目已成为具有与条目数据相关属性的 namedtuple因此例如你可以使用 row.status 访问状态代码,并使用 row.request.url.path_str 访问路径:
```
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            print(f'hit {row.request.url.path_str} with status code {row.status}')
```
如果你只想显示 404可以执行以下操作
```
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            if row.status == 404:
                print(row.request.url.path_str)
```
你可能要对这些数据去重,并打印独立的 404 页面数量:
```
s = set()
with open('ssl_access.log') as f:
    with ApacheSource(f) as source:
        for row in source:
            if row.status == 404:
                s.add(row.request.url.path_str)
print(len(s))
```
我和 Dave 一直在努力扩展 piwheel 的日志记录器,使其包含网页点击量、软件包搜索等内容,这些并不难,都要归功于 lars。它不会告诉我们有关用户的任何答案。我们仍然需要进行数据分析但它采取了一种粗糙的文件格式并以我们可以利用它的方式将它放入我们的数据库。
查阅 lars 的文档,以了解如何读取 Apache、Nginx 和 IIS 日志,并了解你还可以使用它做什么。再次感谢 Dave 提供的出色工具!
* * *
它最初发布在 Ben Nuttall 的 Tooling Blog 中,并获许重新发布。
--------------------------------------------------------------------------------
via: https://opensource.com/article/20/7/python-lars
作者:[Ben Nuttall][a]
选题:[lujun9972][b]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/bennuttall
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/data_metrics_analytics_desktop_laptop.png?itok=9QXd7AUr (Person standing in front of a giant computer screen with numbers, data)
[2]: https://lars.readthedocs.io/en/latest/
[3]: https://opensource.com/resources/python
[4]: https://twitter.com/waveform80/
[5]: https://opensource.com/article/18/10/piwheels-python-raspberrypi
[6]: http://piwheels.org