mirror of
https://github.com/LCTT/TranslateProject.git
synced 2025-01-13 22:30:37 +08:00
Merge remote-tracking branch 'LCTT/master'
This commit is contained in:
commit
4df6c4d64e
@ -1,8 +1,8 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (qfzy1233)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: reviewer: (wxy)
|
||||
[#]: publisher: (wxy)
|
||||
[#]: url: (https://linux.cn/article-11359-1.html)
|
||||
[#]: subject: (How to Change Themes in Linux Mint)
|
||||
[#]: via: (https://itsfoss.com/install-themes-linux-mint/)
|
||||
[#]: author: (It's FOSS Community https://itsfoss.com/author/itsfoss/)
|
||||
@ -10,9 +10,11 @@
|
||||
如何在 Linux Mint 中更换主题
|
||||
======
|
||||
|
||||
自始至终,使用 Cinnamon 桌面环境的 Linux Mint 都是一种卓越的体验。这也是[为何我喜爱 Linux Mint ][1]的主要原因之一。
|
||||
![](https://img.linux.net.cn/data/attachment/album/201909/19/100317ixxp3y1l7lljl47a.jpg)
|
||||
|
||||
自从 Mint 的开发团队 [开始更为严肃的对待设计][2], “桌面主题” 应用便成为了更换新主题,图标,按钮样式,窗口边框以及鼠标指针的重要方式,当然你也可以直接通过它安装新的主题。感兴趣么? 让我们开始吧。
|
||||
一直以来,使用 Cinnamon 桌面环境的 Linux Mint 都是一种卓越的体验。这也是[为何我喜爱 Linux Mint][1]的主要原因之一。
|
||||
|
||||
自从 Mint 的开发团队[开始更为严肃的对待设计][2], “桌面主题” 应用便成为了更换新主题、图标、按钮样式、窗口边框以及鼠标指针的重要方式,当然你也可以直接通过它安装新的主题。感兴趣么?让我们开始吧。
|
||||
|
||||
### 如何在 Linux Mint 中更换主题
|
||||
|
||||
@ -20,70 +22,62 @@
|
||||
|
||||
![Theme Applet provides an easy way of installing and changing themes][3]
|
||||
|
||||
在应用中中有一个“添加/删除”按钮,非常简单,不是么?而且,点击它,我们可以看到Cinnamon Spices( Cinnamon 的官方插件库)的主题按流行程度排序。
|
||||
在应用中有一个“添加/删除”按钮,非常简单吧。点击它,我们可以看到按流行程度排序的 Cinnamon Spices(Cinnamon 的官方插件库)的主题。
|
||||
|
||||
![Installing new themes in Linux Mint Cinnamon][4]
|
||||
|
||||
要安装主题,你所要做的就是点击你喜欢的一个,然后等待它下载。之后,主题将在应用第一页的“Desktop”选项中显示可用。只需双击已安装的主题之一就可以开始使用它。
|
||||
要安装主题,你所要做的就是点击你喜欢的主题,然后等待它下载。之后,主题将在应用第一页的“Desktop”选项中显示可用。只需双击已安装的主题之一就可以开始使用它。
|
||||
|
||||
![Changing themes in Linux Mint Cinnamon][5]
|
||||
|
||||
下面是默认的 Linux Mint 外观:
|
||||
下面是默认的 Linux Mint 外观:
|
||||
|
||||
![Linux Mint Default Theme][6]
|
||||
|
||||
这是在我更换主题之后:
|
||||
这是在我更换主题之后:
|
||||
|
||||
![Linux Mint with Carta Theme][7]
|
||||
|
||||
所有的主题都可以在 Cinnamon Spices 网站上获得更多的信息和更大的截图,这样你就可以更好地了解你的系统的外观。
|
||||
|
||||
[浏览 Cinnamon 主题][8]
|
||||
- [浏览 Cinnamon 主题][8]
|
||||
|
||||
### 在 Linux Mint 中安装第三方主题
|
||||
|
||||
_“我在另一个网站上看到了这个优异的主题,但 Cinnamon Spices 网站上没有……”_
|
||||
> “我在另一个网站上看到了这个优异的主题,但 Cinnamon Spices 网站上没有……”
|
||||
|
||||
Cinnamon Spices 集成了许多优秀的主题,但你仍然会发现,你看到的主题并没有被 Cinnamon Spices 官方网站收录。
|
||||
Cinnamon Spices 集成了许多优秀的主题,但你仍然会发现,你看到的主题并没有被 Cinnamon Spices 官方网站收录。
|
||||
|
||||
这时你可能会想:如果有别的办法就好了,对么?你可能会认为有(我的意思是……当然啦)。首先,我们可以在其他网站上找到一些很酷的主题。
|
||||
这时你可能会想:如果有别的办法就好了,对么?你可能会认为有(我的意思是……当然啦)。首先,我们可以在其他网站上找到一些很酷的主题。
|
||||
|
||||
我推荐你去 Cinnamon 浏览主题。如果你喜欢什么,就下载吧。
|
||||
我推荐你去 Cinnamon Look 浏览一下那儿的主题。如果你喜欢什么,就下载吧。
|
||||
|
||||
[在 Cinnamon 外观中获取更多主题][9]
|
||||
- [在 Cinnamon Look 中获取更多主题][9]
|
||||
|
||||
下载了首选主题之后,你现在将得到一个压缩文件,其中包含安装所需的所有内容。提取它并保存到 ~/.themes. 迷糊么? “~” 代表了你的 home 文件夹的对应路径: /home/{YOURUSER}/.themes.
|
||||
下载了首选主题之后,你现在将得到一个压缩文件,其中包含安装所需的所有内容。提取它并保存到 `~/.themes`。迷糊么? `~` 代表了你的家目录的对应路径:`/home/{YOURUSER}/.themes`。
|
||||
|
||||
[][10]
|
||||
然后跳转到你的家目录。按 `Ctrl+H` 来[显示 Linux 中的隐藏文件][11]。如果没有看到 `.themes` 文件夹,创建一个新文件夹并命名为 `.themes`。记住,文件夹名称开头的点很重要。
|
||||
|
||||
建议在登录 Ubuntu 16.04 时读取“启动会话失败”的修复程序。
|
||||
|
||||
然后跳转到你的主目录。按Ctrl+H[显示Linux中的隐藏文件][11]。如果没有看到.themes文件夹,创建一个新文件夹并命名为.themes。记住,文件夹名称开头的点很重要。
|
||||
|
||||
将提取的主题文件夹从下载目录复制到你的 home 中的.themes文件夹。
|
||||
将提取的主题文件夹从下载目录复制到你的家目录中的 `.themes` 文件夹中。
|
||||
|
||||
最后,在上面提到的应用中查找已安装的主题。
|
||||
|
||||
注记
|
||||
> 注记
|
||||
>
|
||||
> 请记住,主题必须是 Cinnamon 相对应的,即使它是一个从 GNOME 复刻的系统也不行,并不是所有的 GNOME 主题都适用于 Cinnamon。
|
||||
|
||||
请记住,主题必须是 Cinnamon 相对应的,即使它是一个从 GNOME 复刻的系统也不行,并不是所有的 GNOME 主题都适用于 Cinnamon 。
|
||||
改变主题是 Cinnamon 定制工作的一部分。你还可以[通过更改图标来更改 Linux Mint 的外观][12]。
|
||||
|
||||
改变主题是 Cinnamon 定制的一部分。你还可以[通过更改图标来更改 Linux Mint 的外观][12]。
|
||||
|
||||
我希望你现在已经知道如何在 Linux Mint 中更改主题了。快去选取你喜欢的主题吧?
|
||||
|
||||
### João Gondim
|
||||
|
||||
来自巴西的Linux爱好者。
|
||||
我希望你现在已经知道如何在 Linux Mint 中更改主题了。快去选取你喜欢的主题吧。
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://itsfoss.com/install-themes-linux-mint/
|
||||
|
||||
作者:[It's FOSS Community][a]
|
||||
作者:[It's FOSS][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
译者:[qfzy1233](https://github.com/qfzy1233)
|
||||
校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
@ -0,0 +1,139 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (Morisun029)
|
||||
[#]: reviewer: (wxy)
|
||||
[#]: publisher: (wxy)
|
||||
[#]: url: (https://linux.cn/article-11360-1.html)
|
||||
[#]: subject: (How to Check Linux Mint Version Number & Codename)
|
||||
[#]: via: (https://itsfoss.com/check-linux-mint-version/)
|
||||
[#]: author: (Sergiu https://itsfoss.com/author/sergiu/)
|
||||
|
||||
如何查看 Linux Mint 版本号和代号
|
||||
======
|
||||
|
||||
Linux Mint 每两年发布一次主版本(如 Mint 19),每六个月左右发布一次次版本(如 Mint 19.1、19.2 等)。 你可以自己升级 Linux Mint 版本,而次版本也会自动更新。
|
||||
|
||||
在所有这些版本中,你可能想知道你正在使用的是哪个版本。了解 Linux Mint 版本号可以帮助你确定某个特定软件是否适用于你的系统,或者检查你的系统是否已达到使用寿命。
|
||||
|
||||
你可能需要 Linux Mint 版本号有多种原因,你也有多种方法可以获取此信息。让我向你展示用图形和命令行的方式获取 Mint 版本信息。
|
||||
|
||||
* [使用命令行查看 Linux Mint 版本信息][1]
|
||||
* [使用 GUI(图形用户界面)查看 Linux Mint 版本信息][2]
|
||||
|
||||
### 使用终端查看 Linux Mint 版本号的方法
|
||||
|
||||
![][3]
|
||||
|
||||
我将介绍几种使用非常简单的命令查看 Linux Mint 版本号和代号的方法。 你可以从 “菜单” 中打开终端,或按 `CTRL+ALT+T`(默认热键)打开。
|
||||
|
||||
本文中的最后两个命令还会输出你当前的 Linux Mint 版本所基于的 Ubuntu 版本。
|
||||
|
||||
#### 1、/etc/issue
|
||||
|
||||
从最简单的 CLI 方法开始,你可以打印出 `/etc/issue` 的内容来检查你的版本号和代号:
|
||||
|
||||
```
|
||||
[email protected]:~$ cat /etc/issue
|
||||
Linux Mint 19.2 Tina \n \l
|
||||
```
|
||||
|
||||
#### 2、hostnamectl
|
||||
|
||||
![hostnamectl][4]
|
||||
|
||||
这一个命令(`hostnamectl`)打印的信息几乎与“系统信息”中的信息相同。 你可以看到你的操作系统(带有版本号)以及你的内核版本。
|
||||
|
||||
#### 3、lsb_release
|
||||
|
||||
`lsb_release` 是一个非常简单的 Linux 实用程序,用于查看有关你的发行版本的基本信息:
|
||||
|
||||
```
|
||||
[email protected]:~$ lsb_release -a
|
||||
No LSB modules are available.
|
||||
Distributor ID: LinuxMint
|
||||
Description: Linux Mint 19.2 Tina
|
||||
Release: 19.2
|
||||
Codename: tina
|
||||
```
|
||||
|
||||
**注:** 我使用 `–a` 标签打印所有参数, 但你也可以使用 `-s` 作为简写格式,`-d` 用于描述等 (用 `man lsb_release` 查看所有选项)
|
||||
|
||||
#### 4、/etc/linuxmint/info
|
||||
|
||||
![/etc/linuxmint/info][5]
|
||||
|
||||
这不是命令,而是 Linux Mint 系统上的文件。只需使用 `cat` 命令将其内容打印到终端,然后查看你的版本号和代号。
|
||||
|
||||
#### 5、使用 /etc/os-release 命令也可以获取到 Ubuntu 代号
|
||||
|
||||
![/etc/os-release][7]
|
||||
|
||||
Linux Mint 基于 Ubuntu。每个 Linux Mint 版本都基于不同的 Ubuntu 版本。了解你的 Linux Mint 版本所基于的 Ubuntu 版本有助你在必须要使用 Ubuntu 版本号的情况下使用(比如你需要在 [Linux Mint 中安装最新的 Virtual Box][8]添加仓库时)。
|
||||
|
||||
`os-release` 则是另一个类似于 `info` 的文件,向你展示 Linux Mint 所基于的 Ubuntu 版本代号。
|
||||
|
||||
#### 6、使用 /etc/upstream-release/lsb-release 只获取 Ubuntu 的基本信息
|
||||
|
||||
如果你只想要查看有关 Ubuntu 的基本信息,请输出 `/etc/upstream-release/lsb-release`:
|
||||
|
||||
```
|
||||
[email protected]:~$ cat /etc/upstream-release/lsb-release
|
||||
DISTRIB_ID=Ubuntu
|
||||
DISTRIB_RELEASE=18.04
|
||||
DISTRIB_CODENAME=bionic
|
||||
DISTRIB_DESCRIPTION="Ubuntu 18.04 LTS"
|
||||
```
|
||||
|
||||
特别提示:[你可以使用 uname 命令查看 Linux 内核版本][9]。
|
||||
|
||||
```
|
||||
[email protected]:~$ uname -r
|
||||
4.15.0-54-generic
|
||||
```
|
||||
|
||||
**注:** `-r` 代表 release,你可以使用 `man uname` 查看其他信息。
|
||||
|
||||
### 使用 GUI 查看 Linux Mint 版本信息
|
||||
|
||||
如果你对终端和命令行不满意,可以使用图形方法。如你所料,这个非常明了。
|
||||
|
||||
打开“菜单” (左下角),然后转到“偏好设置 > 系统信息”:
|
||||
|
||||
![Linux Mint 菜单][10]
|
||||
|
||||
或者,在菜单中,你可以搜索“System Info”:
|
||||
|
||||
![Menu Search System Info][11]
|
||||
|
||||
在这里,你可以看到你的操作系统(包括版本号),内核和桌面环境的版本号:
|
||||
|
||||
![System Info][12]
|
||||
|
||||
### 总结
|
||||
|
||||
我已经介绍了一些不同的方法,用这些方法你可以快速查看你正在使用的 Linux Mint 的版本和代号(以及所基于的 Ubuntu 版本和内核)。我希望这个初学者教程对你有所帮助。请在评论中告诉我们你最喜欢哪个方法!
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://itsfoss.com/check-linux-mint-version/
|
||||
|
||||
作者:[Sergiu][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[Morisun029](https://github.com/Morisun029)
|
||||
校对:[wxy](https://github.com/wxy)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://itsfoss.com/author/sergiu/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: tmp.pL5Hg3N6Qt#terminal
|
||||
[2]: tmp.pL5Hg3N6Qt#GUI
|
||||
[3]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/09/check-linux-mint-version.png?ssl=1
|
||||
[4]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/09/hostnamectl.jpg?ssl=1
|
||||
[5]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/09/linuxmint_info.jpg?ssl=1
|
||||
[6]: https://itsfoss.com/rid-google-chrome-icons-dock-elementary-os-freya/
|
||||
[7]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/09/os_release.jpg?ssl=1
|
||||
[8]: https://itsfoss.com/install-virtualbox-ubuntu/
|
||||
[9]: https://itsfoss.com/find-which-kernel-version-is-running-in-ubuntu/
|
||||
[10]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/09/linux_mint_menu.jpg?ssl=1
|
||||
[11]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/09/menu_search_system_info.jpg?ssl=1
|
||||
[12]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/09/system_info.png?ssl=1
|
@ -0,0 +1,67 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Oracle Unleashes World’s Fastest Database Machine ‘Exadata X8M’)
|
||||
[#]: via: (https://opensourceforu.com/2019/09/oracle-unleashes-worlds-fastest-database-machine-exadata-x8m/)
|
||||
[#]: author: (Longjam Dineshwori https://opensourceforu.com/author/dineshwori-longjam/)
|
||||
|
||||
Oracle Unleashes World’s Fastest Database Machine ‘Exadata X8M’
|
||||
======
|
||||
|
||||
* _**Exadata X8M is the first database machine with integrated persistent memory and RoCE**_
|
||||
* _**Oracle also announced availability of Oracle Zero Data Loss Recovery Appliance X8M (ZDLRA)**_
|
||||
|
||||
|
||||
|
||||
![][1]
|
||||
|
||||
Oracle has released its new Exadata Database Machine X8M with an aim to set a new bar in the database infrastructure market.
|
||||
|
||||
Exadata X8M combines Intel Optane DC persistent memory and 100 gigabit remote direct memory access (RDMA) over Converged Ethernet (RoCE) to remove storage bottlenecks and dramatically increase performance for the most demanding workloads such as Online Transaction Processing (OLTP), analytics, IoT, fraud detection and high frequency trading.
|
||||
|
||||
“With Exadata X8M, we deliver in-memory performance with all the benefits of shared storage for both OLTP and analytics,” said Juan Loaiza, executive vice president, mission-critical database technologies, Oracle.
|
||||
|
||||
“Reducing response times by an order of magnitude using direct database access to shared persistent memory accelerates every OLTP application and is a game changer for applications that need real-time access to large amounts of data such as fraud detection and personalized shopping,” the official added.
|
||||
|
||||
**What’s unique about it?**
|
||||
|
||||
Oracle Exadata X8M uses RDMA directly from the database to access persistent memory in smart storage servers, bypassing the entire OS, IO and network software stacks. This results in lower latency and higher throughput. Using RDMA to bypass software stacks also frees CPU resources on storage servers to execute more Smart Scan queries in support of analytics workloads.
|
||||
|
||||
**No More Storage Bottlenecks**
|
||||
|
||||
“High-performance OLTP applications require a demanding mixture of high Input/Output Operations Per Second (IOPS) with low latency. Direct database access to shared persistent memory increases peak performance to 16 million SQL read IOPS, 2.5X greater than the industry leading Exadata X8,” Oracle said in a statement.
|
||||
|
||||
Additionally, Exadata X8M dramatically reduces the latency of critical database IOs by enabling remote IO latencies below 19 microseconds – more than 10X faster than the Exadata X8. These ultra-low latencies are achieved even for workloads requiring millions of IOs per second.
|
||||
|
||||
**More Efficient Better than AWS and Azure**
|
||||
|
||||
The company claimed that compared to the fastest Amazon RDS storage for Oracle, Exadata X8M delivers up to 50X lower latency, 200X more IOPS and 15X more capacity.
|
||||
|
||||
Compared to Azure SQL Database Service storage, it says, Exadata X8M delivers 100X lower latency, 150X more IOPS and 300X more capacity.
|
||||
|
||||
According to oracle, a single rack Exadata X8M delivers up to 2X the OLTP read IOPS, 3X the throughput and 5X lower latency than shared storage systems with persistent memory such as a single rack of Dell EMC PowerMax 8000.
|
||||
|
||||
“By simultaneously supporting faster OLTP queries and greater throughput for analytics workloads, Exadata X8M is the ideal platform on which to converge mixed-workload environments to decrease IT costs and complexity,” it said.
|
||||
|
||||
**Oracle Zero Data Loss Recovery Appliance X8**
|
||||
|
||||
Oracle today also announced availability of Oracle Zero Data Loss Recovery Appliance X8M (ZDLRA), which uses new 100Gb RoCE for high throughput internal data transfers between compute and storage servers.
|
||||
|
||||
Exadata and ZDLRA customers can now choose between RoCE or InfiniBand-based Engineered Systems for optimal flexibility in their architectural deployments.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensourceforu.com/2019/09/oracle-unleashes-worlds-fastest-database-machine-exadata-x8m/
|
||||
|
||||
作者:[Longjam Dineshwori][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://opensourceforu.com/author/dineshwori-longjam/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://i2.wp.com/opensourceforu.com/wp-content/uploads/2019/02/Oracle-Cloud.jpg?resize=350%2C212&ssl=1
|
@ -0,0 +1,107 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Election fraud: Is there an open source solution?)
|
||||
[#]: via: (https://opensource.com/article/19/9/voting-fraud-open-source-solution)
|
||||
[#]: author: (Jeff Macharyas https://opensource.com/users/jeffmacharyashttps://opensource.com/users/mbrownhttps://opensource.com/users/luis-ibanezhttps://opensource.com/users/jhibbets)
|
||||
|
||||
Election fraud: Is there an open source solution?
|
||||
======
|
||||
The Trust The Vote project is developing open source technology to help
|
||||
keep elections honest.
|
||||
![Team checklist][1]
|
||||
|
||||
Can open source technology help keep our elections honest? With its [Trust The Vote Project][2], the [Open Source Election Technology (OSET) Institute][3] is working on making that a reality for elections in the United States and around the world.
|
||||
|
||||
The project is developing an open, adaptable, flexible, full-featured, and innovative elections technology platform called [ElectOS][4]. It will support all aspects of elections administration and voting, including creating, marking, casting, and counting ballots and managing all back-office functions. The software is freely available under an Open Source Initiative (OSI)-recognized public license for adoption, adaptation, and deployment by anyone, including elections jurisdictions directly or, more commonly, commercial vendors or systems integrators.
|
||||
|
||||
With elections coming under more and more scrutiny due to vulnerable designs, aging machinery, hacking, foreign influence, and human incompetence, the OSET Institute is working on technology that will help ensure that every vote is counted as it was cast.
|
||||
|
||||
### Mississippi churning
|
||||
|
||||
The Mississippi Republican gubernatorial primary in August 2019 was called into question when a voting machine malfunctioned, denying a vote for candidate Bill Waller as the machine changed it to his opponent, Tate Reeves. The incident was [caught on camera][5].
|
||||
|
||||
"Around 40 states have voting machines that are a decade old or older," J. Alex Halderman, a computer science professor at the University of Michigan, tells [Politifact][6]. "There are reports of machines misbehaving in this manner after almost every election." That's rather alarming. Can open source be a solution to this problem?
|
||||
|
||||
The OSET Institute was founded in January 2007 by venture capital advisers who are alumni of Apple, Mozilla, Netscape, and Sun Microsystems. It is a non-partisan, non-profit 501(c)3 organization that researches and designs public technology—open source technology—for use in the US and around the world.
|
||||
|
||||
"For a long time, there have been systemic problems—market malformation and dysfunction—in the election industry. Due to market dynamics and industry performance issues, there has been no commercial incentive to make the investment in the necessary research and development to produce the kind of high-assurance, mission-critical systems for verifiable and accurate elections," says Gregory Miller, co-founder and COO of the OSET Institute.
|
||||
|
||||
Reflecting back to the 2000 presidential election between Vice President Al Gore and Texas Governor George W. Bush, Miller says: "Nobody was thinking about digital attacks during the ['chadfest' of Florida][7] and even as recently as 2007." Miller adds that one of the most important aspects of public technology is that it must be entirely trustworthy.
|
||||
|
||||
### Essential election technologies
|
||||
|
||||
Most voting systems in use are based around proprietary, black-box hardware and software built on 1990s technology—Windows 2000 or older. Some newer machines are running Windows 7—which is scheduled to lose maintenance and support in January 2020.
|
||||
|
||||
Miller says there are two crucial parts of the election process: the election administration systems and the voting systems.
|
||||
|
||||
* Election administration systems in the back office are responsible for elections setup, administration, and operation, especially casting and counting ballots; voter registration; ballot design, layout, and distribution; poll-book configuration; ballot-marking device configuration; and election results reporting and analytics.
|
||||
* Voting systems are simply the ballot marking, casting, and counting components.
|
||||
|
||||
|
||||
|
||||
The most important element of the system is the bridge between the voting systems in polling places and the back-office administration systems. This behind-the-scenes process aggregates vote tallies into tabulations to determine the results.
|
||||
|
||||
The key device—and arguably the Achilles Heel of the entire ecosystem—is the election management system (EMS), which is the connection between election administration and the voting systems. The EMS machine is a back-office element but also a component of the voting system. Because the EMS software typically resides on a desktop machine used for a variety of government functions that serve citizens, it is the element most vulnerable to attacks.
|
||||
|
||||
Despite the vote-changing problem in the Mississippi primary, Miller warns, "the vulnerability of attack is not to the voting machinery in the polling place but to the tabulation component of the back-office EMS or other vital configuration tools, including the configuration of poll books (those stacks of papers, binders, or … apps that check a voter in to cast a ballot). As a result, attackers need only to find a highly contentious swing state precinct to be disruptive."
|
||||
|
||||
### Code causes change
|
||||
|
||||
Because voting security vulnerabilities are largely software-based, "code causes change," Miller declares. But, there are barriers to getting this done in time for the next US presidential election in November 2020. Foremost is the fact that there is little time left for OSET's team of 12 full-time people to finish the core voting platform and create separate EMS and voting system components, all based on a non-black box, non-proprietary model that uses public, open source technology with off-the-shelf hardware.
|
||||
|
||||
However, there is a lot more to do in addition to developing code for off-the-shelf hardware. OSET is developing new open data standards with NIST and the Elections Assistance Commission (EAC). A new component-based certification process must be invented, and new design guidelines must be issued.
|
||||
|
||||
Meanwhile, service contracts that last for decades or more are protecting legacy vendors and making migration to new systems a challenge. Miller explains, "there are three primary vendors that control 85% of voting systems in the US and 70% globally; with the barriers to entry that exist, it will take a finished system to display the opportunity for change."
|
||||
|
||||
Getting there with open code is a process too. Miller says, "there is a very closely managed code-commit process, and the work faces far more scrutiny than an open source operating system, web server, or [content management system]. So, we are implementing a dual-sandbox model where one allows for wide-ranging, free-wheeling development and contributions. The other is the controlled environment that must pass security muster with the federal government in order for states to feel confident that the actual code for production systems is verifiable, accurate, secure, and transparent. We'll use a process for [passing] code across a review membrane that enables work in the less secure environment to be committed to the production environment. It's a process still in design."
|
||||
|
||||
The licenses are a bit complex: for governments or vendors that have regulatory issues with procuring and deploying commercial systems comprised of open source software, commercial hardware, and professional services, OSET offers the OSET Public License (OPL), an OSI-approved open source license based on the Mozilla Public License. For other research, development, and non-commercial use, or commercial use where certain procurement regulations are not an issue, the code is available under the GPL 2.0 license.
|
||||
|
||||
Of OSET's activities, Miller says, "85% is code development—a democracy software foundry. Another 10% is cybersecurity advisory for election administrators, and the final 5% of OSET's activity is public policy work (we are informers, not influencers in legislation). As a 501(c)3, we can not—and do not—perform lobbying, but a portion of our mission is education. So, our work remains steadfastly nonpartisan and philanthropically funded by grant-making organizations and the public.
|
||||
|
||||
Explains Miller: "We have a fairly straightforward charter: to build a trustworthy codebase that can exist on an inherently untrustworthy hardware base. Certain types of election administration apps and services can live in the cloud, while the voting system—a marriage of that software layer and hardware, federally certified to be deployed—must be built up from a hardened Linux kernel. So, a portion of our R&D lies in the arenas of trusted boot with hardware attestation and other important security architectures such as computer-assisted code randomization and so forth."
|
||||
|
||||
### Work with the code
|
||||
|
||||
There are two levels of access for people who want to work with the OSET Institute's Trust the Vote code. One is to contact the project to request access to certain code to advance development efforts; all legitimate requests will be honored, but the code is not yet accessible in the public domain. The other access point is to the extensive work that the OSET Institute has done for third-party voter registration systems, such as Rock The Vote. That source code is publicly available [online][8].
|
||||
|
||||
One component of this is [RockyOVR][9] for online voter registration services (it is operated by the OSET Institute and Rock The Vote with support from AWS). Another is [Grommet][10], an Android-native mobile app used by voter registration drives. [Siggy][11] and [VoteReady][12] are prototypes for new voter services under development that will be announced soon.
|
||||
|
||||
The OSET Institute is continually on the lookout for talented volunteers to advance the project. Top needs include system architecture and engineering and software development for both cloud-based and offline applications. These are not entry-level projects or positions, and in some cases, they require advanced skills in BIOS and firmware development; operating system internals; device drivers; and more.
|
||||
|
||||
All developers at the OSET Institute start as volunteers, and the best are moved into contract and staff positions, as project funding allows, in a meritocratic process. The Institute is based in Palo Alto, Calif., but operations are distributed and virtual with offices and centers of development excellence in Arlington, Va.; Boston; Mountain View, Calif.; Portland, Ore.; San Francisco; and the University of Edinburgh, Scotland.
|
||||
|
||||
The Open Election Data Initiative wants to give access to election data for a true picture of an...
|
||||
|
||||
The pernicious effects of closed proprietary software reaches its peak of damaging the general...
|
||||
|
||||
One of the ways Obama won the 2012 election was with technology. It wasn’t the only way, but...
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/19/9/voting-fraud-open-source-solution
|
||||
|
||||
作者:[Jeff Macharyas][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/jeffmacharyashttps://opensource.com/users/mbrownhttps://opensource.com/users/luis-ibanezhttps://opensource.com/users/jhibbets
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/checklist_todo_clock_time_team.png?itok=1z528Q0y (Team checklist)
|
||||
[2]: https://trustthevote.org/
|
||||
[3]: https://www.osetfoundation.org/
|
||||
[4]: https://bit.ly/EOSt1
|
||||
[5]: https://twitter.com/STaylorRayburn/status/1166347828152680449
|
||||
[6]: https://www.politifact.com/truth-o-meter/article/2019/aug/29/viral-video-voting-machine-malfunction-mississippi/
|
||||
[7]: https://en.wikipedia.org/wiki/2000_United_States_presidential_election_in_Florida
|
||||
[8]: https://github.com/TrustTheVote-Project
|
||||
[9]: https://github.com/TrustTheVote-Project/Rocky-OVR
|
||||
[10]: https://github.com/TrustTheVote-Project/Grommet
|
||||
[11]: https://github.com/TrustTheVote-Project/Siggy
|
||||
[12]: https://github.com/TrustTheVote-Project/VoteReady
|
@ -0,0 +1,79 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (The community-led renaissance of open source)
|
||||
[#]: via: (https://opensource.com/article/19/9/community-led-renaissance)
|
||||
[#]: author: (Donald Fischer https://opensource.com/users/dff)
|
||||
|
||||
The community-led renaissance of open source
|
||||
======
|
||||
Moving beyond the scarcity mindset of "open core."
|
||||
![shapes of people symbols][1]
|
||||
|
||||
With few commercial participants, early free software and open source communities were, by definition, community-led. Software was designed and created organically by communities of users in response to their needs and inspiration. The results, to a degree nobody predicted, were often magical.
|
||||
|
||||
However, there were some missing pieces that prevented this magic from being unleashed at greater scale. As professional developers in larger organizations began to depend on open source software for key functions, they started looking for the same kinds of commercial support they were used to having for the proprietary software they purchased from companies like Microsoft, Oracle, and SAP. Someone to be accountable for fixing a new security vulnerability in a timely manner, or providing basic intellectual property assurances such as license verification and indemnification, or just delivering the everyday maintenance necessary to keep the software in good working order.
|
||||
|
||||
First-generation open source businesses like Red Hat emerged to respond to these needs. They combined the best of both worlds: the flexibility and control of raw open source with the commercial support that enterprises depend on. These new open source businesses found their opportunity by _adding_ the missing—but necessary—commercial services to community-led open source projects. These services would be costly for organizations to provide on their own and potentially even more costly to do without. One early leader of that era, Cygnus Solutions, even adopted the counter-intuitive tagline "Making free software affordable."
|
||||
|
||||
But back then, it was always overwhelmingly clear: The commercial vendors were in service of the community, filling in around the edges to enable commercial applications. The community was the star, and the companies were the supporting cast.
|
||||
|
||||
### The dark ages of open core
|
||||
|
||||
With the success of the original commercial open source companies like Red Hat, investment dollars flowed toward startups looking to harness the newfound commercial power of open source.
|
||||
|
||||
Unfortunately, by and large, this generation of open source companies drew the wrong lessons from first-generation players like Red Hat.
|
||||
|
||||
Witnessing the powerful combination of community-created technology with vendor-provided commercial capabilities, this new breed of company concluded that the vendors were the stars of the show, not the community.
|
||||
|
||||
This marked a turning point for open source.
|
||||
|
||||
In this vendor-centric view of the world, it was imagined that a single organization could generate the insights and set the roadmap for open source technologies. This drove a pervasive new belief that open source communities primarily represented a capital-efficient marketing channel rather than a new form of internet-enabled co-creation.
|
||||
|
||||
These companies approached open source with a scarcity mindset. Instead of investing in community-led projects to unlock the potential of the crowd, they created vendor-dominated projects, released demo versions under open source licenses, and directed the bulk of their resources to companion proprietary technology that they withheld as paid-only, closed-source products. By reverting to some of [the worst aspects of traditional proprietary software][2]—like uncertain licensing terms, unclear support horizons, and unknowable cost—these businesses crowded out the best aspects of open source.
|
||||
|
||||
As so often happens, this misreading of the open source model took on a new life when it was assigned an innocent-sounding brand name: "open core."
|
||||
|
||||
The open core dog chased its tail into an escalating flurry of blog posts, pitch decks, and even dedicated open core conferences. In its worst moments, leading players in this movement even [sought to redefine the very meaning of the words open source][3].
|
||||
|
||||
In the worldview of open core, the vendors are at the center of the universe, and open source users are just a commodity to be exploited.
|
||||
|
||||
### A community-led renaissance to restore balance
|
||||
|
||||
While business interests whipped themselves into a frenzy around open core, the community of creators at the heart of open source just kept on building. While a handful of high-profile companies occupied the industry headlines, thousands of individual creators and teams kept on building software, one pull request at a time.
|
||||
|
||||
It added up. Today, the modern application development platform isn't from a single vendor, or even a collection of vendors. It's the union of thousands of discrete open source packages—implemented in languages like JavaScript, Python, PHP, Ruby, Java, Go, .NET, Rust, R, and many others. Each element built for its own purpose, but together creating a beautiful tapestry that has become the foundation of all modern applications.
|
||||
|
||||
In some cases, the creators behind these projects are assisted by organizations that arose naturally from the communities, like Ruby Together, the Apache Software Foundation, and the Python Software Foundation. But by and large, these creators are self-supported, making time in the margins of their day jobs and central pursuits to collaborate on the software that makes their work possible while collectively building a huge commons of open source software that's available for any individual or organization to use.
|
||||
|
||||
But now, there's an emerging way for open source maintainers to participate in the value they create, which isn't about withholding value, but instead is about [creating _additional_ value][4].
|
||||
|
||||
In a revival and expansion of the principles that drove the first generation of community-led open source commercial players, creators are now coming together in a new form of collaboration. Rather than withholding software under a different license, they're partnering with each other to provide [the same kinds of professional assurances][5] that companies such as Red Hat discovered were necessary back in the day, but for the thousands of discrete components that make up the modern development platform.
|
||||
|
||||
Today's generation of entrepreneurial open source creators is leaving behind the scarcity mindset that bore open core and its brethren. Instead, they're advancing an optimistic, additive, and still practical model that [adds missing commercial value][6] on top of raw open source.
|
||||
|
||||
And by emulating first-generation open source companies, these creators are rediscovering a wide-open opportunity for value creation that benefits everyone. As commercial organizations engage with managed open source services sourced directly from the creators themselves, there's an immediate clarity in the alignment of interests between producers and consumers.
|
||||
|
||||
The result? The end of the scarcity-mindset dark ages of open core, and a renaissance of technology driven by a new class of thriving, independent, full-time open source creators.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/19/9/community-led-renaissance
|
||||
|
||||
作者:[Donald Fischer][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/dff
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/Open%20Pharma.png?itok=GP7zqNZE (shapes of people symbols)
|
||||
[2]: https://blog.tidelift.com/the-closed-source-sustainability-crisis
|
||||
[3]: https://opensource.com/article/19/4/fauxpen-source-bad-business
|
||||
[4]: https://www.techrepublic.com/article/the-key-to-open-source-sustainability-is-good-old-fashioned-self-interest/
|
||||
[5]: https://tidelift.com/subscription/video/what-is-managed-open-source
|
||||
[6]: https://blog.tidelift.com/what-is-managed-open-source
|
@ -1,235 +0,0 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (laingke)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Create an online store with this Java-based framework)
|
||||
[#]: via: (https://opensource.com/article/19/1/scipio-erp)
|
||||
[#]: author: (Paul Piper https://opensource.com/users/madppiper)
|
||||
|
||||
Create an online store with this Java-based framework
|
||||
======
|
||||
Scipio ERP comes with a large range of applications and functionality.
|
||||
![](https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/osdc_whitehurst_money.png?itok=ls-SOzM0)
|
||||
|
||||
So you want to sell products or services online, but either can't find a fitting software or think customization would be too costly? [Scipio ERP][1] may just be what you are looking for.
|
||||
|
||||
Scipio ERP is a Java-based open source e-commerce framework that comes with a large range of applications and functionality. The project was forked from [Apache OFBiz][2] in 2014 with a clear focus on better customization and a more modern appeal. The e-commerce component is quite extensive and works in a multi-store setup, internationally, and with a wide range of product configurations, and it's also compatible with modern HTML frameworks. The software also provides standard applications for many other business cases, such as accounting, warehouse management, or sales force automation. It's all highly standardized and therefore easy to customize, which is great if you are looking for more than a virtual cart.
|
||||
|
||||
The system makes it very easy to keep up with modern web standards, too. All screens are constructed using the system's "[templating toolkit][3]," an easy-to-learn macro set that separates HTML from all applications. Because of it, every application is already standardized to the core. Sounds confusing? It really isn't—it all looks a lot like HTML, but you write a lot less of it.
|
||||
|
||||
### Initial setup
|
||||
|
||||
Before you get started, make sure you have Java 1.8 (or greater) SDK and a Git client installed. Got it? Great! Next, check out the master branch from GitHub:
|
||||
|
||||
```
|
||||
git clone https://github.com/ilscipio/scipio-erp.git
|
||||
cd scipio-erp
|
||||
git checkout master
|
||||
```
|
||||
|
||||
To set up the system, simply run **./install.sh** and select either option from the command line. Throughout development, it is best to stick to an **installation for development** (Option 1), which will also install a range of demo data. For professional installations, you can modify the initial config data ("seed data") so it will automatically set up the company and catalog data for you. By default, the system will run with an internal database, but it [can also be configured][4] with a wide range of relational databases such as PostgreSQL and MariaDB.
|
||||
|
||||
![Setup wizard][6]
|
||||
|
||||
Follow the setup wizard to complete your initial configuration,
|
||||
|
||||
Start the system with **./start.sh** and head over to **<https://localhost:8443/setup/>** to complete the configuration. If you installed with demo data, you can log in with username **admin** and password **scipio**. During the setup wizard, you can set up a company profile, accounting, a warehouse, your product catalog, your online store, and additional user profiles. Keep the website entries on the product store configuration screen for now. The system allows you to run multiple webstores with different underlying code; unless you want to do that, it is easiest to stick to the defaults.
|
||||
|
||||
Congratulations, you just installed Scipio ERP! Play around with the screens for a minute or two to get a feel for the functionality.
|
||||
|
||||
### Shortcuts
|
||||
|
||||
Before you jump into the customization, here are a few handy commands that will help you along the way:
|
||||
|
||||
* Create a shop-override: **./ant create-component-shop-override**
|
||||
* Create a new component: **./ant create-component**
|
||||
* Create a new theme component: **./ant create-theme**
|
||||
* Create admin user: **./ant create-admin-user-login**
|
||||
* Various other utility functions: **./ant -p**
|
||||
* Utility to install & update add-ons: **./git-addons help**
|
||||
|
||||
|
||||
|
||||
Also, make a mental note of the following locations:
|
||||
|
||||
* Scripts to run Scipio as a service: **/tools/scripts/**
|
||||
* Log output directory: **/runtime/logs**
|
||||
* Admin application: **<https://localhost:8443/admin/>**
|
||||
* E-commerce application: **<https://localhost:8443/shop/>**
|
||||
|
||||
|
||||
|
||||
Last, Scipio ERP structures all code in the following five major directories:
|
||||
|
||||
* Framework: framework-related sources, the application server, generic screens, and configurations
|
||||
* Applications: core applications
|
||||
* Addons: third-party extensions
|
||||
* Themes: modifies the look and feel
|
||||
* Hot-deploy: your own components
|
||||
|
||||
|
||||
|
||||
Aside from a few configurations, you will be working within the hot-deploy and themes directories.
|
||||
|
||||
### Webstore customizations
|
||||
|
||||
To really make the system your own, start thinking about [components][7]. Components are a modular approach to override, extend, and add to the system. Think of components as self-contained web modules that capture information on databases ([entity][8]), functions ([services][9]), screens ([views][10]), [events and actions][11], and web applications. Thanks to components, you can add your own code while remaining compatible with the original sources.
|
||||
|
||||
Run **./ant create-component-shop-override** and follow the steps to create your webstore component. A new directory will be created inside of the hot-deploy directory, which extends and overrides the original e-commerce application.
|
||||
|
||||
![component directory structure][13]
|
||||
|
||||
A typical component directory structure.
|
||||
|
||||
Your component will have the following directory structure:
|
||||
|
||||
* config: configurations
|
||||
* data: seed data
|
||||
* entitydef: database table definitions
|
||||
* script: Groovy script location
|
||||
* servicedef: service definitions
|
||||
* src: Java classes
|
||||
* webapp: your web application
|
||||
* widget: screen definitions
|
||||
|
||||
|
||||
|
||||
Additionally, the **ivy.xml** file allows you to add Maven libraries to the build process and the **ofbiz-component.xml** file defines the overall component and web application structure. Apart from the obvious, you will also find a **controller.xml** file inside the web apps' **WEB-INF** directory. This allows you to define request entries and connect them to events and screens. For screens alone, you can also use the built-in CMS functionality, but stick to the core mechanics first. Familiarize yourself with **/applications/shop/** before introducing changes.
|
||||
|
||||
#### Adding custom screens
|
||||
|
||||
Remember the [templating toolkit][3]? You will find it used on every screen. Think of it as a set of easy-to-learn macros that structure all content. Here's an example:
|
||||
|
||||
```
|
||||
<@section title="Title">
|
||||
<@heading id="slider">Slider</@heading>
|
||||
<@row>
|
||||
<@cell columns=6>
|
||||
<@slider id="" class="" controls=true indicator=true>
|
||||
<@slide link="#" image="https://placehold.it/800x300">Just some content…</@slide>
|
||||
<@slide title="This is a title" link="#" image="https://placehold.it/800x300"></@slide>
|
||||
</@slider>
|
||||
</@cell>
|
||||
<@cell columns=6>Second column</@cell>
|
||||
</@row>
|
||||
</@section>
|
||||
```
|
||||
|
||||
Not too difficult, right? Meanwhile, themes contain the HTML definitions and styles. This hands the power over to your front-end developers, who can define the output of each macro and otherwise stick to their own build tools for development.
|
||||
|
||||
Let's give it a quick try. First, define a request on your own webstore. You will modify the code for this. A built-in CMS is also available at **<https://localhost:8443/cms/>** , which allows you to create new templates and screens in a much more efficient way. It is fully compatible with the templating toolkit and comes with example templates that can be adopted to your preferences. But since we are trying to understand the system here, let's go with the more complicated way first.
|
||||
|
||||
Open the **[controller.xml][14]** file inside of your shop's webapp directory. The controller keeps track of request events and performs actions accordingly. The following will create a new request under **/shop/test** :
|
||||
|
||||
```
|
||||
<!-- Request Mappings -->
|
||||
<request-map uri="test">
|
||||
<security https="true" auth="false"/>
|
||||
<response name="success" type="view" value="test"/>
|
||||
</request-map>
|
||||
```
|
||||
|
||||
You can define multiple responses and, if you want, you could use an event or a service call inside the request to determine which response you may want to use. I opted for a response of type "view." A view is a rendered response; other types are request-redirects, forwards, and alike. The system comes with various renderers and allows you to determine the output later; to do so, add the following:
|
||||
|
||||
```
|
||||
<!-- View Mappings -->
|
||||
<view-map name="test" type="screen" page="component://mycomponent/widget/CommonScreens.xml#test"/>
|
||||
```
|
||||
|
||||
Replace **my-component** with your own component name. Then you can define your very first screen by adding the following inside the tags within the **widget/CommonScreens.xml** file:
|
||||
|
||||
```
|
||||
<screen name="test">
|
||||
<section>
|
||||
<actions>
|
||||
</actions>
|
||||
<widgets>
|
||||
<decorator-screen name="CommonShopAppDecorator" location="component://shop/widget/CommonScreens.xml">
|
||||
<decorator-section name="body">
|
||||
<platform-specific><html><html-template location="component://mycomponent/webapp/mycomponent/test/test.ftl"/></html></platform-specific>
|
||||
</decorator-section>
|
||||
</decorator-screen>
|
||||
</widgets>
|
||||
</section>
|
||||
</screen>
|
||||
```
|
||||
|
||||
Screens are actually quite modular and consist of multiple elements ([widgets, actions, and decorators][15]). For the sake of simplicity, leave this as it is for now, and complete the new webpage by adding your very first templating toolkit file. For that, create a new **webapp/mycomponent/test/test.ftl** file and add the following:
|
||||
|
||||
```
|
||||
<@alert type="info">Success!</@alert>
|
||||
```
|
||||
|
||||
![Custom screen][17]
|
||||
|
||||
A custom screen.
|
||||
|
||||
Open **<https://localhost:8443/shop/control/test/>** and marvel at your own accomplishments.
|
||||
|
||||
#### Custom themes
|
||||
|
||||
Modify the look and feel of the shop by creating your very own theme. All themes can be found as components inside of the themes folder. Run **./ant create-theme** to add your own.
|
||||
|
||||
![theme component layout][19]
|
||||
|
||||
A typical theme component layout.
|
||||
|
||||
Here's a list of the most important directories and files:
|
||||
|
||||
* Theme configuration: **data/*ThemeData.xml**
|
||||
* Theme-specific wrapping HTML: **includes/*.ftl**
|
||||
* Templating Toolkit HTML definition: **includes/themeTemplate.ftl**
|
||||
* CSS class definition: **includes/themeStyles.ftl**
|
||||
* CSS framework: **webapp/theme-title/***
|
||||
|
||||
|
||||
|
||||
Take a quick look at the Metro theme in the toolkit; it uses the Foundation CSS framework and makes use of all the things above. Afterwards, set up your own theme inside your newly constructed **webapp/theme-title** directory and start developing. The Foundation-shop theme is a very simple shop-specific theme implementation that you can use as a basis for your own work.
|
||||
|
||||
Voila! You have set up your own online store and are ready to customize!
|
||||
|
||||
![Finished Scipio ERP shop][21]
|
||||
|
||||
A finished shop based on Scipio ERP.
|
||||
|
||||
### What's next?
|
||||
|
||||
Scipio ERP is a powerful framework that simplifies the development of complex e-commerce applications. For a more complete understanding, check out the project [documentation][7], try the [online demo][22], or [join the community][23].
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/19/1/scipio-erp
|
||||
|
||||
作者:[Paul Piper][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/madppiper
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://www.scipioerp.com
|
||||
[2]: https://ofbiz.apache.org/
|
||||
[3]: https://www.scipioerp.com/community/developer/freemarker-macros/
|
||||
[4]: https://www.scipioerp.com/community/developer/installation-configuration/configuration/#database-configuration
|
||||
[5]: /file/419711
|
||||
[6]: https://opensource.com/sites/default/files/uploads/setup_step5_sm.jpg (Setup wizard)
|
||||
[7]: https://www.scipioerp.com/community/developer/architecture/components/
|
||||
[8]: https://www.scipioerp.com/community/developer/entities/
|
||||
[9]: https://www.scipioerp.com/community/developer/services/
|
||||
[10]: https://www.scipioerp.com/community/developer/views-requests/
|
||||
[11]: https://www.scipioerp.com/community/developer/events-actions/
|
||||
[12]: /file/419716
|
||||
[13]: https://opensource.com/sites/default/files/uploads/component_structure.jpg (component directory structure)
|
||||
[14]: https://www.scipioerp.com/community/developer/views-requests/request-controller/
|
||||
[15]: https://www.scipioerp.com/community/developer/views-requests/screen-widgets-decorators/
|
||||
[16]: /file/419721
|
||||
[17]: https://opensource.com/sites/default/files/uploads/success_screen_sm.jpg (Custom screen)
|
||||
[18]: /file/419726
|
||||
[19]: https://opensource.com/sites/default/files/uploads/theme_structure.jpg (theme component layout)
|
||||
[20]: /file/419731
|
||||
[21]: https://opensource.com/sites/default/files/uploads/finished_shop_1_sm.jpg (Finished Scipio ERP shop)
|
||||
[22]: https://www.scipioerp.com/demo/
|
||||
[23]: https://forum.scipioerp.com/
|
210
sources/tech/20190918 Adding themes and plugins to Zsh.md
Normal file
210
sources/tech/20190918 Adding themes and plugins to Zsh.md
Normal file
@ -0,0 +1,210 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Adding themes and plugins to Zsh)
|
||||
[#]: via: (https://opensource.com/article/19/9/adding-plugins-zsh)
|
||||
[#]: author: (Seth Kenlon https://opensource.com/users/sethhttps://opensource.com/users/sethhttps://opensource.com/users/sethhttps://opensource.com/users/seth)
|
||||
|
||||
Adding themes and plugins to Zsh
|
||||
======
|
||||
Expand Z-shell's capabilities with themes and plugins installed with Oh
|
||||
My Zsh.
|
||||
![Someone wearing a hardhat and carrying code ][1]
|
||||
|
||||
In my [previous article][2], I explained how to get started with [Z-shell][2] (Zsh). For some users, the most exciting thing about Zsh is its ability to adopt new themes. It's so easy to theme Zsh both because of the active community designing visuals for the shell and also because of the [Oh My Zsh][3] project, which makes it trivial to install them.
|
||||
|
||||
Theming is one of those changes you notice immediately, so if you don't feel like you changed shells when you installed Zsh, you'll definitely feel it once you've adopted one of the 100+ themes bundled with Oh My Zsh. There's a lot more to Oh My Zsh than just pretty themes, though; there are also hundreds of plugins that add features to your Z-shell environment.
|
||||
|
||||
### Installing Oh My Zsh
|
||||
|
||||
The [ohmyz.sh][3] website encourages you to install the framework by running a script over the internet from your computer. While the Oh My Zsh project is almost certainly trustworthy, it's generally ill-advised to blindly run scripts on your system. If you want to run the install script, you can download it, read it, and run it after you're satisfied you understand what it's doing.
|
||||
|
||||
If you download the script and read it, you may notice that installation is only a three-step process:
|
||||
|
||||
#### 1\. Clone oh-my-zsh
|
||||
|
||||
First, clone the oh-my-zsh repository into a directory called **~/.oh-my-zsh**:
|
||||
|
||||
|
||||
```
|
||||
`% git clone http://github.com/robbyrussell/oh-my-zsh ~/.oh-my-zsh`
|
||||
```
|
||||
|
||||
#### 2\. Switch the config file
|
||||
|
||||
Next, back up your existing **.zshrc** file and move the default one from the oh-my-zsh install into its place. You can do this in one command using the **-b** (backup) option for **mv**, as long as your version of the **mv** command includes that option:
|
||||
|
||||
|
||||
```
|
||||
% mv -b \
|
||||
~/.oh-my-zsh/templates/zshrc.zsh-template \
|
||||
~/.zshrc
|
||||
```
|
||||
|
||||
#### 3\. Edit the config
|
||||
|
||||
By default, Oh My Zsh's configuration is pretty bland, so you might want to reintegrate your custom **~/.zshrc** into the **.oh-my-zsh** config. To do that, append your old config to the end of the new one using the [cat command][4]:
|
||||
|
||||
|
||||
```
|
||||
`% cat ~/.zshrc~ >> ~/.zshrc`
|
||||
```
|
||||
|
||||
To see the default configuration and learn about some of the options it provides, open **~/.zshrc** in your favorite text editor. The file is well-commented, so it's a great way to get a good idea of what's possible.
|
||||
|
||||
For instance, you can change the location of your **.oh-my-zsh** directory. At installation, it resides at the base of your home directory, but modern Linux convention, as defined by the [Free Desktop][5] specification, is to place directories that extend the functionality of applications in the **~/.local/share** directory. You can change it in **~/.zshrc** by editing the line:
|
||||
|
||||
|
||||
```
|
||||
# Path to your oh-my-zsh installation.
|
||||
export ZSH=$HOME/.local/share/oh-my-zsh
|
||||
```
|
||||
|
||||
then moving the directory to that location:
|
||||
|
||||
|
||||
```
|
||||
% mv ~/.oh-my-zsh \
|
||||
$HOME/.local/share/oh-my-zsh
|
||||
```
|
||||
|
||||
If you're using MacOS, the specification is less clear, but arguably the most appropriate place for the directory is **$HOME/Library/Application\ Support**.
|
||||
|
||||
### Relaunching Zsh
|
||||
|
||||
After editing the config, you have to relaunch your shell. Before you do that, make sure you've finished any in-progress config changes; for instance, don't change the path of **.oh-my-zsh** then forget to move the directory to its new location. If you don't want to relaunch your shell, you can **source** the config file, just as you can with Bash:
|
||||
|
||||
|
||||
```
|
||||
% source ~/.zshrc
|
||||
➜ .oh-my-zsh git:(master) ✗
|
||||
```
|
||||
|
||||
You can ignore any warnings about missing update files; they will be resolved upon relaunch.
|
||||
|
||||
### Changing your theme
|
||||
|
||||
Installing Oh My Zsh sets your Z-shell theme to **robbyrussell**, a theme by the project's maintainer. This theme's changes are minimal, mostly involving the color of your prompt.
|
||||
|
||||
To view all the available themes, list the contents of the **.oh-my-zsh** theme directory:
|
||||
|
||||
|
||||
```
|
||||
➜ .oh-my-zsh git:(master) ✗ ls \
|
||||
~/.local/share/oh-my-zsh/themes
|
||||
3den.zsh-theme
|
||||
adben.zsh-theme
|
||||
af-magic.zsh-theme
|
||||
afowler.zsh-theme
|
||||
agnoster.zsh-theme
|
||||
[...]
|
||||
```
|
||||
|
||||
To see screenshots of themes before trying them, visit the Oh My Zsh [wiki][6]. For even more themes, visit the [External themes][7] wiki page.
|
||||
|
||||
Most themes are simple to set up and use. Just change the value of the theme name in **.zshrc** and reload the config:
|
||||
|
||||
|
||||
```
|
||||
➜ ~ sed -i \
|
||||
's/_THEME=\"robbyrussel\"/_THEME=\"linuxonly\"/g' \
|
||||
~/.zshrc
|
||||
➜ ~ source ~/.zshrc
|
||||
seth@darkstar:pts/0->/home/skenlon (0) ➜
|
||||
```
|
||||
|
||||
Other themes require extra configuration. For example, to use the **agnoster** theme, you must first install the Powerline font. This is an open source font, and it's probably in your software repository if you're running Linux. Install it with:
|
||||
|
||||
|
||||
```
|
||||
`➜ ~ sudo dnf install powerline-fonts`
|
||||
```
|
||||
|
||||
Set your theme in the config:
|
||||
|
||||
|
||||
```
|
||||
➜ ~ sed -i \
|
||||
's/_THEME=\"linuxonly\"/_THEME=\"agnoster\"/g' \
|
||||
~/.zshrc
|
||||
```
|
||||
|
||||
and then relaunch (a simple **source** won't work). Upon relaunch, you will see the new theme:
|
||||
|
||||
![agnoster theme][8]
|
||||
|
||||
### Installing plugins
|
||||
|
||||
Over 200 plugins ship with Oh My Zsh, and you can see them by looking in **.oh-my-zsh/plugins**. Each plugin directory has a README file explaining what the plugin does.
|
||||
|
||||
Some plugins are relatively simple. For instance, the **dnf**, **ubuntu**, **brew**, and **macports** plugins are collections of aliases to simplify interactions with the DNF, Apt, Homebrew, and MacPorts package managers.
|
||||
|
||||
Others are more complex. The **git** plugin, active by default, detects when you're working in a [Git repository][9] and updates your shell prompt so that it lists the current branch and even indicates whether there are unmerged changes.
|
||||
|
||||
To activate a plugin, add it to the plugin setting in **~/.zshrc**. For example, to add the **dnf** and **pass** plugins, open **~/.zshrc** in your favorite text editor:
|
||||
|
||||
|
||||
```
|
||||
`plugins=(git dnf pass)`
|
||||
```
|
||||
|
||||
Save your changes and reload your Zsh session:
|
||||
|
||||
|
||||
```
|
||||
`% source ~/.zshrc`
|
||||
```
|
||||
|
||||
The plugins are now active. You can test the **dnf** plugin by using one of the aliases it provides:
|
||||
|
||||
|
||||
```
|
||||
% dnfs fop
|
||||
====== Name Exactly Matched: fop ======
|
||||
fop.noarch : XSL-driven print formatter
|
||||
```
|
||||
|
||||
Different plugins do different things, so you may want to install only one or two at a time to help you learn the new capabilities of your shell.
|
||||
|
||||
#### Cheating
|
||||
|
||||
Some Oh My Zsh plugins are pretty generic. If you look at a plugin that claims to be a Z-shell plugin and the code is also compatible with Bash, then you can use it in your Bash shell. Some plugins require Z-shell-specific functions, so this won't work with all of them. But you can load plugins like **dnf**, **ubuntu**, **[firewalld][10]**, and others into a Bash shell by using **source** to load the plugin of your choice. For example:
|
||||
|
||||
|
||||
```
|
||||
if [ -d $HOME/.local/share/oh-my-zsh/plugins ]; then
|
||||
source $HOME/.local/share/oh-my-zsh/plugins/dnf/dnf.plugin.zsh
|
||||
fi
|
||||
```
|
||||
|
||||
### To Z or not to Z
|
||||
|
||||
Z-shell is a powerful shell both for its built-in features and the plugins contributed by its passionate community. Whether you use it as your primary shell or just as a shell you visit on weekends or holidays, you owe it to yourself to try it out.
|
||||
|
||||
What are your favorite Z-shell themes and plugins? Tell us in the comments!
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/19/9/adding-plugins-zsh
|
||||
|
||||
作者:[Seth Kenlon][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/sethhttps://opensource.com/users/sethhttps://opensource.com/users/sethhttps://opensource.com/users/seth
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/build_structure_tech_program_code_construction.png?itok=nVsiLuag (Someone wearing a hardhat and carrying code )
|
||||
[2]: https://opensource.com/article/19/9/getting-started-zsh
|
||||
[3]: https://ohmyz.sh/
|
||||
[4]: https://opensource.com/article/19/2/getting-started-cat-command
|
||||
[5]: http://freedesktop.org
|
||||
[6]: https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
|
||||
[7]: https://github.com/robbyrussell/oh-my-zsh/wiki/External-themes
|
||||
[8]: https://opensource.com/sites/default/files/uploads/zsh-agnoster.jpg (agnoster theme)
|
||||
[9]: https://opensource.com/resources/what-is-git
|
||||
[10]: https://opensource.com/article/19/7/make-linux-stronger-firewalls
|
@ -0,0 +1,114 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How to remove carriage returns from text files on Linux)
|
||||
[#]: via: (https://www.networkworld.com/article/3438857/how-to-remove-carriage-returns-from-text-files-on-linux.html)
|
||||
[#]: author: (Sandra Henry-Stocker https://www.networkworld.com/author/Sandra-Henry_Stocker/)
|
||||
|
||||
How to remove carriage returns from text files on Linux
|
||||
======
|
||||
When carriage returns (also referred to as Ctrl+M's) get on your nerves, don't fret. There are several easy ways to show them the door.
|
||||
[Kim Siever][1]
|
||||
|
||||
Carriage returns go back a long way – as far back as typewriters on which a mechanism or a lever swung the carriage that held a sheet of paper to the right so that suddenly letters were being typed on the left again. They have persevered in text files on Windows, but were never used on Linux systems. This incompatibility sometimes causes problems when you’re trying to process files on Linux that were created on Windows, but it's an issue that is very easily resolved.
|
||||
|
||||
The carriage return, also referred to as **Ctrl+M**, character would show up as an octal 15 if you were looking at the file with an **od** octal dump) command. The characters **CRLF** are often used to represent the carriage return and linefeed sequence that ends lines on Windows text files. Those who like to gaze at octal dumps will spot the **\r \n**. Linux text files, by comparison, end with just linefeeds.
|
||||
|
||||
**[ Two-Minute Linux Tips: [Learn how to master a host of Linux commands in these 2-minute video tutorials][2] ]**
|
||||
|
||||
Here's a sample of **od** output with the lines containing the **CRLF** characters in both octal and character form highlighted.
|
||||
|
||||
```
|
||||
$ od -bc testfile.txt
|
||||
0000000 124 150 151 163 040 151 163 040 141 040 164 145 163 164 040 146
|
||||
T h i s i s a t e s t f
|
||||
0000020 151 154 145 040 146 162 157 155 040 127 151 156 144 157 167 163
|
||||
i l e f r o m W i n d o w s
|
||||
0000040 056 015 012 111 164 047 163 040 144 151 146 146 145 162 145 156 <==
|
||||
. \r \n I t ' s d i f f e r e n <==
|
||||
0000060 164 040 164 150 141 156 040 141 040 125 156 151 170 040 164 145
|
||||
t t h a n a U n i x t e
|
||||
0000100 170 164 040 146 151 154 145 015 012 167 157 165 154 144 040 142 <==
|
||||
x t f i l e \r \n w o u l d b <==
|
||||
```
|
||||
|
||||
While these characters don’t represent a huge problem, they can sometimes interfere when you want to parse the text files in some way and don’t want to have to code around their presence or absence.
|
||||
|
||||
### 3 ways to remove carriage return characters from text files
|
||||
|
||||
Fortunately, there are several ways to easily remove carriage return characters. Here are three options:
|
||||
|
||||
#### dos2unix
|
||||
|
||||
You might need to go through the trouble of installing it, but **dos2unix** is probably the easiest way to turn Windows text files into Unix/Linux text files. One command with one argument, and you’re done. No second file name is required. The file will be changed in place.
|
||||
|
||||
```
|
||||
$ dos2unix testfile.txt
|
||||
dos2unix: converting file testfile.txt to Unix format...
|
||||
```
|
||||
|
||||
You should see the file length decrease, depending on how many lines it contains. A file with 100 lines would likely shrink by 99 characters, since only the last line will not end with the **CRLF** characters.
|
||||
|
||||
Before:
|
||||
|
||||
```
|
||||
-rw-rw-r-- 1 shs shs 121 Sep 14 19:11 testfile.txt
|
||||
```
|
||||
|
||||
After:
|
||||
|
||||
```
|
||||
-rw-rw-r-- 1 shs shs 118 Sep 14 19:12 testfile.txt
|
||||
```
|
||||
|
||||
If you need to convert a large collection of files, don't fix them one at a time. Instead, put them all in a directory by themselves and run a command like this:
|
||||
|
||||
```
|
||||
$ find . -type f -exec dos2unix {} \;
|
||||
```
|
||||
|
||||
In this command, we use find to locate regular files and then run the **dos2unix** command to convert them one at a time. The {} in the command is replaced by the filename. You should be sitting in the directory with the files when you run it. This command could damage other types of files, such as those that contain octal 15 characters in some context other than a text file (e.g., bytes in an image file).
|
||||
|
||||
#### sed
|
||||
|
||||
You can also use **sed**, the stream editor, to remove carriage returns. You will, however, have to supply a second file name. Here’s an example:
|
||||
|
||||
```
|
||||
$ sed -e “s/^M//” before.txt > after.txt
|
||||
```
|
||||
|
||||
One important thing to note is that you DON’T type what that command appears to be. You must enter **^M** by typing **Ctrl+V** followed by **Ctrl+M**. The “s” is the substitute command. The slashes separate the text we’re looking for (the Ctrl+M) and the text (nothing in this case) that we’re replacing it with.
|
||||
|
||||
#### vi
|
||||
|
||||
You can even remove carriage return (**Ctrl+M**) characters with **vi**, although this assumes you’re not running through hundreds of files and are maybe making some other changes, as well. You would type “**:**” to go to the command line and then type the string shown below. As with **sed**, the **^M** portion of this command requires typing **Ctrl+V** to get the **^** and then **Ctrl+M** to insert the **M**. The **%s** is a substitute operation, the slashes again separate the characters we want to remove and the text (nothing) we want to replace it with. The “**g**” (global) means to do this on every line in the file.
|
||||
|
||||
```
|
||||
:%s/^M//g
|
||||
```
|
||||
|
||||
#### Wrap-up
|
||||
|
||||
The **dos2unix** command is probably the easiest to remember and most reliable way to remove carriage returns from text files. Other options are a little trickier to use, but they provide the same basic function.
|
||||
|
||||
Join the Network World communities on [Facebook][3] and [LinkedIn][4] to comment on topics that are top of mind.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://www.networkworld.com/article/3438857/how-to-remove-carriage-returns-from-text-files-on-linux.html
|
||||
|
||||
作者:[Sandra Henry-Stocker][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://www.networkworld.com/author/Sandra-Henry_Stocker/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://www.flickr.com/photos/kmsiever/5895380540/in/photolist-9YXnf5-cNmpxq-2KEvib-rfecPZ-9snnkJ-2KAcDR-dTxzKW-6WdgaG-6H5i46-2KzTZX-7cnSw7-e3bUdi-a9meh9-Zm3pD-xiFhs-9Hz6YM-ar4DEx-4PXAhw-9wR4jC-cihLcs-asRFJc-9ueXvG-aoWwHq-atwL3T-ai89xS-dgnntH-5en8Te-dMUDd9-aSQVn-dyZqij-cg4SeS-abygkg-f2umXt-Xk129E-4YAeNn-abB6Hb-9313Wk-f9Tot-92Yfva-2KA7Sv-awSCtG-2KDPzb-eoPN6w-FE9oi-5VhaNf-eoQgx7-eoQogA-9ZWoYU-7dTGdG-5B1aSS
|
||||
[2]: https://www.youtube.com/playlist?list=PL7D2RMSmRO9J8OTpjFECi8DJiTQdd4hua
|
||||
[3]: https://www.facebook.com/NetworkWorld/
|
||||
[4]: https://www.linkedin.com/company/network-world
|
@ -0,0 +1,235 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (laingke)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Create an online store with this Java-based framework)
|
||||
[#]: via: (https://opensource.com/article/19/1/scipio-erp)
|
||||
[#]: author: (Paul Piper https://opensource.com/users/madppiper)
|
||||
|
||||
使用这个 Java 框架创建一个在线商店
|
||||
======
|
||||
Scipio ERP 具有广泛的应用程序和功能。
|
||||
![](https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/osdc_whitehurst_money.png?itok=ls-SOzM0)
|
||||
|
||||
所以,你想在网上销售产品或服务,但要么找不到合适的软件,要么认为定制成本太高? [Scipio ERP][1] 也许正是你想要的。
|
||||
|
||||
Scipio ERP 是一个基于 Java 的开放源码电子商务框架,具有广泛的应用程序和功能。这个项目在 2014 年从 [Apache OFBiz][2] fork 而来,侧重于更好的定制和更现代的吸引力。这个电子商务组件应用非常广泛,可以在多商店安装中工作,同时完成国际化,并具有广泛的产品配置,而且它还兼容现代 HTML 框架。该软件还为许多其他业务案例提供标准应用程序,例如会计,仓库管理或销售人员自动化。它都是高度标准化的,因此易于定制,如果您想要的不仅仅是一个虚拟购物车,这是非常棒的。
|
||||
|
||||
该系统也使得跟上现代 web 标准变得非常容易。所有界面都是使用系统的“[模板工具包][3]”构建的,这是一个易于学习的宏集,可以将 HTML 与所有应用程序分开。正因为如此,每个应用程序都已经标准化到核心。听起来令人困惑?它真的不是——它看起来很像 HTML,但你写的内容少了很多。
|
||||
|
||||
### 初始安装
|
||||
|
||||
在您开始之前,请确保您已经安装了 Java 1.8(或更高版本)的 SDK 以及一个 Git 客户端。完成了?太棒了!接下来,切换到 Github 上的主分支:
|
||||
|
||||
```
|
||||
git clone https://github.com/ilscipio/scipio-erp.git
|
||||
cd scipio-erp
|
||||
git checkout master
|
||||
```
|
||||
|
||||
要安装系统,只需要运行 **./install.sh** 并从命令行中选择任一选项。在开发过程中,最好一直使用 **installation for development** (选项 1),它还将安装一系列演示数据。对于专业安装,您可以修改初始配置数据(“种子数据”),以便自动为您设置公司和目录数据。默认情况下,系统将使用内部数据库运行,但是它[也可以配置][4]使用各种关系数据库,比如 PostgreSQL 和 MariaDB 等。
|
||||
|
||||
![安装向导][6]
|
||||
|
||||
按照安装向导完成初始配置,
|
||||
|
||||
通过命令 **./start.sh** 启动系统然后打开链接 **<https://localhost:8443/setup/>** 完成配置。如果您安装了演示数据, 您可以使用用户名 **admin** 和密码 **scipio** 进行登录。在安装向导中,您可以设置公司简介、会计、仓库、产品目录、在线商店和额外的用户配置信息。暂时在产品商店配置界面上跳过网站实体的配置。系统允许您使用不同的底层代码运行多个在线商店;除非您想这样做,一直选择默认值是最简单的。
|
||||
|
||||
祝贺您,您刚刚安装了 Scipio ERP!在界面上操作一两分钟,感受一下它的功能。
|
||||
|
||||
### 捷径
|
||||
|
||||
在您进入自定义之前,这里有一些方便的命令可以帮助您:
|
||||
|
||||
* 创建一个 shop-override:**./ant create-component-shop-override**
|
||||
* 创建一个新组件:**./ant create-component**
|
||||
* 创建一个新主题组件:**./ant create-theme**
|
||||
* 创建管理员用户:**./ant create-admin-user-login**
|
||||
* 各种其他实用功能:**./ant -p**
|
||||
* 用于安装和更新插件的实用程序:**./git-addons help**
|
||||
|
||||
|
||||
|
||||
另外,请记下以下位置:
|
||||
|
||||
* 将 Scipio 作为服务运行的脚本:**/tools/scripts/**
|
||||
* 日志输出目录:**/runtime/logs**
|
||||
* 管理应用程序:**<https://localhost:8443/admin/>**
|
||||
* 电子商务应用程序:**<https://localhost:8443/shop/>**
|
||||
|
||||
|
||||
|
||||
最后,Scipio ERP 在以下五个主要目录中构建了所有代码:
|
||||
|
||||
* Framework: 框架相关的源,应用程序服务器,通用界面和配置
|
||||
* Applications: 核心应用程序
|
||||
* Addons: 第三方扩展
|
||||
* Themes: 修改界面外观
|
||||
* Hot-deploy: 您自己的组件
|
||||
|
||||
|
||||
|
||||
除了一些配置,您将在 hot-deploy 和 themes 目录中工作。
|
||||
|
||||
### 在线商店定制
|
||||
|
||||
要真正使系统成为您自己的系统,请开始考虑使用[组件][7]。组件是一种模块化方法,可以覆盖,扩展和添加到系统中。您可以将组件视为可以捕获有关数据库([实体][8]),功能([服务][9]),界面([视图][10]),[事件和操作][11]和 Web 应用程序信息的独立 Web 模块。由于组件功能,您可以添加自己的代码,同时保持与原始源兼容。
|
||||
|
||||
运行命令 **./ant create-component-shop-override** 并按照步骤创建您的在线商店组件。该操作将会在 hot-deploy 目录内创建一个新目录,该目录将扩展并覆盖原始的电子商务应用程序。
|
||||
|
||||
![组件目录结构][13]
|
||||
|
||||
一个典型的组件目录结构。
|
||||
|
||||
您的组件将具有以下目录结构:
|
||||
|
||||
* config: 配置
|
||||
* data: 种子数据
|
||||
* entitydef: 数据库表定义
|
||||
* script: Groovy 脚本的位置
|
||||
* servicedef: 服务定义
|
||||
* src: Java 类
|
||||
* webapp: 您的 web 应用程序
|
||||
* widget: 界面定义
|
||||
|
||||
|
||||
|
||||
此外,**ivy.xml** 文件允许您将 Maven 库添加到构建过程中,**ofbiz-component.xml** 文件定义整个组件和 Web 应用程序结构。除了一些在当前目录所能够看到的,您还可以在 Web 应用程序的 **WEB-INF** 目录中找到 **controller.xml** 文件。这允许您定义请求实体并将它们连接到事件和界面。仅对于界面来说,您还可以使用内置的 CMS 功能,但优先要坚持使用核心机制。在引入更改之前,请熟悉**/applications/shop/**。
|
||||
|
||||
#### 添加自定义界面
|
||||
|
||||
还记得[模板工具包][3]吗?您会发现它在每个界面都有使用到。您可以将其视为一组易于学习的宏,它用来构建所有内容。下面是一个例子:
|
||||
|
||||
```
|
||||
<@section title="Title">
|
||||
<@heading id="slider">Slider</@heading>
|
||||
<@row>
|
||||
<@cell columns=6>
|
||||
<@slider id="" class="" controls=true indicator=true>
|
||||
<@slide link="#" image="https://placehold.it/800x300">Just some content…</@slide>
|
||||
<@slide title="This is a title" link="#" image="https://placehold.it/800x300"></@slide>
|
||||
</@slider>
|
||||
</@cell>
|
||||
<@cell columns=6>Second column</@cell>
|
||||
</@row>
|
||||
</@section>
|
||||
```
|
||||
|
||||
不是很难,对吧?同时,主题包含 HTML 定义和样式。这将权力交给您的前端开发人员,他们可以定义每个宏的输出,并坚持使用自己的构建工具进行开发。
|
||||
|
||||
我们快点试试吧。首先,在您自己的在线商店上定义一个请求。您将修改此代码。一个内置的 CMS 系统也可以通过 **<https://localhost:8443/cms/>** 进行访问,它允许您以更有效的方式创建新模板和界面。它与模板工具包完全兼容,并附带可根据您的喜好采用的示例模板。但是既然我们试图在这里理解系统,那么首先让我们采用更复杂的方法。
|
||||
|
||||
打开您商店 webapp 目录中的 **[controller.xml][14]** 文件。Controller 跟踪请求事件并相应地执行操作。下面的操作将会在 **/shop/test** 下创建一个新的请求:
|
||||
|
||||
```
|
||||
<!-- Request Mappings -->
|
||||
<request-map uri="test">
|
||||
<security https="true" auth="false"/>
|
||||
<response name="success" type="view" value="test"/>
|
||||
</request-map>
|
||||
```
|
||||
|
||||
您可以定义多个响应,如果需要,可以在请求中使用事件或服务调用来确定您可能要使用的响应。我选择了“视图”类型的响应。视图是渲染的响应; 其他类型是请求重定向,转发等。系统附带各种渲染器,可让您稍后确定输出; 为此,请添加以下内容:
|
||||
|
||||
```
|
||||
<!-- View Mappings -->
|
||||
<view-map name="test" type="screen" page="component://mycomponent/widget/CommonScreens.xml#test"/>
|
||||
```
|
||||
|
||||
用您自己的组件名称替换 **my-component**。然后,您可以通过在 **widget/CommonScreens.xml** 文件的标签内添加以下内容来定义您的第一个界面:
|
||||
|
||||
```
|
||||
<screen name="test">
|
||||
<section>
|
||||
<actions>
|
||||
</actions>
|
||||
<widgets>
|
||||
<decorator-screen name="CommonShopAppDecorator" location="component://shop/widget/CommonScreens.xml">
|
||||
<decorator-section name="body">
|
||||
<platform-specific><html><html-template location="component://mycomponent/webapp/mycomponent/test/test.ftl"/></html></platform-specific>
|
||||
</decorator-section>
|
||||
</decorator-screen>
|
||||
</widgets>
|
||||
</section>
|
||||
</screen>
|
||||
```
|
||||
|
||||
商店界面实际上非常模块化,由多个元素组成([小部件,动作和装饰器][15])。为简单起见,请暂时保留原样,并通过添加第一个模板工具包文件来完成新网页。为此,创建一个新的 **webapp/mycomponent/test/test.ftl** 文件并添加以下内容:
|
||||
|
||||
```
|
||||
<@alert type="info">Success!</@alert>
|
||||
```
|
||||
|
||||
![自定义的界面][17]
|
||||
|
||||
一个自定义的界面。
|
||||
|
||||
打开 **<https://localhost:8443/shop/control/test/>** 并惊叹于你自己的成就。
|
||||
|
||||
#### 自定义主题
|
||||
|
||||
通过创建自己的主题来修改商店的界面外观。所有主题都可以作为组件在themes文件夹中找到。运行命令 **./ant create-theme** 来创建您自己的主题。
|
||||
|
||||
![主题组件布局][19]
|
||||
|
||||
一个典型的主题组件布局。
|
||||
|
||||
以下是最重要的目录和文件列表:
|
||||
|
||||
* 主题配置:**data/\*ThemeData.xml**
|
||||
* 特定主题封装的HTML:**includes/\*.ftl**
|
||||
* 模板工具包HTML定义:**includes/themeTemplate.ftl**
|
||||
* CSS 类定义:**includes/themeStyles.ftl**
|
||||
* CSS 框架: **webapp/theme-title/**
|
||||
|
||||
|
||||
|
||||
快速浏览工具包中的 Metro 主题;它使用 Foundation CSS 框架并且充分利用了这个框架。然后,然后,在新构建的 **webapp/theme-title** 目录中设置自己的主题并开始开发。Foundation-shop 主题是一个非常简单的特定于商店的主题实现,您可以将其用作您自己工作的基础。
|
||||
|
||||
瞧!您已经建立了自己的在线商店,准备个性化定制吧!
|
||||
|
||||
![搭建完成的 Scipio ERP 在线商店][21]
|
||||
|
||||
一个搭建完成的基于 Scipio ERP的在线商店。
|
||||
|
||||
### 接下来是什么?
|
||||
|
||||
Scipio ERP 是一个功能强大的框架,可简化复杂的电子商务应用程序的开发。为了更完整的理解,请查看项目[文档][7],尝试[在线演示][22],或者[加入社区][23].
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/19/1/scipio-erp
|
||||
|
||||
作者:[Paul Piper][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[laingke](https://github.com/laingke)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://opensource.com/users/madppiper
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://www.scipioerp.com
|
||||
[2]: https://ofbiz.apache.org/
|
||||
[3]: https://www.scipioerp.com/community/developer/freemarker-macros/
|
||||
[4]: https://www.scipioerp.com/community/developer/installation-configuration/configuration/#database-configuration
|
||||
[5]: /file/419711
|
||||
[6]: https://opensource.com/sites/default/files/uploads/setup_step5_sm.jpg (Setup wizard)
|
||||
[7]: https://www.scipioerp.com/community/developer/architecture/components/
|
||||
[8]: https://www.scipioerp.com/community/developer/entities/
|
||||
[9]: https://www.scipioerp.com/community/developer/services/
|
||||
[10]: https://www.scipioerp.com/community/developer/views-requests/
|
||||
[11]: https://www.scipioerp.com/community/developer/events-actions/
|
||||
[12]: /file/419716
|
||||
[13]: https://opensource.com/sites/default/files/uploads/component_structure.jpg (component directory structure)
|
||||
[14]: https://www.scipioerp.com/community/developer/views-requests/request-controller/
|
||||
[15]: https://www.scipioerp.com/community/developer/views-requests/screen-widgets-decorators/
|
||||
[16]: /file/419721
|
||||
[17]: https://opensource.com/sites/default/files/uploads/success_screen_sm.jpg (Custom screen)
|
||||
[18]: /file/419726
|
||||
[19]: https://opensource.com/sites/default/files/uploads/theme_structure.jpg (theme component layout)
|
||||
[20]: /file/419731
|
||||
[21]: https://opensource.com/sites/default/files/uploads/finished_shop_1_sm.jpg (Finished Scipio ERP shop)
|
||||
[22]: https://www.scipioerp.com/demo/
|
||||
[23]: https://forum.scipioerp.com/
|
@ -7,31 +7,29 @@
|
||||
[#]: via: (https://fedoramagazine.org/how-to-set-up-a-tftp-server-on-fedora/)
|
||||
[#]: author: (Curt Warfield https://fedoramagazine.org/author/rcurtiswarfield/)
|
||||
|
||||
How to set up a TFTP server on Fedora
|
||||
如何在 Fedora 上建立一个 TFTP 服务器
|
||||
======
|
||||
|
||||
![][1]
|
||||
|
||||
**TFTP**, or Trivial File Transfer Protocol, allows users to transfer files between systems using the [UDP protocol][2]. By default, it uses UDP port 69. The TFTP protocol is extensively used to support remote booting of diskless devices. So, setting up a TFTP server on your own local network can be an interesting way to do [Fedora installations][3], or other diskless operations.
|
||||
**TFTP** 即简单文本传输协议,允许用户通过 [UDP][2] 协议在系统之间传输文件。默认情况下,协议使用的是 UDP 的 69 号端口。TFTP 协议广泛用于无盘设备的远程启动。因此,在你的本地网络建立一个 TFTP 服务器,这样你就可以进行 [Fedora 的安装][3]和其他无盘设备的一些操作,这将非常有趣。
|
||||
|
||||
TFTP can only read and write files to or from a remote system. It doesn’t have the capability to list files or make any changes on the remote server. There are also no provisions for user authentication. Because of security implications and the lack of advanced features, TFTP is generally only used on a local area network (LAN).
|
||||
TFTP 仅仅能够从远端系统读取数据或者向远端系统写入数据。但它并没有列出远端服务器上文件的能力,同时也没有修改远端服务器的能力(译者注:感觉和前一句话矛盾)。用户身份验证也没有规定。 由于安全隐患和缺乏高级功能,TFTP 通常仅用于局域网(LAN)。
|
||||
|
||||
### TFTP server installation
|
||||
### 安装 TFTP 服务器
|
||||
|
||||
The first thing you will need to do is install the TFTP client and server packages:
|
||||
首先你要做的事就是安装 TFTP 客户端和 TFTP 服务器:
|
||||
|
||||
```
|
||||
dnf install tftp-server tftp -y
|
||||
```
|
||||
|
||||
This creates a _tftp_ service and socket file for [systemd][4] under _/usr/lib/systemd/system_.
|
||||
|
||||
上述的这条命令会为 [systemd][4] 在 _/usr/lib/systemd/system_ 目录下创建 _tftp.service_ 和 _tftp.socket_ 文件。
|
||||
```
|
||||
/usr/lib/systemd/system/tftp.service
|
||||
/usr/lib/systemd/system/tftp.socket
|
||||
```
|
||||
|
||||
Next, copy and rename these files to _/etc/systemd/system_:
|
||||
接下来,将这两个文件复制到 _/etc/systemd/system_ 目录下,并重新命名。
|
||||
|
||||
```
|
||||
cp /usr/lib/systemd/system/tftp.service /etc/systemd/system/tftp-server.service
|
||||
@ -39,9 +37,9 @@ cp /usr/lib/systemd/system/tftp.service /etc/systemd/system/tftp-server.service
|
||||
cp /usr/lib/systemd/system/tftp.socket /etc/systemd/system/tftp-server.socket
|
||||
```
|
||||
|
||||
### Making local changes
|
||||
### 修改文件
|
||||
|
||||
You need to edit these files from the new location after you’ve copied and renamed them, to add some additional parameters. Here is what the _tftp-server.service_ file initially looks like:
|
||||
当你把这些文件复制和重命名后,你就可以去添加一些额外的参数,下面是 _tftp-server.service_ 刚开始的样子:
|
||||
|
||||
```
|
||||
[Unit]
|
||||
@ -57,40 +55,36 @@ StandardInput=socket
|
||||
Also=tftp.socket
|
||||
```
|
||||
|
||||
Make the following changes to the _[Unit]_ section:
|
||||
在 _[Unit]_ 部分添加如下内容:
|
||||
|
||||
```
|
||||
Requires=tftp-server.socket
|
||||
```
|
||||
|
||||
Make the following changes to the _ExecStart_ line:
|
||||
修改 _[ExecStart]_ 行:
|
||||
|
||||
```
|
||||
ExecStart=/usr/sbin/in.tftpd -c -p -s /var/lib/tftpboot
|
||||
```
|
||||
|
||||
Here are what the options mean:
|
||||
下面是这些选项的意思:
|
||||
|
||||
* The _**-c**_ option allows new files to be created.
|
||||
* The _**-p**_ option is used to have no additional permissions checks performed above the normal system-provided access controls.
|
||||
* The _**-s**_ option is recommended for security as well as compatibility with some boot ROMs which cannot be easily made to include a directory name in its request.
|
||||
* _**-c**_ 选项允许创建新的文件
|
||||
* _**-p**_ 选项用于指明在正常系统提供的权限检查之上没有其他额外的权限检查
|
||||
* _**-s**_ 建议使用该选项以确保安全性以及与某些引导 ROM 的兼容性,这些引导 ROM 在其请求中不容易包含目录名。
|
||||
|
||||
默认的上传和下载位置位于 _/var/lib/tftpboot_。
|
||||
|
||||
|
||||
The default upload/download location for transferring the files is _/var/lib/tftpboot_.
|
||||
|
||||
Next, make the following changes to the _[Install]_ section:
|
||||
|
||||
下一步,修改 _[Install}_ 部分的内容
|
||||
```
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Also=tftp-server.socket
|
||||
```
|
||||
|
||||
Don’t forget to save your changes!
|
||||
|
||||
Here is the completed _/etc/systemd/system/tftp-server.service_ file:
|
||||
不要忘记保存你的修改。
|
||||
|
||||
下面是 _/etc/systemd/system/tftp-server.service_ 文件的完整内容:
|
||||
```
|
||||
[Unit]
|
||||
Description=Tftp Server
|
||||
@ -106,42 +100,41 @@ WantedBy=multi-user.target
|
||||
Also=tftp-server.socket
|
||||
```
|
||||
|
||||
### Starting the TFTP server
|
||||
### 启动 TFTP 服务器
|
||||
|
||||
Reload the systemd daemon:
|
||||
重新启动 systemd 守护进程:
|
||||
|
||||
```
|
||||
systemctl daemon-reload
|
||||
```
|
||||
|
||||
Now start and enable the server:
|
||||
|
||||
启动服务器:
|
||||
```
|
||||
systemctl enable --now tftp-server
|
||||
```
|
||||
|
||||
To change the permissions of the TFTP server to allow upload and download functionality, use this command. Note TFTP is an inherently insecure protocol, so this may not be advised on a network you share with other people.
|
||||
|
||||
要更改 TFTP 服务器允许上传和下载的权限,请使用此命令。注意 TFTP 是一种固有的不安全协议,因此不建议你在于其他人共享的网络上这样做。
|
||||
```
|
||||
chmod 777 /var/lib/tftpboot
|
||||
```
|
||||
|
||||
Configure your firewall to allow TFTP traffic:
|
||||
配置防火墙让 TFTP 能够使用:
|
||||
|
||||
```
|
||||
firewall-cmd --add-service=tftp --perm
|
||||
firewall-cmd --reload
|
||||
```
|
||||
|
||||
### Client Configuration
|
||||
### 客户端配置
|
||||
|
||||
Install the TFTP client:
|
||||
|
||||
安装 TFTP 客户端
|
||||
|
||||
```
|
||||
yum install tftp -y
|
||||
```
|
||||
|
||||
Run the _tftp_ command to connect to the TFTP server. Here is an example that enables the verbose option:
|
||||
运行 _tftp_ 命令连接服务器。下面是一个启用详细信息选项的例子:
|
||||
|
||||
```
|
||||
[client@thinclient:~ ]$ tftp 192.168.1.164
|
||||
@ -154,7 +147,7 @@ tftp> quit
|
||||
[client@thinclient:~ ]$
|
||||
```
|
||||
|
||||
Remember, TFTP does not have the ability to list file names. So you’ll need to know the file name before running the _get_ command to download any files.
|
||||
记住,因为 TFTP 没有列出服务器上文件的能力,因此,在你使用 _get_ 命令之前需要知道文件的具体名称。
|
||||
|
||||
* * *
|
||||
|
||||
@ -166,7 +159,7 @@ via: https://fedoramagazine.org/how-to-set-up-a-tftp-server-on-fedora/
|
||||
|
||||
作者:[Curt Warfield][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
译者:[amwps290](https://github.com/amwps290)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
@ -1,159 +0,0 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (Morisun029)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How to Check Linux Mint Version Number & Codename)
|
||||
[#]: via: (https://itsfoss.com/check-linux-mint-version/)
|
||||
[#]: author: (Sergiu https://itsfoss.com/author/sergiu/)
|
||||
|
||||
如何查看 Linux Mint 版本号和代号
|
||||
======
|
||||
|
||||
|
||||
Linux Mint 每两年发布一次主版本(如 Mint 19),每六个月左右发布一次次版本(如 Mint 19.1,19.2等)。 你可以自己升级 Linux Mint 版本,次版本也会自动更新。
|
||||
|
||||
|
||||
在所有这些版本中,你可能想知道你正在使用的是哪个版本。 了解 Linux Mint 版本号可以帮助你确定某个特定软件是否适用于你的系统,或者检查你的系统是否已达到使用寿命。
|
||||
|
||||
你可能需要 Linux Mint 版本号有多种原因,你也有多种方法可以获取此信息。
|
||||
让我向你展示用图形和命令行的方式获取 Mint 版本信息。
|
||||
|
||||
|
||||
* [使用命令行查看 Linux Mint 版本信息][1]
|
||||
* [使用GUI(图形用户界面)查看 Linux Mint 版本信息][2]
|
||||
|
||||
|
||||
|
||||
### 使用终端查看 Linux Mint 版本号的方法
|
||||
|
||||
![][3]
|
||||
|
||||
我将介绍几种使用非常简单的命令查看 Linux Mint 版本号和代号的方法。 你可以从 **菜单** 中打开**终端** ,或按**CTRL+ALT+T** (默认热键)打开。
|
||||
|
||||
|
||||
本文中的 **最后两个命令** 还会输出你当前的 Linux Mint 版本所基于的 **Ubuntu 版本**。
|
||||
|
||||
|
||||
#### 1\. /etc/issue
|
||||
|
||||
|
||||
从最简单的 CLI 方法开始,你可以打印出 **/etc/issue** 的内容来检查你的 **版本号** 和 **代号** :
|
||||
|
||||
|
||||
```
|
||||
[email protected]:~$ cat /etc/issue
|
||||
Linux Mint 19.2 Tina \n \l
|
||||
```
|
||||
|
||||
#### 2\. hostnamectl
|
||||
|
||||
![hostnamectl][4]
|
||||
|
||||
|
||||
这一个命令(**hostnamectl**)打印的信息几乎与 **系统信息** 中的信息相同。 你可以看到你的 **操作系统**(带有**版本号**)以及你的 **内核版本**。3.
|
||||
|
||||
#### 3\. lsb_release
|
||||
|
||||
**lsb_release** 是一个非常简单的Linux实用程序,用于查看有关你的发行版本的基本信息:
|
||||
|
||||
```
|
||||
[email protected]:~$ lsb_release -a
|
||||
No LSB modules are available.
|
||||
Distributor ID: LinuxMint
|
||||
Description: Linux Mint 19.2 Tina
|
||||
Release: 19.2
|
||||
Codename: tina
|
||||
```
|
||||
|
||||
**注:** *我使用 **–***_**a**_ _标签打印所有参数, 但你也可以使用 **-s** 作为简写格式, **-d** 用于描述等 (检查所有标签的 **man lsb_release** )._
|
||||
|
||||
|
||||
#### 4\. /etc/linuxmint/info
|
||||
|
||||
![/etc/linuxmint/info][5]
|
||||
|
||||
This isn’t a command, but rather a file on any Linux Mint install. Simply use cat command to print it’s contents to your terminal and see your **Release Number** and **Codename**.
|
||||
这不是命令,而是所有Linux Mint 安装上的文件。 只需使用 cat 命令将其内容打印到终端,然后查看你的**版本号** 和**代号** 。
|
||||
|
||||
[][6]
|
||||
|
||||
建议阅读避免在 ELemetary OS Freya 中出现两个 Chrome 图标[快速提示]
|
||||
|
||||
#### 5\. 使用 /etc/os-release 命令也可以获取到 Ubuntu 代号
|
||||
|
||||
![/etc/os-release][7]
|
||||
|
||||
|
||||
Linux Mint 基于 Ubuntu。 每个 Linux Mint 版本都基于不同的 Ubuntu 版本。了解 Linux Mint 版本所基于的 Ubuntu 版本有助你在必须要使用 Ubuntu 版本号的情况下使用-在你需要在 [Linux Mint 中安装最新的Virtual Box][8]. 添加仓库时。
|
||||
|
||||
os-release 则是另一个类似于**info**的文件,向你展示 Linux Mint 所基于的 Ubuntu 版本代号。
|
||||
|
||||
|
||||
#### 6\. 使用 /etc/upstream-release/lsb-release 只能获取到 Ubuntu 的基本信息
|
||||
|
||||
|
||||
如果你只想要查看有关 **Ubuntu** 的基本信息,请输出 **/etc/upstream-release/lsb-release**:
|
||||
|
||||
```
|
||||
[email protected]:~$ cat /etc/upstream-release/lsb-release
|
||||
DISTRIB_ID=Ubuntu
|
||||
DISTRIB_RELEASE=18.04
|
||||
DISTRIB_CODENAME=bionic
|
||||
DISTRIB_DESCRIPTION="Ubuntu 18.04 LTS"
|
||||
```
|
||||
|
||||
特别提示: [你可以使用 **uname** 命令查看 Linux 内核版本][9]:
|
||||
|
||||
```
|
||||
[email protected]:~$ uname -r
|
||||
4.15.0-54-generic
|
||||
```
|
||||
|
||||
**注:** _**-r** 代表 **release**, 你可以使用 **man uname** 查看其他信息。
|
||||
|
||||
### 使用 GUI 查看 Linux Mint 版本信息
|
||||
|
||||
如果你对终端和命令行不满意,可以使用图形方法。如你所料,这个非常明了。
|
||||
|
||||
打开 **Menu** (左下角), 然后转到 **Preferences > System Info**:
|
||||
|
||||
![Linux Mint 菜单][10]
|
||||
|
||||
或者,在菜单中,你可以搜索 **System Info**:
|
||||
|
||||
![Menu Search System Info][11]
|
||||
|
||||
在这里,你可以看到你的操作系统(包括版本号),内核和 DE 的版本号:
|
||||
|
||||
![System Info][12]
|
||||
|
||||
**总结**
|
||||
|
||||
我已经介绍了一些不同的方法,用这些方法你可以快速查看你正在使用的 Linux Mint 的版本和代号(以及所基于的Ubuntu 版本和内核)。 我希望这个初学者教程对你有所帮助。请在评论中告诉我们你最喜欢哪个方法!
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://itsfoss.com/check-linux-mint-version/
|
||||
|
||||
作者:[Sergiu][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[Morisun029](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://itsfoss.com/author/sergiu/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: tmp.pL5Hg3N6Qt#terminal
|
||||
[2]: tmp.pL5Hg3N6Qt#GUI
|
||||
[3]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/09/check-linux-mint-version.png?ssl=1
|
||||
[4]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/09/hostnamectl.jpg?ssl=1
|
||||
[5]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2019/09/linuxmint_info.jpg?ssl=1
|
||||
[6]: https://itsfoss.com/rid-google-chrome-icons-dock-elementary-os-freya/
|
||||
[7]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/09/os_release.jpg?ssl=1
|
||||
[8]: https://itsfoss.com/install-virtualbox-ubuntu/
|
||||
[9]: https://itsfoss.com/find-which-kernel-version-is-running-in-ubuntu/
|
||||
[10]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2019/09/linux_mint_menu.jpg?ssl=1
|
||||
[11]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/09/menu_search_system_info.jpg?ssl=1
|
||||
[12]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2019/09/system_info.png?ssl=1
|
Loading…
Reference in New Issue
Block a user