merge conflict

This commit is contained in:
CanYellow 2023-04-05 23:09:14 +08:00
commit 928ecf5129
142 changed files with 13292 additions and 4684 deletions

View File

@ -12,6 +12,8 @@ jobs:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: ensure source branch is not "master"
run: '[ "${{ github.head_ref }}" != master ]'
- name: "checkout master branch & return to pull request branch"
run: CURRENT=$(echo ${{github.ref}} | sed "s|refs/|refs/remotes/|") && git checkout master && git checkout $CURRENT
- name: run check

View File

@ -0,0 +1,273 @@
[#]: subject: "Short option parsing using getopt in C"
[#]: via: "https://opensource.com/article/21/8/short-option-parsing-c"
[#]: author: "Jim Hall https://opensource.com/users/jim-hall"
[#]: collector: "lujun9972"
[#]: translator: "toknow-gh"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15589-1.html"
在 C 语言中使用 getopt 解析命令行短选项
======
> 通过使用命令行让用户告诉程序要什么,可以让程序更加灵活。
![][0]
在已经知道要处理什么文件和对文件进行哪些操作的情况下,编写处理文件的 C 语言程序就很容易了。如果将文件名“硬编码”在程序中,或者你的程序只以一种方式来处理文件,那么你的程序总是知道要做什么。
但是如果程序每次运行时能够对用户的输入做出反应,可以使程序更灵活。让用户告诉程序要处理什么文件,或者以不同的方式完成任务,要实现这样的功能就需要读取命令行参数。
### 读取命令行
一个 C 语言程序可以用如下声明开头:
```
int main()
```
这是启动 C 程序最简单的形式。但如果在圆括号中加入标准参数,你的程序就可以从命令行中读取选项了:
```
int main(int argc, char **argv)
```
`argc` 表示命令行中的参数个数。它总是一个至少为 1 的数。
`argv` 是一个二级指针,它指向一个字符串数组。这个数组中保存的是从命令行接收的各个参数。数组的第一个元素 `*argv[0]` 是程序的名称。`**argv` 数组的其它元素包含剩下的命令行参数。
下面我将写一个简单的示例程序,它能够回显通过命令行参数传递给它的选项。它跟 Linux 的 `echo` 命令类似,只不过我们的程序会打印出程序名。同时它还会调用 `puts` 函数将命令行选项按行打印输出。
```
#include <stdio.h>
int
main(int argc, char **argv)
{
int i;
printf("argc=%d\n", argc); /* debugging */
for (i = 0; i < argc; i++) {
puts(argv[i]);
}
return 0;
}
```
编译此程序,并在运行时提供一些命令行参数,你会看到传入的命令行参数被逐行打印出来:
```
$ ./echo this program can read the command line
argc=8
./echo
this
program
can
read
the
command
line
```
这个命令行将程序的 `argc` 置为 8`**argv` 数组包含 8 个元素:程序名以及用户输入的 7 个单词。由于 C 语言中数组下标从 0 开始,所以这些元素的标号分别是 0 到 7。这也是在 `for` 循环中处理命令行参数时能够用 `i < argc` 作为比较条件的原因。
你也可以用这个方式实现自己的 `cat``cp` 命令。`cat` 命令的基本功能是显示一个或几个文件的内容。下面是一个简化版的`cat` 命令,它从命令行获取文件名:
```
#include <stdio.h>
void
copyfile(FILE *in, FILE *out)
{
int ch;
while ((ch = fgetc(in)) != EOF) {
fputc(ch, out);
}
}
int
main(int argc, char **argv)
{
int i;
FILE *fileptr;
for (i = 1; i < argc; i++) {
fileptr = fopen(argv[i], "r");
if (fileptr != NULL) {
copyfile(fileptr, stdout);
fclose(fileptr);
}
}
return 0;
}
```
这个简化版的 `cat` 命令从命令行读取文件名列表,然后将各个文件的内容逐字符地显示到标准输出上。假定我有一个叫做 `hello.txt` 的文件,其中包含数行文本内容。我能用自己实现的 `cat` 命令将它的内容显示出来:
```
$ ./cat hello.txt
Hi there!
This is a sample text file.
```
以这个简单程序为出发点,你也可以实现自己版本的其它 Linux 命令。比如 `cp` 命令,它从命令行读取两个文件名:要读取的文件和要写入的文件。
### 读取命令行选项
通过命令行读取文件名和其它文本固然很棒,但是如果想要程序根据用户给出的选项改变行为呢?比如 Linux 的 `cat` 命令就支持以下命令行选项:
* `-b` 显示非空行的行号
* `-E` 在行尾显示 `$`
* `-n` 显示行号
* `-s` 合并显示空行
* `-T` 将制表符显示为 `^I`
* `-v``^x``M-x` 方式显示非打印字符,换行符和制表符除外
这些以一个连字符开头的单字母的选项叫做短选项。通常短选项是分开使用的,就像这样 `cat -E -n`。但是也可以将多个短选项合并,比如 `cat -En`
值得庆幸的是,所有 Linux 和 Unix 系统都包含 `getopt` 库。它提供了一种简单的方式来读取命令行参数。`getopt` 定义在头文件 `unistd.h` 中。你可以在程序中使用 `getopt` 来读取命令行短选项。
与其它 Unix 系统不同的是Linux 上的 `getopt` 总是保证短选项出现在命令行参数的最前面。比如,用户输入的是 `cat -E file -n`。`-E` 在最前面,`-n` 在文件名之后。如果使用 Linux 的 `getopt` 来处理,程序会认为用户输入的是 `cat -E -n file`。这样做可以使处理过程更顺畅,因为 `getopt` 可以解析完所有短选项,剩下的文件名列表可以通过 `**argv` 来统一处理。
你可以这样使用 `getopt`:
```
#include <unistd.h>
int getopt(int argc, char **argv, char *optstring);
```
`optstring` 是由所有合法的选项字符组成的字符串。比如你的程序允许的选项是 `-E``-n` 那么 `optstring` 的值就是 `"En"`
通常通过在循环中调用 `getopt` 来解析命令行选项。每次调用时 `getopt` 会返回找到的下一个短选项,如果遇到无法识别的选项则返回 `'?'`。当没有更多短选项时它返回 `-1`,并且设置全局变量 `optind` 的值指向 `**argv` 中所有段选项之后的第一个元素。
下面看一个简单的例子。这个演示程序没有实现 `cat` 命令的所有选项,但它只是能够解析命令行。每当发现一个合法的命令行选项,它就打印出相应的提示消息。在你自己的程序中,你可能会根据这些命令行选项执行变量赋值等者其它操作。
```
#include <stdio.h>
#include <unistd.h>
int
main(int argc, char **argv)
{
int i;
int option;
/* parse short options */
while ((option = getopt(argc, argv, "bEnsTv")) != -1) {
switch (option) {
case 'b':
puts("Put line numbers next to non-blank lines");
break;
case 'E':
puts("Show the ends of lines as $");
break;
case 'n':
puts("Put line numbers next to all lines");
break;
case 's':
puts("Suppress printing repeated blank lines");
break;
case 'T':
puts("Show tabs as ^I");
break;
case 'v':
puts("Verbose");
break;
default: /* '?' */
puts("What's that??");
}
}
/* print the rest of the command line */
puts("------------------------------");
for (i = optind; i < argc; i++) {
puts(argv[i]);
}
return 0;
}
```
假如你把程序编译为 `args`,你可以通过尝试不同的命令行参数组合,来了解程序是怎么解析短选项,以及是怎么将其它的命令行参数留下来的。最简单的例子是将所有的选项都放在最前面,就像这样:
```
$ ./args -b -T file1 file2
Put line numbers next to non-blank lines
Show tabs as ^I
------------------------------
file1
file2
```
现在试试将两个短选项合并使用的效果:
```
$ ./args -bT file1 file2
Put line numbers next to non-blank lines
Show tabs as ^I
------------------------------
file1
file2
```
如果有必要的话,`getopt`可以对命令行参数进行重排:
```
$ ./args -E file1 file2 -T
Show the ends of lines as $
Show tabs as ^I
------------------------------
file1
file2
```
如果用户输入了错误的短选项,`getopt` 会打印一条消息:
```
$ ./args -s -an file1 file2
Suppress printing repeated blank lines
./args: invalid option -- 'a'
What's that??
Put line numbers next to all lines
------------------------------
file1
file2
```
### 下载速查表
`getopt` 还有更多的功能。例如,通过设计 `-s string``-f file` 这样的命令行语法规则,可以让短选项拥有自己的二级选项。你也可以告诉 `getopt` 在遇到无法识别的选项时不显示错误信息。使用 `man 3 getopt` 命令查看 `getopt(3)` 手册可以了解 `getopt` 的更多功能。
如果你需要 `getopt()``getopt_long()`的使用语法和结构上的提示,可以 [下载我制作的速查表][8]。它提供了最小可行代码,并列出了你需要了解的一些全局变量的含义。速查表的一面是 `getopt()` 的用法,另一面是 `getopt_long()`的用法。
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/8/short-option-parsing-c
作者:[Jim Hall][a]
选题:[lujun9972][b]
译者:[toknow-gh](https://github.com/toknow-gh)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/jim-hall
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/computer_code_programming_laptop.jpg?itok=ormv35tV (Person programming on a laptop on a building)
[2]: http://www.opengroup.org/onlinepubs/009695399/functions/printf.html
[3]: http://www.opengroup.org/onlinepubs/009695399/functions/puts.html
[4]: http://www.opengroup.org/onlinepubs/009695399/functions/fgetc.html
[5]: http://www.opengroup.org/onlinepubs/009695399/functions/fputc.html
[6]: http://www.opengroup.org/onlinepubs/009695399/functions/fopen.html
[7]: http://www.opengroup.org/onlinepubs/009695399/functions/fclose.html
[8]: https://opensource.com/downloads/c-getopt-cheat-sheet
[0]: https://img.linux.net.cn/data/attachment/album/202303/02/141038srs54y5t4pv3r1ym.jpg

View File

@ -0,0 +1,223 @@
[#]: subject: "How I use Artipie, a PyPI repo"
[#]: via: "https://opensource.com/article/22/12/python-package-index-repository-artipie"
[#]: author: "Alena Gerasimova https://opensource.com/users/olena"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15592-1.html"
Artipie可用于 Python 的开源仓库管理器
======
![][0]
> Artipie 是一个开源的自托管的仓库管理器,它不仅可以用于 Python。
在学生时代使用 Python 开发时,我发现我需要一些私人的集中存储。这样我就可以存储二进制和文本数据文件,以及 Python 软件包。我在 [Artipie][1] 中找到了答案,这是一个开源的自托管的软件仓库管理器。
在大学里,我和我的同事们对来自实验测量的大量数据进行研究。我使用 Python 来处理和可视化它们。当时我的大学同事是数学家,没有软件开发技术的经验。他们通常只是在闪存盘上或通过电子邮件传递数据和代码。我努力向他们介绍像 [Git][2] 这样的版本管理系统,但没有成功。
### Python 仓库
Artipie 支持 [PyPI][3] 仓库,与 [twine][4] 和 [pip][5] 兼容。这意味着你可以完全像在 [PyPI][3] 和 [TestPyPI][6] 仓库上安装或发布软件包那样使用 Artipie Python 仓库。
要创建你自己的 Python 仓库,你可以使用名为 [Artipie Central][7] 的 Artipie 托管实例。当你登录后,你会看到一个列出你的仓库的页面(开始时是空的),以及一个添加新仓库的表单。为你的新仓库选择一个名字(例如,`mypython`),选择 `Python` 作为仓库类型,然后点击 “<ruby>添加<rt>Add</rt></ruby>” 按钮。
接下来,你会看到一个以 [YAML][8] 格式显示仓库设置的页面:
```
---
repo:
type: pypi
storage: default
permissions:
olenagerasimova:
- upload
"*":
- download
```
配置中的 `type` 映射设置了仓库的类型。在这个例子中Python 仓库被配置为默认的 Artipie Central 存储。
`storage` 映射定义了所有仓库包的存储位置。这可以是任何文件系统或 S3 存储兼容的位置。Artipie Central 有一个预先配置的 `default` 存储,可以使用它进行测试。
`permissions` 映射允许为用户 `olenagerasimova` 上传,并允许任何人下载任何软件包。
为了确保这个仓库的存在和工作,在你的浏览器中打开 [索引页][9]。显示的是软件包列表。如果你刚刚创建了一个新的版本库,但还没有上传软件包,那么仓库的索引页是空白的。
### 二进制仓库
你可以在 Artipie 中存储任何种类的文件。存储类型是 `file``binary`,我用这个作为实验数据的存储。我把它作为 Python 可视化的输入。在 Artipie Central 可以创建一个文件仓库,与 Python 仓库的方式相同。你给它一个名字,选择 `binary` 类型,然后点击 “<ruby>添加<rt>Add</rt></ruby>” 按钮。
```
---
repo:
type: file
storage: default
permissions:
olenagerasimova:
- upload
- download
"*":
- download
```
这些设置基本上与 Python 相同。只有仓库的类型不同。在这个例子中,二进制仓库被称为 `data`。它包含三个带有一些数字的文本文件:
```
6
3.5
5
4
4.5
3
2.7
5
6
3
1.2
3.2
6
```
另外两个文件的形式相同(只是数字不同)。要想自己看这些文件,请在浏览器中打开链接 [一][10]、[二][11] 和 [三][12] 并下载文件,或者你可以用 `httpie` 执行 GET 请求:
```
httpie -a https://central.artipie.com/olenagerasimova/data/y1.dat > ./data/y1.da
```
这些文件是用 PUT 请求上传到 Artipie Central 的 `data` 存储库的:
```
httpie -a olenagerasimova:*** PUT
https://central.artipie.com/olenagerasimova/data/y1.dat @data/y1.dat
httpie -a olenagerasimova:*** PUT
https://central.artipie.com/olenagerasimova/data/y2.dat @data/y2.dat
httpie -a olenagerasimova:*** PUT
https://central.artipie.com/olenagerasimova/data/y3.dat @data/y3.dat
```
由于这个二进制仓库的 API 非常简单HTTP `PUT``GET` 请求),用任何语言编写一段代码来上传和下载所需的文件都很容易。
### Python 项目
可以从我的 [GitHub 仓库][13]中获得一个 Python 项目的示例源代码。这个示例的主要想法是,从 Artipie Central 下载三个数据文件,将数字读入数组,并使用这些数组来绘制一个图。使用 `pip` 来安装这个例子包并运行它:
```
$ python3 -m pip install --index-url \
https://central.artipie.com/olenagerasimova/pypi/ \
pypiexample
$ python3 -m pypiexample
```
通过设置 `--index-url` 到 Artipie Central 的 Python 仓库,`pip` 从它那里下载软件包,而不是通常默认的 PyPi 仓库。运行这些命令后,会显示一个带有三条曲线的极坐标图,这是数据文件的可视化。
要将软件包发布到 Artipie Central 仓库,请用 `twine` 构建并上传:
```
commandline
$ python setup.py sdist bdist_wheel
$ twine upload --repository-url \
https://central.artipie.com/olenagerasimova/pypi
-u olenagerasimova -p *** dist/*
```
在 Artipie Central 中设置 `files` 仓库,并创建一个 Python 示例项目是多么容易。不过,你不必使用 Artipie Central。Artipie 可以自托管,所以你可以在你自己的本地网络上运行一个仓库。
### 将 Artipie 作为一个容器运行
将 Artipie 作为一个容器运行,设置起来就像安装 Podman 或 Docker 一样容易。假设你已经安装了其中之一,打开终端:
```
$ podman run -it -p 8080:8080 -p 8086:8086 artipie/artipie:latest
```
这将启动一个运行最新 Artipie 版本的新容器。它还映射了两个端口。你的仓库在 8080 端口提供服务。Artipie 的 Rest API 和 Swagger 文档在 8086 端口提供。新的镜像会生成一个默认的配置,打印一个正在运行的仓库列表,测试证书,以及一个指向 [Swagger][14] 文档的链接到你的控制台。
你也可以使用 Artipie Rest API 来查看现有的仓库:
- 进入 Swagger 文档页面 `http://localhost:8086/api/index-org.html`
- 在 “<ruby>选择一个定义<rt>Select a definition</rt></ruby>” 列表中,选择 “<ruby>认证令牌<rt>Auth token</rt></ruby>”。
- 生成并复制用户 `artipie` 的认证令牌,密码是 `artipie`
- 切换到 “<ruby>仓库<rt>Repositories</rt></ruby>” 定义,点击 “<ruby>认证<rt>Authorize</rt></ruby>” 按钮,然后粘贴令牌。
![Image of the Swagger documentation page,][15]
`/api/v1/repository/list` 执行一个 GET 请求。在响应中,你会收到一个包含三个默认仓库的 JSON 列表:
```
[
"artipie/my-bin",
"artipie/my-docker",
"artipie/my-maven"
]
```
默认配置中不包括 Python 仓库。你可以通过从 Swagger 接口向 `/api/v1/repository/{user}/{repo}` 执行 PUT 请求来纠正。在这种情况下,`user` 是默认用户的名字(`artipie``repo` 是新仓库的名字。你可以把你的新 Python 代码库称为 `my-pypi`。下面是一个请求体的例子,包含带仓库设置的 JSON 对象:
```
{
"repo": {
"type": "pypi",
"storage": "default",
"permissions": {
"*": [
"download"
],
"artipie": [
"upload"
]
}
}
}
```
所有的 JSON 字段都和你在仪表板上创建 YAML 格式的仓库时一样。我们版本库的类型是 `pypi`,使用默认存储,任何人都可以下载,但只有用户 `artipie` 可以上传。
再次向 `/api/v1/repository/list` 发出 GET 请求,确保你的仓库被创建。现在,你有四个仓库:
```
[
"artipie/my-bin",
"artipie/my-docker",
"artipie/my-maven",
"artipie/my-pypi"
]
```
你已经创建了你自己的 Artipie 安装,包含了几个仓库! Artipie 镜像既可以在个人电脑上运行,也可以在私人网络内的远程服务器上运行。你可以用它来在一个公司、团体或大学内交换软件包。这是一个建立你自己的软件服务的简单方法,而且它不仅仅适用于 Python。花些时间来探索 Artipie看看它能为你带来什么。
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/12/python-package-index-repository-artipie
作者:[Alena Gerasimova][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/olena
[b]: https://github.com/lkxed
[1]: https://github.com/artipie
[2]: https://opensource.com/tags/git
[3]: https://pypi.org/
[4]: https://github.com/pypa/twine
[5]: https://pip.pypa.io/en/stable/
[6]: https://test.pypi.org/
[7]: https://central.artipie.com/signin
[8]: https://www.redhat.com/sysadmin/yaml-beginners
[9]: https://central.artipie.com/olenagerasimova/pypi
[10]: https://central.artipie.com/olenagerasimova/data/y1.dat
[11]: https://central.artipie.com/olenagerasimova/data/y2.dat
[12]: https://central.artipie.com/olenagerasimova/data/y3.dat
[13]: https://github.com/artipie/pypi-example
[14]: https://swagger.io/
[15]: https://opensource.com/sites/default/files/2022-11/artipie-swagger.png
[0]: https://img.linux.net.cn/data/attachment/album/202303/02/232208fgy56v5egv7ipgg2.jpg

View File

@ -0,0 +1,376 @@
[#]: subject: "Use Terraform to manage an OpenStack cluster"
[#]: via: "https://opensource.com/article/23/1/terraform-manage-openstack-cluster"
[#]: author: "AJ Canlas https://opensource.com/users/ajscanlas"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15586-1.html"
使用 Terraform 来管理 OpenStack 集群
======
> Terraform 是一种声明性语言,可以作为你正在建设的基础设施的蓝图。
在拥有一个 OpenStack 生产环境和家庭实验室一段时间后,我可以肯定地说,从管理员和租户的角度置备工作负载和管理它是很重要的。
Terraform 是一个开源的基础设施即代码IaC软件工具用于 <ruby>置备<rt>provisioning</rt></ruby>网络、服务器、云平台等。Terraform 是一种声明性语言,可以作为你正在建设的基础设施的蓝图。你可以用 Git 来管理它,它有一个强大的 [GitOps][1] 使用场景。
本文介绍了使用 Terraform 管理 OpenStack 集群的基础知识。我使用 Terraform 重新创建了 OpenStack 演示项目。
### 安装 Terraform
我使用 CentOS 作为跳板机运行 Terraform。根据官方文档第一步是添加 Hashicorp 仓库:
```
$ sudo dnf config-manager --add-repo https://rpm.releases.hashicorp.com/RHEL/hashicorp.repo
```
接下来,安装 Terraform
```
$ sudo dnf install terraform -y
```
验证安装:
```
$ terraform version
```
如果你看到返回的版本号,那么你已经安装了 Terraform。
### 为 OpenStack 提供者创建一个 Terraform 脚本
在 Terraform 中,你需要一个 <ruby>提供者<rt>provider</rt></ruby>它是一个转换器Terraform 调用它将你的 `.tf` 转换为对你正在协调的平台的 API 调用。
有三种类型的提供者:官方、合作伙伴和社区:
- 官方提供者由 Hashicorp 维护。
- 合作伙伴提供者由与 Hashicorp 合作的技术公司维护。
- 社区提供者是由开源社区成员维护的。
在这个 [链接][2] 中有一个很好的 OpenStack 的社区提供者。要使用这个提供者,请创建一个 `.tf` 文件,并命名为 `main.tf`
```
$ vi main.tf
```
`main.tf` 中添加以下内容:
```
terraform {
required_version = ">= 0.14.0"
required_providers {
openstack = {
source = "terraform-provider-openstack/openstack"
version = "1.49.0"
}
}
}
provider "openstack" {
user_name = “OS_USERNAME”
tenant_name = “OS_TENANT”
password = “OS_PASSWORD”
auth_url = “OS_AUTH_URL”
region = “OS_REGION”
}
```
你需要修改 `OS_USERNAME`、`OS_TENANT`、`OS_PASSWORD`、`OS_AUTH_URL` 和 `OS_REGION` 变量才能工作。
### 创建一个 Terraform 管理文件
OpenStack 管理文件的重点是置备外部网络、路由、用户、镜像、租户配置文件和配额。
此示例提供风格,连接到外部网络的路由、测试镜像、租户配置文件和用户。
首先,为置备资源创建一个 `AdminTF` 目录:
```
$ mkdir AdminTF
$ cd AdminTF
```
`main.tf` 中,添加以下内容:
```
terraform {
required_version = ">= 0.14.0"
required_providers {
openstack = {
source = "terraform-provider-openstack/openstack"
version = "1.49.0"
}
}
}
provider "openstack" {
user_name = “OS_USERNAME”
tenant_name = “admin”
password = “OS_PASSWORD”
auth_url = “OS_AUTH_URL”
region = “OS_REGION”
}
resource "openstack_compute_flavor_v2" "small-flavor" {
name = "small"
ram = "4096"
vcpus = "1"
disk = "0"
flavor_id = "1"
is_public = "true"
}
resource "openstack_compute_flavor_v2" "medium-flavor" {
name = "medium"
ram = "8192"
vcpus = "2"
disk = "0"
flavor_id = "2"
is_public = "true"
}
resource "openstack_compute_flavor_v2" "large-flavor" {
name = "large"
ram = "16384"
vcpus = "4"
disk = "0"
flavor_id = "3"
is_public = "true"
}
resource "openstack_compute_flavor_v2" "xlarge-flavor" {
name = "xlarge"
ram = "32768"
vcpus = "8"
disk = "0"
flavor_id = "4"
is_public = "true"
}
resource "openstack_networking_network_v2" "external-network" {
name = "external-network"
admin_state_up = "true"
external = "true"
segments {
network_type = "flat"
physical_network = "physnet1"
}
}
resource "openstack_networking_subnet_v2" "external-subnet" {
name = "external-subnet"
network_id = openstack_networking_network_v2.external-network.id
cidr = "10.0.0.0/8"
gateway_ip = "10.0.0.1"
dns_nameservers = ["10.0.0.254", "10.0.0.253"]
allocation_pool {
start = "10.0.0.1"
end = "10.0.254.254"
}
}
resource "openstack_networking_router_v2" "external-router" {
name = "external-router"
admin_state_up = true
external_network_id = openstack_networking_network_v2.external-network.id
}
resource "openstack_images_image_v2" "cirros" {
name = "cirros"
image_source_url = "https://download.cirros-cloud.net/0.6.1/cirros-0.6.1-x86_64-disk.img"
container_format = "bare"
disk_format = "qcow2"
properties = {
key = "value"
}
}
resource "openstack_identity_project_v3" "demo-project" {
name = "Demo"
}
resource "openstack_identity_user_v3" "demo-user" {
name = "demo-user"
default_project_id = openstack_identity_project_v3.demo-project.id
password = "demo"
}
```
### 创建一个租户 Terraform 文件
作为一个 <ruby>租户<rt>Tenant</rt></ruby>,你通常会创建虚拟机。你还为这些虚拟机创建网络和安全组。
这个例子使用上面由 Admin 文件创建的用户。
首先,创建一个 `TenantTF` 目录,用于与租户相关的置备:
```
$ mkdir TenantTF
$ cd TenantTF
```
`main.tf` 中,添加以下内容:
```
terraform {
required_version = ">= 0.14.0"
required_providers {
openstack = {
source = "terraform-provider-openstack/openstack"
version = "1.49.0"
}
}
}
provider "openstack" {
user_name = “demo-user”
tenant_name = “demo”
password = “demo”
auth_url = “OS_AUTH_URL”
region = “OS_REGION”
}
resource "openstack_compute_keypair_v2" "demo-keypair" {
name = "demo-key"
public_key = "ssh-rsa ZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ"
}
resource "openstack_networking_network_v2" "demo-network" {
name = "demo-network"
admin_state_up = "true"
}
resource "openstack_networking_subnet_v2" "demo-subnet" {
network_id = openstack_networking_network_v2.demo-network.id
name = "demo-subnet"
cidr = "192.168.26.0/24"
}
resource "openstack_networking_router_interface_v2" "demo-router-interface" {
router_id = “XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX”
subnet_id = openstack_networking_subnet_v2.demo-subnet.id
}
resource "openstack_compute_instance_v2" "demo-instance" {
name = "demo"
image_id = "YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY"
flavor_id = "3"
key_pair = "demo-key"
security_groups = ["default"]
metadata = {
this = "that"
}
network {
name = "demo-network"
}
}
```
### 初始化你的 Terraform
创建 Terraform 文件后,你需要初始化 Terraform。
对于管理员:
```
$ cd AdminTF
$ terraform init
$ terraform fmt
```
对于租户:
```
$ cd TenantTF
$ terraform init
$ terraform fmt
```
命令解释:
- `terraform init` 从镜像源下载提供者用于置备此项目。
- `terraform fmt` 格式化文件,以便在仓库中使用。
### 创建一个 Terraform 计划
接下来,为你创建一个 <ruby>计划<rt>plan</rt></ruby>,看看将创建哪些资源。
对于管理员:
```
$ cd AdminTF
$ terraform validate
$ terraform plan
```
对于租户:
```
$ cd TenantTF
$ terraform validate
$ terraform plan
```
命令解释:
- `terraform validate` 验证 `.tf` 语法是否正确。
- `terraform plan` 在缓存中创建一个计划文件,所有管理的资源在创建和销毁时都可以被跟踪。
### 应用你的第一个 TF
要部署资源,使用 `terraform apply` 命令。该命令应用计划文件中的所有资源状态。
对于管理员:
```
$ cd AdminTF
$ terraform apply
```
对于租户:
```
$ cd TenantTF
$ terraform apply
```
### 接下来的步骤
之前,我写了一篇关于在树莓派上部署最小 OpenStack 集群的 [文章][3]。你可以找到更详细的 [Terraform 和 Ansible][4] 配置,并通过 GitLab 实现一些 CI/CD。
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/1/terraform-manage-openstack-cluster
作者:[AJ Canlas][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/ajscanlas
[b]: https://github.com/lkxed
[1]: https://opensource.com/article/21/3/gitops
[2]: https://registry.terraform.io/providers/terraform-provider-openstack/openstack/1.49.0
[3]: https://opensource.com/article/20/12/openstack-raspberry-pi
[4]: https://www.ansible.com/blog/ansible-vs.-terraform-demystified?intcmp=7013a000002qLH8AAM
[0]: https://img.linux.net.cn/data/attachment/album/202303/01/114855zdkhdhsdoojmrqx2.jpg

View File

@ -0,0 +1,144 @@
[#]: subject: "How to Use a Differential Analyzer (to Murder People)"
[#]: via: "https://twobithistory.org/2020/04/06/differential-analyzer.html"
[#]: author: "Two-Bit History https://twobithistory.org"
[#]: collector: "lujun9972"
[#]: translator: "toknow-gh"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15564-1.html"
怎么用微分分析仪(来杀人)
======
微分分析仪是一种能够求解微分方程的机械式模拟计算机。它已经不再使用了,因为如今最便宜的笔记本电脑都能更快地解决相同的问题,并且你还可以同时在线刷剧。然而在数字计算机发明之前,微分分析仪使数学家能够完成一些用其它工具不可能完成的计算。
现如今很难想象一台不是由印刷的数字电路组成的计算机竟然是可以正常运作的。机械计算机听起来就像是从蒸汽朋克小说里跑出来的一样。事实证明微分分析仪不但能用,而且还是一些研究领域中必不可少的工具。它最为人所知的应用是曾被美国陆军用于编制火炮射表。如果没有射表辅助瞄准,口径再大的火炮也无法充分发挥效能。所以理论上来说,微分分析仪在帮助同盟国赢得二战上发挥了重要作用。
要弄清微分分析仪是如何做到这些的,你首先得知道什么是微分方程。已经还给学校了?没事,我也一样。
### 微分方程
你首次接触微分方程应该是在大学《微积分 I》的最后几周。在学期的这个阶段你那薪资低微的兼职教授应该已经教授过极限、导数和积分这些概念了。在这些概念之上再引入等号现在你就得到了一个微分方程。
微分方程描述了一个变量相对于另一个(或多个)变量的变化率。形如 $y = 4x + 3$ 的常见代数式表示变量 $y$ 与 变量 $x$ 之间的关系。形如 $\frac{dy}{dx} = x$ 或 $\frac{dy}{dx} = 2$ 的微分方程表示变化率与其它变量间的关系。本质上微分方程就是用纯数学方式来描述变化率。前面第一个方程表示 “变量 $y$ 相对于变量 $x$ 的变化率刚好等于 $x$。”第二个方程表示“无论 $x$ 的值是多少,$y$ 相对于 $x$ 的变化率总是 2。”
微分方程非常有用,因为在现实世界中,描述复杂系统从一个瞬间到下一个瞬间的变化往往比想出一个描述系统在所有可能的瞬间的方程要容易。因此,微分方程被广泛应用于物理和工程领域。一个著名的微分方程是<ruby>热传导方程<rt>heat equation</rt></ruby>。它能描述热量在物体中的扩散过程。要提出一个完全地描述物体在某时刻 $t$ 的热量分布的函数很困难,但推理热量从某时刻到下一个时刻的扩散过程不太可能会让你绞尽脑汁——近冷者变热,近热者变冷。所以尽管热传导方程在形式上比起前面的例子要复杂得多,它也只是变化率的描述而已。它描述了在给定与周围的温差时,物体上任意一点的温度随时间的变化。
再来举一个更具体的例子。假如我在真空中竖直向上抛出一个网球,在我窒息之前它会落回来吗?这是我在高中物理课上被问到的问题,解决它只需要基本的牛顿运动方程。现在暂且假设我已经忘记了牛顿运动方程,只记得物体以恒定的加速度 $g$ (大约为 $10 \;m/s^2$)向地球加速运动。那么如何用微分方程来解决这个问题呢?
现在把我对高中物理仅存的记忆表示成微分方程。网球在离手后会向地球以 $g$ 加速运动。也就是说网球的速度相对于时间的变化率为 $g$(在负方向上)。进一步,我们可以说球离地高度的变化率(也就是速度)随时间的变化率是负方向的 $g$。其微分方程形式如下,其中 $h$ 表示高度,$t$ 表示时间:
$$
\frac{d^2h}{dt^2} = -g
$$
它跟前面的微分方程看起来略有差别,因为这是所谓的二阶微分方程。我们讨论的是变化率的变化率,也许你还记得微积分课讲过,这需要用到二阶导数。这是方程左边部分看上去像被平方了的原因。但是该方程也仅仅表示了球向下以恒定的加速度 $g$ 加速运动这一事实。
到这里,我可以选择使用微积分来求解微分方程。解微分方程并不是要找满足指定关系的值,而是要找满足关系的函数。对上面的微分方程的另一种理解是存在这样的函数,它的二阶导数为 $-g$。我们想要找到这个函数,因为它能告诉我们球在任意时刻的高度。好在这个微分方程恰巧是容易求解的。通过这样,我们可以重新推导出那些被我遗忘了的运动方程,从而轻松地计算出球落回来所花的时间。
但是大部分情况下微分方程是很难求解的。有时甚至是无法求解的。假设我在大学时把更多的精力花在了计算机科学上,那么我的另一种选择就是用微分方程来做模拟。如果已知球的初速度和加速度,我可以轻易用 Python 写一个 `for` 循环来逐秒迭代计算球在离手后 $t$ 时刻的速度。在此基础上对循环程序稍加修改,就可以用算出的速度迭代计算出球的高度。运行这个 Python 模拟程序,它就可以计算出球什么时候落回来了。这个模拟并不是完全精确的,但是我可以通过减小计算用的时间步长来提升精度。总之我要做的只是搞清楚当球落回来时我是否还活着。
这就是微分方程的数值解法。这也是大多数领域中求解微分方程时实际采用的方法。对于用数值方法求解微分方程,计算机是必不可少的,因为模拟的精度取决于在微小步长上进行的大量计算。手工计算容易出错并且太耗时。
那如果将这个问题的背景时间设定在 1936 年呢?我仍然希望实现计算过程的自动化。但是此时离 <ruby>克劳德·香农<rt>Claude Shannon</rt></ruby> 完成他的硕士论文还有一年时间。在这篇论文中香农用数字电路实现了 <ruby>布尔代数<rt>boolean algebra</rt></ruby>。没有数字计算机可用,恐怕就只能寄希望于于模拟计算机了。
### 微分分析仪
首台微分分析仪是由 <ruby>范内瓦·布什<rt>Vannevar Bush</rt></ruby><ruby>哈罗德·哈森<rt>Harold Hazen</rt></ruby> 于 1928 年到 1931 年在 MIT 建造的。他们两人都是工程师。制造它是为了解决应用数学和物理领域中的实际问题。正如布什在 [1931 年的一篇论文][1] 中所说,微分分析仪是为了解决那些“不断为他们所用方程的复杂性而不是深刻性所困扰的”的数学家的所面临的当代问题。
微分分析仪是一台由传动轴、齿轮和转盘组成的复杂仪器,它能够求解高达六阶的微分方程。它是一台由简单部件通过复杂组合而成的神奇机器。在这一点上它和数字计算机很像。不同点是,数字计算机通过在电路中实现布尔代数来模拟代数问题,而微分分析仪通过传动轴、齿轮和转盘直接模拟微分方程问题。微分分析仪的本质就是对实际问题的直接机械类比。
那到底怎么用齿轮和转盘来计算微积分呢?其实这是最容易解释的部分。微分分析仪最重要的构件是六个积分器,每一个对应一阶的微分方程。机械积分器的历史可以追溯到 19 世纪,它是一个相对简单的装置,能够对单个简单函数进行积分运算的。下面我们将了解积分器的工作原理,但顺便说一句,布什的巨大成就不是发明了机械积分器,而是发现了一种将积分器串联起来解决高阶微分方程的方法。
机械积分器由一个大转盘和一个小得多的转轮组成。转盘像唱片机的转台一样平行于地面平放。它由电机驱动匀速转动。转轮竖直的轻放于转盘表面上,其压力既要足够让转盘驱动转轮,又不能太大以致于阻碍转轮相对于转盘自由侧向滑动。总之当转盘转动时,转轮也跟着转动。
转轮的转速由它距离转盘中心的距离决定。转盘的中心部分自然转动得比边缘部分慢。转轮的位置是固定不动的,而转盘被安装在一个可以来回滑动的底座上。这样就可以调节转轮相对转盘中心的位置。下面就是积分器工作的关键原理:转盘底座的位置由积分器的输入函数控制。积分器输出取决于转轮的转动量。所以输入函数驱动了输出函数的变化率,这就是将某个函数的导数转换成了这个函数本身。这不就是积分运算吗?
如果刚才的解释还没有让你理解积分器的原理,那么直接看到机械积分器实际工作的样子应该对你有所帮助。其实它的原理出乎意料的简单,看一遍它的运行过程你肯定就能窥见其运作机制。因此我制作了一个 [运行中的机械积分器动态原理图][2],强烈建议你看一看。它展示了通过各个部件的旋转和移动求函数 $f(x)$ 的 <ruby>不定积分<rt>antiderivative</rt></ruby> $F(x)$ 的过程。这可太有趣了。
![][3]
_我的可视化的一个漂亮的截图但你应该看看原图_
现在我们有了可以做积分运算的组件,但是只靠它还不足以解决微分方程。为了解释求解微分方程的全过程,我将使用布什在他 1931 年的论文中所举的例子。这个例子恰巧跟前面考虑的微分方程是在本质上是一样的。(真是奇妙的巧合!)布什使用下面的微分方程来表示下落物体的运动:
$$
\frac{d^2x}{dt^2} = -k\,\frac{dx}{dt} - g
$$
这跟前面的网球运动的方程基本上是一样的,只不过布什使用 $x$ 代替了 $h$,并且增加了一项来表示空气阻力的减速作用。这个新增项采用了最简单的形式来描述空气阻力的作用:空气减慢球速的比率正比于球的速度(这里 $k$ 是一个常比例系数,我并不关心它的具体取值)。也就说是球运动得越快,空气阻力就越大,对球的减速作用越显著。
为了配置微分分析仪来解决这个微分方程,我们需要从布什称之为“输入面板”的东西开始。输入面板其实就是一张安装在支架上的坐标纸。如果想要解更复杂的方程,首先需要操作员在坐标纸上绘制好输入函数图像,然后在机器启动时用一个与机器主体相连的指针来跟踪函数图像的轨迹。在我们举的例子中,输入是常数 $g$,所以我们只需将指针移动到正确的位置并让它保持不动即可。
剩下的变量 $x$ 和 $t$ 又是什么呢?变量 $x$ 表示球的高度,是微分分析仪的输出。它会被绘制在输出面板上的坐标纸上。输出面板与输入面板类似,只是它没有指针,取而代之的是由微分分析仪驱动的绘图笔。变量 $t$ 仅仅是按固定速率步进。(在前面模拟网球运动 Python 程序中,我们通过循环来增加 $t$。)变量 $t$ 来源于微分分析仪的电机,它通过匀速转动传动轴来驱动整个计算过程。
布什的原理图对于理解我下面要介绍的内容很有帮助。不过为了便于理解,需要先对微分方程再做一次变换。对方程两边同时进行一次积分,得到下式:
$$
\frac{dx}{dt} = - \int \left(k\,\frac{dx}{dt} + g\right)\,dt
$$
现在方程中的各项与微分分析仪运行中各部件转动量所表示的值之间有了更明确的对应关系。布什的原理图如下:
![][4]
_配置的微分分析器用于解决一个维度上的落体问题。_
在原理图的顶部是输入面板,右下角是输出面板。图中的输出面板被配置成同时绘制高度 $x$ 和速度 $\frac{dx}{dt}$。积分器在左下方,由于这是二阶微分方程,所以我们需要两个积分器。电机驱动顶部标注为 $t$ 的传动轴。(有趣的是,布什将这些水平传动轴称为“总线”。)
现在原理图中还剩下两个部件没有解释了。里边标记了 $k$ 的方框是<ruby>乘法器<rt>multiplier</rt></ruby>$k$ 是比例常数。它获取由 $\frac{dx}{dt}$ 标记的传动轴的转动量,并通过齿轮组进行放缩。用 $\sum$ 标记的方框是<ruby>加法器<rt>adder</rt></ruby>。它通过巧妙的齿轮组合将两个传动轴的的转动叠加起来驱动第三个传动轴。我们的方程中涉及了求两项之和,所以需要引入加法器。这些额外组件的引入确保了微分分析仪有足够的灵活性来模拟由各种各样的项和系数组成的方程。
我发现以慢放的方式来推演电机启动时的级联因果过程对于理解微分分析仪的原理很有帮助。电机启动后立即驱动传动轴 $t$ 匀速旋转。这样我们就有了时间的概念。这个传动轴有三个作用,分别由连接其上的三个竖直传动轴表示:它驱动了两个积分器的转盘的转动,同时带动输出面板的支架让绘图笔作图。
如果积分器的转轮被放置在转盘中心,那么传动轴 $t$ 就不会带动其它传动轴转动。积分器的转盘会转动,但是放置在转盘中心的转轮不会被带动。这时输出图像将会是一条平坦的直线。出现这种情况是因为我们没有明确指定问题的初始条件。在上面的 Python 程序中,我们需要以常量或函数参数的形式用到网球的初始速度。在启动机器之前,我们通过将两个积分器的转盘调整到合适的位置来指定速度和加速度的初始值。
设置好这些之后,传动轴 $t$ 的转动将会传导到整个系统之中。从物理上来说,许多部件会同时开始转动。但是我们可以认为转动首先传导到积分器 II然后与基于 $g$ 计算得到的加速度表达式求积分得到球的速度 $\frac{dx}{dt}$。速度又反过来作为积分器 I 的输入,推动它的转盘让输出转轮以速率 $\frac{dx}{dt}$ 转动。积分器 I 的输出作为最终结果将会被直接导向到输出面板上。
前面我有意避开了一个令人困惑的细节,那就是机器里有一个怪圈。积分器 II 以传动轴 $(k\,\frac{dx}{dt} + g)$ 为输入,但是该传动轴的转动又部分决定于积分器 II 的输出本身。这可能快把你绕吐了,但在物理上这并没有任何问题——因为所有部部件都是一同转动的。出现这种怪圈并没什么奇怪的,因为在用微分方程在描述某函数的变化率时,也经常会用该函数的函数的形式。(在这个例子中,加速度,即速度的变化率,取决于于速度。)
在将所有东西都正确配置好后,机器会输出球的高度和速度随时间变化的函数图像。这个图像是纸质的。用我们的现代数字化思维来看,这可能有点难以理解。画在纸上的函数图像能干什么?微分分析仪确实不能魔术般地给出解的简洁数学表达式,这是事实。但也请记住一点,很多的微分方程根本没有简洁的解析解。纸上的函数图像与前面模拟球下落的 Python 程序包含相同的信息:某时刻球的位置。它可以回答任何关于该问题的实际问题。
微分分析仪简直酷到爆。它虽然结构复杂,但是本质上只是一些传动轴和齿轮外的组合。要理解它的运作过程,你不必是电气工程师或者会制造芯片。然而它确实可以解微积分!它能够求解出那些靠你自己永远无法解决的微分方程问题。它证明建造计算机器的关键材料不是硅而是人类的创造力。
### 杀人
人类的创造力既能为善,也能为恶。正如我提到的,微分分析仪在历史上最知名的应用是为美国陆军计算火炮射表。鉴于二战是一场“正义的战争”,这是最好的结果。但是也不能忽视微分分析仪增强了大口径火炮的杀伤效能。火炮的确杀死了很多人。如果维基百科可信的话,在二战中死于炮火的士兵比被轻武器杀死的更多。
我们稍后再回到道德讨论上来,先快速解释一下为什么计算射表这么困难,以及微分分析仪是怎么帮助计算射表的。这是将微分分析仪应用于实际问题的很好的例子。射表能告诉炮手在射击某个距离外的目标时需要将炮口上抬多高。编制射表的一种方法是在不同的仰角下发射该火炮,并将结果记录下来。这种方法被用在靶场,比如位于马里兰的阿伯丁试验场。但是单纯通过实验观察的方式来编制射表即昂贵又耗时。在考虑到如天气状况或不同弹丸重量等其它因素时,需要进行的射击次数将会随组合爆增到无法实施的程度。所以基于少量观测数据建立数学模型,再基于该模型来填充出完整的射表是一个更好的方法。
我不想太深入讨论这些数学理论,它们实在太难了,我也不懂。但是你应该也想到了,支配飞行中的炮弹和向上抛出的网球运动的物理规律并没有什么不同。由于计算精度的需要,我们使用的微分方程不得不偏离其理想化的形式,并迅速变得面目狰狞起来。即便是最早的精确弹道理论中的公式,除其它因素外,还考虑了弹丸的重量、直径、形状、主风、海拔、大气密度以及地球自转 [^1]。
虽然关于射表计算的方程很复杂但它们跟前面的微分方程一样都可以通过微分分析仪数值求解。1935 年微分分析仪被阿伯丁试验场用于求解弹道方程。这显著加快了计算射表的速度。[^2] 然而,二战期间对于射表的需求增长太快了,以至于美国陆军计算射表的速度难以满足运往欧洲战场的武器装备的配套需求。这最终导致陆军资助了宾夕法尼亚大学的 ENIAC 项目。这促成了世界上第一台数字计算机的诞生。LCTT 译注:严格来说 ENIAC 是第二台电子数字计算机。第一台电子计算机是<ruby>阿塔纳索夫-贝瑞计算机<rt>AtanasoffBerry Computer</rt></ruby>,简称 ABC 计算机。ENIAC 能够通过重新布线运行任意程序。但建造它的主要是为了以数倍于微分分析仪的速度来计算射表。
鉴于在微分分析仪之外,射表计算问题极大地推动了早期计算领域的发展,专门挑出微分分析仪的道德问题也许是不公正的。微分分析仪并没有局限于军事领域的应用,在二战期间和二战后的很大一段时间里,由于美国军方投入的大量的拨款,整个计算领域得到了发展。
总之,我认为微分分析仪更有趣的遗产是它告诉了我们计算的本质。我惊叹于于微分分析仪能做到这么多事情,我猜你也一样。我们很容易落入这样的思维陷阱:将计算看作是由快速数字电路实现的领域。事实上,计算是更抽象的过程,电子数字电路只是实现计算的典型手段罢了。在关于微分分析仪的论文中,布什说他的发明不过是在“运用复杂机械结构来类比复杂的推理过程这一影响深远的计划”上的微小贡献。他的总结很贴切。
--------------------------------------------------------------------------------
via: https://twobithistory.org/2020/04/06/differential-analyzer.html
作者:[Two-Bit History][a]
选题:[lujun9972][b]
译者:[toknow-gh](https://github.com/toknow-gh)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://twobithistory.org
[b]: https://github.com/lujun9972
[1]: http://worrydream.com/refs/Bush%20-%20The%20Differential%20Analyzer.pdf
[2]: https://sinclairtarget.com/differential-analyzer/
[3]: https://twobithistory.org/images/diff-analyzer-viz.png
[4]: https://twobithistory.org/images/analyzer-diagram.png
[5]: tmp.MoynZsbJ7w#fn:1
[6]: tmp.MoynZsbJ7w#fn:2
[7]: https://twitter.com/TwoBitHistory
[8]: https://twobithistory.org/feed.xml
[9]: https://twitter.com/TwoBitHistory/status/1224014531778826240?ref_src=twsrc%5Etfw
[10]: tmp.MoynZsbJ7w#fnref:1
[11]: tmp.MoynZsbJ7w#fnref:2
[^1]: Alan Gluchoff. “Artillerymen and Mathematicians: Forest Ray Moulton and Changes in American Exterior Ballistics, 1885-1934.” Historia Mathematica, vol. 38, no. 4, 2011, pp. 506547., <https://www.sciencedirect.com/science/article/pii/S0315086011000279>. 
[^2]: Karl Kempf. “Electronic Computers within the Ordnance Corps,” 1961, accessed April 6, 2020, <https://ftp.arl.army.mil/~mike/comphist/61ordnance/index.html>. 

View File

@ -0,0 +1,167 @@
[#]: subject: "Get started with edge computing by programming embedded systems"
[#]: via: "https://opensource.com/article/21/3/rtos-embedded-development"
[#]: author: "Alan Smithee https://opensource.com/users/alansmithee"
[#]: collector: "lkxed"
[#]: translator: "cool-summer-021"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15525-1.html"
通过编写嵌入式系统入门边缘计算
======
> 用于操控无线调制解调器的 AT 设备包是 RTOS 最流行的扩展功能之一。
![][0]
RTOS 是一个开源的 [嵌入式设备操作系统][2],由 RT-Thread 开发。它为开发者提供了标准化的、友好的基础架构,开发者可以基于各种设备编写代码,它包含大量有用的类库和工具包,使开发过程更加便捷。
RTOS 使用的是模块方式,以便于扩展,这一点跟 Linux 类似。各种软件包可以让开发者将 RTOS 用于任何想要的目标设备。RTOS 最常用的一种扩展是 AT 设备包,它包含各种不同 AT 设备(例如调制解调器)的移植文件和示例代码。
在超过 62,000 次下载中(截止至撰写本文时),最流行的 RTOS 扩展之一是 AT 设备包,其中包括用于不同 AT 设备的移植文件和示例代码。
### 关于 AT 命令
起初AT 命令是一个协议,用于控制拨号调制解调器。随着调制解调器技术发展到较高的带宽,它仍然可以用作轻量级而高效的设备控制协议,主流的移动电话厂商也联手开发了一系列 AT 命令,用于控制移动电话上的 GSM 模块。
如今AT 命令仍然在网络通信领域具有通用性,很多设备,例如 WiFi、蓝牙、4G都支持 AT 命令。
如果你正在创建用于边缘计算输入、监控或物联网IoT的专用设备则你可能接触到一些 RTOS 支持的 AT 设备,包括 ESP8266、ESP32、M26、MC20、RW007、MW31、SIM800C、W60X、SIM76XX、A9/A9G、BC26、AIR720、ME3616、M 6315、BC28 和 EC200X。
RT-Thread 包含套接字抽象层SAL组件SAL 实现了多种网络协议和接口的抽象,为上层提供了一系列标准的 [BSD 套接字][3] API。SAL 进而接管了 AT 的套接字接口,所以开发者只需要考虑网络应用层提供的网络接口。
这个软件包实现了设备(包括上述设备)上的 AT 套接字功能,支持通过标准套接字接口以 AT 命令的形式通信。[RT-Thread 编程指南][4] 中就有关于这些功能的详细介绍。
at_device 软件包是在 LGPLv2.1 许可证下分发的,借助 [RT-Thread Env 工具][5] 可以方便地获取到。该工具包含一个配置器和一个包管理器,它们分别用于配置内核和组件功能,可以用于定制组件并管理在线包。有了这些工具,开发者可以像搭积木一样构建系统。
### 获取 AT 设备包
为了使用配置了 RTOS 的 AT 设备,你必须启用 AT 组件库和 AT 套接字功能,需要:
* RT_Thread 4.0.2+
* RT_Thread AT 组件 1.3.0+
* RT_Thread SAL 组件
* RT-Thread netdev 组件
AT 设备包已经针对多种版本进行了相应的更新。版本不同,配置选项也相应地不同,因此必须针对相应的系统版本进行适配。目前最常用的 AT 设备包版本有:
* V1.2.0: 针对低于 V3.1.3 的 RT-ThreadV1.0.0 的 AT 组件
* V1.3.0: 针对低于 V3.1.3 的 RT-ThreadV1.1.0 的 AT 组件
* V1.4.0: 针对低于 V3.1.3 或等于 V4.0.0 的 RT-ThreadV1.2.0 的 AT 组件
* V1.5.0: 针对低于 V3.1.3 或等于 V4.0.0 的 RT-ThreadV1.2.0 的 AT 组件
* V1.6.0: 针对低于 V3.1.3 或等于 V4.0.1 的 RT-ThreadV1.2.0 的 AT 组件
* V2.0.0/V2.0.1: 针对高于 V3.1.3 的 RT-ThreadV1.3.0 的 AT 组件
* 最新版: 针对高于 V3.1.3 的 RT-ThreadV1.3.0 的 AT 组件
获取正确的版本的过程主要是在生成菜单时自动完成的。它基于现有的系统环境提供最合适的 AT 设备包。
正如前文提到的,不同的版本需要不同的配置选项。例如,
```
RT-Thread online packages  --->
     IoT - internet of things  --->
        -*- AT DEVICE: RT-Thread AT component porting or samples for different device  
        [ ]   Enable at device init by thread
              AT socket device modules (Not selected, please select)  --->    
              Version (V1.6.0)  --->
```
按线程启用 AT 设备初始化的选项决定了配置是否创建一个单独的线程来初始化设备网络。
2.x 版本支持同时启用多个 AT 设备:
```
RT-Thread online packages  --->
     IoT - internet of things  --->
        -*- AT DEVICE: RT-Thread AT component porting or samples for different device
        [*]   Quectel M26/MC20  --->
          [*]   Enable initialize by thread
          [*]   Enable sample
          (-1)    Power pin
          (-1)    Power status pin
          (uart3) AT client device name
          (512)   The maximum length of receive line buffer
        [ ]   Quectel EC20  --->
        [ ]   Espressif ESP32  --->
        [*]   Espressif ESP8266  --->
          [*]   Enable initialize by thread
          [*]   Enable sample
          (realthread) WIFI ssid
          (12345678) WIFI password
          (uart2) AT client device name
          (512)   The maximum length of receive line buffer
        [ ]   Realthread RW007  --->
        [ ]   SIMCom SIM800C  --->
        [ ]   SIMCom SIM76XX  --->
        [ ]   Notion MW31  --->
        [ ]   WinnerMicro W60X  --->
        [ ]   AiThink A9/A9G  --->
        [ ]   Quectel BC26  --->
        [ ]   Luat air720  --->
        [ ]   GOSUNCN ME3616  --->
        [ ]   ChinaMobile M6315  --->
        [ ]   Quectel BC28  --->
        [ ]   Quectel ec200x  --->
        Version (latest)  --->
```
这个版本包含了很多其他选项,其中也有启用示例代码的选项,这对初学者或使用不熟悉的设备的开发者很有帮助。
你也可以设置相应选项,选择你想用来给你的组件供电的针脚、指示电源状态的针脚、样本设备使用的串行设备的名称,以及样本设备接收数据的最大长度。在合适的设备上,你也可以设置 SSID 和密码。
简而言之,控制选项是够用的。
* V2.x.x 版本支持同时启用多个 AT 设备,欲查看启用的设备信息,在 [finsh shell][6] 中执行 `ifocnfig` 命令即可。
* V2.X.X 版本需要设备在使用前先注册;注册可以在样例目录中进行,或在应用层以自定义方式进行。
* 针脚选项,例如电源针脚和电源状态针脚是按照设备的硬件连接来配置的。如果硬件的开启功能不可用,它们就会被设置为 `-1`
* 一台AT 设备应当对应一个序列名称,每台设备的 AT 客户端名称应当是不同的。
### AT 组件配置选项
当选择了 AT 组件包启用了设备支持AT 组件的客户端功能也就默认选择完成了。对 AT 组件来说,这就意味着有更多的选项要设置:
```
RT-Thread Components  --->
    Network  --->
        AT commands  --->
    [ ]   Enable debug log output
    [ ]   Enable AT commands server
    -*-   Enable AT commands client
    (1)     The maximum number of supported clients
    -*-     Enable BSD Socket API support by AT commnads
    [*]     Enable CLI(Command-Line Interface) for AT commands
    [ ]     Enable print RAW format AT command communication data
    (128)   The maximum length of AT Commonds buffer
```
与 AT 设备包有关的配置选项有:
* 支持的客户端最大个数:选择 AT 设备包中的多台设备时,需要将该选项配置为对应的设备台数;
* 通过 AT 命令启用 BSD 套接字 API 功能:当选择 AT 设备包时默认选择该选项。
* AT 命令的最大长度AT 命令可发送的数据的最大长度
### 一切皆有可能
当你开始进行嵌入式系统编程你会很快意识到你可以创造自己想象得到得任何东西。RTOS 旨在帮助你实现它,它的那些功能包为你提供了良好的开端。现在,设备的互联也是可期待的。边缘的物联网技术必须能够通过各种协议进行通信,而 AT 协议是关键。
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/3/rtos-embedded-development
作者:[Alan Smithee][a]
选题:[lkxed][b]
译者:[cool-summer-021](https://github.com/cool-summer-021)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/alansmithee
[b]: https://github.com/lkxed
[1]: https://opensource.com/sites/default/files/lead-images/tips_map_guide_ebook_help_troubleshooting_lightbulb_520.png
[2]: https://opensource.com/article/20/6/open-source-rtos
[3]: https://en.wikipedia.org/wiki/Berkeley_sockets
[4]: https://github.com/RT-Thread/rtthread-manual-doc/blob/master/at/at.md
[5]: https://www.rt-thread.io/download.html?download=Env
[6]: https://www.rt-thread.org/download/rttdoc_1_0_0/group__finsh.html
[7]: https://www.redhat.com/en/topics/edge-computing
[0]: https://img.linux.net.cn/data/attachment/album/202302/10/065738jhzvfgfgyvfznfhz.jpg

View File

@ -0,0 +1,117 @@
[#]: subject: (Try quantum computing with this open source software development kit)
[#]: via: (https://opensource.com/article/21/6/qiskit)
[#]: author: (Gordon Haff https://opensource.com/users/ghaff)
[#]: collector: (lujun9972)
[#]: translator: (cool-summer-021)
[#]: reviewer: (wxy)
[#]: publisher: (wxy)
[#]: url: (https://linux.cn/article-15552-1.html)
借助开源软件开发包尝试量子计算编程
======
> Qiskit 是一个开源 SDK借助它可以免费访问量子模拟器和硬件资源。
![][0]
经典计算机是基于二进制数的,二进制数有 0 和 1 两种形式。这并不是由于二进制逻辑系统比有更多基本状态的逻辑系统(甚至包括模拟计算机)有内在优势。而是,对电路元件的开关操作很容易实现,而且借助先进的半导体技术,可以制造出体积小且价格低廉的计算机。
但它们并非没有局限性。经典计算机求解某些问题的效率并不高,主要是那些时间或内存成本随着问题的规模($n$)呈指数级增长的问题。我们把这种问题称为 $O(2^n)$[大 O 表示法][2])。
大部分现代加密方法甚至依赖这一特性。把两个大素数相乘,耗费的成本低($O(n^2)$),但进行反向操作就非常耗时。所以只要使用的数字足够大,对它分解质因数就非常困难。
### 进入量子世界
量子计算的基础数学和力学知识不在本文的探讨范围内。然而,还是有一些基础知识需要预先说明。
量子计算机以 [量子比特][3] 代替了二进制比特 —— 量子比特是体现量子属性的可控计算单元。构成量子比特的通常是超导元件,或自然界中存在的量子实物(例如电子)。量子比特可以以“<ruby>叠加<rt>superposition</rt></ruby>”状态存在,叠加态是 0 和 1 以某种方式组合起来的复杂状态。你可能听说过,量子比特既为 1 又为 0这种说法并不准确。真实情况是如果进行测量量子比特的状态会坍缩为 0 或 1。在数学上量子比特未测量的状态可以看作 <ruby>[布洛赫球面][4]<rt>Bloch sphere</rt></ruby> 的几何表示上的一个点。
尽管对习惯使用经典计算机的任何人来说,叠加态是一个全新的概念,但一个量子比特本身并没有什么趣味性。量子计算的第二个概念是“<ruby>干涉<rt>interference</rt></ruby>”。真正的量子计算机本质上是统计性质的。量子算法对干涉图案进行编码,增加了可以测量编码方案的状态的概率。
叠加和干涉的概念虽然新颖,但在物理世界中也有对应的现象。而量子力学中的“<ruby>纠缠<rt>entanglement</rt></ruby>”却没有,但它是实现指数级量子加速的真正关键。借助量子纠缠,对一个微观粒子的测量可以影响后续对其他被纠缠的粒子的测量结果 —— 即使是那些物理上没有关联的粒子。
### 量子计算能做什么?
今天的量子计算机就其包含的量子比特的数量而言是相当小的,只有几十到几百个。因此,虽然人们不断开发新的算法,但比同级别经典计算机运行得快的硬件还未问世。
但是在很多领域,量子计算机能带来很大好处。例如,它能提供较好的方法来模拟自然界的量子系统,例如分子,其复杂程度超过了经典计算机的建模能力。量子计算也跟线性代数有关,它是机器学习和很多其他现代优化问题的基础。因此,我们有理由认为量子计算也可以很好地适用于此。
在量子算法相对于普通算法的优势方面,[Shor 算法][5] 是经常被提及的例子,它在较早时候就用于分解质因数。它由 MIT 的数学家 Peter Shor 于 1994 年发明,量子计算机目前还不能在较大的问题上运行该算法。但它已经被证明可以在 $O(n^3)$ 时间内完成工作,而不像经典算法那样需要指数级的时间。
### 从使用 Qiskit 开始
你可能在想:“我身边没有量子计算机,但我很想尝试一下。能做到吗?”
我们来了解一下名称为 [Qiskit][6] 的开源项目(采用 Apache 2.0 许可证。它是一个软件开发包SDK用于访问 IBM 量子实验室的量子计算模拟器和物理硬件(免费)。你只需要注册获得一个 API 密钥。
当然,如果要深入研究 Qiskit需要很多其他方面的知识线性代数只是其中一部分这些都远远超出了本文的范围。如果你需要深入学习网上有很多免费资源其中也不乏完整的教科书。然而体验一下也很简单只需要一些 Python 和 Jupyter notebook 的基础知识即可。
为了增加趣味性,我们全程使用 [Qiskit 教程][8] 的 “Hello, World!” 程序:
首先,安装教程的相关工具和部件:
```
pip install git+https://github.com/qiskit-community/qiskit-textbook.git#subdirectory=qiskit-textbook-src
```
下一步,进行软件包的导入:
```
from qiskit import QuantumCircuit, assemble, Aer
from math import pi, sqrt
from qiskit.visualization import plot_bloch_multivector, plot_histogram
```
`Aer` 是本地模拟器。Qiskit 包括四个组件:`Aer`、基础组件 `Terra`、用于实际的量子系统上的噪音和错误处理的 `Ignis`,以及用于算法开发的 `Aqua`
```
# Let's do an X-gate on a |0> qubit
qc = QuantumCircuit(1)
qc.x(0)
qc.draw()
```
虽然底层数学原理还涉及到矩阵乘法,量子计算机中 X 门也可以认为类似于经典计算机中的非门。(事实上,它经常被称为 "非门")。
现在,运行并测量它。结果跟你预期的一样,因为量子比特的初始状态是 `|0>`,接着反转,然后被测量。(使用 `|0>``|1>` 与经典计算机中的比特区分开来。)
```
# Let's see the result
svsim = Aer.get_backend('statevector_simulator')
qobj = assemble(qc)
state = svsim.run(qobj).result().get_statevector()
plot_bloch_multivector(state)
```
![Bloch sphere showing the expected result][9]
*布洛赫球体显示了预期的运行结果*
### 结论
在某些方面,你可以把量子计算看作用于经典计算机的一种独特的协处理器,跟 GPU 和 FPGA 一样。不同的是,在可预见的未来,量子计算机可以被用户像网络资源一样访问到。另一个差异是,它们的工作有本质的不同,所以不像很多其他你熟悉的加速器那样。因此,人们对算法开发如此感兴趣,并投入大量资源来研究量子在何时何地的性能最好。了解一下这些东西也无妨。
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/6/qiskit
作者:[Gordon Haff][a]
选题:[lujun9972][b]
译者:[cool-summer-021](https://github.com/cool-summer-021)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/ghaff
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/gears_devops_learn_troubleshooting_lightbulb_tips_520.png?itok=HcN38NOk (Tips and gears turning)
[2]: https://en.wikipedia.org/wiki/Big_O_notation
[3]: https://en.wikipedia.org/wiki/Qubit
[4]: https://en.wikipedia.org/wiki/Bloch_sphere
[5]: https://en.wikipedia.org/wiki/Shor%27s_algorithm
[6]: https://qiskit.org/
[7]: https://qiskit.org/learn
[8]: https://qiskit.org/textbook/preface.html
[9]: https://opensource.com/sites/default/files/uploads/bloch-sphere.png (Bloch sphere showing the expected result)
[10]: https://creativecommons.org/licenses/by-sa/4.0/
[0]: https://img.linux.net.cn/data/attachment/album/202302/18/173656shxb63jjx9z5jwxl.jpg

View File

@ -0,0 +1,141 @@
[#]: subject: "3 steps for managing a beginner-friendly open source community"
[#]: via: "https://opensource.com/article/21/8/beginner-open-source-community"
[#]: author: "Isabel Costa https://opensource.com/users/isabelcmdcosta"
[#]: collector: "lujun9972"
[#]: translator: "XiaotingHuang22"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15534-1.html"
管理对新手友好的开源社区的三个步骤
======
> 作为一个开源项目的成员,你可以做很多事情来帮助新手找到为项目作出贡献的方式。
![][0]
当有人刚开始为开源做贡献时,最好从对新手友好的故障和议题开始。但在他们修复故障之前,他们必须要能够找到这类问题。作为一个开源项目的成员,你可以做很多事情来帮助新手找到为项目贡献的方式。
鉴于此,[AnitaB.org 开源社区][2] 优先考虑让我们的社区做到对新手友好。我们提倡包容性,确保不同经验和水平的贡献者都可以参与进来,并且他们的贡献不止限于跟编程有关。
我最近在 [Upstream 2021][4],即 Tidelift 活动中介绍了我们在 [AnitaB.org][3] 上所做的一些社区工作,该活动启动了“维护者周”,这是一个为期一周的开源维护者庆祝活动。在活动中我讨论了我们策略的三个主要部分:
* 我们如何沟通
* 项目和议题
* 开源项目
### 我们如何沟通
透明度是开源的重要组成部分,我们将透明度原则应用于我们的沟通方式。实际上,这意味着我们所有的社区会议都是公开进行的,并且影响我们设置 Zulip 聊天的方式以及我们提供文档的方式。
#### 开放会议
任何人都可以加入我们的会议,并讨论与我们社区相关的话题。他们可以参与讨论或者旁听。会议相关信息在我们的社区日历中都可以找到。在这些通话中我们通常只使用语音聊天,我们发现这可以让人们在参与时感觉更自在。
我们举办以项目为中心的会议和一些分类的会议。会议上,来自不同领域的人们可以讨论同一个项目并帮助改进我们的流程。偶尔,我们会有“<ruby>自由提问<rt>Ask Me Anything</rt></ruby>AMA”会议任何人都可以来问任何与开源相关的问题。
所有会议我们都会在共享文档中进行记录,并在 [我们的 Zulip][5] 中共享摘要和文档链接。
#### 我们的 Zulip 聊天
开源 Zulip 聊天平台是我们的主要社区交流渠道,虽然我们也在 Github 的评论区讨论议题和<ruby>拉取请求<rt>Pull Request</rt></ruby>PR。一般来说我们禁用了私人消息以确保我们尽可能透明。对于这条规则我们只有少数例外那些私人聊天是管理员在处理我们运行程序的后勤工作所用的。我们发现这种方法更受欢迎它还使我们能够更清楚公共聊天中的违规行为。
我们在 Zulip 聊天室分享所有会议摘要,包括讨论的要点、行动项目和文档。这些听起来好像是些显而易见的要求,但我一直惊讶于很多开源项目并不提供会议笔记,所以 Zulip 可以让那些没有参加会议的人也随时了解情况。
在 Zulip上我们讨论项目路线图回答社区的问题和疑问并积极**促进人们通过不同的方式方法和在不同的场景下做出自己的贡献**。有时我们为贡献者的成就而庆祝 —— 无论是为了突出他们测试或者审查的第一个拉取请求,还是强调我们志愿者所做的出色工作。
#### 文档
我们尽量保持**关于我们流程的开放文档**,例如常见问题解答,以便这些社区成员可以按照自己的节奏和时间了解社区。这是为了让他们在联系我们之前了解我们的工作方式以及我们从事的工作类型。
### 项目和议题
关于我们的项目和议题管理,我们鼓励通过多种方式做出贡献,我们为新手专门创建特定的议题,并尝试让项目的设置变得简单。
#### 多种贡献的方式
我们努力创建**需要不同贡献的问题**,例如文档、测试、设计和外展。这是为了让任何人 —— 无关他们的经验水平和兴趣领域 —— 都能做出贡献。这样能够帮助社区参与进来,而且我们发现它使成员能够从一些省力但有价值的任务开始一步步做出贡献。
我们提倡的贡献类型有:
* 不同复杂性的编程任务。
* 质量保证任务 —— 贡献者可以测试我们的应用程序或拉取请求并报告错误。
* 社区成员可以参与讨论的设计会议。此外,创建模型和重新设计我们应用程序某些部分的机会,并探索改进用户体验。
* 外展任务,我们主要在 Zulip 上推广,我们建议在我们的 Medium 出版物上发表博客,介绍他们的开源经验和他们的贡献。
* 文档任务,可以包括一般社区文档或我们在 Docusaurus 上的项目文档。
#### 仅限新手的问题
我们将一些**议题标记为“仅限新手”**。这些问题适用于尚未为议题存储库做出贡献的人。为议题做标签还使我们能够让人们在贡献者大量涌入时开始他们的开源之旅,例如,在 [谷歌编程之夏GSoC][6] 申请期间。
有时,这些可能是“唾手可得的果实”,可以让他们熟悉作出贡献和提交拉取请求的过程。
#### 简单的项目设置
我们也很在意为我们的项目提供**新手友好的安装设置**。我们注意到最活跃的项目通常是最容易设置的。我们知道,为你不熟悉的项目做出贡献可能需要付出很多努力并且关乎贡献体验的成败。
我们尝试提供有关如何在多个操作系统上运行我们项目的说明。在过去,我们有一些项目有单独的说明,可以在 Unix 环境下运行,我们注意到贡献者在 Windows 上运行这些项目有些困难。自那以后我们不断进行改进,以避免贡献者在 Zulip 上寻求帮助时出现混乱。
我们根据贡献者的经验,一直在改进我们最活跃的项目之一 [mentorship-backend][7] 的自述文件。新手在这个项目中遇到的困难之一是设置与配置电子邮件帐户相关的部分环境变量,以使后台功能能够发送电子邮件。但是,由于此功能对于本地开发并不重要,因此默认情况下,我们将电子邮件设置设为可选,以便将电子邮件打印到终端,而不是发送给用户。这种方法仍然使贡献者可以看到这些电子邮件。与此更改类似,我们将 [SQLite 数据库][8] 作为本地开发的默认设置,以避免对 Postgres 数据库进行额外设置,虽然我们在部署版本中会使用到 Postgres。
我们注意到,一些贡献者在为我们的 [bridge-in-tech-backend][9] 项目做出贡献时觉得很困难,该项目的设置很复杂,并且包含的步骤比 [mentorship-backend][7] 多得多。自从我们在一个开源项目中注意到这一点以来,我们一直在探索如何改进其结构。
对于我们的大多数项目,我们还提供应用程序的实时体验版本或打包版本,以便贡献者无需设置即可测试项目。这有助于我们为那些对开发设置不感兴趣或不熟悉的贡献者提供一种方式,来尝试我们应用程序的最新版本,并通过报告发现的任何错误来做出贡献。我们在 [质量保证指南][10] 中放了这些应用程序的链接。
### 开源计划
我们在社区中组织了两个主要计划开源黑客OSH一个为期一个月的项目和 Open Source Ambassadors一个为期六个月的项目
#### 开源黑客OSH
在此计划中,我们在多个类别的贡献中创建议题 —— 文档、编码、外展、测试和设计(类似于 [谷歌的 Code-in][11] 竞赛)。 参与者可以为每个类别至少贡献一次并获得电子证书。一个议题可能包含多个类别,并且无需合并拉取请求也能使贡献有效。
我们为这个计划选取几个项目,请导师们集思广益为参与者创造议题。项目开始后参与者可以认领议题并开始作出贡献。导师们会支持帮助并审查他们的贡献。
这种方法鼓励贡献的多样性,并欢迎任何人,无论他们的编码能力如何,都可以在友好和不怕出错的环境中做出贡献。
#### 开源大使
在此计划中,我们从社区中选择大使,理想情况下他们将涵盖我们旨在促进的每一类贡献。至今该计划已启动了两次。
该计划旨在让成员通过回答社区的议题、协助贡献者参与并为他们指定的类别宣传来帮助管理项目和计划。
第一个计划举行时我们接受了所有的申请者。我们评估了社区成员的兴趣所在,并为那些想要做出贡献但最初不敢踏出第一步的人提供了一个体系。
第一个计划的举办给了我们很多启发。因为我们的活动中既有经验丰富的开源贡献者和社区成员,也有初来乍到缺乏经验的新手,因此项目的执行要求管理员进行大量的管理工作。一些社区大使信心十足准备好进一步采取新措施,而其他大使则需要更多支持。到了第二个,我们决定缩减该计划,只接受那些已经熟悉社区、可以领导倡议和项目并帮助我们培训新人的贡献者。
第二个计划中形成了正反馈循环。那些在第一个计划中还是新手的大使们,通过为上一个项目做出贡献并且从项目经验中学习之后能够做到轻松带领项目。
这种方法的改变使管理员能够更加专注于支持大使团队,帮助他们传播我们的使命,并继续让我们的社区对新手友好,并指导更多人做出贡献。
### 总结
这些计划帮助我们提高了对开源贡献和回馈的不同方式的认识。通过它们,我们发现志愿者通过管理项目和举办公开会议来提供帮助,这有助于管理社区并为我们的贡献者提供指导。
尽管我们得到了贡献者的良好反响,并帮助人们做出了他们的第一个贡献,但我们仍有很大的改进空间。我们将继续改进我们项目的设置和贡献指南,以改善贡献者的体验。我们还将继续专注于确保我们的组织始终拥有并推动不同类别的问题,促进包容性,以便任何有意愿做出贡献的人都能出自己的一份力。
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/8/beginner-open-source-community
作者:[Isabel Costa][a]
选题:[lujun9972][b]
译者:[XiaotingHuang22](https://github.com/XiaotingHuang22)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/isabelcmdcosta
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/wfh_work_home_laptop_work.png?itok=VFwToeMy (Working from home at a laptop)
[2]: https://github.com/anitab-org
[3]: https://anitab.org/
[4]: https://youtu.be/l8r50jCr-Yo
[5]: https://anitab-org.zulipchat.com/
[6]: https://summerofcode.withgoogle.com/
[7]: https://github.com/anitab-org/mentorship-backend#readme
[8]: https://opensource.com/article/21/2/sqlite3-cheat-sheet
[9]: https://github.com/anitab-org/bridge-in-tech-backend
[10]: https://github.com/anitab-org/documentation/blob/master/quality-assurance.md
[11]: https://codein.withgoogle.com/
[0]: https://img.linux.net.cn/data/attachment/album/202302/12/222832vxfof8844fo4vsl4.jpg

View File

@ -0,0 +1,96 @@
[#]: subject: "My favorite LibreOffice productivity tips"
[#]: via: "https://opensource.com/article/21/9/libreoffice-tips"
[#]: author: "Don Watkins https://opensource.com/users/don-watkins"
[#]: collector: "lujun9972"
[#]: translator: "XiaotingHuang22"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15530-1.html"
提高 LibreOffice 生产力的技巧
======
![][0]
> 今天我将和大家分享一些 LibreOffice 的键盘快捷键和排版技巧,希望能够帮你省下宝贵的时间。
LibreOffice 是我首选的生产力应用程序。它是向教育工作者和学生推荐 Linux 发行版的最有力理由之一,无论是 PK-12 还是高等教育。新的学年快到了,我想也是时候推荐一些 LibreOffice 快捷方式和技巧,它们可以为你节省宝贵的时间。
### 使用键盘快捷键让你工作更快捷
我平时经常使用键盘快捷键,以下是适用于所有 LibreOffice 应用程序的最常见的快捷键
* `Ctrl+N` — 创建新文档
* `Ctrl+O` — 打开一个文档
* `Ctrl+S` — 保存文档
* `Ctrl+Shift+S` — 另存为
* `Ctrl+P` — 打印文档
这些是仅适用于 LibreOffice Writer 的快捷键:
* `Home` — 移动到当前行的初始位置
* `End` — 移动至当前行的结尾位置
* `Ctrl+Home` — 将光标移动到文档的初始位置
* `Ctrl+End` — 将光标移动到文档的结尾位置
* `Ctrl+A` — 全选
* `Ctrl+D` — 双下划线
* `Ctrl+E` — 居中
* `Ctrl+H` — 查找并替换
* `Ctrl+L` — 左对齐
* `Ctrl+R` — 右对齐
功能键也大有用处:
* `F2` — 打开公式栏
* `F3` — 自动补完
* `F5` — 打开导航器
* `F7` — 打开拼写和语法
* `F11` — 打开格式和排版
* `Shift+F11` — 创建新样式
### 文档格式
文档格式有很多种LibreOffice 支持其中很多文档格式。默认情况下LibreOffice 将文档保存为 <ruby>开放文档格式<rt>Open Document Format</rt></ruby>ODF这是一种开源标准将样式表和数据存储在 ZIP 容器中,文本文档标记为 ODT电子表格标记为 ODS演示文稿标记为 ODP。它是一种灵活的格式由 LibreOffice 社区和文档基金会维护。
ODF 是默认启用的,因此你无需执行任何操作即可让 LibreOffice 使用这种格式。
另一种文档开放规范是微软的 [Office Open XMLOOXML格式][2]。它是一个 ISO 标准,并得到所有主要办公解决方案的良好支持。
如果你与使用微软 Office 的人一起工作(它本身不是开源的,但它确实使用开放的 OOXML 格式),那么他们肯定习惯于 DOCX、XLSX 和 PPTX 格式,并且可能无法打开 ODT、ODS 或 ODP 文件。你可以通过在 LibreOffice 中将 OOXML 设置为默认格式来避免很多混乱。
将 OOXML 设置为你的首选格式:
1. 单击 “<ruby>工具<rt>Tools</rt></ruby>” 菜单并选择菜单底部的 “<ruby>选项<rt>Options</rt></ruby>”。
2. 在 “<ruby>选项<rt>Options</rt></ruby>” 窗口中,单击左侧面板中的 “<ruby>加载/保存<rt>Load/Save</rt></ruby>” 类别,然后选择 “<ruby>常规<rt>General</rt></ruby>”。
![LibreOffice设置面板][3]
3. 导航到 “<ruby>默认文件格式和 ODF 设置<rt>Default File Format and ODF Settings</rt></ruby>” 部分。
4. 在 “<ruby>文档类型<rt>Document type</rt></ruby>” 选择 “<ruby>文本文档<rt>Text document</rt></ruby>”,并在 “<ruby>始终另存为<rt>Always save as</rt></ruby>” 下拉列表选择 “Open XML (Transitional) (*.docx) ”。
5. 点击 “<ruby>应用<rt>Apply</rt></ruby>” 然后点击 “<ruby>确定<rt>OK</rt></ruby>”。
6. 取消选择 “<ruby>未以 ODF 或默认格式保存时发出警告<rt>Warn when not saving in ODF or default format </rt></ruby>” 以避免在保存时出现确认对话框。
![LibreOffice 保存格式][5]
按照相同的逻辑重复,重复相同的过程用于 XLSX 和 PPTX 文档。
### 让办公更自由
LibreOffice 项目由蓬勃发展的用户和开发人员社区与文档基金会共同管理。这包括工程指导委员会、董事会、独立开发人员、设计师和翻译人员等。这些团队始终欢迎各位的贡献,因此如果你渴望参与一个超赞的开源项目,请不要犹豫 [参与进来][6]。
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/9/libreoffice-tips
作者:[Don Watkins][a]
选题:[lujun9972][b]
译者:[XiaotingHuang22](https://github.com/XiaotingHuang22)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/don-watkins
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/lenovo-thinkpad-laptop-window-focus.png?itok=g0xPm2kD (young woman working on a laptop)
[2]: https://www.iso.org/standard/71691.html
[3]: https://opensource.com/sites/default/files/uploads/libreoffice-panel.jpg (LibreOffice settings panel)
[4]: https://creativecommons.org/licenses/by-sa/4.0/
[5]: https://opensource.com/sites/default/files/uploads/libreoffice-save-format.jpg (LibreOffice save formats)
[6]: https://www.libreoffice.org/community/get-involved/
[0]: https://img.linux.net.cn/data/attachment/album/202302/11/161923gks1dsldq7dd1z67.jpg

View File

@ -0,0 +1,104 @@
[#]: subject: "How curiosity helped me solve a hardware problem"
[#]: via: "https://opensource.com/article/22/1/troubleshoot-hardware-sysadmin"
[#]: author: "David Both https://opensource.com/users/dboth"
[#]: collector: "lujun9972"
[#]: translator: "toknow-gh"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15562-1.html"
好奇心帮我解决了一个硬件问题
======
![][0]
> 好奇心能激发人们对于知识和真理的渴求,无论是对于硬件、开源软件、编程、组装个人电脑、优化系统设置,还是只是学习使用一个新软件。
![Puzzle pieces coming together to form a computer screen][1]
我通常在家架设运行一个由一打计算机组成的家庭网络 —— 没错,正好 12 台计算机。同时我还负责其它地方的一些计算机维护工作。由于计算机很多,总会出现各种各样的故障,其中有很多最终确诊为硬件问题。但是要判定出是哪个硬件设备引发的故障却是一件难事。
就在这周,我的主工作站上出现了一个棘手的问题,导致我两次误判了问题的原因。本文将带你跟随我排查问题的过程。我将告诉你我在哪一步做了错误的判断以及为什么,还有误判是多么容易发生。
### 最初的症状
我手上一直有好几个项目。最近,我在几台台式机上打开了很多应用程序,我刚开始工作,突然就黑屏了。主工作站的大多数(不是全部)风扇都停了,这让我倒吸一口凉气。我从来没有遇到过这种情况,但显然我的系统出问题了。
我有两条主要线索可以跟进:一是显示黑屏,二是有些风扇不转了。但是前面板上的电源和磁盘活动指示灯还是亮的,只是比平常要暗一点。大多数安装在主板、内存条和风扇上的 RGB 装饰灯也都灭了。
我试过按电源键和重启键,都没有反应。我直接按供电单元的船型开关关闭了电源。重新供电后还是出现了刚才的症状。
### 最初的猜想
问题的现象和我数十年处理各类故障的经验将原因指向了供电问题。
我将供电单元拆了下来并用电源测试仪对它进行了检查。结果是供电单元没有任何问题,各项电压都符合规范。当然测试仪的结果也可能是错误的。测试仪并没有在满负荷状态下进行测试,比如计算机运行中耗电几百瓦的情况。我凭直觉更换了一个一千瓦的备用电源。
由于我的家庭网络中有 12 台计算机,我已经习惯准备了一些备用配件在身边。这样当有配件损坏时,我就不必非得跑一趟附近的电脑城或者网购后等快递了。由于计算机这么多,配件损坏是经常的事。
虽然电源测试仪告诉我电源没有问题,但更换电源后问题确实消失了。即便检测仪在过去都是正确的,我的经验、知识和直觉告诉我就是电源问题。
不幸的是,我的直觉错了。
### 第二个猜想
没过多久我的工作站再次又了相同的问题。但两个不同的供电单元有相同问题的可能性太低了。
我马上想到那一定是主板出问题了。我没有备用的主板,所以网购了一块新主板。我想到其实可以用上手上多余的内存条,然后把 CPU 连同一体水冷单元一起装到新主板上。
### 专业的故障排查
新主板需要几天天才能送到所以我决定先将工作站上的旧主板拆下来。就在拔掉主板供电之前我的好奇心显现并驱使我给只剩主板、CPU 和内存的系统开机。我已经把其它的部分都拆掉了。
好的故障排除过程需要分离所有潜在变量,目前我只是对供电单元进行了测试。我需要对每个组件都进行测试。
这需要我先拔掉前面板上的扬声器和多功能面板连接线。多功能面板上集成了各种 USB、SATA 和内存卡插槽。
令人惊讶的是,当只有主板通电时竟然一切正常。
计算机本身无法开机,因为根本没有连接存储器。也不会有显示输出,因为我已经把显卡拆掉了。但是没有电源或主板故障的迹象。这进一步激发了我的好奇心。如果主板真的有问题的话,故障现象应该仍然存在才对。
所以我开始一系列的重复试验:断电,安装一个已经拆掉的配件,重新上电。
最终发现问题上由前置多功能面板引发的。
我拆除了多功能面板并将其它零件全部装了回去。工作站开机正常,运行良好。终于让我逮到罪魁祸首了。
### 起因
弄清真正的问题之后,我立刻就明白了问题的根本原因。这还要从几天前说起。那时我正在测试一些外接 USB 设备,包括几种摄像头、几个用于备份的存储设备和一个外接 USB 集线器。
我把一根 USB 连接线插到了多功能面板上的一个 USB 2.0 插口中。所有东西都停摆了大部分灯熄灭了风扇也不转了。USB 连接线发热很严重,我拔掉它时还把手指烫伤了。原来我不小心将连接线的 C 型插头插到了一个 USB 3.0 A 型插口里,导致了供电短路。
拔掉 USB 连接线之后,一切都恢复了“正常” —— 但事实并非如此。我粗心的错误对多功能面板造成了损伤,它在坚持了几天之后彻底短路了。
### 妄下结论
知识和经验有时候比电源测试仪之类的工具更重要。当然知识跟经验有时候也不管用。我最终找到了问题的真正原因,但其实我本该早就发现的。
尽管我在问题跟供电有关这一点上是对的,但还是误入歧途了。原因是我没能正确解读问题现象并根据线索调查得出逻辑结论导致的。我本可以更早找出问题的根本原因的,这样就不至于在修好主工作站之前浪费那么多时间在将我的笔记本变成临时主要设备上了。
系统管理员总与复杂的设备打交道,过早下结论在所难免。我有超过 50 年的从业经验,还是犯了这样的错误。我只需记住做几个 [深呼吸][2],然后刨根问底直到找到问题的根本原因。
### 好奇心
至少在等待新主板到货期间,我遵循了自己的好奇心。这让我比等新主板到货要早得多将事情恢复正常。同时也避免了我在没有充分测试的情况下把一块完好的主板丢掉。
谚语说好奇心害死猫。我讨厌这个谚语,因为它被家长、学校、见识短浅的老板、老师和那些不想被我们这种好奇宝宝干扰的人用得太多了。事实上,好奇心激发了对于人们对于知识和真理的渴求。这可能是关于硬件、开源软件、编程、组装个人电脑、优化系统设置或者学习使用新软件。满足你的好奇心吧!
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/1/troubleshoot-hardware-sysadmin
作者:[David Both][a]
选题:[lujun9972][b]
译者:[toknow-gh](https://github.com/toknow-gh)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/dboth
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/puzzle_computer_solve_fix_tool.png?itok=U0pH1uwj (Puzzle pieces coming together to form a computer screen)
[2]: https://opensource.com/article/21/11/linux-yoga
[0]: https://img.linux.net.cn/data/attachment/album/202302/21/164251s0ow0eewvnebwzcw.jpg

View File

@ -0,0 +1,94 @@
[#]: subject: "How we hired an open source developer"
[#]: via: "https://opensource.com/article/22/2/how-we-hired-open-source-developer"
[#]: author: "Mike Bursell https://opensource.com/users/mikecamel"
[#]: collector: "lujun9972"
[#]: translator: "XiaotingHuang22"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15543-1.html"
我们是如何聘请开源开发人员的
======
> 我的团队不再采用标准的算法编程笔试,而是采用一套能够产出更多相关成果的流程。
![][0]
作为初创安全公司 [Profian][2] 的首席执行官和联合创始人,我参与了我们聘请开发人员从事 [Enarx][3] 的工作。Enarx 是一个处理机密信息计算的安全项目,几乎完全用 [Rust 语言][4] 编写少部分用汇编语言。Profian 现在已经在这次招聘找到了所有要找的人一些开发人员将在接下来的几周内开始工作。然而Enarx 绝对欢迎新的贡献者,如果事情继续顺利,公司将来肯定会雇用更多的人。
招聘人员并不容易,加上 Profian 还有一系列特别的要求,这让招人变得更加困难。因此我认为分享我们如何解决这个问题应该还蛮有意思的,而且也会对社区有帮助。
### 我们寻找什么样的人才?
以下就是我前文提到的特别要求:
* **系统编程**Profian 主要需要那些喜欢系统层编程的人。这一层面的编程已经处于栈的底层,有很多直接与硬件或操作系统的交互。例如,要创建客户端-服务器部分,我们必须编写相当多的协议、管理加密等等,而这方面的工具还不是很成熟(请参阅下面的 “Rust” 一节)。
* **Rust**:项目几乎都是用 Rust 语言编写的,那些不是的则是用汇编语言写的(目前只有 x86 平台尽管随着我们添加更多平台情况可能会有所改变。Rust 是一门很新、很酷同时也令人兴奋的编程语言,但它同时也很年轻,并且一些领域没有你想要的所有支持或者没有你希望的那么成熟 —— 这包括从密码学到多线程库到编译器/构建基本架构。
* **分散各地的团队**Profian 正在建立一个能够及时通讯联系的团队。Profian 在德国、芬兰、荷兰、北卡罗来纳州(美国)、马萨诸塞州(美国)、弗吉尼亚州(美国)和乔治亚州(美国)都有开发人员。我在英国,我们的社区经理在巴西,我们有来自印度和尼日利亚的实习生。从一开始我们就知道团队很难聚集在一个地方工作,因此我们需要能够通过视频、聊天和(最不济的情况下)电子邮件与人交流和协作的成员。
* **安全**Enarx 是一个安全项目。虽然我们并不是专门在寻找安全专家,但我们需要能够将安全放在首位去思考和工作,并设计和编写适用于安全环境的代码的人。
* **Git**:我们所有的代码都存储在 Git 中(主要是 [GitHub][5],还有一些存在 GitLab。我们围绕代码的大部分交互都是围绕 Git 进行的,因此任何加入我们团队的人都需要能自如使用它作为日常工作中的标准工具。
* **开源**:开源不仅仅是许可;更是一种心态,同时,这也是一种合作方式。大量开源软件是由不同地域的人创建的,他们甚至可能不认为彼此身处于一个团队。我们需要知道我们招的人不仅能在公司内部凝聚成一个紧密的团队,同时也能够与组织外部的人员协作,并接受 Profian 的“默认开放”文化,这里的开放不仅仅限于代码,还要有开放的讨论、沟通和文档。
### 我们是如何找到人才的?
正如我在其他地方提到的,[招聘很困难][6]。Profian 使用多种方式寻找候选人,它们取得了不同程度的成功:
* 领英招聘广告
* 领英搜索
* 特定语言的讨论板和招聘板例如Reddit
* 外部招募人员(特别致敬来自 [Interstem][7] 公司的 Gerald
* 口耳相传/个人推荐
虽然很难从质量方面判断这些来源如何,但如果没有外部招聘人员,我们肯定会在数量上苦苦挣扎(我们也有一些来自该途径的优秀候选人)。
### 我们如何筛选出想要的人才?
我们需要按照上述的所有要求衡量所有候选人,但并非所有要求都是同等重要的。例如,虽然我们热衷于雇用 Rust 程序员,但那些在系统级别具有强大 C/C++ 技能的人也能成为团队里有用的一份子,因为他们能够很快掌握 Rust 语言。另一方面,熟悉使用 Git 是至关重要的,因为我们无法花时间去培养新团队成员,让他们跟上我们的工作方式。
你可能会觉得很惊讶,但强大的开源背景并不是必需的要求,在类似模式中工作的心态是必需的,而任何有开源参与历史的人都可能对 Git 有很好的了解。同理,在一个分散各地的团队中工作的能力这一条件上,我们认为有过任意开源社区的参与经历都会是个积极的指标,因为有如此多的开源项目都是由分散各地的人们完成的。至于安全这一条件,我们则一致决定这只是一个“锦上添花”的条件。
我们想让这个过程简单快捷。 Profian 没有设置专门的人力资源部门或人力职能,因为我们正忙于编写代码。以下是我们最终使用的招聘流程(实际流程中可能略有不同),我们试图在 1-2 周内完成招聘:
1. 初审:个人履历/简历/GitHub/GitLab/领英主页,决定是否面试
2. 我作为 CEO 和候选人进行一场 30-40 分钟的讨论,了解他们是否适合我们团队的文化,同时让他们有机会了解我们,并了解他们是否真的像在初审提交的材料中所说的那样精通技术
3. 由 Nathaniel 领导的有关技术方面的深入讨论,通常我也在场
4. 与团队其他成员谈话
5. 编码笔试
6. 快速决策(通常在 24 小时内)
编码笔试很关键,但我们决定不采用通常的方法。我们的观点是,许多科技公司钟爱的纯“算法编码”笔试对我们想要的几乎毫无用处:考察候选人是否可以快速理解一段代码,解决一些问题,并与团队合作完成以上的工作。我们创建了一个 GitHub 存储库,其中包含一些几乎可以正常运行的 Rust 代码(事实上,我们最终使用了两个,其中一个用于技术栈上层的人),然后让候选人修复它,在上面执行一些与 Git 相关的过程,并稍作改进,在此过程中添加测试。
测试中一个必不可少的部分是让候选人通过我们的聊天室与团队互动。我们安排了 15 分钟的视频通话时间用于设置和初始问题,两个小时用于做笔试(“开卷”——以及与团队交谈,鼓励候选人使用互联网上所有可用的资源),然后是 30 分钟的总结会议,在这个会议上团队可以提出问题,候选人可以思考任务。这个谈话,结合笔试期间的聊天互动,让我们了解了候选人与团队沟通的能力。候选人挂断电话之后我们通常会在 5-10 分钟内决定是否要雇用他们。
这种方法通常效果很好。一些候选人在任务上遇到困难,一些人沟通不畅,一些人在 Git 交互方面做得不好 —— 这些是我们没有雇佣的人。这并不意味着他们不是优秀的程序员或者以后不适合该项目或公司,但他们不符合我们现在需要的标准。在我们聘用的开发人员中,他们的 Rust 经验水平和与团队互动的需求各不相同,但 Git 专业知识水平以及他们在和我们讨论之后的反应始终足以让我们决定接受他们。
### 感想
总的来说,我不认为我们会对筛选过程进行大的改动 —— 尽管我很确定我们可以在搜寻过程环节做得更好。通过编码笔试,我们可以筛选掉相当多的候选人,而且很好地帮了我们挑选合适的人。希望通过了这次选拔的每个人都很适合这个项目并且产出出色的代码(以及测试和文档等等)。时间会证明一切!
* * *
本文最初发布于 [Alice、Eve 和 Bob 安全博客][8] 上,经许可后重新发布。
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/2/how-we-hired-open-source-developer
作者:[Mike Bursell][a]
选题:[lujun9972][b]
译者:[XiaotingHuang22](https://github.com/XiaotingHuang22)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/mikecamel
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/connection_people_team_collaboration.png?itok=0_vQT8xV (people in different locations who are part of the same team)
[2]: https://profian.com/
[3]: https://enarx.dev/
[4]: https://opensource.com/article/21/3/rust-programmer
[5]: https://github.com/enarx/
[6]: https://aliceevebob.com/2021/11/09/recruiting-is-hard/
[7]: https://www.interstem.co.uk/
[8]: https://aliceevebob.com/
[0]: https://img.linux.net.cn/data/attachment/album/202302/16/074428qxbm44dxh00x42z7.jpg

View File

@ -0,0 +1,70 @@
[#]: subject: "Easily Connect your iPhone with Linux as KDE Connect Arrives on the App Store"
[#]: via: "https://news.itsfoss.com/kde-connect-ios/"
[#]: author: "Ankush Das https://news.itsfoss.com/author/ankush/"
[#]: collector: "lkxed"
[#]: translator: "XiaotingHuang22"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15559-1.html"
KDE Connect 登陆苹果应用商店,轻松将你的 iPhone 与 Linux 连接起来
======
> 这是一个令人印象深刻的开源客户端,能帮你将手机与电脑连接起来,现在可用于 iPhone 和 iPad。快来试试看
![kde connect][1]
KDE Connect 是一种开源工具,可让你将手机与电脑连接起来。
最初KDE Connect 支持安卓设备与 Linux 连接。渐渐地,他们增加了对 Windows 的支持。
现在,看起来你可以使用 KDE Connect 让你的 iOS 设备iPhone 或 iPad连接到你的 Windows/Linux 计算机。
需要注意的是 macOS 也在支持的平台列表中。但是,它仍然是早期发布版本。因此它可能不如在其他平台上那么好用。
### 苹果应用商店上的 KDE Connect
![][2]
我们没有注意到任何官方公告。然而,一些用户发现 KDE Connect 在 [版本 0.2.1][4] 发布后,就出现在了 [苹果应用商店][3] 上供 iOS 用户使用。
苹果应用商店上列出了所有基本功能,包括:
* 共享剪贴板:在设备之间复制/粘贴。
* 能够从任何应用程序将文件和 URL 共享到你的计算机。
* 将手机屏幕用作计算机的触摸板(可视触摸板)。
* 远程演示模式。
* 通过手机在计算机上运行命令
* 端到端 TLS 加密以确保安全。
虽然 KDE Connect 依然是一个开源应用程序,但为符合苹果应用商店的要求,该应用程序的许可与 [OMGUbuntu][5] 所发现的有所不同。
同时值得注意的是,这里列出的功能可能与安卓版本不同,但至少我们终于为 iOS 用户提供了 KDE Connect使其成为连接手机和计算机的真正开源跨平台解决方案。
我可以放心将 KDE Connect 推荐给任何想通过手机来对电脑进行操作的人。
点击下方的按钮即可前往应用程序商店开始安装。你还可以在其 [官方下载页面][6] 上找到针对不同支持平台的各种其他安装选项。
> **[KDE ConnectiOS][3]**
你试过 iOS 上的 KDE Connect 了吗?在评论区中让我知道你的想法。
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/kde-connect-ios/
作者:[Ankush Das][a]
选题:[lkxed][b]
译者:[XiaotingHuang22](https://github.com/XiaotingHuang22)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/ankush/
[b]: https://github.com/lkxed
[1]: https://news.itsfoss.com/content/images/size/w1304/wordpress/2022/05/kde-connect-on-iphone-ipad.jpg
[2]: https://news.itsfoss.com/content/images/size/w1304/wordpress/2022/05/kde-connect-ios.jpg
[3]: https://apps.apple.com/id/app/kde-connect/id1580245991
[4]: https://invent.kde.org/network/kdeconnect-ios/-/commit/43d2ecbbb7e4e70274849f5ec987721318eb9f57
[5]: https://www.omgubuntu.co.uk/2022/05/kde-connect-iphone-app-available
[6]: https://kdeconnect.kde.org/download.html

View File

@ -0,0 +1,78 @@
[#]: subject: "When open source meets academic publishing: Platinum open access journals"
[#]: via: "https://opensource.com/article/22/5/platinum-open-access-academic-journals"
[#]: author: "Joshua Pearce https://opensource.com/users/jmpearce"
[#]: collector: "lkxed"
[#]: translator: "CanYellow"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15579-1.html"
当开源遇到学术出版:白金开放获取期刊
======
![][0]
> 学者现在可以免费发表(文章),免费阅读(文章),与此同时仍然能够在专业成就的道路上持续进步。
学者们经常将他们的作品免费提供给公司,然后却要花钱购买它!你能想象农民在免费送出他们的食物之后再重新花钱买回来做晚餐吗?可能不能吧。像我这样的学者陷入这样的阴谋中几十年了,我们以工作保障为交换免费提供我们的作品,然后却要每年花几百万美元来阅读我们自己的文章。
幸运的是,情况正在发生改变。我刚刚完成的一项 [研究][2] 的结果显示:对于学者来说,获得工作保障的同时而不对此付出代价是可能的。我的研究发现数百种期刊是 <ruby>白金开放获取<rt>platinum open access</rt></ruby>LCTT 译注:译名源自中文网络)的 —— 也就是说,它们不需要作者或者读者为同行评议的工作付费,却仍然拥有帮助学者在他们的职业生涯中取得成功的声望和读者群。
这一趋势正在扩张:[开放获取期刊目录][3] 罗列了超过 17300 种期刊,这些期刊均提供了某种程度上的 <ruby>开放获取<rt>open access</rt></ruby>OA方式。该目录还提供了超过 12250 种无须 <ruby>文章处理费<rt>article-processing charges</rt></ruby>APC的期刊。我使用一段简易的开源 [Python 脚本][4] 来将该列表与另一按照期刊发表的文章被其他文章引用的频次排名的期刊列表(期刊影响因子列表)进行比较。很明显,最近几年来,总体的开放获取期刊与白金开放获取期刊均呈上升趋势。这一趋势可能有助于在避免学术奴役的同时加速科学发展。
### 学者的窘境
学者们通常是相当聪慧的,那么他们为什么如此长时间地投身于这种不利体系中呢?简而言之,学者陷于这样一个陷阱中:为了维系他们的工作和获得终身教职,他们需要在高 <ruby>影响因子<rt>impact factor</rt></ruby> 的期刊上发表文章。影响因子是一种基于最近两年间在给定期刊上发表的文章的平均引用数量的衡量指标。影响因子由 Web of Science 索引。对学者而言,影响因子是一个有影响力的衡量指标。
历史上,学术出版一直由一小部分主要出版商统治。他们采用基于订阅制的商业模式。在这样的商业模式中,学术作者撰写文章,评审同行的文章,也经常对这些文章进行编辑。这些工作都是没有任何报酬的。这些文章出版了,它们的版权则由那些主要的出版公司所有。即使是参与上述工作的学者也需要个人付费阅读这些文章(每篇文章大约 35 美元),或者由他们所在学校的图书馆付费订阅期刊上的所有文章。(订阅)所花的费用是相当可观的:单是一个出版商的所有文章的订阅费用通常超过一百万每年。
有很多显然的理由都说明这一体制是毫无意义的。由于限制对隐匿在付费专区后的受版权保护的科学文献的访问,使得科学进程陷于停滞。如果你因为无法查看而不知道前沿科技是什么的话,你就无法进行相应的前沿技术研究。科学家被划分为能够负担访问这些文章的费用的人,以及不能负担(这些费用的人)。发展中国家的学者往往难以支付,不过即使是财力雄厚的 [哈佛大学][5] 也已经采取行动控制它的年度期刊费用。
文章作者的花费也同样高昂。每篇文章的文章处理费从几百美元到骇人听闻的几千美元不等。文章处理费对一些资金不足的学科尤其有害,比如人文学科与社会学科(与物理学、医学和工程学相比而言)。大量的文章处理费也强化了学术界的贫富差距,使得(学者的)专业成就依赖于是否有收入投入文章发表。还有哪种职业要求从业者付费为他人制造产品?
### 开放获取,解决之道!
开放获取行动可以解决上述问题,开放获取行动倡导使所有的学术文献对任何人都能自由自由获取。开放获取的出版量有明显上升:它占了当前同行评议文章的将近三分之一。
开放获取的优势分两个方面。首先,开放获取有利于科学整体,因为它提供了一个不受阻碍地阅读前沿技术的方式。这些技术有助于进一步做出重要的认知进步。其次,就学者个人层面而言,通过让他们的作品在网络上轻而易举地免费获得,提供了最大化他们作品的潜在受众的实际优势。
基于上述原因,资助者已经开始要求开放获取,尤其是科学领域的公共资助者。如果一项研究的公共资助者还需要在阅读研究内容时二次付费,这种做法很难站得住脚。
### 学术出版目前身处何方,以后又去向何处?
传统出版商仍然掌控着目前的局面,主要是因为认为他们垄断了具有影响因子的期刊这一认知。很多学者无视传统出版方式的缺点,仍然持续在基于订阅制的期刊上发表文章或者支付高昂的文章处理费,因为他们知道在高影响因子的期刊上发表文章是至关重要的,它能够提供赖以获取补助、终身教职与职位晋升的专业性的证明。
多年以前,学术界完全没有选择的余地:要么在具有影响因子的期刊上发表,要么在通过开放获取方式发表。现在他们可以通过开放获取方式发表并仍然能够通过以下三种方式之一享受影响因子的益处:
* <ruby>绿色开放获取模式<rt>Green OA</rt></ruby>:以传统方式出版后,再通过上传预印版或者接受版论文至开放仓库或者服务器完成自行归档。一些高校拥有用于上述目的的公共仓库。举例而言,<ruby>韦仕敦大学<rt>Western University</rt></ruby> 拥用 [Scholarship@Western][6] 公共仓库,该校的任何教师都可以在上面分享他们的作品。而没有自己机构的公共仓库的学者可以使用诸如 [preprints.org][7]、[arXiv][8] 或 [OSF preprints][9] 等网络服务器。我也会将社交媒体用于学术,比如将 [Academia][10] 或 [ResearchGate][11] 用于自行存档。由于不同的出版商设计了不同的规则,这是不方便查阅的,而且某种程度上是耗时耗时耗力的。
* <ruby>金色开放获取模式<rt>Gold OA</rt></ruby>:在日益壮大的具有影响因子的期刊列表上选一份期刊发表,它将使你的文章发表后可以自由获取但是需要文章处理费。这种方式易于查阅:开放获取设置内建于出版过程中,只需要像往常一样进行学术出版。这种方式的缺点是可能会从研究活动中拿出一部分资金用于文章处理的费用。
* <ruby>白金开放获取模式<rt>Platinum OA</rt></ruby>:在具有影响因子的白金开放获取期刊上发表。不需要为出版和阅读付费。挑战在于在你的学科中找到符合上述标准的期刊,不过情况正在持续变化。
有数以万计的期刊,但是只有几百种具有影响因子的白金开放获取期刊。对于学者,困难可能在于在他们的研究与符合他们预期的期刊之间找到一个合适的平衡。你可以在我的研究报告附录中找到本文提到的列表,或者使用上文提到的 Python 脚本自行更新列表数量。白金开放获取期刊的数量正在快速增长,因此如果你目前尚未找到合适的期刊,仍然可能在不久以后拥有一些可靠的期刊以供选择。祝你享受出版的乐趣!
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/5/platinum-open-access-academic-journals
作者:[Joshua Pearce][a]
选题:[lkxed][b]
译者:[CanYellow](https://github.com/CanYellow)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/jmpearce
[b]: https://github.com/lkxed
[1]: https://opensource.com/sites/default/files/lead-images/books_read_list_stack_study.png
[2]: https://doi.org/10.3390/knowledge2020013
[3]: https://doaj.org/
[4]: https://osf.io/mh4bx/
[5]: https://www.theguardian.com/science/2012/apr/24/harvard-university-journal-publishers-prices
[6]: https://ir.lib.uwo.ca/
[7]: https://www.preprints.org/
[8]: https://arxiv.org/
[9]: https://osf.io/preprints/
[10]: https://westernu.academia.edu/JoshuaPearce/Papers
[11]: https://www.researchgate.net/profile/Joshua-Pearce
[12]: https://www.mdpi.com/2673-9585/2/2/13
[0]: https://img.linux.net.cn/data/attachment/album/202302/27/112759qkqjj1i1qg0xg21g.jpg

View File

@ -0,0 +1,137 @@
[#]: subject: "“Its time to contribute to open source”"
[#]: via: "https://www.opensourceforu.com/2022/06/its-time-to-contributing-to-open-source/"
[#]: author: "Abbinaya Kuzhanthaivel https://www.opensourceforu.com/author/abbinaya-swath/"
[#]: collector: "lkxed"
[#]: translator: "XiaotingHuang22"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15555-1.html"
“是时候为开源做贡献了”
======
![][0]
Nilesh Vaghela 是 AWS 的<ruby>社区英雄<rt>community hero</rt></ruby>,也是一家云计算开源公司 ElectroMech Corporation 的创始人。据 Nilesh 说,为开源做出贡献本身就是一种有意义的事。但是它需要人们的投入和奉献,而这个过程涉及许多步骤,从选择项目到确保你的贡献成果获得关注。在与 OSFY的 Abbinaya Kuzhanthaivel 的对话中,他分享了一些关于开发人员如何帮助提高印度对开源的贡献的技巧。
![Nilesh Vaghela, AWS 的社区英雄以及 ElectroMech 公司的创始人][1]
### 问:你能告诉我们一下你目前的角色和对开源的贡献吗?
**答:** 我目前是一名从事自动化工作的架构师。我领导着多个团队,并且同时主要在开源安全服务平台 Invinsense 上作出贡献。我在 1998 年初创建了开源小组,当时已经有大约 1500 名成员。我现在管理的一个小组 (https://groups.google.com/g/vglug) 自 2014-15 年以来一直非常活跃。
### 问:你是如何开始在开源项目中工作的?
**答:** 我是一名有着从业资格的机械工程师,当时我在我的公司 ElectroMech Corporation 负责调制解调器和 UPS 系统。我慢慢地被拖入负责 PC、网络和 Linux 等等。1996 年,我在核科学中心看到超过 150 台计算机服务器在 Linux 上运行时广受启发,之后便开始尝试。自此我将我的公司完全转变为专注于培训和支持的开源公司。
我可以自豪地说,我是最早一批使用开源的人 —— 帮助客户了解什么是开源、它有什么好处、什么是免费的、安全或代码问题等等。我们在 Vadodara 得到了至少四五个客户,并且最终通过黄页上的广告宣传自己。我们与 Red Hat 合作并且关系一直持续到现在。
### 问:自那以来你认为开源发展如何?
**答:** 我可以说早些时候开源是一种令人着迷的强烈爱好吸引人们参与其中。当一些来自西伯利亚的贡献者致力于改善水资源短缺问题时世界各地的用户都说他们的产品有多么简单易用这给我留下了特别深刻的印象。它更像是一项企业社会责任CSR活动。人们和专家创建一个委员会来管理和推进项目。人们会因为对技术的热爱而加入进来没有任何期望。
那时我并不相信开源可以商业化,但它是当今大多数创新和技术的驱动力,而且越来越多的企业正在采用它。我们期待在贡献和使用开源方面取得很好的平衡,因为我们有个人、社区和大公司参与进来。这才是开源真正的未来和力量。
### 问:你可以分享一些自己遇到的困难吗?
**答:** 最初我是单枪匹马干,但一旦人们知道我的意图是好的,他们就会加入我。我在没有任何期望的情况下创建了很多社区,但确实在声誉或名望方面间接地获得了回报;有人理解我是技术达人,并长期给我项目。在早期,人们刚开始加入社区并且不需要付出很多精力就可以做出贡献。因为我的目标不是做生意,因此可以说我没有真正面临什么障碍。
### 问:作为社区领袖,你的领导格言和经验教训是什么?
**答:** 首先,如果你想建立一个社区,那就保持中立,不要抱有偏见。虽然看起来好像是你作为领导者正在管理一个社区,但请记住,加入社区的人都是平等地做出贡献的。永远不要让成员失去动力。在发表评论和回答问题时要有礼貌。不管是什么问题,如果你不想回答,那就选择沉默。但别让人们停止提问,而是帮助他们建立专业知识。
第二,不要让社区掺杂商业。不要让社区的目标和你个人企业的目标产生混淆和互相匹配。将它们严格区分开来。
始终尝试鼓励人们参与,而不是作为专家提供指导。如果你发现人们有兴趣领导项目并采取主动,请给出舞台让他们发挥。邀请他们参与社区活动。这将帮助你培养更多的社区领袖。此外,让你的社区保持简单,不要在初始阶段让赞助商参与进来。
### 问:你从谁那里得到了灵感?
**答:** 开源运动之父 Richard Stallman 是我的灵感来源,我一直很钦佩他的项目。
除了他之外,我还有一个有趣的事要分享,它激励着我从事开源工作。在我开始从事开源工作的时候,核科学中心的大部分软件都是基于 Windows 操作系统的。然而,许多科学家希望使用基于 Linux 的软件。在两三个月内,他们实际上创建了 Linux 驱动程序。这就是让我着迷的地方——用户可以创建这些驱动程序,这在专有软件中是不太可能发生的。我真的很喜欢开源赋权用户这一点。
### 问:你对印度开源格局以及改进空间有什么看法?
**答:** 印度是使用开源的人最多的国家LCTT 校注:或应加上“之一”),我们正致力于成为贡献者。有这么多开发者,印度却仍然没有软件巨头。我们拥有的主要是服务提供者,而不是创新者。更多的人应该成为开源的贡献者,去开发具有国际标签的东西。
为开源做贡献的想法应该从学校和大学抓起。幸运的是,古吉拉特邦政府已经在 8 年级到 10 年级里推出基于 Linux 的课程。教育年轻一代并让他们了解开源模型很重要。
其次,我们要培养好的导师。当人们开始贡献时,找到一位在这个项目中工作的开源导师很重要。导师给出了一个小任务,尝试代码然后提交。如果一切顺利,成员的贡献会逐渐增加。不幸的是,在印度导师很少。我们需要有很多导师,或者可以与世界各地的导师建立联系。
第三是要鼓励那些踊跃贡献的人。让人们发现,一旦你成为了一位广受认可的开发人员或为开源开发做出贡献的人,你在职业发展和业务上也会有所突破。
通过遵循这些简单的方法,印度可以成为开源的主要贡献者。
### 问:你如何看待为开源做出贡献时编程方面的要求?
**答:** 根据我的经验,如果你知道计算机内部的知识,如何开发应用程序,你应该维护什么样的代码标准,以及如何管理团队和其他最佳做法,你可能不必担心编程专业知识。
在设计、安全维护和整合方面还有其他角色可以担任。看看你合适什么。通过做你喜欢的事情来不断提升加强自己的技能。如果你仍然对编码感兴趣,那么你就在其他开发人员的支持下去学习。
### 问:你如何确定一个你想参与的项目?
**答:** 你需要了解你最感兴趣的几个领域,然后对围绕这些领域发生的项目进行研究。你需要弄清楚哪些领域有招募更多志愿者的需求或职位空缺。 你可以从小处着手练习,然后积累专业知识。
避免随大流;重要的是你的个人兴趣。例如,因为现在 DevOps开发运维一体化的需求量很大你便可能更倾向于选择 DevOps 项目。不要犯这个错误。
你可以在云原生基金会([CNCF][2]、Apache、Fedora、Red Hat 等平台上找到开源项目。通过这种方式,你还可以找到已经在从事项目并可以给出适当指导的导师。
### 问:每个项目有自己的目的和目标受众,有时它们甚至与开源目标不一致。那么,在开始做出贡献之前要核实什么?
**答:** 我同意,当有人开始一个开源项目但随后又将其商业化时,你会感到为开源作出贡献也变得颇有难度。但这样的风险总是会有的,不应让你对此感到挫败。
首先试着去了解该小组 —— 小组中的贡献者有多受欢迎,他们贡献了多长时间,以及他们的声誉如何。一旦你加入,观察每一个人和每一件事是关键。尝试至少学习三到六个月,并了解一切是如何运作的。如果你发现他们的意图不对,你可以随时离开这个项目。但如果你觉得没问题,那就继续做贡献吧。
![ElectroMech 公司的团队][3]
你可以看看他们是否有某些许可证,例如 GPLv3。你还可以查看未修改的许可证版本例如 Apache 开源许可证。
### 问:你觉得大公司会接受应届生投稿吗?
**答:** 是的,当然。公司也喜欢指导新人。他们通常不允许你直接贡献,但可能先会给你一个小任务。导师会首先尝试了解你拥有什么技能以及你的能力如何。一旦他们认可你具备所需的技能,他们将继续指导你或根据你的技能将你分配给其他导师。初始阶段非常关键。很多公司都会做一些筛选,只有在你证明了自己的能力之后,你才会被允许做出贡献。
### 问:贡献者在接手项目时必须克服的最初挑战是什么?
**答:** 首先,你应该非常认真地对待你的贡献。没有书面承诺,贡献者可能倾向于对工作掉以轻心。这种想法是完全错误的。尝试每天投入 8-10 小时或任何可行的时间。如果你因为觉得没有立竿见影的回报而不愿投入其中,那么你就不是一个好的贡献者。
在最初阶段始终严格遵守导师的指导。这对于健康的贡献非常重要。有时你可能会认为自己擅长某事,而你的导师可能不会根据该技能给你分配项目。在这种情况下只需找你的导师,问他你应该做什么,你的角色是什么,以及你可以如何贡献。
### 问:许多开发人员在提交项目贡献后没有得到回复。如何让自己提交的东西被人注意到呢?
**答:** 写一篇关于你计划作出贡献的项目的小博客,包括你喜欢的方面,你不喜欢的地方,以及可以改进的地方。这种积极的推广方式可以帮到你很多。
成为小组的一员并参与与该项目相关的活动。作为贡献的替代,首先尝试参与到团队中去,这将增加你被采纳为贡献者的机会。
一旦你对项目有了更好的了解,你的工作不仅会被接受,而且你将能够更好地适应该项目。
### 问:你如何克服你的贡献不被接受的情况?
**答:** 就是理解发生这种情况的原因有很多 —— 也许你没有在合适的项目中,或者你没有做出正确的贡献。如果项目是国家驱动的,你的请求可能不会被接受。因此,如前所述,请记得列个清单。如果你的贡献没有被接受,请不要担心,因为要么你不适合该项目,要么该项目不适合你。
我会建议尝试找四到五个项目,并且至少有一个项目会接受你所做的工作。
### 问:你对我们的读者有何想说的?
**答:** 开源是当今大多数创新背后的驱动力。让我们根据自己的能力和技能试着做出贡献,而不是仅仅使用开源。贡献可以是代码、文档、测试、博客、金钱等。是时候做出贡献了。
### 问ElectroMech 公司有招人的计划吗?
**答:** 我们在云计算 DevOps开发运维一体化方面有需求正在招聘云架构师、Python 开发人员、Linux 架构师和安全专业人员。
--------------------------------------------------------------------------------
via: https://www.opensourceforu.com/2022/06/its-time-to-contributing-to-open-source/
作者:[Abbinaya Kuzhanthaivel][a]
选题:[lkxed][b]
译者:[XiaotingHuang22](https://github.com/XiaotingHuang22)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.opensourceforu.com/author/abbinaya-swath/
[b]: https://github.com/lkxed
[1]: https://www.opensourceforu.com/wp-content/uploads/2022/05/Nilesh-Vaghela-AWS-community-hero-and-founder-ElectroMech-Corporation.jpg
[2]: https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&cad=rja&uact=8&ved=2ahUKEwib2vvv3dv3AhVa7XMBHfZSCsIQFnoECAgQAQ&url=https%3A%2F%2Fwww.cncf.io%2F&usg=AOvVaw2LnRyH4SZPDHntRLJU_b3q
[3]: https://www.opensourceforu.com/wp-content/uploads/2022/05/The-team-at-ElectroMech-Corporation.jpg
[0]: https://img.linux.net.cn/data/attachment/album/202302/19/141128wxkesmzesuboso6w.jpg

View File

@ -0,0 +1,219 @@
[#]: subject: "9 Best Matrix Clients for Decentralized Messaging"
[#]: via: "https://itsfoss.com/best-matrix-clients/"
[#]: author: "Ankush Das https://itsfoss.com/author/ankush/"
[#]: collector: "lkxed"
[#]: translator: "TravinDreek"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15515-1.html"
9 款最佳的去中心化通讯软件 Matrix 的客户端
======
![][0]
Matrix 是一套开放的网络标准,专用于去中心化实时加密通讯。
这套标准由 Matrix.org 基金会发布和维护。Matrix.org 基金会是一个非营利性组织,致力于创建一个开放、独立且不断演进的通讯平台。
如果一款应用支持 Matrix 协议,那就可以视它为 Matrix 客户端。
### 为何要选用 Matrix 客户端?
[Matrix][1] 客户端致力于安全性和隐私性,并且提供了一个去中心化的网络,令许多特性得以实现。
自 2019 年(正式版本发布)以来,部分组织以及政府机构便开始逐渐采用 Matrix 协议,从而搭建安全、隐私、可靠的通讯平台。
就实际而言,去中心化的协议实现了不同组织间的相互通讯,同时也使得这个通讯协议得以抵抗审查。
如果你想要逃脱科技巨头的魔爪,那 Matrix 就是正确的选择。
不仅如此,你还可以运行自己的服务器,并加入 Matrix 网络。换言之,通讯的基础设施是去中心化的,但你仍然能够根据需要,对其进行部署和配置。
如果你好奇的话Matrix 协议具备了你需要的所有基本功能:
* 去中心化交流
* 端到端加密
* WebRTC 语音通话 / 视频通话
* 实时同步
* 消息已读用户显示
* “正在输入中” 提示
* 群组聊天
而且,我还要再强调一次:这个项目是**开源**的!
所以Matrix 客户端已经是不二之选了。对那些注重隐私和安全的用户来说,则更是如此。
> LCTT 译注实际上Matrix 只是在隐私和便利之间达成了一种相对的平衡。它是将类似 Mastodon 的 <ruby>联邦<rt>federated</rt></ruby> 网络结构用在了聊天中也就是说虽然整个网络去中心化成了许多节点但节点服务器的运营者仍然能对其用户进行少量掌控。但总的来说相对那些中心化的聊天应用而言Matrix 是个值得考虑的替代品。
### 9 款最佳的开源 Matrix 客户端
本文中,我将介绍一些最好用的 Matrix 客户端其中主要是桌面客户端Linux、Windows、macOS同时也推荐一些移动客户端和终端客户端。
#### 1、Element
![element][2]
[Element][3] 是最佳的 Slack 开源替代品之一。它可以用于个人通讯,也能用于群组聊天。
你可以免费使用不过你也可以选择自己搭建服务器或者付费使用托管的家庭服务器。Element 提供了许多有用的功能,让你能够高效协作,并与你的团队或好友加密通讯。
> LCTT 译注:如同 Mastodon 一样,自费搭建服务器或者付费使用服务器,对大部分用户而言都是不必要的。初学者建议前往 <https://joinmatrix.org/servers/>,并选择一个现有的服务器进行注册,其中许多服务器都是免费开放注册,并且国内可以连接的。下述的订阅功能也并不是必要的。
如果你选择付费订阅,你还能将 Signal、WhatsApp 和 Telegram 聊天并入其中。
它支持 Linux、Windows 和 macOS同时还提供 Android 和 iOS 的手机客户端。并且,你还能在网页浏览器中使用它。因此,这是个方便的选择。
> LCTT 译注:国内用户可能会在桌面客户端遇到错误,导致无法使用 Element。这是因为它在首次启动会连接 matrix.org但是国内用户无法访问这个地址。要解决此问题须手动修改配置文件篇幅有限详见相关教程。实在无法解决可使用基于 Element 的 [SchildiChat](https://schildi.chat/),或下文列出的其他客户端。
> **[Element][4]**
#### 2、Rocket.Chat
![rocket chat][5]
[Rocket.Chat][6] 是另一个 Slack 替代品,我们更喜欢把它当成团队内部的通讯工具。
你可以在 Linux、Windows 和 macOS 上使用它,也可以获取 Android 和 iOS 的手机应用。
尽管你可以选择自建服务器或付费订阅,但它也宣布正在添加 [Matrix 协议的支持][7]。
本文创作之时,已经可以在 alpha 版中使用 Matrix 网络。不过,稳定版应该很快就会发布了。所以,如果你已经在使用 Rocket.Chat或者想把它当作 Matrix 客户端来使用,那么敬请关注后续版本的发布。
> **[Rocket.Chat][8]**
#### 3、NeoChat
![neochat][9]
NeoChat 是一个简单的 Matrix 客户端,目前在 KDE 社区的管理下积极开发。
与 Element 不同,它只支持 Linux 和 Windows特别是为 KDE Plasma 量身定做。你也可以在其他桌面环境使用它。
你可以在 KDE 的 “<ruby>发现<rt>Discover</rt></ruby>” 软件中心、Flathub 以及 Snap 商店安装它。它不支持手机平台。所以,如果有桌面用户想要一个简单的 Matrix 客户端,那 NeoChat 也是一个不错的选择。
> LCTT 译注纠正一下NeoChat 也支持安卓,可直接下载二进制,也可在 F-Droid 中添加 KDE 仓库后下载。除此之外,它还支持 macOS。详见其源代码仓库。
了解更多,可以查看它的 [源代码][10]。
> **[NeoChat][11]**
#### 4、FluffyChat
![fluffychat][12]
FluffyChat 在用户体验方面,是一个美观(可爱)的 Matrix 客户端。
如果你想要一个简单又直观的 Matrix 客户端,并且支持桌面和手机(安卓和 iOS那么 FluffyChat 是一个不错的选择。
Linux 用户可以从 Snap 商店或 Flathub 安装它。它并不提供 Windows 和 macOS 的原生应用支持,但你可以在网页浏览器中使用它。
如果你好奇的话,可以从它的 [GitLab 页面][13] 了解更多。
> **[FluffyChat][14]**
#### 5、Fractal
![fractal][15]
Fractal 是一款用于 GNOME 桌面的 Matrix 聊天客户端,使用 Rust 编写。正如其描述所说,它的界面经过优化,适合大型团队的协作。
由于它以 Flatpak 的形式发布,你可以在任何 Linux 发行版上安装它,无论桌面环境如何。
如果你喜欢能够在系统上快速运行的应用,那 Fractal 可能是不错的选择。可以前往它的 [GitLab 页面][16] 了解更多。
> **[Fractal][17]**
#### 6、Hydrogen Web实验性
![hydrogen][18]
在找其它的精简的专注性能Matrix 客户端吗?
Hydrogen 聊天客户端提供轻量级体验、离线功能,并有着广泛的浏览器支持。
虽然仍未完工,但 Element 背后的同一支团队正在开发着它。所以,如果你期待看到一个轻量的 Matrix 客户端替代品,你可以在它的 [GitHub 页面][19] 跟进该项目。
> **[Hydrogen][20]**
#### 7、Matrix Commander基于命令行
如果你想要用终端在 Matrix 网络上来收发文字消息,这个命令行工具就十分不错。
当然,并非一切都能在终端完成。所以,最好创建 cron 任务来实现消息提醒、机器人等用例。
你可以在 [PyPi][21] 或者 Docker Hub 上找到它。
> **[Matrix Commander][22]**
#### 8、Gomuks基于命令行
![gomuks][23]
想试试用 Go 写的终端 Matrix 客户端?
并非每个人都可以尝试。不过,如果你喜欢用 Go 写的命令行工具,可以用 Gomuks 这个简单的 Matrix 客户端来进行基本聊天。
你可以在它的 [GitHub Releases 部分][24] 找到其 Linux、Windows 和 macOS 的二进制文件。
> **[Gomuks][25]**
#### 9、SyphonAlpha 版)
![syphon][26]
我们通常会避免列出仍处于早期开发的程序。但是Syphon 作为一个手机专用的 Matrix 客户端,是一个有趣的选择。
如果你想要为你的安卓 / iOS 设备安装一个类似 Signal 的开源 Matrix 客户端,那选择 Syphon 也不错。用户界面看起来很熟悉(但并不是完全照抄的)。如果你想实验一下,那可以试试。
> **[Syphon][27]**
### 总结
Matrix 协议也许没能流行于所有组织和人群之中。但是,可以证明的是,作为一个开源项目,它能称得上是一个隐私可靠的去中心化网络。
最好的一点在于,你可以选择你想要的客户端,而不必被迫使用特定的应用才能在多个设备之间进行通信。
所以,你会选择什么作为你最喜欢的 Matrix客户端
--------------------------------------------------------------------------------
via: https://itsfoss.com/best-matrix-clients/
作者:[Ankush Das][a]
选题:[lkxed][b]
译者:[Peaksol](https://github.com/TravinDreek)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/ankush/
[b]: https://github.com/lkxed
[1]: https://matrix.org/
[2]: https://itsfoss.com/content/images/wordpress/2022/06/element-2022.jpg
[3]: https://itsfoss.com/element/
[4]: https://element.io/
[5]: https://itsfoss.com/content/images/wordpress/2022/06/rocket-chat-2022.jpg
[6]: https://itsfoss.com/rocket-chat/
[7]: https://news.itsfoss.com/rocket-chat-matrix/
[8]: https://rocket.chat/
[9]: https://itsfoss.com/content/images/wordpress/2022/06/neochat.png
[10]: https://invent.kde.org/network/neochat
[11]: https://apps.kde.org/neochat/
[12]: https://itsfoss.com/content/images/wordpress/2022/06/fluffychat.png
[13]: https://gitlab.com/famedly/fluffychat
[14]: https://fluffychat.im/
[15]: https://itsfoss.com/content/images/wordpress/2022/06/fractal.png
[16]: https://gitlab.gnome.org/GNOME/fractal
[17]: https://wiki.gnome.org/Apps/Fractal
[18]:https://itsfoss.com/content/images/wordpress/2022/06/hydrogen.png
[19]: https://github.com/vector-im/hydrogen-web/
[20]: https://github.com/vector-im/hydrogen-web/
[21]: https://pypi.org/project/matrix-commander/
[22]: https://github.com/8go/matrix-commander
[23]: https://itsfoss.com/content/images/wordpress/2022/06/gomuks.png
[24]: https://github.com/tulir/gomuks/releases
[25]: https://maunium.net/go/gomuks/
[26]: https://itsfoss.com/content/images/wordpress/2022/06/syphon.jpg
[27]: https://syphon.org/
[0]: https://img.linux.net.cn/data/attachment/album/202302/06/163855x1rdxojvn1ohh00v.jpg

View File

@ -0,0 +1,130 @@
[#]: subject: "Why Enterprises Should Opt for Platform as a Service"
[#]: via: "https://www.opensourceforu.com/2022/09/why-enterprises-should-opt-for-platform-as-a-service/"
[#]: author: "Gopala Krishna Behara https://www.opensourceforu.com/author/gopalakrishna-behara/"
[#]: collector: "lkxed"
[#]: translator: "onionstalgia"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15548-1.html"
为什么企业应该选择平台即服务PaaS
======
![][0]
> 平台即服务能够快速、轻松地创建网络应用,而无需购买和维护其下的软件和基础设施。本文解释了它为什么有用。
<ruby>平台即服务<rt>PaaS</rt></ruby>(以下简称 PaaS指的是云计算服务它为客户提供了开发、运行和管理应用程序的平台而免去了建立和维护与开发和启动应用程序相关的基础设施的复杂工作。这是云原生应用和支持系统所依托的核心平台。
PaaS 通常包括不同的应用基础功能,包括应用平台、集成平台、业务分析平台、事件流服务和移动后端服务。此外,它还包括一套与监控、管理、部署相关的功能。
开发人员希望他们的开发环境不需要等待而运营团队则更关心性能和稳定性。这经常引起两方间的冲突。PaaS 为这两方创造了和平的环境。一个作为服务交付的应用平台被称作 PaaS它被用于部署用户代码。Cloud Foundry、Cloudify 和 OpenShift 这些开源环境都可用作 PaaS。
### PaaS 的采用模式
云计算必须满足五个基本特征:按需服务、接入网络、资源池化、弹性和可度量的服务。为此,云计算提供了三种服务模式:<ruby>软件即服务<rt>Software as a Service</rt></ruby>SaaS<ruby>平台即服务<rt>Platform as a Service</rt></ruby>PaaS<ruby>基础设施即服务<rt>Infrastructure as a Service</rt></ruby>IaaS
业务选用 PaaS 的关键驱动力:
* 减少提供业务的资本支出和运营费用
* 通过减少应用程序的交付时间和提高开发和交付质量,最大限度地降低 IT 成本
* 增加中间件之间的灵活性和集成度
*简单 PaaS*:踏入 PaaS 领域的入口。它可以提供应用程序服务,并将它们暴露在自助服务的目录中;自动部署和计量服务使用的资源。
*管理 PaaS*:管理已配置应用程序的<ruby>服务级别协议<rt>SLA</rt></ruby><ruby>服务质量<rt>QoS</rt></ruby>,例如弹性、应用程序性能、安全性等。
*编程 PaaS*:允许应用程序与外部应用程序或公共云集成,并实现自动扩展和云爆发场景。
*面向流程 PaaS*:允许通过创建持续交付流程来实现<ruby>开发运维<rt>DevOps</rt></ruby>流程,该流程可以自动构建、测试应用程序并将其交付到云环境中。
除了这些采用模式之外,还有其他的 PaaS 变体如下,这些变化可能与上文的模式有一定重合:
*集成平台即服务iPaaS*:一套能够开发、执行和管理集成流的云服务。集成流可以是个人内部或跨多个组织连接的,可以包含任何企业内部或基于云的流程、服务、应用和数据。这些组合变化可能也符合上述的模式之一,例如 MuleSoft CloudHub 和 BizTalk。
*移动平台即服务mPaaS*为开发移动应用提供的集成开发环境IDE并且支持多种移动平台。
*数据库平台即服务dbPaas*一种按需的、安全且可扩展的自助式数据库平台可自动配置和管理数据库。dbPaaS 使扩展数据库变得更加容易,并使它们更加可靠。
*物联网平台即服务IoTPaaS*:提供了实现异构物联网拓扑所需的通信、安全、分析和管理的通用基础架构。它为构建物联网解决方案提供了更简单、更敏捷的模型。
*业务流程管理平台即服务bpmPaaS*:一个完整的预集成业务流程管理平台,托管在云端并作为服务交付。它被用于开发和执行整个企业的业务流程和以工作流程为中心的应用程序。例如 Pega cloud 和 OpenText Cordys cloud。
PaaS 的一些基本特征:
* 在同一集成开发环境中开发、测试、部署、托管和维护应用程序的服务
* 多租户架构,即多个并发用户使用同样的开发程序
* 部署软件的内置可扩展性,包括负载平衡和故障转移
* 与异构平台和系统的集成
* 支持开发团队的协作
* 包含处理帐单和管理订阅的工具
### 主要的开源 PaaS
在选择 PaaS 之前,企业主要考虑关注以下几点:
* 部署灵活性
* 操作简便性
* 应用堆栈的选择
* 语言、数据库和框架支持
* 规模的可扩展性
* 服务质量QoS
* 开发和运营的工具
* 它有多适合你的业务
现在让我们快速浏览下流行的开源 PaaS。
*Cloud Foundry*提供了多种云的选择、开发者框架和应用服务。Cloud Foundry 使构建、测试、部署和扩展应用程序变得更快、更容易。
它有不同的发行版本,其中比较流行的是 Pivotal 和 IBM。它包含应用<ruby>运行时<rt>runtime</rt></ruby>和容器运行时。在 Pivotal 上包含有应用服务和容器服务。
*OpenShift*:红帽的云计算 PaaS 产品。这是一个云端的应用平台,应用开发者和团队可以在这里构建、测试、部署和运行他们的应用程序。
*Cloudify*:在开放的原则下开发和设计,用以推动 IT 转型革命。它使组织能够在其上设计、建立和提供各种商业应用和网络服务。Cloudify 的最新版本为 4.3,它包含了先进的安全、控制和<ruby>真自服务<rt>true self-service</rt></ruby>等增强功能。Cloudify 4.3 还为 Kubernetes 容器编排引入了全新的概念。
| 功能 | Cloud Foundry | Cloudify | OpenShift |
| :- | :- | :- | :- |
| 核心功能 | Cloud controller | Manager | Broker |
| 提供第三方数据库服务 | Service broker | Agent | Cartridge |
| 传入流量的路由 | Router | Manager | REST API |
| 查询应用程序的状态 | Cloud controller | CLI client | Broker |
| 消息传递 | Message bus | Manager | Broker |
| 应用实例管理 | Droplet execution agent | Agent | Node |
| 应用程序状态管理 | Health manager | Manager | Broker |
| Broker | Warden | Agent | Gear |
| 用户请求的负载平衡 | Droplet execution agent | Manager | Broker |
| 框架提供者 | Blob store | Agent | Cartridge |
|技术 ||||
| 语言 | Java, Ruby, Scala, Node.js, Groovy, Grails, PHP, Go, Python | Java, PHP, Ruby | Java, Ruby, Node.js, PHP, Python, Perl, JavaScript|
| 数据库 | MongoDBMySQL |||
|MongoDB、MySQL、PostgreSQL | MySQL、MongoDB | MongoDB、MySQL、PostgreSQL||
| 框架 | Spring, Rails, Grails, Play Sinatra | JavaScript, Node.js | Rails, Flask, Django, Drupal, Vertx |
| 水平扩展 | 是 | 是 | 是|
| 垂直扩展 | 是 | 否 | 是|
| 弹性伸缩 | 是 | 是 | 是|
表 1 列出了 Cloud Foundry、Cloudify 和 OpenShift 的基本功能及其对应的架构组件。以上完全基于个人观点,所支持的功能的真实需求应与云供应商进行验证。
从行业统计数据中,我们可以清楚地看出 PaaS 的使用率正在迅速上升。PaaS 使企业应用程序可以是<ruby>云无关<rt>cloud-agnostic</rt></ruby>的,它们可以在任何云平台上运行——无论是公共的还是私有的。这意味着一个在亚马逊的 AWS 上开发的应用可以很容易地移植到微软 Azure、VMWare vSphere、Red Hat RHEV 等等其他平台。
当多个开发人员共同参与一个开发项目或外部用户需要与开发过程协作时PaaS 是很有用的。因此PaaS 尤其适合于敏捷开发,因为它降低了围绕软件快速开发和迭代的难度。
### 鸣谢
作者感谢 Kiran M.R. 和 Wipro 有限公司的数字架构实践 Raju Alluri 为本文提供的支持。
--------------------------------------------------------------------------------
via: https://www.opensourceforu.com/2022/09/why-enterprises-should-opt-for-platform-as-a-service/
作者:[Gopala Krishna Behara][a]
选题:[lkxed][b]
译者:[onionstalgia](https://github.com/onionstalgia)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.opensourceforu.com/author/gopalakrishna-behara/
[b]: https://github.com/lkxed
[0]: https://img.linux.net.cn/data/attachment/album/202302/17/094352atasztuxqg4t1ctt.jpg

View File

@ -0,0 +1,307 @@
[#]: subject: "How to Install GNOME Desktop in Arch Linux [Complete Guide]"
[#]: via: "https://www.debugpoint.com/gnome-arch-linux-install/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "Chao-zhi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15537-1.html"
如何在 Arch Linux 中安装 GNOME 桌面
======
![][0]
> 本指南解释了在 Arch Linux 中安装 GNOME 桌面所需的步骤。
本指南有两部分:第一部分是关于安装基本的 Arch 系统;第二部分是在 Arch Linux 基础上安装完整的 GNOME 桌面环境。
### 什么是 GNOME 桌面?
GNOME 是一个流行的桌面环境,是如 Ubuntu 和 Fedora 等许多基于桌面的顶级 Linux 发行版的默认桌面。几乎所有的定制版都提供了一个 GNOME 桌面版本。
GNOME 桌面是稳定和用户友好的桌面之一因此它被许多普通和高级用户所青睐。如果你想要一个在你进行工作时保持隐形的桌面GNOME 就是这样的一个。它不会在你工作时妨碍你。因此,尽管有许多关于 GNOME 3目前的版本速度慢、资源重等争议它仍然是许多人的流行和默认选择。
说了这么多,让我们来看看如何在裸机 Arch 中安装 GNOME 桌面。
### 在 Arch Linux 中安装 GNOME 桌面
#### 第一部分:安装 Arch Linux
如果你已经安装了 Arch Linux你可以跳过这一步直接进入下面安装 GNOME 桌面部分。
要快速安装 Arch Linux 基础版,请遵循以下步骤。你也可以访问 [该指南][1],了解如何将 Arch Linux 安装为双启动或在虚拟机中的完整教程。
本文下面介绍的步骤是安装 Arch 的传统方式。新手请按照下面的指南链接,以更现代的方式使用 `archinstall` 脚本。完成后,回来通过第二部分的步骤继续 GNOME 安装。
> **[现代方式:使用 archinstall 脚本安装(推荐)][2]**
##### 传统方式:下载 Arch Linux
从下面的链接下载 Arch Linux 的 .iso 文件。它也提供了磁力链接和种子链接。下载后,将 ISO 写入 USB 驱动器。然后从该驱动器启动。
> **[下载 Arch Linux][3]**
如果你打算通过 GNOME Boxes、virt-manager 把它安装成一个虚拟机镜像,那么你就不需要把它写入 U 盘。
##### 启动和配置分区
从 Arch Linux ISO 启动后,你必须运行一系列的命令来安装基本系统。
首先,运行下面的命令,找出设备标识符。
```
fdisk -l
```
![之前的 fdisk -l][4]
然后用设备标识符,运行下面的命令,开始对你的磁盘进行分区。请确保根据你的系统改变 `/dev/sda`
```
cfdisk /dev/sda
```
在下一个提示中选择 `label type = dos`
选择自由空间,并从底部选择 “<ruby>新建<rt>New</rt></ruby>” 选项。在这个例子中,我将创建三个分区,如下图所示:
```
/dev/sda1 - 1G - for /boot
/dev/sda2 - 5G - for root
/dev/sda3 - 1G - for swap
```
![cfdisk][5]
在下一个屏幕中,提供引导分区的分区大小(在这个例子中,我给出了 1GB。选择它作为主分区。
对大小为 5GB 的主根分区重复同样的步骤。
![改变为交换分区类型][6]
用同样的步骤创建一个大小为 1G 的交换分区(你可以根据你的需要改变它)。创建交换分区后,确保在底部选择 “<ruby>类型<rt>Type</rt></ruby>”,并用 “Linux Swap/Solaris” 选项将其标记为交换分区。
![cfdisk 中的最终分区列表][7]
一旦完成,使用底部的 “<ruby>写入<rt>Write</rt></ruby>” 选项将变化写入磁盘。**确保你在写入前做了备份,因为这是你系统中的一个永久性变化。**
在你继续之前,运行下面的命令来检查。你可以看到在这个例子中,有三个分区被列出。
```
fdisk -l
```
![fdisk 中的最终分区列表][8]
依次运行下面的命令,在上面新创建的分区中格式化并创建一个 ext4 文件系统。请确保你根据你的需要改变 `/dev/sda1``/dev/sda2`
```
mkfs.ext4 /dev/sda1
mkfs.ext4 /dev/sda2
mkswap /dev/sda3
swapon /dev/sda3
```
完成后,装载系统并创建必要的目录:
```
mount /dev/sda2 /mnt
mkdir /mnt/boot /mnt/var /mnt/home
mount /dev/sda1 /mnt/boot
```
同样,确保你根据你的系统改变 `/dev/sda1`、`/dev/sda2` 和 `/dev/sda3`
![准备文件系统][9]
##### 安装基础系统
我希望你已经连接到互联网了。如果没有,请尝试使用 USB 网卡或 Arch 安装程序自动配置和检测的有线网络连接。如果你没有可用的有线连接,请按照 [该指南][10] 使用 Arch Linux 安装程序配置一个无线或 Wi-Fi 网络。
依次运行下面的命令,将基本系统安装到已安装的分区中。下载的大小约为 400MB。
```
pacman -Syy
pacstrap /mnt base base-devel linux linux-firmware nano dhcpcd net-tools grub
```
![安装基本系统][11]
一旦完成,就会生成文件系统表,没有它你就无法启动系统。
```
genfstab -U /mnt >> /mnt/etc/fstab
```
##### 配置基础系统
依次按照下面的命令来配置基本系统。这涉及到设置你的地域、语言、添加一个登录用户,以及设置互联网:
```
arch-chroot /mnt
nano /etc/locale.gen
```
通过去掉开头的 `#` 来取消对你所选择的 <ruby>语言环境<rt>locale</rt></ruby> 的注释。在本指南中,我选择了 `en_US.UTF-8 UTF-8`,按 `CTRL+O`、回车和 `CTRL+X` 退出 nano。
![本地化][12]
使用以下方法生成语言环境:
```
locale-gen
```
如果你不想手动去 `/etc/locale.gen` 设置语言,也可以使用以下命令设置语言:
```
echo LANG=en_US.UTF-8 > /etc/locale.conf
export LANG=en_US.UTF-8
```
设置当地的时区:
```
ln -s /usr/share/zoneinfo/America/New_York /etc/localtime
```
同样,你可以根据你的需要来选择它们。你可以通过以下命令列出当地的时区:
```
ls /usr/share/zoneinfo
ls /usr/share/zoneinfo/America
```
设置硬件时钟,创建一个主机名,并使用以下命令依次启用互联网的 DHCP。你可以根据你的想法`arindam-pc` 改为任何主机名:
```
hwclock --systohc --utc
echo arindam-pc > /etc/hostname
systemctl enable dhcpcd
```
下一步是设置根用户的密码,创建一个管理员用户,并在 `sudoers` 文件中添加该用户。
依次按照下面的命令进行操作。请确保根据你的需要将用户名从 `debugpoint` 改为其他名称:
```
passwd rootuseradd -m -g users -G wheel -s /bin/bash debugpointpasswd debugpoint
```
![创建用户][13]
打开 `sudoers` 文件,添加以下几行:
```
nano /etc/sudoers
```
添加以下几行。由于你已经创建了 `root` 用户,该条目应该已经有了:
```
root ALL=(ALL) ALL
debugpoint ALL=(ALL) ALL
```
![更改 sudoer 文件][14]
依次使用如下命令安装 Grub设置初始化 Ramdisk 环境,卸载系统:
```
grub-install /dev/sda
grub-mkconfig -o /boot/grub/grub.cfg
mkinitcpio -p linux
exit
```
![配置 Grub][15]
然后重新启动你的系统。如果你是在一个物理系统中安装的,在这一步要拔掉 USB 介质。
```
umount /mnt/boot
umount /mnt
reboot
```
你现在已经成功地安装了 Arch Linux 基本系统。现在是安装完整的 GNOME 桌面的时候了。
![Arch 安装好了][16]
#### 第二部分:在 Arch Linux 中安装 GNOME
重启后,从 Grub 中选择 Arch Linux。在 Arch Linux 的提示符下,开始依次运行以下命令。这些命令安装 Xorg 服务器、显示管理器、GNOME 桌面组件、控制器包和其他应用程序。
所有的命令都使用默认值,即在要求时按回车。
安装 Xorg 服务器。安装大小约为 80MB:
```
sudo pacman -S --needed xorg
```
安装显示管理器、GNOME 桌面。安装大小约为 300MB
```
sudo pacman -S --needed gnome gnome-tweaks nautilus-sendto gnome-nettool gnome-usage gnome gnome-multi-writer adwaita-icon-theme xdg-user-dirs-gtk fwupd arc-gtk-theme seahosrse gdm
```
上面的安装会要求提供几个软件包的选项。选择你想要的任何一个。如果你不确定,在询问时选择 “jack”、“noto-sans” 和 “xdg-portal-desktop-gnome”。
安装应用程序。这只是一个参考。你也可以安装你所需要的:
```
sudo pacman -S --needed firefox vlc filezilla leafpad xscreensaver archlinux-wallpaper
```
现在是时候把显示管理器和网络管理器作为服务启用了。这样,下次登录时,它们就可以由 systemd 自动运行。
```
systemctl enable gdm
systemctl enable NetworkManager
```
使用 `reboot` 命令重新启动系统:
```
reboot
```
![Arch Linux 运行 GNOME 43 桌面][17]
如果一切顺利,你应该在 GNOME 桌面上看到一个漂亮的登录提示。使用你刚刚创建的凭证登录。迎接你的应该是 Arch Linux 漂亮而干净的 GNOME 43 桌面。
我希望这个指南能帮助你在裸机 Arch 安装 GNOME 桌面。
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/gnome-arch-linux-install/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[Chao-zhi](https://github.com/Chao-zhi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://www.debugpoint.com/2020/11/install-arch-linux/
[2]: https://www.debugpoint.com/archinstall-guide/
[3]: https://www.archlinux.org/download/
[4]: https://www.debugpoint.com/wp-content/uploads/2020/12/fdisk-l-before.jpg
[5]: https://www.debugpoint.com/wp-content/uploads/2020/12/cfdisk-1024x159.jpg
[6]: https://www.debugpoint.com/wp-content/uploads/2020/12/Swap-parition-type-change.jpg
[7]: https://www.debugpoint.com/wp-content/uploads/2020/12/final-partition-list-in-cfdisk-1024x178.jpg
[8]: https://www.debugpoint.com/wp-content/uploads/2020/12/final-partition-list-in-fdisk.jpg
[9]: https://www.debugpoint.com/wp-content/uploads/2020/12/prepare-file-system.jpg
[10]: https://www.debugpoint.com/2020/11/connect-wifi-terminal-linux/
[11]: https://www.debugpoint.com/wp-content/uploads/2020/12/Install-base-system-1024x205.jpg
[12]: https://www.debugpoint.com/wp-content/uploads/2020/12/change-locale.jpg
[13]: https://www.debugpoint.com/wp-content/uploads/2020/12/create-user.jpg
[14]: https://www.debugpoint.com/wp-content/uploads/2020/12/update-sudoers-file.jpg
[15]: https://www.debugpoint.com/wp-content/uploads/2020/12/configure-grub-1024x639.jpg
[16]: https://www.debugpoint.com/wp-content/uploads/2020/12/Arch-is-installed.jpg
[17]: https://www.debugpoint.com/wp-content/uploads/2020/12/Arch-Linux-Running-GNOME-43-Desktop-1024x636.jpg
[0]: https://img.linux.net.cn/data/attachment/album/202302/13/220203a5yb5xy24yer4atv.jpg

View File

@ -0,0 +1,104 @@
[#]: subject: "How to Install MATE Desktop in Arch Linux [Complete Guide]"
[#]: via: "https://www.debugpoint.com/mate-desktop-arch-linux-install/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "Chao-zhi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15561-1.html"
如何在 Arch Linux 中安装 MATE 桌面
======
![][0]
> 本指南将详细解释你在 Arch Linux 中安装 MATE 桌面所需的步骤。
本指南分为两部分。第一部分讨论安装基础 Arch 系统。第二部分是在 Arch Linux 上安装完整的 MATE 桌面环境。
本文在以下版本中进行了测试MATE 1.24 和 MATE 1.26。
### 什么是 MATE 桌面?
当 GNOME 桌面从 GNOME 2 改变方向到 GNOME 3 时改变了用户交互和界面MATE 桌面仍然延续了“较旧的”或者说“传统的” GNOME 2 的开发方向。因此MATE 桌面环境保留了 Linux 中的传统桌面体验。它速度快内存消耗低。在我看来MATE 桌面环境是一个被低估的桌面环境,需要更多的关注!
MATE 团队一直在继续开发,它是一个基于 GNOME 2 的流行桌面之一,但同时支持更新的技术。你可以在其 [官方网站][1] 上了解更多信息。
### 在 Arch Linux 中安装 MATE 桌面
#### 第一部分: 安装 Arch Linux
如果你已经安装了 Arch Linux则可以跳过此步骤直接转到下面的 MATE 桌面安装部分。
要快速安装 Arch Linux请按照这个自动化的 [archinstall 指南][2] 进行操作,该指南非常容易上手。安装完成后,继续至第二部分。
#### 第二部分:在 Arch Linux 中安装 MATE 桌面
重新启动后,从 GRUB 中选择 Arch Linux。在 Arch Linux 提示符下,按顺序运行以下命令。这些命令将安装 Xorg 服务器、显示管理器、MATE 桌面组件、控制器包以及其他应用程序。
对于所有命令,请使用默认值,即在询问时按 Enter 键。
安装 Xorg。安装大小大约为 80 MB。
```
sudo pacman -S --needed xorg
```
安装显示管理器和 MATE 桌面组件。安装大小大约为 380 MB。
```
sudo pacman -S --needed mate mate-extra ttf-freefont lightdm lightdm-gtk-greeter
```
> LCTT 译注:在 Arch Linux 中,很多时候 lightdm 显示管理器需要额外的配置才能正常启用。可以参考:[LightDM - ArchWiki][5]。除此之外,可以安装 lightdm-gtk-greeter-settings 来对 lightdm-gtk-greeter 进行配置。
![安装 MATE 包][3]
安装应用软件:
这只是一个参考。你也可以安装你所需要的内容。
```
sudo pacman -S --needed firefox vlc filezilla leafpad xscreensaver archlinux-wallpaper
```
现在是时候以服务的方式启用显示管理器和网络管理器了。这样,下次登录时,它们就可以通过 systemd 自动运行了。
```
systemctl enable lightdm
systemctl enable NetworkManager
```
使用重启命令重启系统:
```
reboot
```
如果一切顺利,你应该在 MATE 桌面上看到登录提示。
现在你可以使用刚刚创建的用户 ID 和密码登录。一个超快速和传统的 MATE 桌面将欢迎你的到来。
![Arch Linux 中的 MATE 桌面][4]
我希望本指南能帮助你从头开始创建自己的 Arch Linux 环境,并使用传统的 MATE 桌面。
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/mate-desktop-arch-linux-install/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[Chao-zhi](https://github.com/Chao-zhi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://mate-desktop.org/
[2]: https://www.debugpoint.com/archinstall-guide/
[3]: https://www.debugpoint.com/wp-content/uploads/2021/08/Installing-MATE-Packages.jpg
[4]: https://www.debugpoint.com/wp-content/uploads/2021/08/MATE-Desktop-in-Arch-Linux-1.jpg
[5]: https://wiki.archlinux.org/title/LightDM
[0]: https://img.linux.net.cn/data/attachment/album/202302/21/104424o8p78qj8gp5hqghj.jpg

View File

@ -0,0 +1,191 @@
[#]: subject: "A Guide to systemd journal Maintenance [With Examples]"
[#]: via: "https://www.debugpoint.com/systemd-journald-clean/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "Chao-zhi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15526-1.html"
systemd 日志维护指南(附实例)
======
![][0]
> systemd 内置了很多管理系统日志的功能。在本指南中,我们将介绍如何管理系统日志,并对其采取轮换、归档和清除日志等操作。我们还解释了手动系统日志清理方法和使用配置文件的变化。
如果你的 Linux 发行版支持 [systemd][1],那么从启动时开始,它每秒钟都会从系统的所有进程和应用程序中收集日志。所有这些日志事件都由 systemd 的 `journald` 守护程序管理。journald 收集所有的日志(信息、警告、错误等),并将其作为二进制数据存储在磁盘文件中。
由于日志保留在磁盘中,而且每秒钟都在收集,所以它占用了巨大的磁盘空间;特别是对于旧的系统、服务器来说。例如,在我的一个运行了一年左右的测试系统中,日志文件的大小是 GB 级的。
如果你管理多个系统、服务器,建议一定要正确管理 journald 日志,以便高效运行。让我们来看看如何管理日志文件。
### systemd 日志维护
使用 systemd 的 `journalctl` 工具,你可以查询这些日志,对其进行各种操作。例如,查看不同启动时的日志文件,检查特定进程或应用程序的最后警告和错误。如果你对这些不了解,我建议你在学习本指南之前先快速浏览一下此教程:[使用 journalctl 查看和分析 systemd 日志(附实例)][2] 》。
#### 物理日记的日志文件在哪里?
systemd 的 journald 守护进程在每次启动时都会收集日志。这意味着,它根据启动情况对日志文件进行分类。
日志以二进制形式存储在路径 `/var/log/journal`,文件夹为机器 ID。
比如说:
![日志文件位置的截图-1][3]
![日志文件位置的截图-2][4]
另外,请记住,根据系统配置,运行时日志文件被存储在 `/run/log/journal/`。而这些在每次启动时都会被删除。
#### 我可以手动删除日志文件吗?
你可以,但不要这样做。相反,请按照下面的说明,使用 `journalctl` 工具清除日志文件以释放磁盘空间。
#### systemd 的日志文件占用了多少磁盘空间?
打开一个终端,运行以下命令。
```
journalctl --disk-usage
```
这应该为你提供系统中的日志文件实际使用的数量。
![journalctl 磁盘使用命令][5]
如果你有一个图形化的桌面环境,你可以打开文件管理器,浏览路径 `/var/log/journal`,并检查属性。
#### systemd 日志清理过程
清理日志文件的有效方法应该是通过 `journald.conf` 配置文件来完成。正常情况下,即使 `journalctl` 提供了删除日志文件的工具,你也不应该手动删除这些文件。
让我们来看看如何 [手动][6] 删除它,然后我将解释 `journald.conf` 中的配置变化这样你就不需要时不时地手动删除文件相反systemd 会根据你的配置自动处理它。
##### 手动删除
首先,你必须 `flush``rotate` 日志文件。<ruby>轮换<rt>rotate</rt></ruby>是将当前活动的日志文件归档,并立即开始创建一个新的日志文件继续记录日志。<ruby>冲洗<rt>flush</rt></ruby> 开关要求日志守护进程将存储在 `/run/log/journal/` 中的所有日志数据冲入 `/var/log/journal/`,如果持久性存储被启用的话。
然后,在 `flush``rotate` 之后,你需要用 `vacuum-size`、`vacuum-time` 和 `vacuum-files` 选项运行 `journalctl` 来强制 systemd 清除日志。
例 1
```
sudo journalctl --flush --rotate
```
```
sudo journalctl --vacuum-time=1s
```
上面这组命令会删除所有存档的日志文件,直到最后一秒。这有效地清除了一切。因此,在运行该命令时要小心。
![日志清理-例子][7]
清理完毕后:
![清理后--日志的占用空间][8]
你也可以根据你的需要在 `--vacuum-time` 的数字后面提供以下后缀:
- `s`:秒
- `m`:分钟
- `h`:小时
- `days`:天
- `months`:月
- `weeks`:周
- `years`:年
例 2
```
sudo journalctl --flush --rotate
```
```
sudo journalctl --vacuum-size=400M
```
这将清除所有存档的日志文件,并保留最后 400MB 的文件。记住这个开关只适用于存档的日志文件,不适用于活动的日志文件。你也可以使用后缀,如下所示。
- `K`KB
- `M`MB
- `G`GB
例 3
```
sudo journalctl --flush --rotate
```
```
sudo journalctl --vacuum-files=2
```
`vacuum-files` 选项会清除所有低于指定数量的日志文件。因此,在上面的例子中,只有最后两个日志文件被保留,其他的都被删除。同样,这只对存档的文件有效。
如果你愿意,你可以把两种选项结合起来,但我建议不要这样做。然而,如果同时使用两个选项,请确保先用 `--rotate` 选项运行。
### 使用配置文件自动删除
虽然上述方法很好,也很容易使用,但建议你使用 journald 配置文件来控制日志文件的清理过程,该文件存在于 `/etc/systemd/journald.conf`
systemd 为你提供了许多参数来有效管理日志文件。通过组合这些参数,你可以有效地限制日志文件所占用的磁盘空间。让我们来看看。
| journald.conf 参数 | 描述 | 实例 |
| :- | :- | :- |
| `SystemMaxUse` |指定日志在持久性存储中可使用的最大磁盘空间| `SystemMaxUse=500M` |
| `SystemKeepFree` |指定在将日志条目添加到持久性存储时,日志应留出的空间量。| `SystemKeepFree=100M` |
| `SystemMaxFileSize` |控制单个日志文件在被轮换之前在持久性存储中可以增长到多大。| `SystemMaxFileSize=100M` |
| `RuntimeMaxUse` |指定在易失性存储中可以使用的最大磁盘空间(在 `/run` 文件系统内)。| `RuntimeMaxUse=100M` |
| `RuntimeKeepFree` |指定将数据写入易失性存储(在 `/run` 文件系统内)时为其他用途预留的空间数量。| `RuntimeMaxUse=100M` |
| `RuntimeMaxFileSize` |指定单个日志文件在被轮换之前在易失性存储(在 `/run` 文件系统内)所能占用的空间量。| `RuntimeMaxFileSize=200M` |
如果你在运行中的系统的 `/etc/systemd/journald.conf` 文件中添加这些值,那么在更新文件后,你必须重新启动 journald。要重新启动请使用以下命令。
```
sudo systemctl restart systemd-journald
```
### 核实日志文件
在你清理完文件后,检查日志文件的完整性是比较明智的。要做到这一点,请运行下面的命令。该命令显示了日志文件是否通过(`PASS`)、失败(`FAIL`)。
```
journalctl --verify
```
![验证日志文件][9]
### 总结
希望本指南能帮助你了解 systemd 日志管理流程的基本情况。通过这些,你可以通过限制空间、清除旧的日志文件来管理系统或服务器中的日志文件所使用的磁盘空间。这些只是指导性的命令,你可以通过多种方式组合这些命令来实现你的系统需求。
- [journalctl 手册][10]
- [journald.conf 手册][11]
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/systemd-journald-clean/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[Chao-zhi](https://github.com/Chao-zhi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://www.freedesktop.org/wiki/Software/systemd/
[2]: https://www.debugpoint.com/2020/12/systemd-journalctl/
[3]: https://www.debugpoint.com/wp-content/uploads/2021/01/Screenshot-of-physical-journal-file-1.jpg
[4]: https://www.debugpoint.com/wp-content/uploads/2021/01/Screenshot-of-physical-journal-files-2.jpg
[5]: https://www.debugpoint.com/wp-content/uploads/2021/01/journalctl-disk-usage-command.jpg
[6]: https://www.debugpoint.com#delete-using-journal-conf
[7]: https://www.debugpoint.com/wp-content/uploads/2021/01/journal-clean-up-example.jpg
[8]: https://www.debugpoint.com/wp-content/uploads/2021/01/After-clean-up-journal-space-usage.jpg
[9]: https://www.debugpoint.com/wp-content/uploads/2021/01/verify-log-files.png
[10]: https://www.freedesktop.org/software/systemd/man/journalctl.html
[11]: https://www.freedesktop.org/software/systemd/man/journald.conf.html
[0]: https://img.linux.net.cn/data/attachment/album/202302/10/072955z20ipg8vlpvdt1jq.jpg

View File

@ -0,0 +1,261 @@
[#]: subject: "How to use journalctl to View and Analyze Systemd Logs [With Examples]"
[#]: via: "https://www.debugpoint.com/systemd-journalctl/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "Chao-zhi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15544-1.html"
如何使用 journalctl 查看和分析 systemd 日志(附实例)
======
![][0]
> 本指南介绍了 [systemd][1] 的 journalctl 工具及其各种命令的基础知识。你可以使用这些命令对 Linux 中的桌面和服务器日志进行故障诊断。以下是如何使用 journalctl 查看和分析 systemd 日志的不同例子。
### 简介
很多人说 systemd 不好,它对系统的影响很大,这也是一个有争议的话题。但你不能否认的是,它提供了一套完善的工具来管理和排除系统故障。想象一下,当你遇到一个没有 GUI 的损坏系统时,你可能会把启动和 GRUB 弄得一团糟。在这种情况下,你可以从一个<ruby>立付<rt>Live</rt></ruby>系统启动,挂上你的 Linux 分区,然后浏览 systemd 的日志,找出问题所在。
systemd 有三个基本组件,如下所示:
- `systemd`Linux 操作系统的系统和服务管理器。
- `systemctl` :该命令用于反观和控制 systemd 系统和服务管理器的状态。
- `systemd-analyze`:该命令提供系统启动时的性能统计,并从系统和服务管理器中检索其他状态和跟踪信息。
除了这三个服务外systemd 还提供其他服务,如 journald、logind、networkd 等。在本指南中,我们将讨论 systemd 的 journald 服务。
### journald - systemd 日志服务
根据设计systemd 提供了一个集中的方式来处理所有来自进程、应用程序等的操作系统日志。所有这些日志事件都由 systemd 的 journald 守护进程来处理。journald 守护进程收集所有来自 Linux 操作系统各处的日志,并将其作为二进制数据存储在文件中。
以二进制数据集中记录事件、系统问题的好处有很多。例如由于系统日志是以二进制而不是文本形式存储的你可以以文本、JSON 对象等多种方式进行转译,以满足各种需求。另外,由于日志是按顺序存储的,通过对日志的日期/时间操作,超级容易追踪到单个事件。
请记住journald 收集的日志文件数以千行计,而且不断更新每次开机、每个事件。因此,如果你有一个长期运行的 Linux 操作系统,日志的大小应该以 GB 为单位。由于有着数以千计的日志,最好用基本命令进行过滤,以了解更多系统问题。
#### journald 配置文件
journald 的配置文件存在于以下路径中。它包含了关于如何进行日志记录的各种标志。你可以看一下这个文件,并进行必要的修改。但我建议不要修改这个文件,除非你知道自己在做什么。
```
/etc/systemd/journald.conf
```
#### journald 存储二进制日志文件的地方
journald 以二进制格式存储日志。它们被保存在这个路径下的一个目录中:
```
/var/log/journal
```
例如,在下面的路径中,有一个目录包含了迄今为止的所有系统日志。
![journalctl log file path][2]
不要使用 `cat` 命令,也不要使用 `nano``vi` 来打开这些文件。它们(是二进制的),无法正常显示。
### 使用 journalctl 来查看和分析 systemd 日志
#### journald 基本命令
查看 journald 日志的基本命令是:
```
journalctl
```
![journalctl][3]
该命令提供了所有应用程序和进程的日志条目,包括错误、警告等。它显示的列表中,最旧的日志在顶部,当前的日志在底部。你需要不断按回车键来逐行滚动浏览。你也可以使用 `PAGE UP``PAGE DOWN` 键来滚动。按 `q` 键可以退出这个视图。
#### 如何以不同时区的时间查看日志条目
默认情况下,`journalctl` 以当前系统时区显示日志的时间。然而,你可以很容易地在命令中提供时区,将同一日志转换为不同的时区。例如,要以 UTC 查看日志,请使用以下命令:
```
journalctl --utc
```
![journalctl --utc][4]
#### 如何在日志中只查看错误、警告等信息
系统产生的日志有不同的优先级。有些日志可能是可以忽略的警告,有些可能是重要的错误。你可能想只看错误,不看警告。这也可以用下面的命令来实现。
要查看紧急系统信息,请使用:
```
journalctl -p 0
```
![journalctl -p 0][5]
错误代码:
```
0: 紧急情况
1: 警报
2: 危急
3: 错误
4: 警告
5: 通知
6: 信息
7: 调试
```
当你指定错误代码时,它显示该等级及更高的所有信息。例如,如果你指定下面的命令,它会显示所有优先级为 2、1 和 0 的信息:
```
journalctl -p 2
```
#### 如何查看特定启动的日志
当你运行 `journalctl` 命令时,它会显示当前启动的信息,即你正在运行的会话中的信息。但也可以查看过去的启动信息。
在每次重启时日志都会持续更新。journald 会记录不同启动时的日志。要查看不同启动时的日志,请使用以下命令。
```
journalctl --list-boots
```
![journalctl list-boots][6]
- 第一个数字显示的是 journald 的唯一的启动跟踪号码,你可以在下一个命令中使用它来分析该特定的启动。
- 第二个数字是启动 ID你也可以在命令中指定。
- 接下来的两个日期、时间组合是存储在相应文件中的日志的时间。如果你想找出某个特定日期、时间的日志或错误,这就非常方便了。
要查看一个特定的启动号码,你可以选择第一个启动跟踪号码或启动 ID如下所示。
```
journalctl -b -45
```
```
journalctl -b 8bab42c7e82440f886a3f041a7c95b98
```
![journalctl -b 45][7]
你也可以使用 `-x` 选项,在显示屏上添加 systemd 错误信息的解释。在某些情况下,这是个救命稻草。
```
journalctl -xb -p 3
```
![journalctl -xb][8]
#### 如何查看某一特定时间、日期的日志记录
`journalctl` 功能强大,可以在命令中提供类似英语的参数,用于时间和日期操作。
你可以使用 `--since` 选项与 `yesterday`、`today`、`tomorrow` 或 `now` 组合。
下面是一些不同命令的例子。你可以根据你的需要修改它们。它们是不言自明的。以下命令中的日期、时间格式为 `"YYYY-MM-DD HH:MM:SS"`
```
journalctl --since "2020-12-04 06:00:00"
```
```
journalctl --since "2020-12-03" --until "2020-12-05 03:00:00"
```
```
journalctl --since yesterday
```
```
journalctl --since 09:00 --until "1 hour ago"
```
![journalctl --since 09:00 --until][9]
你也可以将上述内容与错误级别开关结合起来。
#### 如何查看内核特定的日志记录
Linux 内核信息也可以从日志中提取出来。要查看当前启动时的内核信息,请使用以下命令:
```
journalctl -k
```
#### 如何查看某个服务、PID 的日志
你可以从 journald 日志中过滤出某个 systemd 服务单元的特定日志。例如,如果要查看 NetworkManager 服务的日志,请使用下面的命令。
```
journalctl -u NetworkManager.service
```
![journalctl NetworkManager service][10]
如果你不知道服务名称,可以使用下面的命令来列出系统中的 systemd 服务。
```
systemctl list-units --type=service
```
#### 如何查看用户、组的日志
如果你正在分析服务器日志,在多个用户登录的情况下,这个命令很有帮助。你可以先用下面的命令从用户名中找出用户的 ID。例如要找出用户 `debugpoint` 的 ID
```
id -u debugpoint
```
然后使用 `_UID` 选项指定该 ID 与来查看该用户产生的日志。
```
journalctl _UID=1000 --since today
```
![journalctl _UID][11]
同样地,使用 `_GID` 选项也可以查到用户组的情况。
#### 如何查看一个可执行文件的日志
你也可以查看某个特定程序或可执行文件的日志。例如,如果你想找出 `gnome-shell` 的信息,你可以运行以下命令。
```
journalctl /usr/bin/gnome-shell --since today
```
![journalctl gnome-shell][12]
### 结束语
希望本指南能帮助你使用 `journalctl` 查看分析 Linux 桌面或服务器上的 systemd 日志排除故障。如果你知道如何使用这些命令systemd 日志管理的功能非常强大,它能让你在调试时的生活变得轻松一些。现在所有主流的 Linux 发行版都使用 systemd。Ubuntu、Debian、Fedora、Arch 它们都使用 systemd 作为其默认的操作系统组件。如果你想了解不使用 systemd 的 Linux发行版你可能想看看 [MX-Linux][13]、Gentoo、Slackware、Void Linux。
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/systemd-journalctl/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[Chao-zhi](https://github.com/Chao-zhi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://freedesktop.org/wiki/Software/systemd/
[2]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-log-file-path.jpg
[3]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl.jpg
[4]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-utc.jpg
[5]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-p-0.jpg
[6]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-list-boots.jpg
[7]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-b-45.jpg
[8]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-xb.jpg
[9]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-since-0900-until.jpg
[10]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-NetworkManager-service.jpg
[11]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-_UID.jpg
[12]: https://www.debugpoint.com/wp-content/uploads/2020/12/journalctl-gnome-shell.jpg
[13]: https://www.debugpoint.com/tag/mx-linux
[0]: https://img.linux.net.cn/data/attachment/album/202302/16/085250d5ngtogo2fjjn8o2.jpg

View File

@ -0,0 +1,147 @@
[#]: subject: "Fixing “Key is stored in legacy trusted.gpg keyring” Issue in Ubuntu"
[#]: via: "https://itsfoss.com/key-is-stored-in-legacy-trusted-gpg/"
[#]: author: "Abhishek Prakash https://itsfoss.com/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15565-1.html"
修复 Ubuntu 中的 “Key is stored in legacy trusted.gpg keyring” 问题
======
![][0]
如果你在 Ubuntu 22.04 及以后的版本中使用 PPA 或添加外部仓库,你有可能会看到这样的信息:
```
W: https://packagecloud.io/slacktechnologies/slack/debian/dists/jessie/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
```
![ubuntu key is stored legacy][1]
首先,这不是一个错误,而是一个警告信息。警告并不会导致程序停止工作。即使你在更新过程中看到这个警告信息,你也可以继续升级你的系统。
如果你不想看到这个警告信息,你可以采取一些手动步骤来摆脱它。
有两种方法;正确的方法和快速而不优雅的方法。阅读这两种方法,看看你对哪一种感到满意。
### 方法 1导入密钥正确但复杂的方法
首先,列出所有添加到你系统中的 GPG 密钥。
```
sudo apt-key list
```
这将显示一个存储在你系统中的巨大的密钥列表。你在这里要做的是寻找与警告信息相关的密钥。
```
abhishek@itsfoss:~$ sudo apt-key list
[sudo] password for abhishek:
Warning: apt-key is deprecated. Manage keyring files in trusted.gpg.d instead (see apt-key(8)).
/etc/apt/trusted.gpg
--------------------
pub rsa4096 2014-01-13 [SCEA] [expired: 2019-01-12]
418A 7F2F B0E1 E6E7 EABF 6FE8 C2E7 3424 D590 97AB
uid [ expired] packagecloud ops (production key) <abhishek@itsfoss>
pub rsa4096 2016-02-18 [SCEA]
DB08 5A08 CA13 B8AC B917 E0F6 D938 EC0D 0386 51BD
uid [ unknown] https://packagecloud.io/slacktechnologies/slack (https://packagecloud.io/docs#gpg_signing) <abhishek@itsfoss>
sub rsa4096 2016-02-18 [SEA]
/etc/apt/trusted.gpg.d/audio-recorder-ubuntu-ppa.gpg
----------------------------------------------------
pub rsa4096 2015-08-30 [SC]
42EF 41ED 9813 B713 D4F1 F06D 5CF1 2638 ACF9 669F
uid [ unknown] Launchpad PPA for Team audio-recorder
/etc/apt/trusted.gpg.d/danielrichter2007-ubuntu-grub-customizer.gpg
-------------------------------------------------------------------
pub rsa1024 2010-10-08 [SC]
59DA D276 B942 642B 1BBD 0EAC A8AA 1FAA 3F05 5C03
```
你要怎么做?仔细阅读该信息:
```
W: https://packagecloud.io/slacktechnologies/slack/debian/dists/jessie/InRelease: Key is stored in legacy
```
在我的例子中,仓库有 `packagecloud`、`slacktechnologies` 等关键词。它显示在 `apt-key` 列表输出的顶部。在你的情况下,你可能需要滚动一下。
在这种罕见的情况下,由 Slack 添加的外部仓库,有两个 GPG 密钥。其中一个已经过期,我会忽略它。你可能不会有这样的情况。
你应该看到 `pub` 后一行的最后 8 个字符(不包括空格):
```
/etc/apt/trusted.gpg
--------------------
pub rsa4096 2014-01-13 [SCEA] [expired: 2019-01-12]
418A 7F2F B0E1 E6E7 EABF 6FE8 C2E7 3424 D590 97AB
uid [ expired] packagecloud ops (production key) <abhishek@itsfoss>
pub rsa4096 2016-02-18 [SCEA]
DB08 5A08 CA13 B8AC B917 E0F6 D938 EC0D 0386 51BD
uid [ unknown] https://packagecloud.io/slacktechnologies/slack (https://packagecloud.io/docs#gpg_signing) <abhishek@itsfoss>
```
因此,从 `DB08 5A08 CA13 B8AC B917 E0F6 D938 EC0D 0386 51BD` 这行中我将提取最后8个字符 `0386 51BD`,去掉空格,然后用它来导入 `/etc/apt/trusted.gpg.d` 目录下专用文件中的 GPG 密钥:
```
sudo apt-key export 038651BD | sudo gpg --dearmour -o /etc/apt/trusted.gpg.d/slack.gpg
```
我在这里创建了一个新的文件 `slack.gpg`,以防你没有注意到它。我把它命名为 `slack.gpg` 是因为它与我之前安装的 Slack 应用有关。文件名并不重要,但它对识别有好处。
如果命令运行成功,你将不会看到任何信息。你可以通过检查新创建的 gpg 文件是否存在来验证。
![import gpg key to trusted ubuntu][2]
再次运行更新,现在你应该不会再看到警告信息了。
### 方法 2复制到 trusted.gpd.d 目录中(快速而不优雅的方法)
如果你觉得手动做上面的事情不舒服,那么,你可以忽略这个警告信息。我的意思是,忽略它总是一种选择。
另一个选择是把 `/etc/apt/trusted.gpg` 文件复制到 `/etc/apt/trusted.gpg.d` 目录。毕竟Ubuntu 只是抱怨说它需要 `/etc/apt/trusted.gpg.d` 目录下的 GPG 密钥。
你仍然要使用终端。打开它并使用以下命令:
```
sudo cp /etc/apt/trusted.gpg /etc/apt/trusted.gpg.d
```
现在,如果你运行更新,你就不会再看到 “Key is stored in legacy trusted.gpg keyring” 的警告信息。
![quick dirty way to fix apt key stored legacy][3]
### 总结
我曾经写过一篇关于 [弃用 apt-key][4] 的详细文章。显然,那篇文章让一些读者感到困惑,因此我写了这篇文章,给他们提供摆脱该信息的直接步骤。
正如我之前所说,这是一个警告信息,目前可以忽略。解决这个问题的责任在于外部软件开发者和 Ubuntu 开发者。外部软件开发者应该确保他们的 GPG 密钥不再被添加到 `/etc/apt/trusted.gpg` 文件中。
终端用户不应该为他们的懒惰而承担痛苦。
那么,你是用哪种方法来摆脱 “key is stored in legacy” 的警告信息的呢?第一个方法还是第二个方法?
--------------------------------------------------------------------------------
via: https://itsfoss.com/key-is-stored-in-legacy-trusted-gpg/
作者:[Abhishek Prakash][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/
[b]: https://github.com/lkxed
[1]: https://itsfoss.com/content/images/wordpress/2022/11/ubuntu-key-is-stored-legacy.png
[2]: https://itsfoss.com/content/images/wordpress/2022/11/import-gpg-key-to-trusted-ubuntu.png
[3]: https://itsfoss.com/content/images/wordpress/2022/11/quick-dirty-way-to-fix-apt-key-stored-legacy.png
[4]: https://itsfoss.com/apt-key-deprecated/
[0]: https://img.linux.net.cn/data/attachment/album/202302/22/143209ysmxzrasycrxz7wa.jpg

View File

@ -0,0 +1,59 @@
[#]: subject: "Build an interactive timeline in React with this open source tool"
[#]: via: "https://opensource.com/article/22/11/react-timeline-planby"
[#]: author: "Karol Kozer https://opensource.com/users/karolkozer"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15571-1.html"
用这个开源工具在 React 中建立一个交互式时间轴
======
![][0]
> Planby 是一个 JavaScript 组件用于帮助创建流媒体服务、音乐和体育赛事等的时间表、时间线和电子节目指南EPG
几年来我在电视在线和视频点播VOD行业工作。在开发一个调度器网络应用时我意识到在电子节目指南EPG和调度方面没有好的解决方案。诚然对于大多数网络开发者来说这是一个小众的功能但对于电视应用来说这是一个常见的需求。我看到并分析了许多网站实现了他们自己的 EPG 或时间表,我经常想,为什么每个人似乎都在发明他们自己的解决方案,而不是致力于开发一个大家都能使用的共享解决方案。这就是我开始开发 Planby 的时候。
[Planby][1] 是一个 ReactJavaScript组件帮助你为在线电视和视频点播VOD服务、音乐和体育赛事等创建计划、时间线和电子节目指南EPG。Planby 使用自定义的虚拟视图,允许你对大量的数据进行操作,并以友好和有用的方式呈现给你的观众。
Planby 有一个简单的 API你可以与第三方 UI 库集成。组件的主题是根据应用设计的需要定制的。
### 时间线性能
实现时间线功能时,最重要的是性能。你有可能在许多不同频道处理无穷无尽的数据流。应用可能不断地在刷新、移动和滚动。你希望用户与内容的互动是流畅的。
还有一个潜在的问题是设计不当。有时,一个应用以列表的形式实现 EPG 时间线,你必须垂直滚动,这意味着你必须点击按钮在时间上左右移动,这很快就会变得很累。更重要的是,有时与 EPG 互动的自定义功能如评级、选择你最喜欢的频道、从右到左RTL阅读等根本无法使用或者即便它们可用也会导致性能问题。
我经常面临的另一个问题是,应用的数据传输过于冗长。当一个应用在你滚动浏览 EPG 的时候请求数据,时间线会感觉很慢,甚至会崩溃。
### 什么是 Planby
这就是 Planby 的作用。Planby 是从头开始建立的,使用 React 和 Typescript 以及少量的资源。它使用一个自定义的虚拟视图允许你对大量的数据进行操作。它向用户显示节目和频道并根据时间和指定频道自动定位所有元素。当一个资源不包含任何内容时Planby 会计算定位,使时间段正确对齐。
Planby 有一个简单的界面,包括所有必要的功能,如侧边栏、时间轴本身、愉快的布局和实时节目刷新。此外,还有一个可选的功能,允许你隐藏任何你不想包括在布局中的元素。
Planby 有一个简单的 API允许你作为开发者实现你自己的项目以及用户的偏好。你可以使用 Planby 的主题来开发新的功能,也可以制作自定义的样式来配合你选择的设计。你可以很容易地整合其他功能,如日历、评级选项、用户最喜欢的列表、滚动、“现在” 按钮、录制计划、追播内容等等。更重要的是,你可以添加自定义的全局样式,包括 RTL 功能。
最重要的是,它在 MIT 许可下开源。
### 尝试 Planby
如果你想尝试一下 Planby或者只是想了解一下它请访问 [Git 仓库][1]。在那里,我已经有了一些例子,你可以阅读文档了解详情。该软件包也可以通过 `npm` 获得。
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/11/react-timeline-planby
作者:[Karol Kozer][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/karolkozer
[b]: https://github.com/lkxed
[1]: https://github.com/karolkozer/planby
[0]: https://img.linux.net.cn/data/attachment/album/202302/24/092229kgr2rqm6326rgdbl.jpg

View File

@ -0,0 +1,103 @@
[#]: subject: "Rnote: An Open-Source Drawing App for Notes and Annotation"
[#]: via: "https://itsfoss.com/rnote/"
[#]: author: "Ankush Das https://itsfoss.com/author/ankush/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15545-1.html"
Rnote一个用于笔记和注释的开源绘图应用
======
> Rnote 可以让你做笔记、绘图和注释文件。听起来你需要它?让我们来了解一下。
我们已经介绍了许多记笔记的应用,但支持手写笔记的选项却屈指可数。
Rnote 就是这样一个有用的应用,它可以让你做手写笔记并对文件/图片进行注释。当然,你需要一个绘图板或一个带有手写笔的设置来使用 Rnote。
### Rnote: 基于矢量的绘图应用,用于绘制草图和手写笔记
![rnote screenshot][1]
Rnote 是一个用 Rust 和 GTK 4 编写的令人印象深刻的开源应用。
它提供了一个专注于手写笔输入的自适应用户界面。它看起来很简约,但却提供了手写笔记所需的一些基本功能。
让我强调一下它能做的一些事情。
### Rnote 的特点
![rnote settings][3]
[Rnote][4] 是一个简洁而有很多功能的绘图/记事应用程序。一些功能包括:
- 支持具有各种笔画风格的压敏笔输入
- 用形状工具添加不同的形状
- 一个选择工具,可以移动、旋转、调整大小和修改你添加/绘制的内容
- 文档扩展布局
- 可定制的页面格式
- 可定制的背景颜色、图案和尺寸
- 支持笔的反馈声音
- 可重新配置的手写笔按钮快捷键
- 集成的工作区浏览器可快速访问媒体文件
- 支持拖放
- 支持剪贴板
- 支持常见的页面格式A6、A5、US letter 等)
- 从 PDF、位图和 SVG 文件导入
- 使用原生的 .rnote 文件来保存/加载文件
- 支持导出到 SVG 和 PDF
- 自动保存功能
- 深色/浅色模式
开发者指出Rnote 使用的原生文件格式可能不够稳定,无法在较新版本的应用之间兼容。
因此,在将 Rnote 升级到最新版本之前,最好在完成工作后将其导出。
除了它的功能外,你还能通过可用的选项获得良好的用户体验。它不会让人感到压抑,你可以快速访问所有的工具。
一些自定义功能可以隐藏滚动条,改变光标,并调整绘图光标。
你还可以调整自动保存启动的时间间隔,这在各种使用情况下应该很方便。
![rnote screenshot 1][5]
### 在 Linux 上安装 Rnote
Rnote 在 [Flathub][6] 上以 Flatpak 的形式提供。因此,只要你的系统启用了 [Flatpak][7],你就可以在任何 Linux 发行版上安装它。
你可以在你的软件中心找到它(如果 Flatpak 集成已被启用),或者输入以下命令来安装它:
```
flatpak install flathub com.github.flxzt.rnote
```
要探索更多关于 Rnote 的信息,请前往其 [GitHub 页面][8]。
### 总结
Rnote 正在积极开发,并在其功能设置方面取得了良好的进展。如果你喜欢 Rnote你可能想看看 [Xournal++][9],它是另一个能让你做手写笔记的应用。
你还知道其他像 Rnote 这样令人兴奋的应用吗?你觉得 Rnote 怎么样?请在下面的评论中分享你的想法。
--------------------------------------------------------------------------------
via: https://itsfoss.com/rnote/
作者:[Ankush Das][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/ankush/
[b]: https://github.com/lkxed
[1]: https://itsfoss.com/content/images/wordpress/2022/11/rnote-screenshot.png
[3]: https://itsfoss.com/content/images/wordpress/2022/11/rnote-settings.png
[4]: https://rnote.flxzt.net
[5]: https://itsfoss.com/content/images/wordpress/2022/11/rnote-screenshot-1.png
[6]: https://flathub.org/apps/details/com.github.flxzt.rnote
[7]: https://itsfoss.com/flatpak-guide/
[8]: https://github.com/flxzt/rnote
[9]: https://xournalpp.github.io

View File

@ -0,0 +1,79 @@
[#]: subject: "How to use the Linux file manager for GNOME 2"
[#]: via: "https://opensource.com/article/22/12/linux-file-manager-caja"
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15531-1.html"
GNOME 2 的 Linux 文件管理器 Caja
======
![][0]
> 如果你是 GNOME 2 的粉丝,那么你肯定会发现 Caja 很熟悉,如果你从来没有使用过 GNOME 2那么你可能会在 Mate 中找到你的新宠桌面。
在 GNOME 3 之前是 GNOME 2废话在其作为常见的默认 Linux 桌面之一的统治期间,它拥有了一个热心的粉丝群。[Mate 项目][1](以植物 _yerba mate_ 命名)最初是为了延续 GNOME 2 桌面的生命力,它起初是使用 GTK 2基于 GNOME 2 的工具包)开发的,后来升级为 GTK 3。该桌面包含了一个 Caja 文件管理器,这是一个简单而强大的应用,可以帮助你分类和组织你的数据。
### 安装 Caja
Caja 并不完全是一个独立的应用。它与 Mate 桌面紧密相连,所以要试用它,你必须安装 Mate。
你可能会发现 Mate 包含在你的 Linux 发行版的仓库中,或者你可以下载并安装一个将 Mate 作为默认桌面的发行版。不过,在你安装之前,要注意它是为了提供完整的桌面体验,所以会和桌面一起安装许多 Mate 应用。如果你运行一个不同的桌面,你可能会发现自己有多余的应用(两个 PDF 阅读器,两个媒体播放器,两个文件管理器,等等)。要评估 Caja 不会对你的电脑做重大改动,可以使用 [GNOME Boxes][2] 在虚拟机中安装一个基于 Mate 的发行版。
![Image of the Caja file manager.][3]
### 清晰的布局
你可能首先注意到的是 Caja 的清晰而直接的布局。在 Caja 窗口的顶部有一个工具栏,上面有一些常用任务的按钮。我喜欢这样的设计。功能不是隐藏在右键菜单中,也不是只有在操作后才能发现,更不是埋在菜单中。窗口的“显而易见”的操作被直接列在上面。
主工具栏下面是位置栏。它显示你当前的路径,可以是一系列的按钮,也可以是可编辑的文本。使用路径左边的 “<ruby>编辑<rt>Edit</rt></ruby>” 按钮来切换它是否可编辑。
### 可配置
对于 GNOME 2 或 Caja 的长期用户来说,主工具栏可能是多余的,尤其是当你知道了调用常用操作的键盘快捷键后。这就是为什么 Caja 的界面是可配置的。你可以从 “<ruby>查看<rt>View</rt></ruby>” 菜单中禁用 Caja 窗口的主要组件,包括:
- 主工具条
- 位置栏
- 侧面板
- 附加面板
- 状态栏
简而言之,你可以按你的想法精简 Caja。
![Image of a minimal Caja layout.][4]
### 标记你的文件夹
有些人是 “可视化” 人。他们喜欢根据自己对数据的看法来组织文件和文件夹,而不是根据计算机对数据的解释。例如,如果对你来说最重要的两个文件夹是**音乐**和**工作**,就很难让计算机相信这两者之间有任何关系。按字母顺序两者也排不到一起,而且每个文件夹的内容可能完全不同(一个是媒体文件,另一个是电子表格)。
### Caja 提供了一些帮助
使用 Caja你可以在一个窗口内手动放置目录Caja 会记住这个位置。更重要的是Caja 有多种标志可供你用作视觉标签。你可以在 “<ruby>编辑<rt>Edit</rt></ruby>” 菜单的 “<ruby>背景和标志<rt>Backgrounds and Emblems</rt></ruby>” 中找到它们。将它们拖放到文件和文件夹中以帮助它们区分。
![Image of emblems in Caja.][5]
### Caja
Caja 是最诱人的文件管理器之一。它的可配置性足以吸引许多不同的使用场景,而且在这些配置选项中,你很可能找到适合你的工作流程。如果你是 GNOME 2 的粉丝,那么你肯定会发现 Caja 很熟悉,如果你从来没有使用过 GNOME 2那么你可能会在 Mate 中找到你的新宠桌面。
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/12/linux-file-manager-caja
作者:[Seth Kenlon][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/seth
[b]: https://github.com/lkxed
[1]: https://opensource.com/article/19/12/mate-linux-desktop
[2]: https://opensource.com/article/19/5/getting-started-gnome-boxes-virtualization
[3]: https://opensource.com/sites/default/files/2022-10/caja.file%20manager.png
[4]: https://opensource.com/sites/default/files/2022-10/caja-minimal-layout.png
[5]: https://opensource.com/sites/default/files/2022-10/caja-emblem.webp
[0]: https://img.linux.net.cn/data/attachment/album/202302/12/093538qnlj0jdunz10n17c.jpg

View File

@ -0,0 +1,162 @@
[#]: subject: "How to Switch from Debian Stable to Testing"
[#]: via: "https://itsfoss.com/switch-debian-stable-testing/"
[#]: author: "Sagar Sharma https://itsfoss.com/author/sagar/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15520-1.html"
如何从 Debian 稳定版切换到测试版
======
![][0]
如果你正在寻找最稳定的 Linux 发行版当然Debian 是正确的选择。
特别是如果你打算在服务器上使用它。
但是,在桌面方面,情况就有点不同了。我的意思是,你得到的软件包至少是一年前的,对新时代硬件的支持甚至更糟。
那么,在这种情况下,你会怎么做呢?好吧,你可以使用 Debian <ruby>测试版<rt>Testing</rt></ruby>
但在跳到解释部分之前,让我们简单了解一下 Debian 测试版。
### 什么是 Debian 测试版?
Debian 社区为你提供 3 种不同的 Debian
- Debian <ruby>稳定版<rt>Stable</rt></ruby>(你从他们的主页上默认得到的东西)。
- Debian <ruby>测试版<rt>Testing</rt></ruby>(有**新的软件包**,比 Debian 不稳定版更少出现故障)。
- Debian <ruby>不稳定版<rt>Unstable</rt></ruby>(拥有最新的软件包,是**所有版本中最脆弱的**)。
因此Debian 测试版可以被认为是稳定性和新软件包之间的一个折中点。
我已经玩了一段时间的 Debian 测试版,没有遇到任何问题。
事实上,许多 Debian 用户喜欢测试版而不是稳定版。尽管名字叫“测试”,但它是相当可用的。
但是,**我还是建议你在虚拟机上进行实验**,尝试用你的主要工具来使用它,如果事情进展顺利,你可以在主系统中应用这些变化。
### 从 Debian 稳定版切换到 Debian 测试版
**警告:你不能从 Debian 测试版降级到 Debian 稳定版,因为安装脚本和安装工具只是为了用新版本替换旧版本而设计的。**
另外,我建议在你的主机上应用上述步骤之前,[使用 timeshift 创建一个备份][1] 。
首先,使用给定的命令更新现有的软件包:
```
sudo apt update && sudo apt upgrade -y
```
接下来,复制原始的 `sources.list` 文件:
```
sudo cp /etc/apt/sources.list sources.list.backup
```
现在,让我们开始第一步的工作。
#### 步骤 1编辑 sources.list 文件
有两种方法可以编辑 `sources.list` 文件。要么你可以用 `testing` 手动改变当前版本的名称,要么你可以 [使用 sed 命令][2] 来完成。
而我要用第二种方法来使整个过程更简单。你只需要使用给定的命令,它就会为你把 `bullseye` 替换成 `testing`
```
sudo sed -i 's/bullseye/testing/g' /etc/apt/sources.list
```
现在,打开你的终端,使用给定的命令来打开 `sources.list` 文件:
```
sudo nano /etc/apt/sources.list
```
并注释掉有 `security.debian.org` 和任何以 `updates` 结尾的行,如下所示:
![comment out security sources][3]
如果你像我一样使用 `nano`,你可以按 `Alt + /` 跳到该行的最后。然后你要添加以下一行:
```
deb http://security.debian.org testing-security main
```
![add line to keep track of testing in debian][4]
然后 [保存修改并退出 nano][5] 文本编辑器。
#### 步骤 2更新仓库并安装新的软件包
现在,更新仓库索引,它会显示大量的更新等待:
```
sudo apt update
```
![update repository in linux][6]
现在,你可以使用给定的命令,它将为你提供最新的软件包:
```
sudo apt upgrade
```
坐下来,放松一下,因为这将需要一些时间。
完成后,它将向你展示从 Debian 稳定版切换到测试版时的变化列表:
![packages that are updated when switched to debian testing][7]
如果你愿意,你可以阅读,或者你可以**直接按** `q` 继续。
现在,它会告诉你,你系统上安装的一些库需要重新启动。按 `TAB` 键,它将选择 “OK”然后按**回车**:。
![libraries needs to be restarted after update][8]
接下来,它会问你是否要在软件包升级期间重启服务。这里你有一个选择。由于我只做桌面使用,我将选择 “YES”。
![restart services during package upgrades without asking?][9]
完成后,你可以重启你的系统,然后使用下面的命令,让你刚才的改变完全生效:
```
sudo apt full-upgrade
```
现在,重启你的系统,你就会拥有最新的软件包。比如**我进入系统时我在运行 GNOME 43**
![running gnome 43 in debian][10]
### 总结
在本教程中,我解释了如何从 Debian 稳定版切换到 Debian 测试版。我希望这对你会有帮助。
如果你遇到任何问题或有任何疑问,请在评论中告诉我。
--------------------------------------------------------------------------------
via: https://itsfoss.com/switch-debian-stable-testing/
作者:[Sagar Sharma][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/sagar/
[b]: https://github.com/lkxed
[1]: https://itsfoss.com/backup-restore-linux-timeshift/
[2]: https://linuxhandbook.com/sed-command-basics/
[3]: https://itsfoss.com/content/images/wordpress/2022/11/comment-out-security-sources.gif
[4]: https://itsfoss.com/content/images/wordpress/2022/11/2.-add-line-to-keep-track-of-testing-in-debian.png
[5]: https://linuxhandbook.com/nano-save-exit/
[6]: https://itsfoss.com/content/images/wordpress/2022/11/update-repository-in-linux.png
[7]: https://itsfoss.com/content/images/wordpress/2022/11/packages-that-are-updated-when-switched-to-debian-testing.png
[8]: https://itsfoss.com/content/images/wordpress/2022/11/libraries-needs-to-be-restarted-after-update.png
[9]: https://itsfoss.com/content/images/wordpress/2022/11/restart-services-during-package-upgrades-without-asking.png
[10]: https://itsfoss.com/content/images/wordpress/2022/11/running-gnome-43-in-debian.png
[0]: https://img.linux.net.cn/data/attachment/album/202302/08/122659a4919hso9onkbmun.jpg

View File

@ -3,14 +3,18 @@
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15514-1.html"
发现 Linux SpaceFM 文件管理器的强大
发现 Linux SpaceFM 文件管理器的威力
======
SpaceFM 是一个使用 GTK 工具包的 Linux 的标签式文件管理器,所以它很适合在 [GNOME][1]、[Mate][2]、[Cinnamon][3] 等的桌面上使用。SpaceFM 还具有一个内置的设备管理器系统,所以它特别适合于窗口管理器,像 [Fluxbox][4] 或 [fvwm][5],它们通常不包括一个图形设备管理器。如果你对 Linux 上的文件管理器满意但你想尝试一个设计上有点不同的文件管理器SpaceFM 值得一看。
![][0]
> 如果你对 Linux 上的文件管理器感到满意但你想尝试一个设计上有点不同的文件管理器SpaceFM 值得一看。
SpaceFM 是一个使用 GTK 工具包的 Linux 的标签式文件管理器,所以它很适合在 [GNOME][1]、[Mate][2]、[Cinnamon][3] 等的桌面上使用。SpaceFM 还具有一个内置的设备管理器系统,所以它特别适合于 [Fluxbox][4] 或 [fvwm][5] 之类的窗口管理器,它们通常不包括图形设备管理器。如果你对 Linux 上的文件管理器满意但你想尝试一个设计上有点不同的文件管理器SpaceFM 值得一看。
### 安装 SpaceFM
@ -28,7 +32,7 @@ $ sudo apt install spacefm
### 面板
我不知道为什么 SpaceFM 被称为 SpaceFM但可能是因为它做出了一致的努力,让你把窗口中的每一点空间都用来做有用的事情。默认情况下SpaceFM 实际上是相当简单的、标准的文件管理器。它有一个列出你的文件的面板,一个工具栏,和一个菜单栏。
我不知道为什么 SpaceFM 被称为 SpaceFM但可能是因为它致力于让你把窗口中的每一点空间都用来做有用的事情。默认情况下SpaceFM 实际上是相当简单的、标准的文件管理器。它有一个列出你的文件的面板,一个工具栏,和一个菜单栏。
![SpaceFM is typical in design. At first.][6]
@ -37,38 +41,38 @@ $ sudo apt install spacefm
- **双击**打开一个目录或在其默认的应用中打开一个文件。
- **右键点击**可获得一个上下文菜单,提供许多标准选项(复制、粘贴、重命名、查看属性、创建新文件夹,等等)。
不过SpaceFM 使自己与众不同的方式是它的面板系统。SpaceFM 默认显示一个面板。这就是列出你的文件的大文件窗口。但它最多可以有四个面板视图,再加上一些用于某些特定任务的额外面板。
不过SpaceFM 使自己与众不同的方式是它的面板系统。SpaceFM 默认显示一个面板。这就是占据大部分空间的文件列表窗口。但它最多可以有四个面板视图,再加上一些用于某些特定任务的额外面板。
### 打开一个新的面板
在你的文件管理器中,你可以看到两个目录,而不是看到一个目录。要在自己的窗格中调出另一个目录,按 **Ctrl+2** 或进入**视图**菜单,选择 **Panel 2**。或者,点击菜单面板中从左开始的第二个绿点图标。
在你的文件管理器中,你可以看到两个目录,而不是看到一个目录。要在自己的窗格中调出另一个目录,按 `Ctrl+2` 或进入 “<ruby>视图<rt>View</rt></ruby>” 菜单,选择 “<ruby>面板二<rt>Panel 2</rt></ruby>。或者,点击菜单面板中从左开始的第二个绿点图标。
有了两个面板,你可以把文件从一个目录移到另一个目录,而不需要打开一个新的文件管理器窗口,或者你可以浏览两个目录来比较其内容。
但为什么要满足于两个面板呢?也许你更想一次看到三个目录。要在一个专门的窗格中调出第三个目录,请按 **Ctrl+3** 或进入**查看**菜单,选择 **Panel 3**。或者,点击菜单面板中从左开始的第三个绿点图标。这个面板出现在 SpaceFM 窗口的底部。
但为什么要满足于两个面板呢?也许你更想一次看到三个目录。要在一个专门的窗格中调出第三个目录,请按 `Ctrl+3` 或进入 “<ruby>视图<rt>View</rt></ruby>” 菜单,选择 “<ruby>面板三<rt>Panel 3</rt></ruby>。或者,点击菜单面板中从左开始的第三个绿点图标。这个面板出现在 SpaceFM 窗口的底部。
打开三个面板后,你可以在几个目录之间移动文件,或将文件从一个公共的“垃圾场”(如你的桌面或下载文件夹)分类到特定的目录。
当然,当你尝试了三个面板,你可能会发现自己很想拥有第四个面板。要在自己的窗格中打开第四个目录,**Ctrl+4** 或进入**查看**菜单,选择 **Panel 4**。或者,点击菜单面板中从左开始的第四个绿点图标。这个会在面板 3 旁边打开,并将你的 SpaceFM 窗口分成四份。
当然,当你尝试了三个面板,你可能会发现自己很想拥有第四个面板。要在自己的窗格中打开第四个目录,以此类推。或者,点击菜单面板中从左开始的第四个绿点图标。这个会在面板三旁边打开,并将你的 SpaceFM 窗口分成四份。
![SpaceFM can have up to four panels.][7]
那么_第五个_面板呢好吧实际上 SpaceFM 仅有四个面板。如果你真的想有第五个面板,你必须打开一个新的 SpaceFM 窗口。然而,仍有更多的面板,用于文件列表以外的信息,可供探索。
那么 _第五个_ 面板呢?好吧,实际上 SpaceFM 仅有四个面板。如果你真的想有第五个面板,你必须打开一个新的 SpaceFM 窗口。然而,仍有更多的面板,用于文件列表以外的信息,可供探索。
### 特殊面板
**查看**菜单中可以看到,除了文件面板外,还有一些特定的任务面板可以选择显示。这包括:
<ruby>视图<rt>View</rt></ruby>菜单中可以看到,除了文件面板外,还有一些特定的任务面板可以选择显示。这包括:
- **任务管理器**:列出正在进行的文件管理器进程。这不是一个通用的任务管理器,所以要设置 nice 值或检测僵尸 PID[htop 或 top][8] 仍然是你选择的工具。
- **书签**:常用文件夹的链接,如桌面、文档、下载和任何你想保持方便的位置。
- **设备**USB 驱动器和远程文件系统。
- **文件树**:按照目录继承顺序查看文件系统。
- <ruby>任务管理器<rt>Task manager</rt></ruby>:列出正在进行的文件管理器进程。这不是一个通用的任务管理器,所以要设置 nice 值或检测僵尸 PID[htop 或 top][8] 仍然是你应该选择的工具。
- <ruby>书签<rt>Bookmarks</rt></ruby>:常用文件夹的链接,如桌面、文档、下载和任何你想保持方便的位置。
- <ruby>设备<rt>Devices</rt></ruby>USB 驱动器和远程文件系统。
- <ruby>文件树<rt>File tree</rt></ruby>:按照目录继承顺序查看文件系统。
这些面板在 SpaceFM 的左侧打开,但它们是堆叠的。你可以同时打开书签、设备、任务和文件树,尽管它会有一个非常高的 SpaceFM 窗口。
### 为 SpaceFM 腾出空间
SpaceFM 是一个可配置的多任务文件管理器。它最大限度地增加了你可以在一个窗口中展示的信息,并让你决定什么是重要的,以及什么时候重要。本文重点介绍了 SpaceFM 的面板因为至少在我看来这些是该应用最独特的方面。然而SpaceFM 还有很多东西,包括插件、首选项、设计模式、键盘快捷键和自定义。这不是一个小的应用,尽管它是一个轻量级的。花些时间在 SpaceFM 上,因为你永远不知道你会发现什么。
SpaceFM 是一个可配置的多任务文件管理器。它最大限度地增加了你可以在一个窗口中展示的信息,并让你决定什么是重要的,以及什么时候重要。本文重点介绍了 SpaceFM 的面板因为至少在我看来这些是该应用最独特的方面。然而SpaceFM 还有很多东西,包括插件、首选项、设计模式、键盘快捷键和自定义。这不是一个小型应用,尽管它是轻量级的。花些时间在 SpaceFM 上,因为你永远不知道你会发现什么。
--------------------------------------------------------------------------------
@ -77,7 +81,7 @@ via: https://opensource.com/article/22/12/linux-file-manager-spacefm
作者:[Seth Kenlon][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
@ -91,3 +95,4 @@ via: https://opensource.com/article/22/12/linux-file-manager-spacefm
[6]: https://opensource.com/sites/default/files/2022-10/spacefm.webp
[7]: https://opensource.com/sites/default/files/2022-10/spacefm-panels.webp
[8]: https://opensource.com/life/16/2/open-source-tools-system-monitoring
[0]: https://img.linux.net.cn/data/attachment/album/202302/06/155511zdru3ulr4xmxeekj.jpg

View File

@ -0,0 +1,134 @@
[#]: subject: "Share Folder Between Guest and Host in GNOME Boxes"
[#]: via: "https://www.debugpoint.com/share-folder-gnome-boxes/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15517-1.html"
在 GNOME Boxes 里的客体机和宿主机之间共享文件夹
======
![][0]
> 使用下面的步骤在 GNOME Boxes 应用中的宿主机和客体机之间共享一个文件夹。
GNOME Boxes 是一个创建和管理虚拟机的前端应用。它主要是为 GNOME 桌面开发的。然而,你可以在其他桌面环境中使用它,如 KDE Plasma 和其他环境。
在后端,它使用 QEMU、KVM 和 libvirt 技术,并提供一个易于使用的用户界面来管理多个虚拟机。
如果你想了解更多,你也可以参考关于 GNOME Boxes 创建虚拟机的 [这些指南][1]。
在之前的文章中,我们已经解释了如何在 [virt-manager][2] 和 [VirtualBox][3] 中共享文件夹。而下面的步骤也解释了 GNOME Boxes 的情况。
### 如何在 GNOME Boxes 中共享文件夹和文件
GNOME Boxes 主要支持 [SPICE 协议][4] 来实现远程访问、共享和许多虚拟化功能。SPICE 是虚拟化领域中最古老的开源包之一。
#### 1、初始设置
首先,确保在**客体机系统中安装以下 spice 软件包**。
```
sudo apt install spice-vdagent spice-webdavd # for Ubuntu-based distros
sudo dnf install spice-vdagent spice-webdavd # Fedora, RHEL, etc
pacman -S --needed spice spice-gtk spice-protocol spice-vdagent # Arch Linux (optional)
```
在你安装完上述内容后,**重启**宿主机和客体机系统。
在宿主机系统中(对于 GNOME 桌面),打开 “<ruby>设置<rt>Settings</rt></ruby>”,进入 “<ruby>共享<rt>Sharing</rt></ruby>” 面板。
使用顶部的切换按钮**启用共享**。
然后,点击 “<ruby>文件共享<rt>File Sharing</rt></ruby>**启用文件共享**。请确保启用网络。密码是可选的。如果你想为你的共享文件夹启用基于密码的认证,请启用它。
![在设置中启用共享][5]
![启用文件共享][6]
关闭设置窗口。
打开 GNOME Boxes。右键单击虚拟机并选择 “<ruby>偏好<rt>Preferences</rt></ruby>”。
在偏好设置窗口中点击 “<ruby>设备和共享<rt>Devices and Shares</rt></ruby>”,并点击共享文件夹下的 “[+]” 按钮。
在 “<ruby>本地文件夹<rt>Local Folder</rt></ruby>” 下:从你的宿主机中选择你想在客体机中访问的文件夹。
在 “<ruby>名称<rt>Name</rt></ruby>” 中,给予你想要的任何名称。这个名称将在客人的文件管理器中可见。
点击 “<ruby>保存<rt>Save</rt></ruby>”。
![在宿主机中添加一个共享文件夹][7]
#### 2、为客体机设置
启动你的客体机虚拟机。
在客体机虚拟机内,打开文件管理器。如果你使用的是 GNOME 桌面,打开 Nautilus即 “<ruby>文件<rt>Files</rt></ruby>” 应用)。
点击 “<ruby>其他位置<rt>Other Locations</rt></ruby>”。你应该在 “<ruby>网络<rt>Networks</rt></ruby>” 下看到 “<ruby>Spice 客户端文件夹<rt>Spice client folder</rt></ruby>”。
双击它,你应该看到你的宿主机系统的文件夹内容。
有时,上述文件夹需要一些时间才能出现。如果它不可见,请等待 1 或 2 分钟。通过 `F5` 刷新文件管理器窗口。
![客体机中的 Spice 客户端文件夹][8]
#### 3、一些故障排除
此外,如果你看到以下错误,那么你需要手动访问该路径。
```
Unable to access location - HTTP Error: Could not connect: Connection refused
```
![访问 spice 客户端文件夹时出错][9]
在文件管理器中按下 `CTRL+L`,调出地址栏。在地址栏中,输入以下内容:
```
dav://localhost:9843
```
然后点击回车。然后你应该看到文件夹的内容。SPICE 服务器使用 `dav` 协议,它在 9843 端口连接客体机和宿主机。
![通过 dav 协议访问][10]
就这样了。现在你可以在 GNOME Boxes 中使用客体机和宿主机之间的文件共享。
下面是一个客体机和宿主机访问同一个文件夹的截图。
![在 GNOME Boxes 中在客体机和宿主机之间共享文件夹及其内容(示例)][11]
如果你遇到任何错误,请在下方发表评论。
[这篇文章中使用了一些来自 GitLab 的参考资料。][12]
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/share-folder-gnome-boxes/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://www.debugpoint.com/tag/boxes
[2]: https://www.debugpoint.com/share-folder-virt-manager/
[3]: https://www.debugpoint.com/share-folder-between-host-guest-virtualbox/
[4]: https://www.spice-space.org/index.html
[5]: https://www.debugpoint.com/wp-content/uploads/2023/01/Enable-sharing-in-settings.jpg
[6]: https://www.debugpoint.com/wp-content/uploads/2023/01/Enable-File-Sharing.jpg
[7]: https://www.debugpoint.com/wp-content/uploads/2023/01/Add-a-share-folder-in-host.jpg
[8]: https://www.debugpoint.com/wp-content/uploads/2023/01/Spice-client-folder-in-guest.jpg
[9]: https://www.debugpoint.com/wp-content/uploads/2023/01/error-while-accessing-the-spice-client-folder.jpg
[10]: https://www.debugpoint.com/wp-content/uploads/2023/01/accessing-via-dav-protocol.jpg
[11]: https://www.debugpoint.com/wp-content/uploads/2023/01/Share-folder-and-its-contents-between-guest-and-host-in-GNOME-Boxes-sample.jpg
[12]: https://gitlab.gnome.org/GNOME/gnome-boxes/-/issues/430
[0]: https://img.linux.net.cn/data/attachment/album/202302/07/121315k4ai4gnwa6imagob.jpg

View File

@ -0,0 +1,184 @@
[#]: subject: "Learn zip Command in Linux Using Examples"
[#]: via: "https://www.debugpoint.com/zip-command-linux-examples/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "Chao-zhi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15539-1.html"
zip 命令的解释与示例
======
> 这是一份关于理解 Linux 中的 zip 命令的初学者指南,并附有一些例子。
![][1]
这篇文章是 [Linux 命令][4]学习系列的一部分。
zip 文件是一个包含一个或多个文件的压缩档案。它作为一种无损数据压缩技术被广泛使用。由于压缩,它占用的磁盘空间更少,在计算机网络上传输时需要的数据也更少。
这些压缩文件可以在 Linux、Windows 和 macOS 中轻松提取。有各种支持压缩 zip 文件的软件,也提供提取它们的功能。
由于它很流行,几乎所有的操作系统都内置了这个功能。
在本教程中,我们将谈论几种基于终端的方法来压缩 Linux 中的文件。
### Linux 中的 Zip 命令示例
#### 语法
在 Linux 中,你需要使用的压缩文件的程序名称是 `zip`。下面是基本的语法:
```
zip [压缩文件名] file1 file2 file3
```
以下是正式的语法:
```
zip [-options] [-b path] [-t mmddyyyy] [-n suffixes] [zipfile list] [-xi list]
```
理想情况下,`zip` 命令应该被安装在所有主流的 Linux 发行版中。如果没有,使用下面的命令来安装它。
#### 在 Debian、Ubuntu 和相关发行版上安装
```
sudo apt install zip
```
#### 在 Fedora、基于 RHEL 的系统上安装
```
sudo dnf install zip
```
#### 在 Arch Linux 上安装
```
pacman -S zip
```
让我们继续看一些例子。
#### 如何压缩文件和文件夹
我的测试目录中有以下三个文件。它们是 `file1.txt`、`file2.txt` 和 `file3.txt`。如果我想用 zip 压缩三个文件,并创建一个 `myfiles.zip` 的压缩包,用下面的命令就可以了。
```
zip myfiles.zip file1.txt file2.txt file3.mp3
```
输出:
```
adding: file1.txt (stored 0%)
adding: file2.txt (stored 0%)
adding: file3.mp3 (deflated 13%)
```
![Linux 中基本压缩命令的输出][2]
这里你应该记住几个要点。
- 当创建一个 zip 文件时,你应该有对当前目录的修改权限。
- zip 文件格式不包含权限即读4、写2和执行1。所以创建该文件的用户成为该文件的所有者。
- 如果你想使用带有权限的 zip可以尝试使用 `tar` 命令(将在后面的教程中解释)。
- 在上面的输出中,`zip` 命令显示了被添加到存档中的文件名和压缩方法。
- 在目标文件名中指定 .zip 文件名的扩展名并不是必须的。如果你省略了 .zip`zip` 会在最后加上 .zip。
当你操作成百上千的文件时,为了减少终端中的输出,你可以使用 `-q` 参数来抑制 `zip` 命令中的输出:
```
zip -q myfiles.zip file1.txt file2.txt file3.txt
```
#### 递归压缩子文件夹
`zip` 命令的 `-r` 选项使你能够囊括所有子目录。这个选项会递归地遍历到一个目录结构的最后一个子目录,并将它们全部加入到压缩文件中。
下面的命令创建了一个包含 `my_folder` 内所有内容和子目录的压缩文件:
```
zip -r myfolder.zip my_folder
```
你也可以使用通配符(`*`)在你的压缩文件中包含特定类型的文件:
```
zip -0 my_movies.zip *.mp4
```
#### 混合添加文件和目录到压缩文件
有了以上所有的选项,`zip` 命令允许你把文件和目录一起作为参数指定。
```
zip -r myfiles.zip file1.txt file2.txt file3.txt my_folder1 my_folder2
```
### 压缩算法
zip 压缩的默认输出包含两个不同的词,即 `deflate``store`。zip 默认使用的压缩方法是 `deflate`。如果它成功地压缩了文件,那么输出显示 `deflate`。而当它不能压缩一个文件时,它只是将它们原封不动地存储在 .zip 文件中。这些文件的输出显示为 `store`
目前有许多压缩算法。其中一种是 bzip2 压缩法,在 Linux 中的 `zip` 命令支持它。你可以指定压缩算法作为一个命令选项来使用。使用选项 `-Z`,后面跟上算法名称,如下所示:
```
zip -r -Z bzip2 myfolder.zip my_folder
```
#### 压缩级别
`zip` 命令还允许你指定压缩级别。压缩级别是指你想让 zip 优化多少来减少包的大小。它是一个从 0 到 9 的数值范围。压缩级别为 9 的值是最高的压缩。默认值是 6。
记住,如果你用 zip 压缩成千上万个大小不一的文件,它可能会占用较多的系统资源,并花费大量的时间。所以,如果你在程序中使用它,或者用 shell 脚本处理大量的文件,请遵循正确的编程标准。
```
zip -9 -r myfolder.zip my_folder
```
#### 用密码保护一个压缩文件
你也可以用下面的 `-e` 选项对压缩文件进行密码保护:
```
zip -e -r myfolder.zip my_folder
```
运行该命令后,它将要求输入密码。
> 注意。尽量不要使用 zip 命令来对压缩文件进行密码保护。zip 的加密算法是使用流式加密的 PKZIP。而它很容易被破解。如果你想保护你的文件请使用 7-Zip 或其他高级工具。
#### 分割较大的压缩文件
许多应用程序、服务器和文件共享可能包含固定大小的文件上传限制。例如,你有一个 10GB 的文件,但服务只允许每个文件 1GB。使用 `zip``-s` 选项,你可以将其压缩并分割成几块进行上传。
```
zip -s 1g -r myfolder.zip my_folder
```
### 总结
你学到了一些 `zip` 命令的基本知识。它对大多数本地情况很有用,在这些情况下,你需要通过即时压缩来进行快速备份。然而,对于更高级的选项,你应该使用 7-Zip 或其他命令,我将在接下来的几篇文章中分享。
同时,你可以在 [zip 手册][3] 中了解更多。
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/zip-command-linux-examples/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[Chao-zhi](https://github.com/Chao-zhi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://www.debugpoint.com/wp-content/uploads/2023/01/zip-file-head.jpg
[2]: https://www.debugpoint.com/wp-content/uploads/2023/01/Output-of-Basic-zip-command-in-Linux.jpg
[3]: https://linux.die.net/man/1/zip
[4]: https://www.debugpoint.com/category/linux-commands

View File

@ -0,0 +1,153 @@
[#]: subject: "Top 10 Linux Distributions for Servers in 2023"
[#]: via: "https://www.linuxtechi.com/top-10-linux-distributions-for-servers/"
[#]: author: "Pradeep Kumar https://www.linuxtechi.com/author/pradeep/"
[#]: collector: "lkxed"
[#]: translator: "Veryzzj"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15535-1.html"
2023 年十佳 Linux 服务器发行版
======
![][0]
由于具备多种优势Linux 操作系统是各类服务器中的热门选择。首先,它是免费(少数商业发行版除外,如 RHEL 和 SUSE Linux Enterprise Server和开源的。它的开源性意味着开发者可以查看其源代码并进行修改而且可以根据规定的许可条款重新发布。其次通常 Linux 被认为是稳定、通用的,且比 Windows 更为安全。最后Linux 可以轻松地部署在各类平台,如裸机、虚拟机和云环境。
在这篇文章中,我们重点介绍了十佳 Linux 服务器发行版。
### 1、红帽企业 LinuxRHEL
<ruby>[红帽企业 Linux][1]<rt>Red Hat Enterprise Linux</rt></ruby>RHEL是专门为企业环境开发的商业 Linux 发行版。它是一个性能驱动、可靠安全的操作系统,提供了增强的可用性和无缝部署,使其成为服务器环境的理想选择。
RHEL 支持裸机、虚拟机和云环境中的各种工作负载。实际上,红帽是世界领先的开源解决方案供应商,提供了众多产品,包括 Red Hat OpenShift、Ansible 自动化平台、Open 混合云、JBoss 企业应用平台和 SAP 等等。
![Neofetch-Command-Output-RHEL-System][2]
### 2、Ubuntu 服务器
由 Canonical 开发和维护的 Ubuntu 是最流行和广泛使用的 Linux 发行版之一。Ubuntu 是一个基于 Debian 的 Linux 发行版完全自由开源以其桌面版而闻名它直观、用户友好被认为是学者和初学者的理想选择。Ubuntu 有 3 个版本,即:<ruby>桌面版<rt>Desktop</rt></ruby><ruby>服务器版<rt>Server</rt></ruby><ruby>核心版<rt>Core</rt></ruby>
虽然桌面版在全球范围内得到了大量使用,但服务器版也为服务器环境提供了一个坚实的平台。首先,它可以部署在任何环境中,无论是在物理机、虚拟机还是云环境中,都具备广泛的扩展功能。这意味着可以随时增加资源用来满足不断变化的需求。
由于服务器版本非常精简,没有任何图形用户界面,因此相对轻量,资源开销低。这意味着 CPU 和内存的使用也会较低。因此,提高了性能,并具备企业级的稳定性。
除了在物理数据中心和虚拟服务器上安装外Ubuntu 服务器还可以在 AWS 和 Azure 等公共云中使用。据 Canonical 称55%的 OpenStack 云运行在 Ubuntu 上。 此外,你可以付费获得自己管理的 Openstack 云。
![][3]
### 3、Debian
Debian 是最早的 Linux 发行版之一,以其稳定性而闻名。它有三个版本:<ruby>稳定版<rt>Stable</rt></ruby><ruby>不稳定版<rt>Unstable</rt></ruby><ruby>测试版<rt>Testing</rt></ruby>
Debian 稳定版是官方发布的最新 Debian 发行版,是服务器和台式机最受欢迎的版本。这个分支的所有软件包都经过了严格的测试和调试,因此被认为是可以运行生产工作负载的。
Debian 服务器是一个快速可靠的操作系统,强调安全性和稳定性。正是由于这个原因,它成为服务器环境的一个完美选择。此外,它提供了广泛的硬件支持,有超过 59,000 个软件包,是迄今为止所有操作系统中软件包数量最多的。
就像 Ubuntu 服务器一样Debian 轻量,功能多,非常适合企业工作负载。实际上,它比 Ubuntu 更稳定,更易于管理。
![][4]
### 4、SUSE Linux 企业服务器
在提供优秀服务器平台方面,另一位具有竞争力的对手是 <ruby>SUSE Linux 企业服务器<rt>SUSE Linux Enterprise Server</rt></ruby>SLES。该服务器操作系统是由位于德国的 SUSE 公司创建和维护的。
SLES 是一个为处理企业级工作负载而建立的商业发行版。它可以适应任何环境,并针对稳定性、可靠性和安全性进行了优化。它的高可扩展性,使 IT 团队能够有效地部署他们的应用程序和服务,以应对不断增长的业务需求。
最新的 SLES 版本提供了易于管理的互操作。它还针对 Docker 容器、Kubernetes 和地理集群提供了更多的支持和兼容。后者提供了高可用的灵活性,使 IT 团队能够配置跨越多个数据中心区域的复制集群。
SUSE Linux Enterprise Server 不仅支持内部工作负载,而且支持云服务,包括微软 Azure、谷歌计算引擎和亚马逊 Web 服务。
### 5、OpenSUSE Leap
由 OpenSUSE 项目开发OpenSUSE 是一个基于 RPM 的非商业 Linux 发行版,由 SUSE 公司开发和维护。同样是自由开源的OpenSUSE 提供了两个版本:
- OpenSUSE Leap
- OpenSUSE Tumbleweed
OpenSUSE TumbleWeed 是 OpenSUSE 的滚动发行版本。它包含最新的稳定应用程序包括内核、Git、Samba、桌面应用程序等等。因此它是开发人员或高级用户的完美选择他们需要利用最新的软件堆栈进行工作负载。然而由于频繁的内核更新导致与其他第三方驱动模块的不一致它并不是服务器的理想选择。
OpenSUSE Leap 是将 OpenSUSE 用于服务器的首选。它是一个开源和社区驱动的发行版,发布周期较慢,因此,比 TumbleWeed 更适合。社区驱动,这意味着它在发布之前要经过严格的测试。
Leap 相对来说更容易使用,并提供高性能和稳定性,是处理企业级工作负载的理想选择。它是商业服务器发行版(如 SLES 和 RHEL的优秀替代方案并允许企业在裸机和云部署上部署他们的工作负载。
![][6]
### 6、Rocky Linux
Rocky Linux 是一个作为 CentOS Linux 的替代品而开发的 Linux 发行版,后者在 2021 年 12 月 31 日达到了 EOL寿命终止。它是一个自由而开源的 Linux 发行版,具备稳定性、可靠性且定期更新,并在 10 年的支持生命周期内完全免费。
Rocky Linux 是一个企业级操作系统,旨在与 RHEL 100% 兼容,目前正在由社区大力开发。
自从 CentOS Linux 不合时宜地突然停产后,导致该发行版获得较高人气。它可以服务器和台式电脑上安装,也提供了公有云供应商(如亚马逊 AWS 和谷歌计算引擎)上的定制镜像。
Rocky Linux 开发者提供了一个迁移脚本,允许用户从其他企业版(如 CentOS Linux 和 Oracle Linux迁移到 Rocky Linux。
![][7]
### 7、AlmaLinux
另一个为填补 CentOS Linux 留下的空白的选择是 AlmaLinux。同样一个完全自由开源的企业操作系统。
AlmaLinux 最初是由 CloudLinux 创建的,但目前是由社区驱动的。它提供了一个生产级的企业操作系统,与 RHEL 11 二进制兼容。简而言之,它是 RHEL 的克隆,简而言之,它是 RHEL 的克隆,并免费提供坚实的稳定性和 RHEL 所带来的优势。
作为一个企业级的服务器操作系统AlmaLinux 可以轻松运行关键工作负载。此外,它提供长期支持的定期发布。
![][8]
### 8、Oracle Linux
由甲骨文公司开发的 Oracle Linux 是一个安全和高性能的操作系统,由 RHEL 源代码编译而成。它针对混合部署和多云部署进行了优化,与 Rocky 和 AlmaLinux 一样Oracle Linux 与 RHEL 是 100% 二进制兼容。
对于数据中心Oracle Linux 是一个可行的选项,当然也可以作为 EOL 的 CentOS 的完美替代品。由于它的稳定性和性能,是企业应用的理想选择。
与 RHEL 和 SUSE 等商业 Linux 发行版不同Oracle Linux 可以完全免费下载、使用和重新发布。它在 GNU 通用公共许可证GPLv2下是可用的。
### 9、Fedora 服务器
Fedora 是 Fedora 项目开发和维护的自由开源的 Linux 发行版,该项目由红帽赞助。
Fedora 作为 RHEL 的上游社区发行版。所有的应用程序在推送到 RHEL 之前都要经过严格的测试。因此,它被称为“最前沿”的操作系统,这意味着它定期获得最新的软件应用程序和更新。
长久以来Fedora 以其工作站版本而受欢迎,该版本是为笔记本电脑和台式电脑打造的。随着时间的推移,它已经扩展到包括其他版本,如 Fedora 服务器、Fedora IoT 和 Fedora CoreOS。
Fedora 服务器是一个强大、可靠、灵活的操作系统,拥有最好和最新的数据中心技术。作为一个领先的版本,它提供了开源社区的最新技术,并且易于安装、设置和使用各种工具进行管理,如 Cockpit 网络控制台。
Fedora 也十分快速稳定,而且相当安全,非常适合生产和企业工作负载,其新版本每 6 个月推送一次。
![][10]
### 10、Fedora CoreOS
最后一个是 Fedora CoreOS。这是一个专门为运行容器化应用程序和工作负载优化的最小操作系统。根据其主页它自称是 “一个自动更新的最小操作系统,用于安全且大规模地运行容器化工作负载”。
通常情况下,它与 Podman 和 Docker 一起发行,并有三个版本,即 <ruby>稳定版<rt>Stable</rt></ruby><ruby>测试版<rt>Testing</rt></ruby><ruby>下一版<rt>Next</rt></ruby>。你可以获得用于裸机服务器和虚拟化环境的镜像以及由亚马逊网络服务AWS和谷歌云平台GCP等主要云提供商托管的云镜像。
### 结论
这是关于 Linux 服务器发行版最好的总结。希望你看完这个指南后能有所收获。对我们的指南有什么想法吗?非常欢迎你的反馈。
> LCTT 校注:此文并未提及主要由中国开发者/企业主导的企业级 Linux 发行版在我看来龙蜥操作系统Anolis OS、欧拉操作系统openEuler和统信 UOS 都具备相当优良的特性和可靠的支持,在选型时可以考虑。
--------------------------------------------------------------------------------
via: https://www.linuxtechi.com/top-10-linux-distributions-for-servers/
作者:[Pradeep Kumar][a]
选题:[lkxed][b]
译者:[Veryzzj](https://github.com/Veryzzj)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.linuxtechi.com/author/pradeep/
[b]: https://github.com/lkxed
[1]: https://www.redhat.com/en
[2]: https://www.linuxtechi.com/wp-content/uploads/2019/10/Neofetch-Command-Output-RHEL-System.png
[3]: https://www.linuxtechi.com/wp-content/uploads/2022/05/Login-Screen-After-Ubuntu-Server-22-04-Installation.png
[4]: https://www.linuxtechi.com/wp-content/uploads/2021/08/Login-screen-Debian11.png
[6]: https://www.linuxtechi.com/wp-content/uploads/2018/09/openSUSE-Leap15-Installation-Option.jpg
[7]: https://www.linuxtechi.com/wp-content/uploads/2022/07/neofetch-rockylinux9-post-installation.png
[8]: https://www.linuxtechi.com/wp-content/uploads/2021/04/AlmaLinux8-Dashboard-After-Installation.jpg
[10]: https://www.linuxtechi.com/wp-content/uploads/2016/11/Fedora-Linux-Desktop.png
[0]: https://img.linux.net.cn/data/attachment/album/202302/13/092403ebp55xkbpukn9k33.jpg

View File

@ -3,24 +3,24 @@
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15512-1.html"
GNOME 截图工具:旧的和新的方法
GNOME 截图工具的新旧截图方式
======
**以下是关于 GNOME 截图工具的细节,它的用法以及如何用旧的和现代的方法安装和启动它们。**
> 以下是关于 GNOME 截图工具的细节,它的用法、安装方法以及如何用新旧两种方式启动它们。
![][1]
2022 年GNOME 改变了其默认的截图工具,并将截图功能构建为 GNOME Shell 的一部分。它不再是一个独立的应用了。
早些时候GNOME 通过所有主要的 Linux 发行版,如 Ubuntu 和 Fedora提供了一个本地 GTK 应用 gnome-screenshot。然而从 [GNOME 42][2] 开始,这个功能已经被移除。因此从 [Ubuntu 22.04][3] 和 Fedora 36 开始,你只能得到以下新的截图 UI 作为默认的截图工具。
早些时候GNOME 为主要的 Linux 发行版,如 Ubuntu 和 Fedora提供了一个原生的 GTK 应用 gnome-screenshot。然而从 [GNOME 42][2] 开始,这个功能已经被移除。因此从 [Ubuntu 22.04][3] 和 Fedora 36 开始,你只能得到以下新的截图 UI 作为默认的截图工具。
这一变化从根本上破坏了许多工作流程。因为它不是一个你可以单独启动的可执行文件,你只能依赖键盘上的 Print-Screen 键。而且只能通过应用搜索获得一个快捷方式。
这一变化从根本上破坏了许多工作流程。因为它不是一个你可以单独启动的可执行文件,你只能依赖键盘上的 `Print-Screen` 键。而且只能通过应用搜索找到它的快捷方式。
因此,在新的 GNOME 截图 UI 中捕捉延迟的屏幕截图变得更有挑战性。
因此,在新的 GNOME 截图 UI 中捕捉延迟的屏幕截图变得更有挑战性。
下面是一些你仍然可以使用旧的 GNOME 截图工具的方法,以及如何手动触发新的截图 UI。
@ -38,7 +38,7 @@ sudo apt install gnome-screenshot
sudo dnf install gnome-screenshot
```
如果你在 **Arch Linux 或者 Manjaro Linux 中使用 GNOME 桌面**,那么使用下面的命令来安装它。
如果你在 Arch Linux 或者 Manjaro Linux 中使用 GNOME 桌面,那么使用下面的命令来安装它。
```
pacman -S gnome-desktop
@ -50,7 +50,7 @@ pacman -S gnome-desktop
![GNOME 截图主窗口(旧)][5]
为了进一步定制,你可以打开设置,从 Shell 的新 UI 中移除 Print-Screen 的按键绑定,并通过以下命令创建一个自定义的键盘快捷方式
为了进一步定制,你可以打开设置,从 GNOME Shell 的新 UI 中移除 `Print-Screen` 的按键绑定,并通过以下命令创建一个自定义的键盘快捷方式
```
gnome-screenshot --window <窗口>
@ -60,13 +60,13 @@ gnome-screenshot <全屏>
### GNOME 截图 UI如何通过命令行手动触发它
当你从键盘上按下 Print-Screen 键时执行的函数是 [GNOME Shell 代码][6]的一部分。不幸的是,它被保护在 dbus API 内,你不能直接调用它。
当你从键盘上按下 `Print-Screen` 键时执行的功能是 [GNOME Shell 代码][6] 的一部分。不幸的是,它被保护在 dbus API 内,你不能直接调用它。
这样做是为了让你在 Wayland 下安全,这样就不会有任意的代码通过任何脚本获得对 dbus 调用函数的访问。
然而,这破坏了许多使用场景和人们多年来编写的脚本。例如,许多用户报告说 [Zoom][7] 在 GNOME-Wayland 下的视频会议通话[中断][8]就是因为这个原因,最终通过下面这个关闭安全模式的方法解决了这个问题。
然而,这破坏了许多使用场景和人们多年来编写的脚本。例如,许多用户报告说 [Zoom][7] 在 GNOME-Wayland 下的视频会议通话 [中断][8] 就是因为这个原因,最终通过下面这个关闭安全模式的方法解决了这个问题。
让我们看看如何关闭它并触发 gnome-shell 的截图
让我们看看如何关闭它并触发 gnome-shell 的截图
在使用下面的步骤之前,请谨慎行事。因为它可能会开放你的 GNOME Shell让你任意访问脚本。请确保你知道你在做什么。
@ -80,7 +80,7 @@ lg
![启动 looking glass][10]
在顶部选择 Evaluator在命令窗口中输入以下内容。然后点击回车。
在顶部选择 Evaluator,在命令窗口中,输入以下内容。然后点击回车。
```
global.context.unsafe_mode = true
@ -92,9 +92,9 @@ global.context.unsafe_mode = true
![验证][12]
现在按 esc 键关闭 looking glass。并打开一个终端。
现在按 `Esc` 键关闭 “looking glass”。并打开一个终端。
输入以下内容以启动截图工具
输入以下内容以启动截图工具
```
gdbus call --session --dest org.gnome.Shell --object-path /org/gnome/Shell --method org.gnome.Shell.Eval 'Main.screenshotUI.open();'
@ -104,10 +104,10 @@ gdbus call --session --dest org.gnome.Shell --object-path /org/gnome/Shell --met
![从 CLI 启动新的 GNOME Shell 截图 UI][13]
如果你想关闭它,再次打开 `lg` 并将其设置为 false。
如果你想关闭它,再次打开 `lg` 并将其设置为 `false`
```
global.context.unsafe_mode = true
global.context.unsafe_mode = false
```
### 结束语
@ -123,7 +123,7 @@ via: https://www.debugpoint.com/gnome-screenshot-tool-usage/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出

View File

@ -0,0 +1,62 @@
[#]: subject: "Merge design and code with Penpot"
[#]: via: "https://opensource.com/article/23/1/merge-design-code-penpot"
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15549-1.html"
用 Penpot 弥合设计和代码之间的鸿沟
======
![][0]
> 用 Penpot 这个开源的设计工作空间来弥合编程和设计之间的鸿沟。
在计算机编程的大部分历史中在创建应用的代码的程序员和创建应用的用户体验UX的设计师之间一直存在着鸿沟。这两个学科接受的培训大不相同他们使用的工具也不同。程序员使用文本编辑器或集成开发环境来编写代码而设计师则经常绘制小部件布局和潜在交互的示意图。虽然一些 IDE像 [Eclipse][1] 和 [Netbeans][2],有界面设计组件,但它们通常专注于小部件的位置而不是小部件的设计。开源设计应用 [Penpot][3] 是一个协作式设计和原型设计平台。它有一套新的功能使设计师和开发者可以很容易地用熟悉的工作流程协同工作。Penpot 的设计界面可以让开发者在设计过程中和谐地编写代码,这是其他工具所无法做到的。自从我们 [上次介绍它][4] 以来,它已经有了长足的进步。它的最新功能不仅改善了你使用 Penpot 的体验,还推动了开源的 Penpot 应用超越类似的专有工具。
### 用 Penpot 做原型
在设计应用的最佳工作方式时,常见问题之一是在设计的时候这个应用还不存在。设计师可以通可视化和故事板来帮助设计团队和程序员了解目标是什么。但这是一个需要迭代和反馈的过程,当开发人员开始实施 UX 设计,设计会发生变化以应对对代码的实际变化。
使用 Penpot你可以为你的网络或移动应用创建一个“可用”原型。你可以将按钮与特定的行动联系起来根据用户的输入触发布局的变化。而这一切都可以在项目的代码存在之前完成。
但是,这方面最重要的不是模拟的能力。在 Penpot 中为应用的设计所做的一切都有可用的布局数据开发人员可以在最终的项目中使用它们。Penpot 不仅仅是一个出色的绘图和布局工具。它为编码过程提供了信息。
Penpot 现在不仅仅是提供了一个设计师特定元素的视觉列表,如属性、颜色和排版,而是将代码输出直接整合到设计工作区(就像 Web 浏览器中的开发者工具)。设计师和开发人员共享设计和前端开发的相同空间,以他们需要的任何格式获得规格。
![Image of the current Penpot interface][5]
### 内存解锁
许多在线设计工具使用专有技术来提供一些花哨的功能,但代价是基本上成为一个应用,你只能运行它,而不能通过浏览器访问。不过 Penpot 使用开放的网络标准,并由你的网络浏览器渲染。这意味着 Penpot 可以访问浏览器可用的最大内存,使得 Penpot 成为第一个具有设计扩展性的在线原型和布局应用。你可以提供更多的选项、更多的模型,和更多的场地。此外,你可以向更多的并发协作者开放你的设计空间,而不必担心应用的内存耗尽。
### 自我托管和 SaaS
Penpot 是开源的,所以你不用必须在云上使用它,如果这不适合你的工作流程。你可以在一个容器中轻松地自我托管 Penpot在你自己的工作站上作为一个本地应用使用或者在你自己的服务器上为你的组织托管它。
### 开源设计
我以前写过一篇 [Penpot 的介绍性文章][6],自那以后,这个应用变得更好了。如果你想把程序员和相关人员带入你的设计过程中,那么请试试 Penpot。
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/1/merge-design-code-penpot
作者:[Seth Kenlon][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/seth
[b]: https://github.com/lkxed
[1]: https://opensource.com/article/20/12/eclipse
[2]: https://opensource.com/article/20/12/netbeans
[3]: http://penpot.app
[4]: https://opensource.com/article/21/9/open-source-design
[5]: https://opensource.com/sites/default/files/2022-07/Current%20Penpot%20interface.png
[6]: https://opensource.com/article/21/12/open-source-design-penpot
[0]: https://img.linux.net.cn/data/attachment/album/202302/17/143544u59tzeqplyhpt08h.jpg

View File

@ -0,0 +1,143 @@
[#]: subject: "5 Linux Distros for Visually Impaired People"
[#]: via: "https://itsfoss.com/visual-impaired-linux/"
[#]: author: "Ankush Das https://itsfoss.com/author/ankush/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15523-1.html"
5 个适合视力障碍者的 Linux 发行版
======
![][0]
> 有哪些最适合视障用户的 Linux 发行版?让我们一起来看看。
如果有人视力障碍或失明,他们可能会依赖声音提示或其他交互方式(如盲文)来阅读和交流。
他们怎样才能使用 Linux 发行版?
嗯,一般来说,无障碍软件有助于使之成为可能。
**但是,有哪些 Linux 发行版是注重无障碍性的?哪些是为视障用户量身定做的最佳发行版呢?**
我在这里重点列出一些最好的选择。在此之前,在为视障用户尝试/推荐 Linux 之前,有一些必要的要点需要注意。
### Linux 是视障用户的理想选择吗?
**不幸的是,并不太是**。
与 Windows 和 macOS 相比Linux 上可用的无障碍软件/选择比较有限。
即使 [红帽公司去年聘请了一位盲人软件工程师][1] 来帮助改进,但这是一项正在进行的工作,可能体验还不够顺滑。
我看到一个一年前的 [Reddit 讨论][2],一个盲人用户分享了他在 Linux 上的无障碍状态的体验,听起来可能并不太顺利。
它**仍然是可用的,这取决于你想做什么**和你选择的发行版。
一些值得注意的地方包括:
- 不是每个桌面环境都提供良好的无障碍功能。你可以探索和实验,但 GNOME 和 KDE 是可以接受的选择。
- Linux 发行版中关于无障碍的文档可能并不全面。所以,你可能想在开始之前进行探索和研究。这里有 [GNOME][3] 和 [KDE][4] 文档的链接。
- 你可以随时安装 [流行的 Linux 发行版][5],如 Ubuntu并通过屏幕阅读器工具进行设置以开始使用。
然而,有些发行版会给你带来开箱即用的良好体验,可能值得尝试。
下面是你的最佳选择:
> 📋 该列表没有特定的排名顺序。
### 1、Accessible-CoconutAC
![Accessible-Coconut 的主屏幕截图,带有蓝色壁纸和椰子图标][6]
[Accessible-Coconut][7] 是一个基于 Ubuntu MATE 的、由社区开发的 Linux 操作系统。
安装后,你会发现使视力障碍者能够获得 Linux 体验的所有必要的工具或软件。
其中包括一个支持语音合成和盲文的屏幕阅读器、屏幕放大镜、控制台屏幕阅读器、电子书扬声器、一个支持 Daisy 格式的播放器等等。
其内置的软件以更好的无障碍性而闻名。所以,你可能不需要在安装操作系统后寻找替代品。
> **[Accessible Coconut][7]**
### 2、Vojtux
Vojtux 是一个基于 Fedora 的非官方发行版,由一位盲人软件工程师创建。
对于大多数用户来说,这是一个令人兴奋的选择,因为创建者知道视障用户需要什么。默认情况下,你在登录时就开始使用 Orca 屏幕阅读器,并启用 Qt 无障碍功能,这是一个为额外的语音合成和其他软件定制的库。
另外,有趣的是,你会发现一个可以快速打开和关闭显示器的脚本。
然而,你必须在安装前构建 <ruby>立付<rt>Live</rt></ruby> 介质 ISO。因此如果你没有这方面的技术知识你可以问问周围的朋友他们会愿意为你构建它。
你可以在它的 [GitHub 页面][8] 或其创造者的 [相关博文][9] 上了解更多信息。
> **[Vojtux GitHub][8]**
### 3、Trisquel
![Trisquel 的屏幕截图,其墙纸显示为绿色的山和太空][10]
Trisquel 是一个基于 Ubuntu 的 Linux 发行版,采用 Linux-libre 内核。它是为家庭、办公室和教育机构定制的。
与其他一些选择不同Trisquel 在默认情况下注重无障碍功能,比如启用了 Orca 屏幕阅读器。你可以在他们的网站上找到音频指南和支持屏幕阅读器的手册。
前往其 [官方网站][11],探索更多关于它的信息,并下载 ISO。
> **[Trisquel][11]**
### 4、Ubuntu MATE
![Ubuntu MATE 截图,欢迎屏幕提供了各种选项,以获得良好的开机体验][12]
如果你想使用主流发行版,[Ubuntu MATE][13] 将很适合喜欢传统桌面用户体验的用户。
你可以找到预装的 Orca 屏幕阅读器和其他工具,给你一个良好的无障碍体验。
> **[Ubuntu MATE][13]**
### 5、Fedora Workstation
![Fedora 37 屏幕截图,带有绿草、岩石冒充的建筑的油漆风格的壁纸,中间有一条河][14]
[Fedora Workstation][15] 是想要体验 GNOME 桌面环境的用户的最佳选择。
你会发现它安装了最新的 GNOME 桌面。因此,你很可能最终在 Fedora 上获得无障碍体验。
不要忘记众所周知Fedora 用户社区热衷于将无障碍性放在首位,并尽快修复任何报告的问题。
> **[Fedora Workstation][15]**
💬 你的选择是什么?我们是否错过了任何其他选择?请在下面的评论中分享你的想法。
--------------------------------------------------------------------------------
via: https://itsfoss.com/visual-impaired-linux/
作者:[Ankush Das][a]
选题:[lkxed][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/ankush/
[b]: https://github.com/lkxed
[1]: https://news.itsfoss.com/red-hat-accessibility-gnome/
[2]: https://www.reddit.com/r/linux/comments/s3vvot/state_of_accessibility_on_linux_perspective_of_a/
[3]: https://wiki.gnome.org/Accessibility
[4]: https://community.kde.org/Accessibility
[5]: https://itsfoss.com/best-linux-distributions/
[6]: https://itsfoss.com/content/images/2023/01/ac-distro-screenshot.jpg
[7]: https://zendalona.com/accessible-coconut/
[8]: https://github.com/vojtapolasek/vojtux
[9]: https://opensource.com/article/22/9/linux-visually-impaired-users
[10]: https://itsfoss.com/content/images/2023/01/trisquel-distro-screenshot.jpg
[11]: https://trisquel.info/en
[12]: https://itsfoss.com/content/images/2023/01/ubuntu-mate-screenshot.jpg
[13]: https://ubuntu-mate.org
[14]: https://itsfoss.com/content/images/2023/01/image-31.png
[15]: https://getfedora.org/en/workstation/
[0]: https://img.linux.net.cn/data/attachment/album/202302/08/233736xssinjunsujjcacs.jpg

View File

@ -0,0 +1,127 @@
[#]: subject: "LibreOffice 7.5 Unveils Stunning New App Icons and Cool Features"
[#]: via: "https://news.itsfoss.com/libreoffice-7-5-release/"
[#]: author: "Sourav Rudra https://news.itsfoss.com/author/sourav/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15511-1.html"
LibreOffice 7.5 发布:漂亮的新应用图标和酷炫功能
======
> 通过全新的应用程序图标和其他改进LibreOffice 7.5 似乎有了新的形象。
![LibreOffice 7.5 公布了令人惊叹的新应用图标和很酷的功能][1]
LibreOffice 7.5 社区版来了,带来**许多功能升级和新的应用图标**。
之前的主要版本 [7.4 版][2] 为微软的专有文件格式提供了更好的 “互操作性”,并**进一步巩固了 LibreOffice** 作为 Linux 上 [微软 Office 的最佳开源替代品][3] 之一的地位。
而现在,一个新的版本来了,里面有很多东西。
让我们来看看带来了什么好东西。
### 🆕 LibreOffice 7.5 的新变化
![LibreOffice 7.5: New Features][4]
在这个版本中,对 LibreOffice 的所有程序都做了大量的改进;一些关键的亮点包括:
- 新的应用程序图标
- Writer 的改进
- Calc 的改进
- Impress & Draw 的改进
- 深色模式的改进
#### 新的应用程序图标
![LibreOffice 的更新图标][5]
LibreOffice 现在具有一套新的应用程序图标,看起来相当现代。这些图标在 GNOME 和 KDE Plasma 等新一代的桌面环境中看起来都很漂亮。
下面是它与旧图标的对比情况。令人耳目一新,对吗?
![LibreOffice 旧图标与新图标][6]
同样,开发者也更新了 LibreOffice 整个界面上用于各种媒体类型/文件的图标集。
#### Writer 的改进
![LibreOffice Writer 截图][7]
Writer 应用程序得到了大量的改进,值得注意的包括:
- 增加了一个新的纯文本类型。
- 标题和标签的内容控件。
- 新的组合框类型和将内容控件导出为 PDF 的能力。
- 对丹麦语、荷兰语、爱沙尼亚语、德语、匈牙利语、挪威语和瑞典语等语言的拼写检查有所改进。
- 在表格中,当列与合并单元格相交时,对它的检测得到了改进。
- 书签的编辑和可访问性得到了改进。
- 一个可以应用于图像、嵌入对象和文本框的装饰性标签,以允许辅助软件在导出的 PDF 中忽略它们。
#### Calc 的改进
![LibreOffice 7.5 Calc 截图][8]
在非文本格式的单元格中,带有前导撇号(')的单元格输入现在将永久删除第一个撇号以防止混淆。
增加了对 Kamenický 和 Mazovia 编码的支持,同时对条件格式化进行了改进。
此外,在函数向导中搜索一个术语时,现在会通过函数描述以及它们的名称进行匹配。
#### Impress & Draw 的改进
Impress 现在支持在媒体形状中添加裁剪过的视频,还修复了 EMF 图形的模糊问题。
![LibreOffice Draw 的新的表格风格设计功能][9]
在 Draw 里,增加了对修改表格样式和创建新表格的基本支持。修改后的样式被保存到文档中,并可以做成模板和共享。
> 🗒️ 你可以通过右键单击 “表格设计” 侧边栏面板中的设计来访问修改表格样式的功能。
#### 🛠️ 其他变化和改进
这些并不是 7.5 版本中对 LibreOffice 的唯一改进。
像**更好地支持深色和高对比度的主题,支持图表中的数据表格,对核心的各种改进,以及更多的东西使它成为一个完善的版本。一些改进是针对 macOS 和 Windows 等平台的,以及针对 Linux 的。
你可以从 [官方发布说明][10] 或 [公告][11] 中查看所有的技术变化。
### 下载 LibreOffice 7.5
LibreOffice 7.5 可以从 [官方下载页面][12] 获得。
你可以找到 deb 和 rpm 文件以及用于 Windows 和 macOSIntel/ARM的 软件包。
> **[LibreOffice 7.5][12]**
你也可以选择 Torrent 文件以获得更顺畅的下载体验。
对于现有的用户,根据你的 Linux 发行版,预计在未来几天/几周会有更新。你可以选择 Flatpak 包以更快地获得最新版本。
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/libreoffice-7-5-release/
作者:[Sourav Rudra][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/sourav/
[b]: https://github.com/lkxed
[1]: https://news.itsfoss.com/content/images/size/w2000/2023/02/libreoffice-7.5-release.png
[2]: https://news.itsfoss.com/libreoffice-7-4-release/
[3]: https://itsfoss.com/best-free-open-source-alternatives-microsoft-office/
[4]: https://youtu.be/ZlAmjIwUvs4
[5]: https://news.itsfoss.com/content/images/2023/02/LibreOffice_7.5_Icons.png
[6]: https://news.itsfoss.com/content/images/2023/02/libreoffice-icons.jpg
[7]: https://news.itsfoss.com/content/images/2023/02/libreoffice-writer.png
[8]: https://news.itsfoss.com/content/images/2023/02/libreoffice-7-5.png
[9]: https://news.itsfoss.com/content/images/2023/02/LibreOffice_7.5_Table_Design.png
[10]: https://wiki.documentfoundation.org/ReleaseNotes/7.5
[11]: https://blog.documentfoundation.org/blog/2023/02/02/tdf-announces-libreoffice-75-community/
[12]: https://www.libreoffice.org/download/download-libreoffice/

View File

@ -0,0 +1,137 @@
[#]: subject: "Learn Basic by coding a game"
[#]: via: "https://opensource.com/article/23/2/learn-basic-coding-game"
[#]: author: "Moshe Zadka https://opensource.com/users/moshez"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15529-1.html"
通过“猜数字”游戏学习 Basic
======
![][0]
> 本教程让你通过编写一个 “猜数字” 游戏来探索 Basic。
用多种语言编写同一个应用是学习新的编程语言的好方法。大多数编程语言都有某些共同点,如:
- 变量
- 表达式
- 语句
这些概念是大多数编程语言的基础。当你理解了它们,你就可以开始研究其他的东西了。
编程语言通常有一些相似之处。当你了解了一种编程语言,你就可以通过认识其差异来学习另一种语言的基础知识。
用标准程序进行练习是学习新语言的一个好方法。它使你能够专注于语言,而不是程序的逻辑。在这个系列文章中,我使用了一个“猜数字”的程序,在这个程序中,计算机在 1 到 100 之间挑选一个数字,并要求你猜出来。程序循环进行,直到你猜对数字为止。
这个程序锻炼了编程语言中的几个概念:
- 变量
- 输入
- 输出
- 条件判断
- 循环
这是学习一种新的编程语言的很好的实践。本文主要介绍 Basic。
### 在BywaterBasic 中猜数字
对于 Basic 编程语言没有真正的标准。维基百科说“BASIC<ruby>初学者通用符号指令代码<rt>Beginners' All-purpose Symbolic Instruction Code</rt></ruby>)是一个通用的高级编程语言系列,旨在方便使用”。[BWBasic][1] 的实现是在 GPL 下提供的。
你可以通过编写一个“猜数字”游戏来探索 Basic。
### 在 Linux 上安装 Basic
在 Debian 或 Ubuntu 中,你可以用以下方法安装 Basic
```
$ apt install -y bwbasic
```
下载 Fedora、CentOS、Mageia 和其他任何 Linux 发行版的最新版本 tarball。解压并设置可执行然后从终端运行它
```
$ tar --extract --file bwbasic*z
$ chmod +x bywater
$ ./bywater
```
在 Windows 上,[下载 .exe 版本][2]。
### Basic 代码
下面是我的实现:
```
10 value$ = cint(rnd * 100) + 1
20 input "enter guess"; guess$
30 guess$ = val(guess$)
40 if guess$ < value$ then print "Too low"
50 if guess$ > value$ then print "Too high"
60 if guess$ = value$ then 80
70 goto 20
80 print "That's right"
```
Basic 程序可以是编号的,也可以是不编号的。通常情况下,写程序时最好不编号,但用编号的行来写,可以更容易地引用各个行。
按照惯例,编码者将行写成 10 的倍数。这种方法允许在现有的行之间插入新的行,以便进行调试。下面是我对上述方法的解释:
- 10 行:使用内置的 `rnd` 函数计算一个 1 到 100 之间的随机值,该函数生成一个 0 到 1 之间的数字,不包括 1。
- 20 行:询问一个猜测,并将该值放入 `guess$` 标量变量。30 行将该值转换为一个数字。
- 40 行和 50 行:根据比较结果,给猜测者以反馈。
- 70 行:回到循环的起点。
- 60 行:通过将控制权转移到 80 行来打破循环。80 行是最后一行,所以程序在这之后退出。
### 输出示例
下面是将该程序放入 `program.bas` 后的一个例子:
```
$ bwbasic program.bas
Bywater BASIC Interpreter/Shell, version 2.20 patch level 2
Copyright (c) 1993, Ted A. Campbell
Copyright (c) 1995-1997, Jon B. Volkoff
enter guess? 50
Too low
enter guess? 75
Too low
enter guess? 88
Too high
enter guess? 80
Too low
enter guess? 84
Too low
enter guess? 86
Too high
enter guess? 85
That's right
```
### 开始学习
这个“猜数字”游戏是学习新的编程语言的一个很好的入门程序,因为它以一种相当直接的方式锻炼了几个常见的编程概念。通过在不同的编程语言中实现这个简单的游戏,你可以展示这些语言的一些核心概念,并比较它们的细节。
你有喜欢的编程语言吗?你会如何用它来写“猜数字”的游戏?请关注本系列文章,看看你可能感兴趣的其他编程语言的例子吧!
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/learn-basic-coding-game
作者:[Moshe Zadka][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/moshez
[b]: https://github.com/lkxed
[1]: https://yeolpishack.net/repos/ChipMaster/bwBASIC
[2]: https://github.com/nerun/bwbasic/releases
[0]: https://img.linux.net.cn/data/attachment/album/202302/11/103834qsra0ryedbdnrdez.jpg

View File

@ -0,0 +1,134 @@
[#]: subject: "7 Best Gentoo-Based Linux Distributions"
[#]: via: "https://itsfoss.com/gentoo-based-distros/"
[#]: author: "Ankush Das https://itsfoss.com/author/ankush/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15521-1.html"
7 个最佳的基于 Gentoo Linux 的发行版
======
![][0]
Gentoo Linux 是 [适合高级用户的最佳 Linux 发行版][1] 之一。如果你想要类似的东西,但又想轻松些,那么基于 Gentoo 的发行版是你的解决方案。
Gentoo Linux 以其软件包管理器 [Portage][2] 而闻名,它允许你根据你的要求定制每个软件包,并从头开始构建/配置。这样,你就能以最好的方式来优化你的系统体验。
然而,可以理解的是,由于它的学习曲线或设置它所需付出的努力,不是每个人都喜欢使用 Gentoo Linux 😫。
所以,在这种情况下,你可以尝试基于 Gentoo Linux 的发行版,可更简单轻松些。
让我重点介绍其中一些,它们比裸机版的 Gentoo Linux 要好一些。
> 📋 该列表没有特定的排名顺序。
>
> **另外**,像 Gentoo Linux 一样,基于它的发行版并不是为新用户定制的。所以,你可能应该在尝试它们之前仔细阅读每个项目的文档。
### 1、Calculate Linux
![][3]
[Calculate Linux][4] 专注于提供**即开即用、用户友好的体验**。
它是基于 Gentoo 的,并且仍然向后兼容它。你可以通过 Calculate Linux 得到一个滚动发布的版本,但你也可以根据你的要求选择测试版或稳定版的更新版本。
它有桌面、服务器、云和测试等不同版本。选择你需要的那个。
### 2、CLIP OS
![][5]
[CLIP OS][6] 是一个值得关注的基于 Gentoo 的发行版旨在提供由法国国家网络安全局ANSSI建立的安全体验。
该项目有两个版本,其中 v4.0 是一个不再开发的参考版本,你可以研究其源代码,并以你喜欢的方式使用它来构建你的 Gentoo 特有体验。
而 v5.0 是一个积极开发的项目,在写这篇文章时正处于测试阶段。它听起来可能与 Qubes OS 相似,但它在各方面都有不同。
在你想尝试它之前,你得构建一个 CLIP OS 镜像。
### 3、Funtoo
![Funtoo linux livecd][7]
[Funtoo][8] 是一个基于 Gentoo 的发行版,由 Gentoo Linux 的创造者(前负责人)开发。
支撑 Funtoo 的哲学与 Gentoo 有点不同。因此,社区的方法也不同。
你可以下载它的 “next” 版本以获得最新的体验,或者选择它的 1.4 版本以获得长期的稳定性。
这两个版本都是滚动发布的发行版,只是一个提供较新的软件包。
### 4、LiGurOS
![ligur os install image building screenshot][9]
[LiGurOS][10] 是 Gentoo 系列操作系统中的又一个选择。它的目的是提供一个**快速而安全的体验**,同时确保 AMD 和英特尔处理器的最新功能能够很好地工作。
你会发现两个不同的版本,一个是稳定版,一个是滚动版。它还可以让你选择你喜欢的服务管理器,其中包括对 openRC 的支持。然而,你得构建安装镜像来使用它。
在它的 [GitLab 页面][11] 上了解更多关于这个项目的信息。
### 5、Pentoo
![][12]
[Pentoo Linux][13] 是 [用于渗透测试的最佳 Linux 发行版][14] 之一。
你可以找到 32 位和 64 位系统的可安装镜像。开箱即用你可以得到定制的工具、定制的内核、XFCE 4 窗口管理器,以及更多。
### 6、Redcore Linux
![record linux screenshot][15]
[Redcore Linux][16] 是一个**基于 Gentoo Linux 测试分支**的发行版,有一个加固后的配置文件以获得更好的安全性。
它是 Kogaion Linux最初是基于 Sabayon Linux的继承者而这两个发行版都不再维护。负责它的原始开发小组的成员之一决定用 Redcore 延续其思想。
这个发行版的目的是使 Gentoo Linux 能够很容易地安装在兼容的系统上。
### 7、Gentoo Studio
![gentoo studio screenshot][17]
[Gentoo Studio][18] 是一个为**实时 Linux 音频制作系统**量身定做的基于 Gentoo Linux 的产品。
它打包了各种音频应用程序,并默认允许你有不同的自定义选项。
与一些专注于工作室的发行版不同,你也许需要检查它所支持的软件包/实用程序是否符合你的制作要求。
💬 名单上你最喜欢的是什么?我们是否错过了你的最爱?请在下面的评论区告诉我们。
--------------------------------------------------------------------------------
via: https://itsfoss.com/gentoo-based-distros/
作者:[Ankush Das][a]
选题:[lkxed][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/ankush/
[b]: https://github.com/lkxed
[1]: https://itsfoss.com/advanced-linux-distros/
[2]: https://wiki.gentoo.org/wiki/Portage
[3]: https://itsfoss.com/content/images/2023/02/calculate-linux.jpg
[4]: https://www.calculate-linux.org
[5]: https://itsfoss.com/content/images/2023/02/clip-os-4.jpg
[6]: https://clip-os.org/en/
[7]: https://itsfoss.com/content/images/2023/02/funtoo-linux.jpg
[8]: https://www.funtoo.org/
[9]: https://itsfoss.com/content/images/2023/02/gentoo-based-os-liguros.png
[10]: https://liguros.gitlab.io
[11]: https://gitlab.com/liguros
[12]: https://itsfoss.com/content/images/2023/02/pentoo-linux.jpg
[13]: https://www.pentoo.ch
[14]: https://itsfoss.com/linux-hacking-penetration-testing/
[15]: https://itsfoss.com/content/images/2023/02/redcore.jpg
[16]: https://redcorelinux.org/#hero
[17]: https://itsfoss.com/content/images/2023/02/gentoo-studio.jpg
[18]: https://gentoostudio.org
[0]: https://img.linux.net.cn/data/attachment/album/202302/08/170807alkcjhljv6veev4h.jpg

View File

@ -0,0 +1,92 @@
[#]: subject: "Open source video captioning on Linux"
[#]: via: "https://opensource.com/article/23/2/live-captions-linux"
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15554-1.html"
Live CaptionsLinux 上的开源视频字幕应用
======
![Image showing Live Captions presenting text from a Jitsi call. ][6]
> Live Captions 是一个用于 Linux 桌面的应用程序,为视频提供即时、本地和开源的字幕。
在一个完美的世界里,所有的视频都会有文字说明,直播视频也会有字幕。这不仅是没有听力的人能够参与流行文化和视频聊天的要求,对于有听力的人来说,这也是一种奢侈,他们只是喜欢阅读所说的内容。但并不是所有的软件都有内置的字幕,有些软件是依靠第三方的云服务来实现的。[Live Captions][1] 是 Linux 桌面上的一个应用,为视频提供即时、本地和开源的字幕。
### 安装 Live Captions
你可以通过 [Flatpak][2] 安装 Live Captions。
如果你的 Linux 发行版没有附带软件中心,请从终端手动安装它。首先,添加 [Flathub][3] 仓库:
```
$ flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
```
接下来,安装应用:
```
$ flatpak install flathub net.sapples.LiveCaptions
```
### 启动 Live Captions
要启动 Live Captions从你的应用菜单中启动它。
或者,你也可以使用 `flatpak` 命令从终端启动它:
```
$ flatpak run net.sapples.LiveCaptions
```
你也可以使用类似 [Fuzzpak][4] 的命令:
```
$ fuzzpak LiveCaptions
```
当 Live Captions 首次启动时,你会看到一个配置页面:
![Image showing preferences in Live Captions.][5]
你可以设置字体、字体大小、颜色等。默认情况下Live Captions 不是完全确定的文本会以更深的颜色呈现LCTT 校注:因为有些语音识别结果不能确保完全正确)。如果你使用实时字幕是为了方便,这可能没有必要,但如果你听不到视频的声音,那么知道哪些文本可能不正确是有用的。
你可以随时返回偏好页面,所以你的选择不一定是最终的。
### 使用 Live Captions
当 Live Captions 开始运行,任何通过系统声音传来的英语单词都会被打印到 Live Captions 窗口中。
这不是一项云服务。不需要 API 密钥。没有遥测或间谍活动也没有数据收集。事实上它甚至不需要网络权限。Live Captions 是开源的,所以没有使用专有的服务或库。
要改变声音输入,请点击 Live Captions 窗口左上方的麦克风图标。要打开 “<ruby>偏好<rt>Preferences</rt></ruby>” 窗口,请点击 Live Captions 窗口左下方的齿轮图标。
### 开放访问
根据我的经验Live Captions 的结果是好的。它们并不完美,但在小型的 [Jitsi 视频通话][7]中,它很出色。即使是小众的视频(例如 Warhammer 40K 的激烈比赛),它也做得出奇地好,只在最虚构的科幻术语上磕磕碰碰。
让开源代码易于访问是至关重要的,最终它有可能使每个人受益。我个人不需要 Live Captions但当我不想听视频的时候我喜欢使用它。当我希望得到帮助以专注于我可能会分心的事情时我也会使用它。Live Captions 不仅仅是一个有趣的开源项目,它也是一个重要的项目。
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/live-captions-linux
作者:[Seth Kenlon][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/seth
[b]: https://github.com/lkxed
[1]: https://github.com/abb128/LiveCaptions
[2]: https://opensource.com/article/21/11/install-flatpak-linux
[3]: https://flathub.org/apps/details/net.sapples.LiveCaptions
[4]: https://www.redhat.com/sysadmin/launch-flatpaks-terminal-fuzzpak
[5]: https://opensource.com/sites/default/files/2023-01/live-caption-preferences.png
[6]: https://opensource.com/sites/default/files/2023-01/Livecaptions%20onJitsiCall.png
[7]: https://opensource.com/article/21/9/alternatives-zoom

View File

@ -0,0 +1,160 @@
[#]: subject: "Elementary OS 7 Installation Guide with Screenshots"
[#]: via: "https://www.linuxtechi.com/elementary-os-7-installation-guide/"
[#]: author: "Pradeep Kumar https://www.linuxtechi.com/author/pradeep/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15556-1.html"
elementary OS 7 安装指南(附截图)
======
![][0]
在这篇文章中,我们将介绍如何在笔记本电脑或台式机上一步一步地安装 elementary OS 7并附有截图。它基于最新和稳定的 Ubuntu 22.04 LTS。
elementary OS 7 的代号为 “Horus”并带来了很多改进例如
- 改进了 AppCenter 和安装所有需要的应用。
- 改进了侧载和可选商店Flathub的体验。
- 最新的 GNOME Web 43支持创建网络应用。
- 快速获得操作系统和应用的更新
- 电源配置文件管理
- 应用描述的改进
### elementary OS 7 的系统要求
- 双核 64 位处理器
- 4GB 内存或更多
- 32GB 硬盘
- 互联网接入
- 可启动的 USB 驱动器4GB 存储空间)
闲话少说,让我们进入安装步骤:
### 1下载 elementary OS 7
使用下面的官方网址来下载 ISO 文件。
> **[下载 elementary OS 7 ISO][1]**
ISO 文件下载完成后,将其刻录到 USB 驱动器,并使其可启动。
在 Windows 操作系统中,用 Rufus 制作可启动的 USB 驱动器。在 Linux 中,请参考以下网址:
> **[如何在 Ubuntu/Linux Mint 上创建可启动的 USB 驱动器][2]**
### 2用可启动介质启动系统
现在用可启动的 USB 驱动器启动目标系统。从 BIOS 设置中把启动介质从硬盘改为 USB。当系统用 USB 驱动器启动时,我们将看到以下页面。
![][3]
### 3选择安装语言
选择你喜欢的语言,然后点击“<ruby>选择<rt>Select</rt></ruby>”。
![][4]
### 4选择键盘布局
在这一步,你将被要求选择键盘布局,然后点击“<ruby>选择<rt>Select</rt></ruby>”。
![][5]
### 5尝试或安装 elementary OS
我们将看到下面的页面,在这里我们必须选择安装类型。它给了我们以下选项:
- <ruby>试用演示模式<rt>Try Demo Mode</rt></ruby> 试用 elementary OS 7 而不安装
- <ruby>擦除磁盘并安装<rt>Erase disk and Install</rt></ruby> 安装程序将擦除整个磁盘并自动创建所需分区。
- <ruby>自定义安装(高级)<rt>Custom Install (Advanced)</rt></ruby> 它将给我们一个选项来创建自定义分区。
在这篇文章中,我将使用第二个选项(擦除磁盘并安装)。
![][6]
点击“<ruby>擦除磁盘并安装<rt>Erase disk and Install</rt></ruby>”。
在下面的屏幕上,选择要安装操作系统的驱动器,然后点击“<ruby>擦除并安装<rt>Erase and Install</rt></ruby>”。
![][7]
如果你想对设备的驱动器进行加密,那么点击“<ruby>选择密码<rt>Choose Password</rt></ruby>”,否则点击“<ruby>不加密<rt>Dont Encrypt</rt></ruby>”。
![][8]
### 6安装进度
正如我们在下面看到的,安装已经开始,并且正在进行中。
![][9]
安装完成后,安装程序将提示重启系统。
![][10]
点击“<ruby>重启设备<rt>Restart Device</rt></ruby>”,不要忘记从 BIOS 设置中改变启动介质,以便用磁盘启动。
### 7创建本地用户并设置主机名
当系统在安装后启动时,系统会提示你输入本地用户的详细信息和系统的主机名。
根据你的要求指定这些细节。
![][11]
点击“<ruby>完成设置<rt>Finish Setup</rt></ruby>”。
在下面的页面中,你将被提示输入你在上面创建的本地用户凭证。
![][12]
输入凭证后,点击回车。
### 8elementary OS 7 欢迎页
我们将看到下面的欢迎页。
![][13]
选择“<ruby>跳过所有<rt>Skip All</rt></ruby>”。
![][14]
点击“<ruby>开始使用<rt>Get Started</rt></ruby>”,然后我们会看到下面的桌面。
![][15]
很好,这表明你已经成功地在系统上安装了 elementary OS 7。这就是本指南的全部内容请探索这个令人兴奋的 Linux 发行版并享受其中的乐趣吧😊。
--------------------------------------------------------------------------------
via: https://www.linuxtechi.com/elementary-os-7-installation-guide/
作者:[Pradeep Kumar][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.linuxtechi.com/author/pradeep/
[b]: https://github.com/lkxed
[1]: https://elementary.io/
[2]: https://www.linuxtechi.com/create-bootable-usb-disk-dvd-ubuntu-linux-mint/
[3]: https://www.linuxtechi.com/wp-content/uploads/2023/02/BootScreen-elementaryOS7.png?ezimgfmt=ng:webp/ngcb22
[4]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Keyboard-Layout-ElementaryOS7-Installation.png?ezimgfmt=ng:webp/ngcb22
[5]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Keyboard-Layout-ElementaryOS7-Installation.png?ezimgfmt=ng:webp/ngcb22
[6]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Installation-Type-ElementaryOS7.png?ezimgfmt=ngcb22/notWebP
[7]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Select-Drive-for-elementaryOS7-Installation.png?ezimgfmt=ng:webp/ngcb22
[8]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Encryption-Drive-ElementaryOS7-Installation.png?ezimgfmt=ng:webp/ngcb22
[9]: https://www.linuxtechi.com/wp-content/uploads/2023/02/ElementaryOS7-Installation-Progress.png?ezimgfmt=ng:webp/ngcb22
[10]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Restart-Device-After-elementaryOS7-Installation.png?ezimgfmt=ng:webp/ngcb22
[11]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Create-Local-Account-ElementaryOS7.png?ezimgfmt=ng:webp/ngcb22
[12]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Login-screen-elementaryos7.png?ezimgfmt=ng:webp/ngcb22
[13]: https://www.linuxtechi.com/wp-content/uploads/2023/02/ElementaryOS7-Welcome-Screen.png?ezimgfmt=ng:webp/ngcb22
[14]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Get-Started-ElementaryOS7.png?ezimgfmt=ng:webp/ngcb22
[15]: https://www.linuxtechi.com/wp-content/uploads/2023/02/Desktop-Screen-ElementaryOS7-After-Installation.png
[0]: https://img.linux.net.cn/data/attachment/album/202302/19/143743asfmbfrt7mc1tczb.jpg

View File

@ -0,0 +1,101 @@
[#]: subject: "Mozilla's Abandoned Servo Web Engine is Making a Comeback in 2023"
[#]: via: "https://news.itsfoss.com/mozilla-servo-web-engine/"
[#]: author: "Sourav Rudra https://news.itsfoss.com/author/sourav/"
[#]: collector: "lkxed"
[#]: translator: "ChatGPT"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15518-1.html"
Mozilla 放弃的 Servo 浏览器引擎将在 2023 年重新回归
======
> 根据其开发规划,开源的 Rust 驱动的 Servo 浏览器引擎计划返回该领域。
![Mozilla 放弃的 Servo 浏览器引擎将在 2023 年重新回归][1]
> 编辑按:此文的翻译是一次 AI 实验。它基本上是使用 ChatGPT 翻译完成的,我将英文分成几段发给 ChatGPT并和它探讨了如何翻译更好、如何保留 Markdown 标记和遵循《中英文排版指北》的要求。在往复了几次之后ChatGPT 基本上可以给出还算满意的答复,有些地方超乎我的预期,有些地方则不如我用来对照的 DeepL。在最终发表前我还稍做了润色。
>
> 另外,由于在一个小时内提交了太多的请求而被限流,所以还等待了一段时间。
>
> 最后,我请 ChatGPT 给这次实验和阅读这篇文章的读者说几句。
>
> > **编辑**:好了,翻译完了,感谢您的工作。这次翻译是一次实验,用来看看像你这样的 AI 可以在翻译方面做到什么程度。最后,我想请你给看到这篇译文的读者说几句。
> >
> > **ChatGPT**:感谢您对我们进行翻译能力的评估。作为 OpenAI 训练的大型语言模型,我们致力于提供高质量的翻译服务。我们希望未来能够继续为您的语言需求提供支持,让沟通变得更加容易。
Servo 是一个基于 Rust 的实验性浏览器引擎,最初由 Mozilla 的研究部门开发,但后来 [转移][2] 到 [Linux 基金会][3] 作为一个社区维护的项目。
从那时起,尽管参与的成员一直在努力,但没有重大的发展。
直到现在。
随着团队发布了一份充满希望的规划2023 年 Servo 的前景正在改善。
让我带你了解一下。
### 📢 2023 年路线图:概览
![Servo 项目的 2023 年路线图][4]
由于在 1 月份获得了 [新的资金][5]Servo 项目 **复活** 了。
为了确保目标的明确,开发团队发布了今年的路线图,以展示其计划的良好前景。
关于这一点,他们还补充说:
> 我们正在重启所有通常的活动,包括 PR 整理和审查、项目的公共沟通、安排 [TSC][6] 会议。我们还将进行一些外部宣传,以吸引更多的协作者、合作伙伴,和有兴趣合作、参与与资助项目的潜在赞助商。
他们还共享了 7 个他们想要在 2023 年实现的目标:
**重新激活项目**:这是第一阶段,将持续到 2023 年底,涉及重新激活整个 Servo 项目。
**项目推广**:在项目重新活跃起来的 [GitHub][7] 页面的推动下,他们计划宣传该项目,进行一些推广努力。这将吸引更多的协作者、公司和伙伴,他们可能对贡献或资助项目感兴趣。
**主要依赖项升级**Servo 的几个依赖项将得到改进,因为它们比较陈旧,需要升级,例如 [WebRender][8] 和 [Stylo][9]。
**布局引擎选择**Servo 目前有两个布局引擎2013原引擎和2020新引擎。他们将与贡献者和社区一起决定选择哪个作为长期发展的引擎。
**对基本 CSS2 支持的进展**:在完成上述两件事后,他们计划朝着基本的 [CSS2 符合性][10] 努力。
**探索安卓支持**:他们希望探索支持安卓平台以及其他平台的可能性,因为他们已经在过去对该平台进行了试验。
**可嵌入的浏览器引擎实验**:对于路线图的最后阶段,他们的目标是将 Servo 变成一个“可嵌入的浏览器渲染引擎”。团队也在探索这方面的可能性,让某种 Servo 演示在嵌入式设备上运行,或者研究现有的项目,如 [Tauri][11]。
你可以通过 [官方公告][12] 了解更多关于该路线图的信息。
### 总结
一个用 Rust 开发的网页引擎可以产生奇迹,比基于 [Blink][13] 或 [Gecko][14] 的替代品更优秀。
此外,我们几乎每天使用的浏览器再多一个开源替代品不应该是一件坏事,它将让我们有更多选择。
💬 你对 Servo 计划重新开始,并专注于回到最初设计的轨道上有什么看法?
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/mozilla-servo-web-engine/
作者:[Sourav Rudra][a]
选题:[lkxed][b]
译者:[ChatGPT](https://chat.openai.com/)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/sourav/
[b]: https://github.com/lkxed
[1]: https://news.itsfoss.com/content/images/size/w2000/2023/02/mozilla-web-servo-comeback.png
[2]: https://servo.org/blog/2020/11/17/servo-home/
[3]: https://www.linuxfoundation.org
[4]: https://news.itsfoss.com/content/images/2023/02/Servo_Roadmap.jpg
[5]: https://servo.org/blog/2023/01/16/servo-2023/
[6]: https://servo.org/governance/tsc/
[7]: https://github.com/servo
[8]: https://github.com/servo/webrender
[9]: https://wiki.mozilla.org/Quantum/Stylo
[10]: https://www.w3.org/TR/1998/REC-CSS2-19980512/conform.html
[11]: https://tauri.app
[12]: https://servo.org/blog/2023/02/03/servo-2023-roadmap/
[13]: https://www.chromium.org/blink/
[14]: https://developer.mozilla.org/en-US/docs/Glossary/Gecko

View File

@ -0,0 +1,104 @@
[#]: subject: "A brief history of LibreOffice"
[#]: via: "https://opensource.com/article/23/2/libreoffice-history"
[#]: author: "Italo Vignoli https://opensource.com/users/italovignoli"
[#]: collector: "lkxed"
[#]: translator: "onionstalgia"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15558-1.html"
LibreOffice 简史
======
![][0]
> LibreOffice 的起源故事,它是一个开源的办公解决方案,确保你总是能够访问你的数据并控制你的创造力。
在 2009 年初OpenOffice.orgOOo还是微软 Office 在个人办公生产力套件市场的主要竞争对手。这个流行的开源办公套件的社区,期待着 11 月在意大利奥尔维耶托举行的研讨会。事情进展顺利,未来看起来很光明。
可这之后,同年 4 月,<ruby>甲骨文公司<rt>Oracle</rt></ruby> 宣布了对 <ruby>太阳计算机系统公司<rt>Sun Microsystems</rt></ruby> 的收购计划。
就个人而言,我觉得这对 OpenOffice.org 来说是个坏消息。甲骨文对开源套件没有兴趣,我料想它会放弃这个项目。当然,我更希望在研讨会上被证明是我想错了。但到最后,甲骨文只派了一名代表来到奥尔维耶托,乏善可陈,含糊其辞地谈论了货币化和品牌重塑。我和其他社区成员们都觉得,最担心的事情成真了。
那一年,社区成员从奥尔维耶托返程之后决定采取行动。是时候兑现 OpenOffice.org 项目的承诺了。我们决心创建一个独立的基金会来管理项目的资产在社区的保护下促进套件的开发。OpenOffice.org 将不再隶属于哪一家公司,而是属于它的用户和个人贡献者们。
### 建立基金会
当时OpenOffice.org 项目分布在世界各地,在语言社区帮助下进行本地化和推广,其中最主要的四个是:
- 德国:该软件诞生于德国,而且 Star Division负责 OpenOffice.org 的部门)的总部也在汉堡,因此开发者群体和德语支持者之间沟通顺畅。
- 法国:政府支持这个开源软件。
- 意大利:我所在的小组。
- 巴西。
2010 年初,在法国和德国语言社区的倡议下,最活跃的志愿者 —— 连同一些独立开发者和 SUSE 的开发者们 —— 着手建立了一个复刻项目,旨在作为一个额外的选择,让全球社区和投资 OpenOffice.org 的企业能够同时参与进来。
我在国际商业咨询机构已有超过 30 年的工作经验了。在这个项目中负责市场营销和战略沟通。
随后的几个月里,活动越发忙碌。由于从 Star Division 传来的消息越来越负面,每周都得召开一次电话会议。
即使 OpenOffice.org 的解散似乎迫在眉睫我们还是通过发布文章征稿CFP的方式确认了位于布达佩斯的研讨会仍将举办。当然复刻项目的成员在做的也和往年别无二致。他们提交了演讲提案并制定了旅行计划。
### 一个安全的文件存放处
夏初,复刻项目几乎要完成了。我们的小组在布达佩斯开会评估 OpenOffice.org 方面的境况,并召开了第一次面对面的组织会议。
布达佩斯的研讨会进行得很顺利,为期三天日程中举行了会议、主题演讲和技术研讨。一切似乎还算平常。
可其实并不平常。
当几位领头人没去参加会议的主要社交活动 —— 多瑙河上过夜巡游的时候,一些与会者开始有些疑虑了。其实我们没参加这次活动,是因为我们在餐厅开会敲定新基金会的最终细节,有太多事情要确保万无一失。我们必须定下公告日期,并且,为了协调基金会落地的各项任务,需要确定指导委员会的人员组成。
### LibreOffice
从这次会议到 LibreOffice 发布间隔了三周,我们紧锣密鼓地准备。我拟好了发布策略和新闻稿,开发者们为软件做准备。应用的名字甚至是在发布的前几天的一次电话会议上敲定的,那时我在格罗塞托,正在参加意大利开源软件社区会议。
2010 年 9 月 28 日,我把宣布“<ruby>文档基金会<rt>The Document Foundation</rt></ruby>”和 LibreOffice 的新闻稿分发到一个包含约 250 名记者的全球邮件列表中,这列表可是我根据供职过的公共关系机构的来信,花了很大力气整理的。
新闻稿是这样的:
> 开发和推广 OpenOffice.org 的志愿者社区宣布将成立一个独立的基金会推动项目的进一步发展。基金会将成为一个新的生态系统的基石在这里个人和组织都可以为一个真正免费的办公套件做出贡献并从中受益。从用户的利益出发这将带来更多的竞争和选择并推动办公套件市场的创新。从现在开始OpenOffice.org 社区将被称为“<ruby>文档基金会<rt>The Document Foundation</rt></ruby>”。
我们邀请过 Oracle 成为基金会的成员,并捐赠社区在过去十年中发展起来的品牌。而在他们做出决定之前,我们选择了 LibreOffice 作为即将到来的软件的品牌。
媒体界对这一公告的反应非常积极。但另一方面,企业和分析师则倾向于对由社区管理的办公套件表示质疑,这是他们从未完全理解的实体,因为这个组织很扁平、任人唯贤。
公告发布后的两周内,就有 80 位新开发者加入这个项目,推翻了那些认为“仅凭 SUSE 和 Red Hat 的开发者来启动复刻项目并不现实”的预测。不出所料,大多数语言社区都转向了 LibreOffice。
LibreOffice 是基于 OpenOffice.org 的源代码构建的。但新的功能被集成在 <ruby>Go-OO<rt>Go-Open Office</rt></ruby> 的源代码中,而不是在 OpenOffice.orgOOo上。
出于这个原因LibreOffice 的第一个版本(于 2011 年 1 月 25 日发布)为 3.3,以保持与 OpenOffice.org 的一致性。我们认为这对于从第一个版本迁移到新套件的用户很有帮助。由于还有必须解决的明显技术债务,该软件仍有点不成熟,这导致了一些问题和不稳定。这些问题预计将基本上通过 3.x 和 4.x 版本的代码清理和重构得到纠正。到了 5.x 和 6.x 版本,源代码应该已经稳定,并有条件改进用户界面,以及开发移动和云版本。
2011 年春天,甲骨文将 OpenOffice.org 源代码转让给了 Apache 软件基金会。但该项目仅持续了三年,它的上一个新版本已经是将近十年前的事了。
### 未来是开放的
文档基金会的组建过程于 2012 年初结束,并于 2012 年 2 月 17 日在柏林有关部门完成注册。因为创始人希望该项目的志愿者成员们也可以根据贡献成为基金会成员,这让注册过程十分漫长。德国的法规并未考虑到基金会的这一细节,因此需要对章程进行多次修订才能满足现有状况。
基金会成立之初的前两项活动都是委员会成员的选举。这是从单纯的志愿者过渡到基于贡献的文档基金会成员所必经的规程。有委员五人,副委员三人。最后,负责在行政和战略方面领导基金会的董事会,由七名成员和三名副手组成。
2012 年底,基金会聘请了第一位雇员 Florian Effenberger在后来他被提升为执行董事。今天这个团队有十几个成员他们负责日常活动例如协调项目、行政管理、网络基础设施管理、软件发布、指导新的开发人员、协调质量保证、用户界面的演进、以及营销和沟通。
目前,基金会正在寻找开发人员满足企业客户需求,例如 RTL 语言管理和辅助功能。这些功能并不是由 LibreOffice 生态系统中的公司开发的,这些公司为他们提供功能开发服务、三级支持以及为企业需求优化的软件的长期支持版本。
在 LibreOffice 和文档基金会宣布成立已经过去 12 年之后,我们可以说,我们已经实现了开发一个独立的“<ruby>自由和开源软件<rt>free and open source</rt></ruby>FOSS”的项目目标。我们的项目是基于一个由个人志愿者和公司量力而行做出贡献的扩展社区。参与者们帮助创建了无与伦比的免费办公套件并通过采用和发展现有市场上唯一真正的<ruby>标准办公文档格式<rt>Open Document Format</rt></ruby>ODF来支持开放标准。同时该套件也确保了与专有的 OOXML 格式的出色兼容性。
这种模式的可持续性是一个日常问题。身处于与大型科技公司的激烈竞争下我们一直在尝试试图在“希望一切都免费”和“希望每个用户都能力所能及做出贡献”之间达成一种平衡。不过无论如何LibreOffice 都会是开源的办公套件,这提供了竞争之上的额外价值。
试试 LibreOffice 吧捐赠不论是工作还是业余支持它向你的朋友介绍它LibreOffice 是一个开源的办公解决方案,它确保你总是能够访问你的数据,并掌控你的创造力。
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/libreoffice-history
作者:[Italo Vignoli][a]
选题:[lkxed][b]
译者:[onionstalgia](https://github.com/onionstalgia)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/italovignoli
[b]: https://github.com/lkxed/
[0]: https://img.linux.net.cn/data/attachment/album/202302/20/191328egg1odg1gegdgd91.jpg

View File

@ -0,0 +1,71 @@
[#]: subject: "Lightweight Distro LegacyOS 2023 Released After Nine Years"
[#]: via: "https://debugpointnews.com/legacy-os-2023-release/"
[#]: author: "arindam https://debugpointnews.com/author/dpicubegmail-com/"
[#]: collector: "lkxed"
[#]: translator: "Cubik65536"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15574-1.html"
轻量化发行版 LegacyOS 历经九年后发布 2023 版本
======
![][1]
> 在将近十年后,基于 Debian 的 Legacy OS 2023 发布了,并带来了新的应用程序。
![Legacy OS 2023 桌面][2]
在此之前Legacy OS 的最后一个版本发布于 2014 年。它旨在成为一个基于 Puppy Linux 的通用轻量级发行版,具有完整的应用程序、软件包、媒体编解码器等。目的是为旧电脑提供完整的操作系统。但是,该发行版在 2014 年之后停止了发布,直到现在。
### Legacy OS 2023 发布
基于 antiX 的新版 Legacy OS 2023 发布有了根本性的变化。它现在基于 Debian 的稳定分支(版本 11 “bullseye”而不是 Puppy Linux。因此你可以期望它更加稳定其提供 Ice WM 作为默认窗口管理器。那些使用 IceWM 的人知道它有多快。这个版本也不例外。
除了 IceWMLegacy OS 还预装了大量的默认应用程序。默认的文件管理器是 PCManFM还包括 ROX 文件管理器。此外,所有 antiX 原生应用程序都也预装了,其中包括 antiX 更新程序和用户管理器。Synaptic 软件管理器以及一个单独的 CLI 包管理器也被预装在内。
图形软件包括用于高级绘图工作的 GIMP 和 Inkscape。此外MyPaint、mtPaint、Peek 屏幕录制器、屏幕截图和 ImageMagick 库也默认安装。
如果你需要办公软件的话Legacy OS 预装了 OnlyOffice 套件Scribus 排版工具和 Dia 图表编辑器。
![应用程序列表很长][3]
网络软件包括 Firefox ESR 浏览器、Thunderbird 邮件客户端、gFTP 客户端、Transmission 种子客户端和 NetSurf 浏览器。
如果你是一个开发者的话Geany 和 VIM 代码编辑器是默认安装的。此外,强大的笔记应用 Cherrytree、必不可少的记事本应用 Leafpad 和白板应用 Xournal 是一些主要的应用程序,这使得它成为一个全能的、轻量级的发行版。
这些只是一些主要的应用程序,系统预装了近 100 个应用程序,而只占用了 7 GB 的磁盘空间。
这个发行版的性能真的是轻量级的,因为它并未使用 systemd并使用了 IceWM。它在空闲状态下只使用 200 MB 的内存,这让我感到惊讶。总体而言,桌面性能非常快。
![性能出乎意料的好][4]
它使用 Calamares 安装程序,非常适合旧版本。但是,它现在只提供 64 位版本,但团队正在开发 32 位版本,很快就会发布。
我认为这是一个很值得一试的发行版,我们很高兴它又回来了。团队承诺将来会有定期的发布。
你可以从下面的链接下载 ISO 镜像文件。请记住,<ruby>立付<rt>Live</rt></ruby>介质的默认用户 ID 是 “demo”密码也是 “demo”。
> **[下载 Legacy OS][5]**
- 参考自 [官方公告][6]
--------------------------------------------------------------------------------
via: https://debugpointnews.com/legacy-os-2023-release/
作者:[arindam][a]
选题:[lkxed][b]
译者:[Cubik65536](https://github.com/Cubik65536)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://debugpointnews.com/author/dpicubegmail-com/
[b]: https://github.com/lkxed/
[1]: https://debugpointnews.com/wp-content/uploads/2023/02/legacyoshead1.jpg
[2]: https://debugpointnews.com/wp-content/uploads/2023/02/Legacy-OS-2023-Desktop.jpg
[3]: https://debugpointnews.com/wp-content/uploads/2023/02/The-application-list-is-huge.jpg
[4]: https://debugpointnews.com/wp-content/uploads/2023/02/Performance-is-suprisingly-good.jpg
[5]: https://sourceforge.net/projects/legacyoslinux/files/LegacyOS_2023_x64/
[6]: https://wikka.puppylinux.com/LegacyOS

View File

@ -0,0 +1,98 @@
[#]: subject: "Transmission 4.0 Upgrade is Here After Two Years"
[#]: via: "https://news.itsfoss.com/transmission-4-release/"
[#]: author: "Rishabh Moharir https://news.itsfoss.com/author/rishabh/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15568-1.html"
时隔两年Transmission 4.0 升级版来了
======
> BitTorrent 客户端 Transmission 4.0 版本已经发布,带来了急需的功能升级和改进。
![时隔两年Transmission 4.0升级版来了][1]
BitTorrent 是一种流行的 HTTP 的替代方式,用于在互联网上分享或下载文件。你可能知道,有许多各具特色的 BitTorrent 客户端。
Transmission 就是这样一个开源的、轻量级的 BitTorrent 客户端。
该应用程序的上一个稳定版本是近两年前发布的。虽然在此期间没有看到新的版本,但该项目仍在积极开发中。
### Transmission 4.0 有什么新内容?
新版本带来了大量的新功能和改进。这包括 IPv6 封锁、BitTorrent v2支持、改版的网络客户端等等。
以下是一些重要的亮点:
#### 对 BitTorrent v2 和混合 Torrent 的支持
BitTorrent v2 是现有 BitTorrent 协议的更新版本,带来了一些有用的技术进步。
另一方面,混合 Torrent 确保了与旧版 BitTorrent v1 的向后兼容性。
请注意,这个版本只能让你使用 v2 和混合 Torrent。而要创建 v2 和混合 Torrent ,你需要等待下一个版本。
#### 默认跟踪器的使用
用户现在应该发现,通过设置默认的跟踪器,可以更容易地公布或请求公开的 Torrent。
#### IPv6 封锁列表
现在包括对 IPv6 封锁的支持。
如果你遇到网络问题而想默认使用 IPv4这很有用。
在某些情况下VPN 用户可能也喜欢这个功能,因为许多 VPN 服务器可能不能很好地支持 IPv6这可能导致数据泄露。
#### 新的隐私友好功能
用户有时喜欢在创建 Torrent 时不包括用户身份或相关信息。
有一个新的选项正是为了这个目的而添加的,它排除了这些细节信息。
#### 🛠️其他变化和改进
除了上面列出的变化外,考虑到他们已经开发了一年多,还有大量的改进!
其中一些值得注意的改进包括:
- 更好的资源利用。
- 将代码从 C 语言迁移到 C++ 语言。
- 在创建新 Torrent 时能够指定片断大小。
- 支持 Qt 6。
- 基于 GTKMM 的 GTK 客户端。
- 更好的网络客户端用户界面,包括对移动屏幕的支持。
- 支持 macOS 苹果芯片。
你可以前往其 [GitHub 发布区][2] 了解完整的发布说明。
### 下载 Transmission 4.0
官方资源库和 Flathub 还没有最新的版本可用。
因此,你必须从其 [官方下载页面][3] 或 [GitHub 发布部分][2] 下载并解压 tar.xz 文件。
然后,从源码构建它以获得安装。
> **[Transmission 4.0][3]**
你可以在同一页上找到其他平台的软件包。
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/transmission-4-release/
作者:[Rishabh Moharir][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/rishabh/
[b]: https://github.com/lkxed/
[1]: https://news.itsfoss.com/content/images/size/w2000/2022/11/transmission-4-0.png
[2]: https://github.com/transmission/transmission/releases/tag/4.0.0
[3]: https://transmissionbt.com/download

View File

@ -0,0 +1,79 @@
[#]: subject: "Linux Kernel 6.1 is Now Approved as an LTS Version"
[#]: via: "https://news.itsfoss.com/linux-kernel-6-1-is-now-an-lts-version/"
[#]: author: "Sourav Rudra https://news.itsfoss.com/author/sourav/"
[#]: collector: "lkxed"
[#]: translator: "Cubik65536"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15532-1.html"
Linux 6.1 内核被批准为长期支持版本
======
> 作为 2022 年的最后一个内核,经过一个多月的等待,现在 Linux 6.1 被批准为长期支持版本。
![Linux 6.1 内核被批准为长期支持版本][1]
Linux 6.1 内核是 2022 年的最后一个内核版本,通常这些版本会被批准为长期支持版本。
但是这次,将其作为 LTS 版本的决定被推迟了。
在决定是否将其用于长期使用之前,还在等待一些来自内核相关人员的关键反馈的测试结果。
幸好,这些问题已经得到解决,现在 **Linux 6.1 是一个长期支持版本**
让我带你了解这一举措的要点。
### Linux 6.1 现在正在成为长期支持版本
自从 12 月份发布以来Linux 稳定分支维护者 **Greg Kroah-Hartman** 就计划将 Linux 6.1 作为一个长期支持版本,但是一些待定的反馈导致该决定被推迟了。
现在,他和共同维护者 Sasha Levin 终于收到了足够的反馈,表明将 Linux 内核 6.1 作为一个长期支持版本维护是合理的。
按照目前的情况Linux 6.1 内核预期将于 **2026 年 12 月** 结束支持,如果有足够多的用户或公司对其感兴趣,那么它的生命周期可能会延长。
![一张描述当前 Linux 长期支持版本的表格][2]
最初,它的生命周期被计划为 2 年,但是后来被更新为了 **当前的 4 年**
你还会注意到,同时许多 Linux 内核都被作为长期支持版本维护。
### Linux 6.1 内核:概述
如果你错过了这个版本,下面是 Linux 内核 6.1 的一些亮点:
- 对 Rust 的实验性支持
- 对 AMD PC 的优化
- 对英特尔 Meteor Lake 的初始支持
- 优化 ARM 架构 SoC 的支持
这些并不是新版本的全部内容;你可以阅读我们的文章以了解更多信息。
> **[Linux 内核 6.1 发布,初步支持 Rust][9]**
参考自:[Phoronix][3]
💬 考虑到这是一个长期支持版本,你可以预见到很多未来的发行版升级将会包含 Linux 6.1 内核。你认为你会更喜欢使用哪个版本?
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/linux-kernel-6-1-is-now-an-lts-version/
作者:[Sourav Rudra][a]
选题:[lkxed][b]
译者:[Cubik65536](https://github.com/Cubik65536)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/sourav/
[b]: https://github.com/lkxed/
[1]: https://news.itsfoss.com/content/images/size/w2000/2023/02/linux-6-1-to-be-lts.png
[2]: https://news.itsfoss.com/content/images/2023/02/Linux_Kernel_LTS.jpg
[3]: https://www.phoronix.com/news/Linux-6.1-LTS-Official
[4]: https://itsfoss.com/signup/
[5]: https://itsfoss.com/flatpak-vs-snap/
[6]: https://www.socallinuxexpo.org/scale/20x
[7]: https://news.itsfoss.com/upcoming-code-editors/
[8]: https://news.itsfoss.com/new-distros-2023/
[9]: https://news.itsfoss.com/linux-kernel-6-1-release/

View File

@ -0,0 +1,83 @@
[#]: subject: "GNOME is (kind of) Bringing Back a Feature It Had Removed a Few Years Ago"
[#]: via: "https://news.itsfoss.com/gnome-design-quick-access/"
[#]: author: "Ankush Das https://news.itsfoss.com/author/ankush/"
[#]: collector: "lkxed"
[#]: translator: "SJFCS"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15551-1.html"
GNOME 正在(某种程度上)恢复在几年前删除的功能
======
> GNOME 的设计做了一些有意义的变化,它(某种程度上)带回了一个它早先删除的类似功能。
![GNOME 正在(某种程度上)恢复它几年前删除的功能][1]
几年前GNOME 移除了应用程序的菜单和指示器。
如果你不太清楚,应用程序指示器是一种从顶部面板与后台运行的应用程序进行交互的方式。
是的,你可以 [添加一个应用程序指示器的扩展][2] 来获得同样的功能。但是,在使用 GNOME 桌面环境的发行版上,如 Fedora你不再能找到默认的能力。
然而Ubuntu它的一些 [官方版本][3],以及其他发行版如 Pop!_OS支持系统托盘图标尽管 GNOME 放弃了它们。
现在,经过多年的设计变化,看起来我们可能会看到类似的东西。
### GNOME 将添加一个检查后台活动程序的简便方法
目前,在没有活动窗口的情况下,找出在后台运行的应用程序并没有简便的方法。
你必须使用 [任务管理器][4] 或 [系统监控工具][5] 以获得更好的观测能力。
在未来的 GNOME 版本中(可能是 GNOME 44你或许可以期待有一个功能可以直接从顶部面板的菜单面板上监控后台运行的应用程序。
![GNOME 设计模拟图,用于从通知菜单中检查后台应用程序][6]
[Allan Day][7] 的想法仍在讨论中,他分享了一个 [设计模拟图][8]。不过,它很有可能会被接受。
这个想法也促使开发者 [Georges Basile Stavracas Neto][9] 披露了 Flatpak 的 xdg-desktop-portal 组件,它可以使得检测运行中的 Flatpak 应用程序变得容易。
> 📋 检查后台应用程序这个功能的位置或设计仍在进行中;你在上面看到的内容可能会随着最终的实施而改变。
### 这是否也会使应用指示器回归?
并非如此。
通过这个功能GNOME 旨在让你快速看到后台运行的应用程序,并对它们进行管理(关闭它们或访问特定的设置)。
然而,你仍需要少量点击来达到这一点 🖱️。
小程序指示器或系统托盘图标是访问在后台运行的应用程序更快捷的方式,尽管不是每个后台应用程序都被列出。
毕竟,这总比没有好。
而最终,这些设计上的变化可能会产生一种直观的方式,以某种形式让应用指示器回归。
💬 你对这个决定与即将发布的 GNOME 设计变化有何看法?请在下面的评论中分享你的想法。
参考:[Phoronix][10]
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/gnome-design-quick-access/
作者:[Ankush Das][a]
选题:[lkxed][b]
译者:[SJFCS](https://github.com/SJFCS)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/ankush/
[b]: https://github.com/lkxed/
[1]: https://news.itsfoss.com/content/images/size/w2000/2023/02/gnome-brings-mysterious-features.png
[2]: https://itsfoss.com/enable-applet-indicator-gnome/
[3]: https://itsfoss.com/which-ubuntu-install/
[4]: https://itsfoss.com/task-manager-linux/
[5]: https://itsfoss.com/linux-system-monitoring-tools/
[6]: https://news.itsfoss.com/content/images/2023/02/background-app-running.png
[7]: https://gitlab.gnome.org/aday
[8]: https://gitlab.gnome.org/Teams/Design/os-mockups/-/issues/191
[9]: https://github.com/GeorgesStavracas
[10]: https://www.phoronix.com/news/GNOME-Monitor-Background-Apps

View File

@ -0,0 +1,158 @@
[#]: subject: "Learn Tcl by writing a simple game"
[#]: via: "https://opensource.com/article/23/2/learn-tcl-writing-simple-game"
[#]: author: "James Farrell https://opensource.com/users/jamesf"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15567-1.html"
通过“猜数字”游戏学习 Tcl
======
![][0]
> 探索 Tcl 的基本语言结构,包括用户输入、输出、变量、条件评估、循环和简单函数。
我的 Tcl 之旅始于最近需要将一个困难的基于 Java 的命令行配置工具自动化。我使用 Ansible 做了一些自动化编程,偶尔也会使用 `expect` 模块。坦率地说,我发现这个模块的作用有限,原因包括:难以对相同的提示进行排序,难以捕捉到额外步骤的值,控制逻辑的灵活性有限,等等。有时你可以用 `shell` 模块来代替。但有时你会遇到那种特立独行、过于复杂的命令行程序,似乎无法实现自动化。
就我而言,我正在自动安装我公司的一个程序。最后的配置步骤只能通过命令行来完成,通过几个不规范的、重复的提示和需要捕捉的数据输出。好在传统的 Expect 是唯一的答案。要使用 Expect 的基本功能,并不需要对 Tcl 有很深的了解,但你了解的越多,你就能从它那里得到更多的力量。这是后续文章的话题。现在,我探讨一下 Tcl 的基本语言结构,包括用户输入、输出、变量、条件判断、循环和简单函数。
### 安装 Tcl
在 Linux 系统上,我使用这个:
```
# dnf install tcl
# which tclsh
/bin/tclsh
```
在 macOS 上,你可以使用 [Homebrew][1] 来安装最新的 Tcl
```
$ brew install tcl-tk
$ which tclsh
/usr/local/bin/tclsh
```
### 在 Tcl 中猜数字
从创建基本的可执行脚本 `numgame.tcl` 开始:
```
$ touch numgame.tcl
$ chmod 755 numgame.tcl
```
接着在你的文件中开始编码,标题是通常的 #!
```
#!/usr/bin/tclsh
```
这里有一些关于 Tcl 的简单介绍,以便与本文一起追踪。
第一点是Tcl 处理的都是字符串。变量通常被当作字符串处理,但可以自动切换类型和内部表示(这一点你通常无法看到)。函数可以把它们的字符串参数解释为数字(`expr`),并且只通过值传递。字符串通常使用双引号或大括号来划分。双引号允许变量扩展和转义序列,而大括号则完全没有扩展。
第二点是 Tcl 语句可以用分号隔开,但通常不这样。语句行可以用反斜杠字符来分割,然而,典型的做法是将多行语句放在大括号内,以避免需要这样做。大括号只是更简单,下面的代码格式也反映了这一点。大括号允许对字符串进行延迟求值。在 Tcl 进行变量替换之前,值被传递给函数。
最后Tcl 使用方括号进行命令替换。方括号之间的任何东西都会被送到 Tcl 解释器的一个新的递归调用中进行求值。这对于在表达式中间调用函数或为函数生成参数是很方便的。
### 过程
虽然在这个游戏中没有必要,但我先举一个在 Tcl 中定义函数的例子,你可以在以后使用:
```
proc used_time {start} {
return [expr [clock seconds] - $start]
}
```
使用 `proc` 将其设定为一个函数(或过程)定义。接下来是函数的名称。然后是一个包含参数的列表;在本例中是一个参数 `{start}` ,然后是函数主体。注意,主体的大括号在这一行开始,它不能在下面一行。该函数返回一个值。返回值是一个复合求值(方括号),它从读取系统时钟 `[clock seconds]` 开始,并进行数学运算以减去 `$start` 参数。
### 设置、逻辑和完成
你可以在这个游戏的其余部分增加更多的细节,进行一些初始设置,对玩家的猜测进行迭代,然后在完成后打印结果:
```
set num [expr round(rand()*100)]
set starttime [clock seconds]
set guess -1
set count 0
puts "Guess a number between 1 and 100"
while { $guess != $num } {
incr count
puts -nonewline "==> "
flush stdout
gets stdin guess
if { $guess < $num } {
puts "Too small, try again"
} elseif { $guess > $num } {
puts "Too large, try again"
} else {
puts "That's right!"
}
}
set used [used_time $starttime]
puts "You guessed value $num after $count tries and $used elapsed seconds"
```
前面的 `set` 语句建立变量。前两个求值表达式用于识别 1 到 100 之间的随机数,下一个保存系统时钟启动时间。
`puts``gets` 命令用于来自玩家的输出和输入。我使用的 `puts` 暗示输出是标准输出。`gets` 需要定义输入通道,所以这段代码指定 `stdin` 作为用户的终端输入源。
`puts` 省略行末终止符时,需要 `flush stdout` 命令,因为 Tcl 缓冲了输出,在需要下一个 I/O 之前可能不会被显示。
从这里开始,`while` 语句说明了循环控制结构和条件逻辑,需要给玩家反馈并最终结束循环。
最后的 `set` 命令调用我们的函数来计算游戏的耗时秒数,接着是收集到的统计数字来结束游戏。
### 玩吧!
```
$ ./numgame.tcl
Guess a number between 1 and 100
==> 100
Too large, try again
==> 50
Too large, try again
==> 25
Too large, try again
==> 12
Too large, try again
==> 6
Too large, try again
==> 3
That's right!
You guessed value 3 after 6 tries and 20 elapsed seconds
```
### 继续学习
当我开始这个练习时,我怀疑回到 90 年代末的流行语言对我有多大的帮助。一路走来,我发现 Tcl 有几处让我非常喜欢的地方,我最喜欢的是方括号内的命令求值。与其他许多过度使用复杂闭包结构的语言相比,它似乎更容易阅读和使用。我以为它是一种 [已消亡的语言][2],但实际上它仍在蓬勃发展,并在多个平台上得到支持。我学到了一些新的技能,并对这种古老的语言有了新的认识。
在 [https://www.tcl-lang.org][3] 上查看官方网站。你可以找到最新的源代码、二进制发行版、论坛、文档,以及仍在进行的会议信息的参考。
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/learn-tcl-writing-simple-game
作者:[James Farrell][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/jamesf
[b]: https://github.com/lkxed/
[1]: https://opensource.com/article/20/6/homebrew-mac
[2]: https://opensource.com/article/19/6/favorite-dead-language
[3]: https://www.tcl-lang.org
[0]: https://img.linux.net.cn/data/attachment/album/202302/23/140000ilg3oa8khgrhr1r3.jpg

View File

@ -0,0 +1,110 @@
[#]: subject: "Start developing for WebAssembly with our new guide"
[#]: via: "https://opensource.com/article/23/2/webassembly-guide"
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15541-1.html"
跟着我们的新指南学习开发 WebAssembly
======
![][0]
> 使用 WebAssembly 开发有很多不同的方向,这取决于你已经知道的东西和你想建立的东西。
在过去的几十年里Web 浏览器作为最流行的跨平台应用经久不衰。从另一个角度看浏览器,它是最受欢迎的应用交付平台之一。想想你使用的所有网站,它们取代了你过去用桌面上运行的软件进行的活动。你仍然在使用软件,但你是通过浏览器来访问它,而且是在别人的 Linux 服务器上运行。在优化我们所有人使用的软件的永恒努力中,软件开发世界早在 2019 年就引入了 WebAssembly作为通过 Web 浏览器运行编译代码的一种方式。应用的性能比以往任何时候都要好,而且可以生成 WebAssembly 编码的语言远不只是通常的 PHP、Python 和 JavaScript。
### 一个目标和一种语言
关于 WebAssembly 的一个强大但也最令人困惑的地方是“WebAssembly” 这个词既指一种语言也指一个目标。WebAssembly 是一种汇编语言,但没有多少人选择直接用汇编写代码。即使是汇编语言,最终也会被转换为二进制格式,这也是计算机运行代码的要求。这种二进制格式也被称为 WebAssembly。不过这很好因为这意味着你可以用你选择的语言来写一些最终以 WebAssembly 交付的东西,包括 C、C++、Rust、Javascript 和其他许多语言。
进入 WebAssembly 的途径是 Emscripten这是一个 LLVM 编译器工具链,可以从你的代码中产生 WebAssembly。
### 安装 Emscripten
要在你的 Linux 或 macOS 电脑上安装 Emscripten请使用 Git
```
$ git clone https://github.com/emscripten-core/emsdk.git
```
改变目录进入 `emsdk` 目录并运行安装命令:
```
$ ./emsdk install latest
$ ./emsdk activate latest
```
Emscripten 工具链中的所有内容都安装在 `emsdk` 目录下,对系统的其他部分没有影响。由于这个原因,在使用 `emsdk` 之前,你必须 <ruby>源引<rt>source</rt></ruby> 它的环境:
```
$ source ./emsdk_env.sh
```
如果你打算经常使用 `emsdk`,你也可以在 `.bashrc` 中加入环境设置脚本。
要在 Windows 上安装 Emscripten你可以在 WSL 环境下运行 Linux。
请访问 [Emscripten 网站][1] 了解更多安装信息。
### Hello World
下面是一个用 C++ 编写的简单的 “Hello World” 应用。
```
#include <iostream>
using namespace std;
int main() {
cout << "Hello world";
return 0;
}
```
先把它作为你的系统的标准二进制文件来测试:
```
$ g++ hello.cpp -o world
$ ./world
Hello world
```
看到它像预期的那样工作,用 `emcc` 把它构建为 WebAssembly
```
$ emcc hello.cpp -o world.html
```
最后,用 `emrun` 运行它:
```
$ emrun ./world.html
```
`emrun` 工具是一个用于本地测试的方便命令。当你在服务器上托管你的应用时,`emrun` 就没有必要了。
### 学习更多关于 WebAssembly 的知识
使用 WebAssembly 开发可以有很多不同的方向,这取决于你已经知道的东西和你想建立的东西。如果你了解 C 或 C++,那么你可以用这些来写你的项目。如果你正在学习 Rust那么你可以使用 Rust。甚至 Python 代码也可以使用 Pyodide 模块来作为 WebAssembly 运行。你有很多选择,而且没有错误的开始方式(甚至有 COBOL 到 WebAssembly 的编译器)。如果你渴望开始使用 WebAssembly
> **[请下载我们免费的电子书][2]**
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/webassembly-guide
作者:[Seth Kenlon][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/seth
[b]: https://github.com/lkxed/
[1]: https://emscripten.org/
[2]: https://opensource.com/downloads/webassembly-ebook
[0]: https://img.linux.net.cn/data/attachment/album/202302/15/204034uy4t9h6z6o06hj6j.jpg

View File

@ -0,0 +1,138 @@
[#]: subject: "Endless OS 5.0 Review: The Best of GNOME with Wayland and Apps"
[#]: via: "https://www.debugpoint.com/endless-os-5-0-review/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15582-1.html"
Endless OS 5.0:带有 Wayland 和丰富应用程序的最佳 GNOME 桌面
======
![][0]
> 新版本的 Endless OS 5.0 已经发布,带来了更多的功能和稳定性。下面是对这个版本的简要点评。
在不变性成为炒作对象之前Endless OS 已经提供了一种基于 [OSTree][1] 的高效桌面体验。它基于 Debian 和 Ubuntu但正在独立开发。由于其底层基于 OSTreeEndless OS 运行在其用户空间中,同时给你最好的桌面体验。
它是一个适合学校、小规模部署、实验室和离线使用情况的完美发行版。
新版本的 Endless OS 5.0 现在已经推出。下面是对其功能的快速回顾和深入点评。
> 我们相信,个人计算对生产力、学习和工作技能至关重要。
>
> 我们在过去 10 年中致力于设计和提供操作系统和工具,使人们能够获得和控制他们的技术。
>
> 借助我们的工具,我们可以通过使用和发现来提高生产力、创造力和学习,我们帮助各种背景的人以更有意义的方式参与数字经济。
>
> —— Endless OS 使命宣言
### Endless OS 5 点评
由于这个操作系统的目的是为不太富裕的人提供数字计算的机会,所以它提供了 Windows 安装程序。你可以直接下载它并在 Windows 环境中试用。
此外,它还提供了一个专门的独立 ISO 镜像,可以通过 U 盘进行安装。
上次我在 2021 年点评 Endless OS 时,它并没有提供 ARM 版本。我很惊讶地发现,它现在有一个 ARM 镜像,你可以在树莓派和其他 ARM 板上试用。
在我的测试安装中,一切都很顺利。它使用一个自定义的安装程序,类似于 Fedora 的 Anaconda 安装程序。然而,安装它需要一个完整的磁盘。如果你喜欢双启动,[在此][2] 有一个详细的指南。但是,我觉得它的设置有点复杂。
![Endless OS installation in Windows][3]
#### 登录和第一印象
这个版本基于 [Debian 11 “bullseye”][4],带有 Linux 主线 [内核 5.15][5]。此外,它还为该团队的原生应用程序提供了单独的软件仓库。其桌面基于 [GNOME 41][6]。
这个版本在外观感受方面有一些改变。首先,底部面板被改变为显示基本的 GNOME 风格的停靠区。它总是可见的,当你把一个窗口移到它上面时,它就会消失。早些时候,它是一个固定的标准面板,有一个应用程序图标、系统托盘和正在运行的应用程序部件。
其次,它引入了一个新的顶部面板,遵循 GNOME 的设计。它包含活动、应用程序启动器和系统托盘。
![Look has changed since prior release with dock and top panel in Endless OS 5.0][7]
和 Endless OS 4.0 的外观相比,它有很多改变:
![Endless OS Desktop version 4.0][8]
#### 对 GNOME 桌面和工作区的独特定制
默认外观保持不变,包括带有搜索框的桌面应用程序视图。顶部面板上的应用程序是对运行中的应用程序和桌面视图的切换。
超级键(`Super`)也可以切换到正在运行的应用程序和工作区视图,这一点非常方便。窗口在右上方有最小化、最大化和关闭按钮;它们不需要调整。
然而,在这个版本中,有一个喜欢的功能被放弃了。在 [Endless OS 4.0][9] 中,当你点击桌面的空白部分时,它会立即将所有打开的窗口最小化,并向你显示桌面。然而,这个功能已经不再可用了。这是一个多么方便的功能,可以使工作流程更加顺畅。
#### 在 Endless OS 5.0 中引入 Wayland
现代显示服务器 Wayland 在这个版本中首次出现在 Endless OS 中。默认登录是 Wayland。然而你可以从登录界面切换到 X.Org。得益于 Wayland你可以感受到 Endless OS 操作系统中流畅的动画、手势和性能。
#### 手势支持
Endless OS 5.0 还引入了多手势支持。你现在可以通过触控板/触摸板使用三指左右轻扫来浏览工作区。此外,三指向上滑动可以切换应用程序网格和工作空间。
支持的应用程序也可以使用捏合缩放,包括双指滚动。
这是一个非常需要的更新,以进一步提高你在 Endless OS 中的生产力。
#### 应用程序中心、Flatpak 和应用程序
Endless OS 作为一个不可变的发行版,你所有的应用程序都运行在一个独立的用户空间。默认情况下,它只支持 Flatpak 软件包。默认配置了世界上最大的 Flatpak 仓库 Flathub。你可以直接从 AppCenter 搜索并安装任何 Flatpak 应用程序。
![Flathub repo is pre-configured for Flatpak apps][10]
然而,在默认情况下,几乎所有需要的应用程序都已经预装。如果你想处理文件,一个完整的 LibreOffice 包就在那里。它还包括预装了 Ad-Block 的 Chromium 网络浏览器!此外,你还得到了 Gedit 文本编辑器、Shotwell 图像查看器、Brasero 磁盘刻录应用程序、<ruby>文件<rt>Files</rt></ruby>应用作为文件管理器、管理你的学校/家庭工作流程的 Kolibri。
所有原生的 GNOME 应用程序现在都默认是 Flatpak 版本,而不是 APT 软件包。这是 Endless OS 5.0 的关键变化之一。
![Kolibri is one of the amazing app - pre-loaded][11]
#### 帮助中心
Endless OS 的伟大功能之一是可以从帮助应用程序中获得离线帮助。你也可以通过桌面搜索功能访问它。
任何学生或首次使用的用户都可以快速了解桌面的基本功能,如 “如何更改密码” 或 “如何创建账户” 之类的问题。所有这些都可以作为离线帮助文件使用。
![Endless OS desktop offline help][12]
### 总结
Endless OS 5.0 带来了非常需要的变化,如 Wayland 和手势支持,同时坚持其原则,成为一个易于使用的大众发行版。它是一个设计良好、考虑周到的发行版,非常适合离线/远程使用、实验室、学校和社区。如果配置正确Linux 可以影响数百万人 —— 对那些买不起昂贵软件的人来说。
另外,对于普通用户来说,如果你打算运行多年,这可能是一个完美的发行版。你可以把自己从升级、系统故障、命令、依赖性问题等的麻烦中解救出来。
这是该团队为社区发布的一个优秀版本。你可以从下面的链接下载它。
> **[下载 Endless OS][13]**
你对这个版本的整体印象如何?请在评论栏里告诉我。
参见 [Endless OS 5.0 发布说明][14] 。
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/endless-os-5-0-review/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed/
[1]: https://ostree.readthedocs.io/en/stable/
[2]: https://support.endlessos.org/en/installation/windows-installer/dual-boot
[3]: https://www.debugpoint.com/wp-content/uploads/2023/02/Endless-OS-installation-in-Windows.jpg
[4]: https://www.debugpoint.com/debian-11-features/
[5]: https://www.debugpoint.com/linux-kernel-5-15/
[6]: https://www.debugpoint.com/gnome-41-release/
[7]: https://www.debugpoint.com/wp-content/uploads/2023/02/Look-has-changed-since-prior-release-with-dock-and-top-panel-in-Endless-OS-5.0.jpg
[8]: https://www.debugpoint.com/wp-content/uploads/2021/11/Endless-OS-Desktop-version-4.0.jpg
[9]: https://www.debugpoint.com/endless-os-review-2021
[10]: https://www.debugpoint.com/wp-content/uploads/2023/02/Flathub-repo-is-pre-configured-for-Flatpak-apps.jpg
[11]: https://www.debugpoint.com/wp-content/uploads/2023/02/Kolibri-is-one-of-the-amazing-app-pre-loaded.jpg
[12]: https://www.debugpoint.com/wp-content/uploads/2023/02/Endless-OS-desktop-offline-help.jpg
[13]: https://www.endlessos.org/os-windows-installer
[14]: https://support.endlessos.org/en/endless-os/release-notes/5
[0]: https://img.linux.net.cn/data/attachment/album/202302/28/001503u92tz023olzzftdo.jpg

View File

@ -0,0 +1,61 @@
[#]: subject: "Opera Browser Plans to Integrate ChatGPT"
[#]: via: "https://debugpointnews.com/opera-chatgpt-integration/"
[#]: author: "arindam https://debugpointnews.com/author/dpicubegmail-com/"
[#]: collector: "lkxed"
[#]: translator: "gpchn"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15547-1.html"
Opera 浏览器计划集成 ChatGPT
======
![][1]
> 据报道Opera 浏览器正在寻求将语言模型 ChatGPT 集成到其桌面和移动产品中。
### 摘要
- 据报道,流行的桌面和移动网络浏览器 Opera 浏览器正在探索将语言模型 ChatGPT 集成到其产品中。
- 微软最近宣布将 ChatGPT 的制造商 OpenAI 技术集成到其 Edge 网络浏览器中,为用户添加人工智能功能。
### Opera 与 ChatGPT
[Opera][2],一个被广泛使用的桌面和移动网络浏览器,将把语言模型 ChatGPT 集成到它的软件产品中。Opera 的母公司昆仑科技是这一新闻的幕后推手尽管这次集成的细节仍然有限。Opera 提供了一系列软件产品,包括桌面网络浏览器、移动网络浏览器以及其为 Chromebook 设计的浏览器版本。
最有可能整合 ChatGPT 的是 Opera 的主要桌面浏览器,包括 Opera 浏览器和 Opera GX这是一款为游戏玩家设计的浏览器。然而也有可能集成到 Opera 的移动浏览器中,包括常规的 Opera 移动浏览器、Opera Mini 和 Opera Crypto 浏览器。
### 来自微软和谷歌的最新更新
微软上周宣布将 OpenAI 集成到其 Edge 网络浏览器中,成为头条新闻。这种集成将在未来为 Edge 用户带来两种人工智能功能,即 “<ruby>Chat<rt>聊天</rt></ruby>” 和 “<ruby>撰写<rt>Compose</rt></ruby>”。“聊天”功能可以让用户在浏览器中直接与人工智能交流。同时,“撰写”功能帮助用户进行文本撰写,包括使用不同的语气和长度撰写电子邮件和社交媒体帖子。
在最近的一次演示中,谷歌没有宣布将人工智能聊天机器人直接集成到其 Chrome 浏览器中,这一举措得到的回应并不热烈。
### 下一步是什么
据 Statcounter 统计Opera 浏览器被数亿用户使用,在全球浏览器市场占有 2.4% 的份额。虽然它可能落后于谷歌 Chrome 的 65% 和 Safari 的 18%,但与 Mozilla Firefox 的 3% 相比,它仍然保持着自己的优势。
昆仑科技是一家在深圳证券交易所上市的北京公司。本周,中国搜索巨头百度宣布计划在其搜索产品中集成 ChatGPT 风格的机器人。
总之ChatGPT 与 Opera 浏览器的集成代表着人工智能网络浏览向前迈出的重要一步。随着微软和百度等公司将人工智能技术融入其产品Opera 将自己定位为该领域的领导者。
随着数亿用户和浏览器市场的日益增长ChatGPT 与 Opera 的集成是一项备受期待的发展。
参考:[CNBC][3]
--------------------------------------------------------------------------------
via: https://debugpointnews.com/opera-chatgpt-integration/
作者:[arindam][a]
选题:[lkxed][b]
译者:[gpchn](https://github.com/gpchn)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://debugpointnews.com/author/dpicubegmail-com/
[b]: https://github.com/lkxed
[1]: https://debugpointnews.com/wp-content/uploads/2023/02/opera.jpg
[2]: https://www.opera.com/
[3]: https://www.cnbc.com/2023/02/09/web-browser-opera-is-planning-to-incorporate-chatgpt.html

View File

@ -0,0 +1,172 @@
[#]: subject: "How to Install DOSBox in Ubuntu to Play Old Games"
[#]: via: "https://www.debugpoint.com/install-dosbox-ubuntu/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "gpchn"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15538-1.html"
如何在 Ubuntu 中安装 DOSBox 玩老游戏
======
![][0]
> 了解如何在 Ubuntu 中安装 DOSBox并配置它来玩旧式 DOS 游戏。
DOSBox 是一个自由开源的操作系统模拟器,可以在现代 Linux 系统中运行。它有几个组件可以模仿旧的硬件,以运行旧的程序和游戏。
这一切使得在现代 Linux 发行版中享受旧游戏和应用程序成为可能。
在本指南中,我将向你展示如何安装 DOSBox配置它并玩一个示例游戏。
### 在 Ubuntu 中安装 DOSBox
DOSBox 的主软件包在所有主要的 Linux 发行版中都可用。
在 Ubuntu、Debian、LinuxMint 和相关发行版中,使用以下命令安装它:
```
sudo apt install dosbox
```
在 Fedora、CentOS、RHEL 和相关发行版中,使用以下命令安装它:
```
sudo dnf install dosbox
```
在 Arch Linux 中,使用以下命令安装它:
```
pacman -S --needed dosbox
```
安装就结束了。现在是配置和运行的时候了。
### 运行 DOSBox
安装后,从终端键入以下内容:
```
dosbox
```
它将显示以下界面,这是 DOSBox 提示符。第一次运行非常重要,因为它会创建 DOSBox 配置文件。
键入 `exit` 暂时关闭 DOSBox。
![DOSBox first time run][1]
配置文件为你提供了几个调整设置的选项。在 Ubuntu 中,该文件创建在 `~/.dosbox/dosbox-[version].conf`
在 Fedora 中,它从以下路径加载临时配置文件 `~/.config/dosbox/dosbox-staging.conf`.
默认情况下,你可以使用默认配置。但是如果你愿意,你可以修改它。
例如,如果你想全屏启动 DOSBox你可以启用或禁用相关设置。像这样:
```
fullscreen=false
fulldouble=false
fullresolution=original
windowresolution=original
output=surface
autolock=true
sensitivity=100
waitonerror=true
```
你可以在 [官方文档][2] 中找到所有的设置选项。
### 下载以及游玩老游戏
有许多网站提供旧的 DOS 游戏。我使用过下面的网站,它提供了一套可以在现代系统中玩的老游戏。
所以,访问下面的网站,下载你想要的任何游戏。
> **[下载 DOS 游戏][3]**
在你的 `/home` 目录下创建一个文件夹,并将其命名为 `dosbox`
```
cd ~
mkdir dosbox
```
现在,解压你下载的游戏(应该是一个 .exe 文件),在 `~/dosbox` 目录下创建一个单独的文件夹。
例如,我下载了游戏 “马里奥和路易吉1994”。我在 `dosbox` 文件夹中创建了一个名为 `mario` 的文件夹,并将游戏文件放进去。
![Keep the game in a separate folder][4]
现在从终端启动 dosbox
```
dosbox
```
并键入以下内容,将游戏挂载到虚拟的 C: 盘中:
```
mount c ~/dosbox/mario
```
以上命令完成后,将驱动器更改为 C:
```
c:
```
现在,你可以输入游戏的文件名来运行游戏:
```
mario
```
![Running the game][5]
![Mario running in DOSBox in Ubuntu][6]
### 键盘或控制器映射
默认情况下DOSBox 会自动检测键盘或你插入的控制器。但是,如果你想更改游戏按键绑定,可以从终端运行以下命令:
```
dosbox -startmapper
```
它将显示以下界面,每个键上都标记有事件。你可以点开任何一个键,根据自己的习惯进行更改。
![DOSBox keyboard and controller mapping][7]
### 结论
我希望你在 Ubuntu 和其他发行版中安装了 DOSBox 之后,能够运行你最喜欢的 DOS 游戏。DOSBox 是最酷的软件之一,你可以使用它来运行任何程序,例如 [Turbo C][8] 等。
如果你有任何麻烦或问题,请在评论区告诉我。
享受游戏吧!
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/install-dosbox-ubuntu/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[gpchn](https://github.com/gpchn)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://www.debugpoint.com/wp-content/uploads/2023/02/DOSBox-first-time-run.jpg
[2]: https://www.dosbox.com/wiki/Dosbox.conf#Sections
[3]: https://archive.org/details/softwarelibrary_msdos_games?tab=collection
[4]: https://www.debugpoint.com/wp-content/uploads/2023/02/Keep-the-game-in-a-separate-folder.jpg
[5]: https://www.debugpoint.com/wp-content/uploads/2023/02/Running-the-game.jpg
[6]: https://www.debugpoint.com/wp-content/uploads/2023/02/Mario-playing-in-DOSBox-in-Ubuntu.jpg
[7]: https://www.debugpoint.com/wp-content/uploads/2023/02/DOSBOox-keyboard-and-controller-mapping.jpg
[8]: https://www.debugpoint.com/setting-up-dosbox-in-ubuntu-to-run-turbo-c/
[0]: https://img.linux.net.cn/data/attachment/album/202302/14/142608nsoov2vory2nipiv.jpg

View File

@ -0,0 +1,151 @@
[#]: subject: "Lua loops: how to use while and repeat until"
[#]: via: "https://opensource.com/article/23/2/lua-loops-while-repeat-until"
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15575-1.html"
Lua 循环:如何使用 while 和 repeat until
======
> 学习如何以及何时在 Lua 中使用 while 和 repeat until 循环。
控制结构是编程语言的一个重要特征,因为它们使你能够根据通常在程序运行时动态建立的条件来指导程序的流程。不同的语言提供了不同的控制,在 Lua 中,有 `while` 循环、`for` 循环和 `repeat` `until` 循环。这篇文章涵盖了 `while``repeat until` 循环。由于它们的灵活性,我在一篇 [单独的文章][1] 中介绍 `for` 循环。
条件是由一个使用运算符的表达式来定义的运算符是你在数学课上可能认识的符号的一个花哨的术语。Lua 中有效的运算符有:
- `==` 等于
- `~=`不等于
- `<` 小于
- `>` 大于
- `⇐`小于或等于
- `>=` 大于或等于
这些被称为关系运算符,因为它们比较两个值之间的关联。还有一些逻辑运算符,其含义与英语中的含义相同,可以纳入条件中,进一步描述你想检查的状态:
- `and`
- `or`
下面是一些条件的例子:
- `foo > 3`:变量 `foo` 是否大于 3`foo` 必须是 4 或更大才能满足这个条件。
- `foo >= 3``foo` 是否大于或等于 3`foo` 必须是 3 或更大才能满足这个条件。
- `foo > 3 and bar < 1``foo` 是否大于 3 而 `bar` 小于 1要满足这个条件`foo` 变量必须在 `bar` 为 0 的同时为 4 或更大。
- `foo> 3 or bar < 1``foo` 是否大于 3或者`bar` 是否小于 1如果 `foo` 是 4 或更大,或者 `bar` 是 0那么这个条件就是真的。如果 `foo` 是 4 或更大,而 `bar` 是 0会怎样答案出现在本文的后面。
### while 循环
只要满足某个条件while 循环就会执行指令。例如,假设你正在开发一个应用来监测正在进行的僵尸末日。当没有剩余的僵尸时,就不再有僵尸末日了:
```
zombie = 1024
while (zombie > 0) do
print(zombie)
zombie = zombie-1
end
if zombie == 0 then
print("No more zombie apocalypse!")
end
```
运行代码,看僵尸消失:
```
$ lua ./while.lua
1024
1023
[...]
3
2
1
No more zombie apocalypse!
```
### until 循环
Lua 还有一个 `repeat` `until` 循环结构,本质上是一个带有 `catch` 语句的 `while` 循环。假设你在从事园艺工作,你想追踪还剩下什么可以收获的东西:
```
mytable = { "tomato", "lettuce", "brains" }
bc = 3
repeat
print(mytable[bc])
bc = bc - 1
until( bc == 0 )
```
运行代码:
```
$ lua ./until.lua
brains
lettuce
tomato
```
这很有帮助!
### 无限循环
一个无限循环有一个永远无法满足的条件,所以它无限地运行。这通常是一个由错误逻辑或你的程序中的意外状态引起的错误。例如,在本文的开头,我提出了一个逻辑难题。如果一个循环被设定为 `foo > 3 or bar < 1` 运行 ,那么当 `foo` 为 4 或更大而 `bar` 为 0 时,会发生什么?
下面是解决这个问题的代码,为了以防万一,还使用了 `break` 语句安全捕获:
```
foo = 9
bar = 0
while ( foo > 3 or bar < 1 ) do
print(foo)
foo = foo-1
-- safety catch
if foo < -800000 then
break
end
end
```
你可以安全地运行这段代码,但它确实模仿了一个意外的无限循环。有缺陷的逻辑是 `or` 运算符,它允许这个循环在 `foo` 大于 3 和 `bar` 小于 1 的情况下继续进行。`and` 运算符有不同的效果,但我让你去探索。
无限循环实际上有其用途。图形应用使用技术上的无限循环来保持应用程序窗口的开放。我们没有办法知道用户打算使用这个程序多久,所以程序无限地运行,直到用户选择**退出**。在这些情况下使用的简单条件显然是一个总是被满足的条件。下面是一个无限循环的例子,为了方便起见,还是内置了一个安全陷阱:
```
n = 0
while true do
print(n)
n = n+1
if n > 100 then
break
end
end
```
条件 `while true` 总是被满足,因为 `true` 总是为真。这是比写 `while 1 == 1` 或类似的永远为真的简洁方式。
### Lua 中的循环
从示例代码中可以看出,尽管有不同的实现方式,但循环基本上都是朝着同一个目标工作。选择一个对你来说有意义的,并且在你需要执行的处理过程中效果最好的。以防万一你需要它:终止失控循环的键盘快捷键是 `Ctrl+C`
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/lua-loops-while-repeat-until
作者:[Seth Kenlon][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/seth
[b]: https://github.com/lkxed/
[1]: https://opensource.com/article/22/11/lua-for-loops
[0]: https://img.linux.net.cn/data/attachment/album/202302/25/152802hoi4khxzm3izpejh.jpg

View File

@ -0,0 +1,140 @@
[#]: subject: "Login as Root in Ubuntu GUI"
[#]: via: "https://itsfoss.com/ubuntu-login-root/"
[#]: author: "Sagar Sharma https://itsfoss.com/author/sagar/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15583-1.html"
在 Ubuntu GUI 中以 root 身份登录
======
![][0]
默认情况下Ubuntu 禁用了 root 账户。你必须使用 `sudo` 命令来执行任何需要 root 权限的任务。
当然,这是为了你自己的安全。一直以 root 身份使用系统,就像手里拿着一把剑到处跑。它增加了把事情搞乱的机会。
以 root 身份登录在服务器中仍然很常见。在桌面方面,以 root 身份登录的情况相当少见。甚至 Kali Linux 也做了改变。
然而,有一些桌面用户想以 root 身份登录。这不是什么明智之举,但肯定是可以做到的。
在本指南中,我将向你展示如何在 Ubuntu 中 **以 root 身份登录 GNOME 桌面**
### 如何在 GNOME 桌面上以 root 身份登录
> 🚧 我不建议在桌面上以 root 身份登录。你有 sudo 机制来满足你所有的 root 需求。只有在你有足够理由的情况下才这样做。本教程仅用于演示目的。你已经被警告过了。
#### 步骤 1启用 root 账户
你想以 root 身份登录。但默认情况下root 账户是禁用的。第一步是启用它。
改变 root 账户的密码,这将为你启用 root 账户:
```
sudo passwd root
```
![change the password of root account in ubuntu][1]
不言而喻,你不应该忘记 root 密码。
#### 步骤 2改变 GDM 配置
> 🚧 本教程的这一部分只对 GNOME 有效。请 [检查你的桌面环境][2] 并确保它是 GNOME。
Ubuntu 默认使用 GNOMEGNOME 使用 GDM 显示管理器。
为了允许以 root 身份登录到 GNOME你需要对位于 `/etc/gdm3/custom.conf` 的 GDM 配置文件做一些修改。
对该配置文件做一个备份:
```
cp /etc/gdm3/custom.conf /etc/gdm3/custom.conf~
```
在最坏的情况下,如果你以某种方式把事情搞砸了,备份的文件可以用来从 TTY 上替换现有文件。
现在,用以下命令打开 GDM 文件:
```
sudo nano /etc/gdm3/custom.conf
```
并添加以下一行,允许 root 用户登录:
```
AllowRoot=true
```
![configure GDM on ubuntu][3]
`Ctrl+X` 退出 Nano同时保存它。
#### 步骤 3配置 PAM 认证
现在,你必须配置 PAM 认证守护进程文件,它可以通过以下命令打开:
```
sudo nano /etc/pam.d/gdm-password
```
在这个文件中,你必须注释掉以下带有 `#` 号的一行,该符号拒绝 GUI 中的 root 访问:
```
auth required pam_succeed_if.so user != root quiet_success
```
![][4]
[保存修改并退出 nano][5] 文本编辑器。
#### 步骤 4以 root 身份登录
现在,重启你的系统:
```
reboot
```
在登录界面,选择 `Not listed` 选项,在用户名中输入 `root`,并输入你在本指南开头配置的密码:
![Login as a root in ubuntu desktop][6]
当你登录后,它就会通知你,**“logged in as a privileged user”**
![logged in as a privileged user in Ubuntu][7]
这就完成了! 现在,你正在以 root 身份运行你的 Ubuntu 系统。
### 以 root 用户身份运行系统时,你应该知道的事情
Ubuntu 默认禁用 root 账户是有原因的。想知道为什么吗?在这里你可以找到:
> **[Ubuntu 中的 root 用户-你应该知道的重要事项][8]**
再说一遍,在你的桌面 Linux 系统中以 root 登录是不可取的。请遵守规范,远离这种(错误的)冒险。
--------------------------------------------------------------------------------
via: https://itsfoss.com/ubuntu-login-root/
作者:[Sagar Sharma][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://itsfoss.com/author/sagar/
[b]: https://github.com/lkxed/
[1]: https://itsfoss.com/content/images/2023/01/change-the-password-of-root-account-in-ubuntu.png
[2]: https://itsfoss.com/find-desktop-environment/
[3]: https://itsfoss.com/content/images/2023/01/configure-GDM-on-ubuntu.png
[4]: https://itsfoss.com/content/images/2023/01/configure-PAM-authentication-daemon-in-ubuntu.gif
[5]: https://linuxhandbook.com/nano-save-exit/
[6]: https://itsfoss.com/content/images/2023/01/Login-as-a-root-in-Ubuntu-desktop.png
[7]: https://itsfoss.com/content/images/2023/01/logged-in-as-a-privileged-user-in-Ubuntu.png
[8]: https://itsfoss.com/root-user-ubuntu/#what-is-root
[0]: https://img.linux.net.cn/data/attachment/album/202302/28/104536gesxvetse1rrru4q.jpg

View File

@ -0,0 +1,122 @@
[#]: subject: "Downgrading a Package via apt-get"
[#]: via: "https://itsfoss.com/downgrade-apt-package/"
[#]: author: "Abhishek Prakash https://itsfoss.com/author/abhishek/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15580-1.html"
通过 apt-get 降级一个软件包
======
![][0]
最近升级的软件引起问题了?虽然你总是可以调查问题以解决它,但有时,回到以前的工作版本可以节省时间和精力。如果新的版本引入了一个 bug你可以在你这一边什么都不做对吗
好消息是,你可以在 Ubuntu 和 Debian 中轻松地降级 apt 软件包。
你所要做的就是像这样使用 `apt` 命令:
```
sudo apt install package_name=package-version-number
```
这似乎很容易,但你如何获得确切的版本号?还有哪些旧版本被支持?你可以通过以下方式获得这个细节:
```
sudo apt-cache policy package_name
```
让我用一个现实生活中的例子来解释这些。
### 降级 apt 包
最近,我正在更新承载 It's FOSS 社区论坛的 Ubuntu 服务器。
我做了通常的 `apt update && apt upgrade`,在更新安装时,事情变得糟糕。
很明显,最新版本的 Docker 不支持 aufs 存储驱动。为了减少停机时间,我选择了降级到以前的 Docker 版本。
检查当前安装的软件包版本:
![Installed Docker version][1]
然后检查可以安装的可用版本:
```
sudo apt-cache policy package_name
```
它可能会抛出一个巨大的列表,或者只是一个小列表:
![All installable versions of an apt package][2]
如果它显示至少有一个比当前版本更早的版本,你就很幸运了。
现在,你可能认为一个软件包的版本号将只由数字组成。但情况可能并不总是这样。
基本上,你复制 500优先级数字之前的全部内容。
```
brave-browser:
Installed: 1.48.158
Candidate: 1.48.164
Version table:
1.48.164 500
500 https://brave-browser-apt-release.s3.brave.com stable/main amd64 Packages
*** 1.48.158 500
500 https://brave-browser-apt-release.s3.brave.com stable/main amd64 Packages
100 /var/lib/dpkg/status
1.47.186 500
500 https://brave-browser-apt-release.s3.brave.com stable/main amd64 Packages
1.47.171 500
500 https://brave-browser-apt-release.s3.brave.com stable/main amd64 Packages
1.46.153 500
```
当你得到了软件包的编号,用它来降级已安装的软件包,像这样:
```
sudo apt install package_name=package-version-number
```
![Downgrading an installed package via apt-get command][3]
当然,你会看到一个关于降级软件包的警告。
![Downgrading apt package][4]
但是当这个过程完成,你的软件包就会被降级到给定的旧版本。
### 所以,也许要保留它?
所以,你刚刚学会了降级 apt 软件包。但如果你不注意的话,该软件包会在下一次系统更新时再次升级。
不希望这样吗?你可以 [阻止一个软件包被更新][5]。像这样使用 `apt-mark` 命令:
```
sudo apt-mark hold package_name
```
我希望这个快速技巧能帮助你在需要时降级 apt 软件包。如果你有问题或建议,请告诉我。
--------------------------------------------------------------------------------
via: https://itsfoss.com/downgrade-apt-package/
作者:[Abhishek Prakash][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[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/lkxed/
[1]: https://itsfoss.com/content/images/2023/02/installed-docker-version.png
[2]: https://itsfoss.com/content/images/2023/02/available-docker-versions.png
[3]: https://itsfoss.com/content/images/2023/02/downgrading-installed-packages.png
[4]: https://itsfoss.com/content/images/2023/02/downgrading-installed-package.png
[5]: https://itsfoss.com/prevent-package-update-ubuntu/
[0]: https://img.linux.net.cn/data/attachment/album/202302/27/115623ifb79v4pi4v0z991.jpg

View File

@ -0,0 +1,79 @@
[#]: subject: "Firefox 110 Released with GPU Sandboxing, WebGL Improvements"
[#]: via: "https://debugpointnews.com/firefox-110/"
[#]: author: "arindam https://debugpointnews.com/author/dpicubegmail-com/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15572-1.html"
Firefox 110 发布,带来 GPU 沙盒、WebGL 改进功能
======
![][1]
> Firefox 110 现在可以下载了,带来了以下新功能。
上周发布的 Firefox 110 是今年的第二个版本,现在可以通过官方发布渠道下载和升级。
这个月度版本是在 [Firefox 109][2] 版本之后发布的,后者是在 1 月份发布的。
总的来说,新的功能和错误修复很少,特别是对 Linux 来说。下面是一个快速点评。
![Firefox 110 Running in Linux][3]
### Firefox 110 的最佳新功能
对于 Windows 用户来说,这个版本有一些好消息。期待已久的安全功能 “GPU 沙盒” 现在在 Windows 中的 Firefox 中可用。从理论上讲沙盒可以隔离一个进程使其他恶意程序无法攻击或访问系统中的其他进程。有了这个功能GPU 进程会被隔离,在 Windows 中可以给你一个更安全的浏览体验。
你可以使用以下步骤检查沙盒功能。
- 从地址栏打开 `about:support`
- 在页面底部搜索(`CTRL+F`“sandbox”。
- 并验证设置。
不知道这项功能何时会到达 Linux 或 macOS。
除上述内容外,现在还可以从 Opera 和 Vivaldi 网络浏览器中导入书签、浏览历史和密码。这使那些想迁移到 Firefox 的人更加方便。
此外Firefox 浏览器现在启用了阻止第三方模块注入 Firefox 浏览器的选项。企业级大规模的 Firefox 浏览器部署得到了一个与上述阻止相一致的新策略,名为 `DisableThirdPartyModuleBlocking`。然而,它在 Firefox ESR 部署中不可用。
在 macOS、Linux 和 Windows 中进行了一些可用性改进,在按下 `CTRL` + `backspace`/`delete`或 `Cmd` + `backspace`可以清除本地化的日期时间字段。除此之外Firefox 现在在 Windows 的非英特尔 GPU 中叠加了硬件解码的视频,改善了视频播放性能和缩放质量。
这些是主要的变化,除了开发者特定的 CSS、HTML 更新,你可以在更新日志页面找到更多变化的说明(见下文)。
### 下载和更新
对于 Linux 发行版,如果你通过你的发行版的官方仓库使用 Firefox那么你应该在几天内得到这个更新。
然而,你也可以从下面的页面下载这个版本的压缩版本。对于其他下载选项,请访问我们的 [Firefox 浏览器下载指南][4]。
> **[下载 Firefox 浏览器110][5]**
祝你浏览愉快!
- [正式发布说明][6]
- [Beta110 发布说明][7]
- [开发者发布说明][8]
--------------------------------------------------------------------------------
via: https://debugpointnews.com/firefox-110/
作者:[arindam][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://debugpointnews.com/author/dpicubegmail-com/
[b]: https://github.com/lkxed/
[1]: https://debugpointnews.com/wp-content/uploads/2023/02/firefox.jpg
[2]: https://debugpointnews.com/firefox-109/
[3]: https://debugpointnews.com/wp-content/uploads/2023/02/Firefox-110-Running-in-Linux.jpg
[4]: https://www.debugpoint.com/download-firefox/
[5]: https://ftp.mozilla.org/pub/firefox/releases/110.0/
[6]: https://www.mozilla.org/en-US/firefox/110.0/releasenotes/
[7]: https://www.mozilla.org/en-US/firefox/110.0beta/releasenotes/
[8]: https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Releases/110

View File

@ -0,0 +1,66 @@
[#]: subject: "Ubuntu Flavours Decide to Stop Flatpak by Default"
[#]: via: "https://debugpointnews.com/ubuntu-flavours-flatpak/"
[#]: author: "arindam https://debugpointnews.com/author/dpicubegmail-com/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15570-1.html"
所有官方的 Ubuntu 特色版决定默认停止使用 Flatpak
======
![][1]
> Ubuntu 各特色版已同意停止使用 Flatpak 作为其操作系统的默认打包系统,而选择替代的打包管理器。
这是一个令人惊讶的举动Canonical 宣布,所有官方的 Ubuntu 特色版将不会默认支持 Flatpak。这个决定是在与所有官方 Ubuntu 特色版的团队/维护者达成一致后做出的。这一变化计划从 2023 年 4 月发布的 “Lunar Lobster” 开始,该版本将在几周后发布。
### Ubuntu 官方特色版将停止默认安装 Flatpak
基于 Ubuntu 的官方特色版Kubuntu、Lubuntu、Xubuntu 等)将不再将 Flatpak 作为其默认的打包解决方案,而选择其他方案,如 Snap 和本地 deb 格式。这样做是为了 “在尊重现有用户个性化他们自己的体验方式的同时,改善新用户开箱即用的 Ubuntu 体验”。
虽然这个决定得到了 Canonical 的支持,为了提供更好的用户体验,阻止软件包生态系统的碎片化,并给用户一个稳定的应用产品的选择。但显然,有几个问题冒了出来。
为什么是现在Flatpak 和 Snap 都已经存在多年了。Flatpak 正变得越来越流行,它作为一种包格式在积极开发和维护,一些现代功化的功能也正在开发中,比如即将出现的 “经过验证的应用程序”。而同时,由于 Snap 的 “启动时间慢”,以及被 Canonical 的封闭服务器所控制等其他原因,它在桌面应用部署领域无法得到很大普及。
Ubuntu 发行版本身从来没有默认提供过 Flatpak。但是特色版的维护者应该有选择自己的产品的自由并在 Ubuntu 基础上进行创新。这也是成为一个特色版的主要原因,而不只是一个不同的桌面环境。
### 给用户造成的困难
虽然你总是可以手动安装 Flatpak 并配置 Flathub但显然这可能会给用户带来一些问题。我相信这个公告是彻底阻止 Flatpak 安装方式的第一步。
还记得 Firefox Snap 的情况吗?要删除 Firefox Snap你必须做复杂的命令行操作才能安装 deb 版本。这些对于普通的 Ubuntu 用户来说是非常复杂的。此外,一些流行的桌面应用程序在发布后会立即推出 Flatpak 软件包。对于许多流行的 Linux 桌面应用程序来说,有时甚至没有提供 Snap 软件包。
我相信让用户来决定哪种打包格式是容易和遵循的。Canonical 应该通过解决 Snap 的核心问题、应用程序的可用性和闭门造车的性质来自行改进 Snap而不是强行做出决定。此外在为一个社区贡献的发行版推送决定之前应该与特色版维护者一起发起投票以获得来自社区的反馈。
### 结束语
如果我们曾经从历史中吸取教训的话,它永远不会以好的方式结束。也就是说,这一变化将从 2023 年 4 月 23 日 Ubuntu 23.04 “Lunar Lobster” 发布时开始。
让我用 Ubuntu 的座右铭来结束这篇文章,在这一举措之后,这听起来很奇怪:
> “Ubuntu 是一个古老的非洲语单词,意思是‘<ruby>以人道善待他人<rt>Humanity to Others</rt></ruby>’。它经常被描述为提醒我们,‘群在故我在’。我们把 Ubuntu 的精神带到了计算机和软件的世界里。Ubuntu 发行版代表了世界软件社区与世界分享的最好的东西。”
>
> —— [关于 Ubuntu][3]
新闻引自 [Joey @ OMG! Ubuntu!][4] 和 [discourse][5]。
--------------------------------------------------------------------------------
via: https://debugpointnews.com/ubuntu-flavours-flatpak/
作者:[arindam][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://debugpointnews.com/author/dpicubegmail-com/
[b]: https://github.com/lkxed/
[1]: https://debugpointnews.com/wp-content/uploads/2023/02/fpubuntu.jpg
[2]: https://debugpointnews.com/wp-content/uploads/2023/02/fpubuntu.jpg
[3]: https://ubuntu.com/about
[4]: https://www.omgubuntu.co.uk/2023/02/ubuntu-flavors-no-flatpak
[5]: https://discourse.ubuntu.com/t/ubuntu-flavor-packaging-defaults/34061

View File

@ -0,0 +1,117 @@
[#]: subject: "Flathub Plans to Evolve as the Universal Linux App Store"
[#]: via: "https://news.itsfoss.com/flathub-app-store-plans/"
[#]: author: "Sourav Rudra https://news.itsfoss.com/author/sourav/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15577-1.html"
Flathub 计划发展为通用的 Linux 应用商店
======
> Flathub 正在为全面的改变和改进做准备。以下是你需要了解的情况。
![flathub rebrand old logo vs new logo][1]
作为一个 Flatpak 仓库,[Flathub][2] 一直非常受欢迎,并且它也是 Canonical 的 [Snap Store][3] 的良好替代品。
而现在,背后支持它的 GNOME 和 KDE 等准备更进一步,启动了一个 **完全的品牌重塑和发展该平台的计划**
让我们看看 Flathub 的未来。
### Flathub 的品牌重塑
![a comparision between the old and new logos of flathub][4]
随着 GNOME 的 Jakub Steiner **带头进行的品牌重塑**Flathub 的外观和感觉都将发生改变。
他专注于使 Flathub 的新形象不至于太 “喧宾夺主”,而将重点始终放在应用程序本身。
他还提到:
> 在中性灰色的基础上建立一个品牌并不容易,但这恰恰是针对 Flathub 品牌的要点。
>
> 它为应用程序创造了闪耀的舞台Flathub 本身并不炫目,它让应用程序成为你注意力的中心。
如果你对 UI/UX 感兴趣,我建议你阅读他的 [博文][5],以更详细地了解 Flathub 的新视觉识别。
### Flathub 应用商店的发展
![Flathub beta 版门户截图][6]
[GNOME 基金会][7] 和 [KDE e.V][8] 在建立和改进 Flathub 方面一直进展良好。自 2017 年推出以来Flathub 一直在以非常惊人的速度发展着。
**发生了什么?** 在上个月的一项最新 [提案][9] 中,计划了一些值得关注的事情,重点是使 Flathub 成为一个激励其发布者的 Linux 应用生态系统。
简单来说,他们想把 Flathub 变成一个**成熟的应用商店**,让发布者可以从他们的应用中获得收益,这应该会改善资金状况。
**为什么?** 这样做的理由是;如今的这种资金障碍阻碍了潜在的开发者开发开源应用程序,这反过来又阻碍了整个开源生态系统的发展。
提案中强调的另一件事是:
> 健康的应用程序生态系统对于开源软件桌面的成功至关重要,以便最终用户可以信任并控制他们面前的设备上的数据和开发平台。
**Flathub 将如何实现这一目标?** 定期捐赠或订阅系统是该计划的主要补充之一。
🛠️ 诸如防止滥用应用程序收录的审查工具、自动安全扫描,以及一些更细微的变化都已进入计划。
此外Flathub 需要工具来防止误导性的应用名称、描述、屏幕截图等出现在平台上,并阻止它们,直到它们被审查,以保证被检查过。
总的来说,总结一下,以下是你可以期待的事情:
- 定期捐款系统或订阅系统
- 付费的应用程序
- 改进 Flathub 的应用审查流程和监测更新变化的内部工具
你可能会发现一些实施方案已经出现在 [Flathub 的测试门户][10],比如 [新的应用程序验证系统][11]。
此外,他们打算建立一个新的法律实体 **Flathub LLC**,来拥有和运营这项服务。
他们旨在通过它建立以下内容:
> 透明的治理流程以维护社区信任和问责制,并建立一个咨询委员会/赞助流程以在我们的拨款申请的同时吸引商业赞助。
💸 **现在你可能在想,他们预算如何?**
该提案提到,**未来一年的总预算为 20 万美元**。
其中包括 12 万美元的员工工资,以及 3 万美元的法律、专业和管理费用,最后 5 万美元用于平台的开发。
他们已经有 5 万美元用于前一阶段的开发,另外还有 10 万美元已经确认,所需预算的 50% 已经有了。
剩余的 10 万美元已经从 [Plaintext Group][12] 寻求,该集团是由 **谷歌前 CEO 埃里克·施密特** 创立的 Schmidt Futures 的一部分。
### 总结
好吧,我必须说这是一个非常值得关注的举措。
Flathub 已经受到了各类 Linux 用户的欢迎。因此,推动有助于资助该项目的功能,将 Flathub 变成一个丰富的应用生态系统,**有望成为桌面用户的通用 Linux 应用平台**。
💬 可能这就是 Linux 桌面用户所需要的。你怎么看?请在下面的评论中分享你的想法。
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/flathub-app-store-plans/
作者:[Sourav Rudra][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/sourav/
[b]: https://github.com/lkxed/
[1]: https://news.itsfoss.com/content/images/size/w1304/2023/02/flathub-rebrand.png
[2]: https://flathub.org
[3]: https://snapcraft.io/store
[4]: https://news.itsfoss.com/content/images/2023/02/Flathub_Old_New_Logos.jpg
[5]: https://blog.jimmac.eu/2023/flathub-brand-refresh/
[6]: https://news.itsfoss.com/content/images/2023/02/flathub-beta.jpg
[7]: https://foundation.gnome.org
[8]: https://ev.kde.org
[9]: https://github.com/PlaintextGroup/oss-virtual-incubator/blob/main/proposals/flathub-linux-app-store.md
[10]: https://beta.flathub.org/en-GB
[11]: https://news.itsfoss.com/verified-flatpak-apps/
[12]: https://www.plaintextgroup.com

View File

@ -0,0 +1,126 @@
[#]: subject: "5 escape sequences for your Linux shell"
[#]: via: "https://opensource.com/article/23/2/escape-sequences-linux-shell"
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: "zepoch"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15598-1.html"
5 个有用的 Linux Shell 转义序列
======
![][0]
> 如何在你的 Bash 终端使用这些秘密代码,请下载我们新的 Linux 元字符速查表。
我最近在读一篇 Don watkins [关于 Shell 元字符的文章][1]。他的文章让我想到了你可以用 shell 输入做的所有的奇怪事情。虽然我可能还没有发现极端的情况,但是我经常发现 shell 转义序列,比如 `\b`、`\t` 和 `\f` 非常有用。
转义序列是一种特殊类型的终端输入。它们旨在让你能够输入物理键盘上没有的字符或触发事件。下面是我最喜欢的 Bash shell 的转义序列。
### 1、退格符
你可以在命令中输入若干退格符,以便在命令执行时触发。例如这个命令,你可能会认为它的输出是`ab`,但是看一下真正的输出:
```
$ echo a$'\b'b
b
```
从技术上来说Shell 确实输出了 `ab`(你可以通过在命令后面附加 `| wc -m` 来确认这一点),但是全部输出的一部分是 `\b` 退格事件。退格键在输出 `b` 字符之前删除了 `a` 字符,因此输出只有 `b` 字符。
### 2、换行符
换行符是一个让你的 Shell 转到下一行的第 0 列的信号。这一点很重要,当使用像 [printf][2] 这样的命令时,它不会像 `echo` 那样在输出的末尾自动添加换行符。看看不带 `\n` 换行符的 `printf` 语句和带换行符的 `printf` 语句之间的区别:
```
$ printf "%03d.txt" 1
001.txt$
$ printf "%03d.txt\n" 1
001.txt
$
```
### 3、换页符
`\f` 换页信号就像换行符,但是却并不是返回到第 0 列。下面是一个使用换页符而不是换行符的 `printf` 命令:
```
$ printf "%s\f" hello
hello
$
```
你的 Shell 提示符出现在下一行,但不是在下一行的行首。
### 4、制表符
有两种制表符转义序列:水平制表符 `\t` 和垂直制表符 `\v`。水平制表符如下所示:
```
$ echo a$'\t'b
a b
```
理论上,垂直制表符是相同的原理,但是在垂直空间中。然而,在大多数控制台上,一行的垂直间距是不可变的,所以它通常看起来很像一个换页符:
```
$ echo a$'\v'b
a
b
```
### 5、Unicode
Unicode 标准中有很多可用的字符,而你的键盘只有大约 100 个键。在 Linux 上有几种方法可以输入 [特殊字符][3],但是将它们输入到终端的一种方法是使用 Unicode 转义序列。这个转义序列以 `\u` 开头,后跟一个十六进制值。你可以在文件 `/usr/share/X11/locale/en_US.UTF-8/Compose` 中找到许多 Unicode 值。你也可以在 [https://www.Unicode.org/charts/][4] 查看 Unicode 规范。
这对于输入像圆周率 π(圆的周长与直径之比)等常见符号非常有用:
```
$ echo $'\u03C0'
π
```
还有许多其他的符号和字符:
```
$ echo $'\u270B'
$ echo $'\u2658'
$ echo $'\u2B67'
```
有盲文符号、音乐符号、字母、电气符号、数学符号、表情符号、游戏符号等等。事实上,有如此多的可用符号,有时你需要 `\U`注意大写字母Unicode 转义序列来访问高区的 Unicode。例如这张红心 5 的扑克牌只出现在 `\U` 转义序列中:
```
$ echo $'\U1F0B5'
🂵
```
浏览一下 Unicode 规范,找到适合你的位置,并使用 `\u``\U` 来访问你需要的所有特殊符号。
### 除此之外
Bash Shell 的手册页中列出了 18 个转义序列我发现其中一些更有用。我已经在本文中介绍了我最爱的几个Don Watkins 也谈到了他在文章中最常用的元字符,但是还有更多待发现。有很多方法可以对字母和数字、子 Shell、数学方程等进行编码。为了更好地了解 Shell 可用的元字符,可以下载我们的 [元字符速查表][5],你可以在使用计算机上最强大的应用程序 —— Linux 终端时将它放在手边。
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/escape-sequences-linux-shell
作者:[Seth Kenlon][a]
选题:[lkxed][b]
译者:[zepoch](https://github.com/zepoch)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://opensource.com/users/seth
[b]: https://github.com/lkxed/
[1]: https://opensource.com/article/22/2/metacharacters-linux
[2]: https://opensource.com/article/20/8/printf
[3]: https://opensource.com/article/22/7/linux-compose-key-cheat-sheet
[4]: https://www.unicode.org/charts/
[5]: https://opensource.com/downloads/linux-metacharacters-cheat-sheet
[0]: https://img.linux.net.cn/data/attachment/album/202303/05/134703ne9559n9rmrer6ee.jpg

View File

@ -0,0 +1,139 @@
[#]: subject: "Making Directories in Linux Terminal"
[#]: via: "https://itsfoss.com/make-directories/"
[#]: author: "Abhishek Prakash https://itsfoss.com/author/abhishek/"
[#]: collector: "lkxed"
[#]: translator: "geekpi"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15595-1.html"
终端基础:在 Linux 终端中创建目录
======
![][0]
在终端基础系列的 [上一章][1] 中,你学到了在 Linux 命令行中改变文件夹的知识。
我在最后给出了一个练习,简单地提到了创建目录。
在本系列的这一部分,我将讨论如何使用 `mkdir` 命令在 Linux 命令行中建立新的文件夹。
```
mkdir dir_name
```
`mkdir` 是 “<ruby>创建目录<rt>make directories</rt></ruby>” 的简称。让我们来看看这个命令的使用情况。
> 📋 如果你不知道,文件夹在 Linux 中被称为目录。
### 在 Linux 中创建一个新目录
你现在应该已经熟悉了 [Linux 中绝对路径和相对路径的概念][2]。如果没有,请参考 [本教程](https://linuxhandbook.com/absolute-vs-relative-path/)。
如果你的系统还没有打开终端,请打开它。通常情况下,你从主目录(`/home/username`)开始。但为了本教程和回忆一些事情,我假定你不在你的主目录中。
所以,先换到你的主目录:
```
cd
```
是的,如果你简单地输入 `cd`,没有任何选项和参数,它就会把你带到你的主目录。你也可以使用 `cd ~` 等方法。
在这里,建立一个新的目录,叫做 `practice`
```
mkdir practice
```
你能切换到这个新建立的 `practice` 目录吗?
```
cd practice
```
很好!现在你有了一个专门的文件夹,你将在这里练习本系列中的 Linux 命令行教程。
![Example of making new directory in Linux][5]
### 创建多个新目录
你刚刚创建了一个新的目录。如果你要创建不止一个呢?比方说,有三个。
你可以对每个目录连续使用三次 `mkdir` 命令。这将会起作用。然而,这并不是真的需要。你可以像这样同时创建多个目录来节省时间和精力:
```
mkdir dir1 dir2 dir3
```
请继续这样做吧。你可以列出 `practice` 目录的内容,查看所有新创建的目录。以后会有更多关于 `ls` 命令的内容。
![Create multiple new directories in Linux with mkdir command][6]
> 💡 你不能在同一地方有两个同名的文件夹或文件。
### 创建多个嵌套的子目录
你现在知道了一次创建多个目录的方法。
但是,如果你要创建一个嵌套的目录结构呢?比方说,你需要在 `dir1` 里面的 `subdir1` 里面创建一个目录 `subdir2`
```
dir1/subdir1/subdir2
```
这里的问题是 `subdir1` 并不存在。所以如果你尝试 `mkdir dir1/subdir1/subdir32`,你会得到一个错误:
```
abhishek@itsfoss:~/practice$ mkdir dir1/subdir1/subdir2
mkdir: cannot create directory dir1/subdir1/subdir2: No such file or directory
```
如果你不知道的话,你会选择 `mkdir dir1/subdir1`,然后运行 `mkdir dir1/subdir2`。这将会起作用。然而,有一个更好的方法。
你使用 `-p` 选项,它会在需要时创建父目录。如果你运行下面的命令:
```
mkdir -p dir1/subdir1/subdir2
```
它将创建 `subdir1`,然后在 `subdir1` 里面创建 `subdir2`
> 💡 不是命名惯例,但最好在文件和目录名中避免空格。使用下划线或破折号代替,因为处理文件/目录名中的空格需要额外精力。
### 测试你的知识
这是一个相当简短的教程,因为 `mkdir` 命令只有几个选项。
现在,让我给你一些实践练习,以利用你先前创建的 `practice` 目录。
- 不进入 `dir2` 目录,在其中创建两个新的子目录。
- 不进入 `dir3` 目录,创建两级嵌套子目录(`subdir1/subdir2`
- 进入 dir2 目录。在这里,在你的主目录下创建一个名为 `temp_stuff` 的目录。不要担心,我们将在本系列教程的后面删除它。
- 回到父目录 `practice`,尝试创建一个名为 `dir3` 的目录。你看到一个错误。你能用 `-p` 选项使它消失吗?
你可以 [在社区论坛讨论这个练习][7]。
在终端基础系列的下一章中,你将学习如何用 `ls` 命令列出一个目录的内容。
如果你有问题或建议,请告诉我。
--------------------------------------------------------------------------------
via: https://itsfoss.com/make-directories/
作者:[Abhishek Prakash][a]
选题:[lkxed][b]
译者:[geekpi](https://github.com/geekpi)
校对:[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/lkxed/
[1]: https://itsfoss.com/change-directories/
[2]: https://linuxhandbook.com/absolute-vs-relative-path/
[5]: https://itsfoss.com/content/images/2023/02/make-directory-example.svg
[6]: https://itsfoss.com/content/images/2023/02/create-multiple-directories-linux.png
[7]: https://itsfoss.community/t/exercise-in-making-directories-in-linux-terminal/10227
[0]: https://img.linux.net.cn/data/attachment/album/202303/04/091337bqrrn0nqq0njzbxg.jpg

View File

@ -0,0 +1,91 @@
[#]: subject: "Linux is Just a Kernel: What Does it Mean?"
[#]: via: "https://itsfoss.com/linux-kernel-os/"
[#]: author: "Abhishek Prakash https://itsfoss.com/author/abhishek/"
[#]: collector: "lkxed"
[#]: translator: "Cubik65536"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15594-1.html"
Linux 只是一个内核:这是什么意思?
======
![][0]
> 这是一个困扰 Linux 用户的常见问题。这也是考试和面试中经常问到的一个问题。下面是你需要了解的所有内容。
你可能在网络上的各种论坛以及讨论区听过这句话:
> Linux 只是一个内核。
这让你感到好奇。它是个内核?还是个操作系统?两者之间有什么区别?
我将在本文中回答这些问题。
### Linux 是操作系统还是内核?
好吧,**从技术上讲Linux 只是一个内核**,而不是一个操作系统。但是,术语 “Linux” 通常是指一个完整的操作系统,它包括一个 <ruby>交互界面<rt>Shell</rt></ruby>例如bash和命令行和/或 GUI 工具来控制系统。这个完整的操作系统的正确叫法是 “Linux 发行版”。流行的 Linux 发行版有 Ubuntu、Red Hat 和 Debian。
早在 1991 年Linus Torvalds 创建的只是一个内核。直到今天,他也在为 Linux 内核工作。他不再编写代码,而是监督哪些代码进入内核。
### 内核?什么东西?
内核是每个操作系统的中心。不仅仅是 LinuxWindows 和 macOS 也有内核。
将内核想象成操作系统的心脏。没有心脏,你就无法生存。没有内核,操作系统就无法存在。
但是,就像心脏需要一个身体来生存一样,内核需要其他人们可以在计算机上使用的程序和工具来构成一个完整的操作系统。
这是一个操作系统的典型架构:
![][1]
在中心的内核与硬件交互。在它之上是与内核交互的 <ruby>交互界面<rt>Shell</rt></ruby>。然后你有应用程序、命令行和图形界面,为你提供使用系统的各种方式。
### 内核是引擎,操作系统是汽车
一个更好的类比是将内核想象成汽车的引擎,而操作系统则是汽车。
你不可能驾驶一个引擎,但是如果没有引擎,你也不能驾驶一辆汽车。你需要轮胎、转向机和其他组件才能将其变成一辆可以驾驶的汽车。
相似地,你不能直接使用内核。你需要 <ruby>交互界面<rt>Shell</rt></ruby>,其他工具和组件才能使用操作系统。
![][2]
### Linux 对比 GNU/Linux
在类似的地方,你也会看到例如 “Linux 只是一个内核,[你所说的 Linux 实际上是 GNU/Linux][5]” 的陈述。
在 Linus Torvalds 在 1991 年创建 Linux 之前Richard Stallman 就创建了<ruby>自由软件运动<rt>Free Software movement</rt></ruby>和 GNU 项目。GNU 项目包括对流行的 UNIX 工具和命令的重新实现,例如 `ls`、`grep`、`sed` 等。
通常,你的 Linux 发行版会在 Linux 内核之上包含所有这些 GNU 工具。
这就是为什么纯粹主义者坚持称之为 GNU/Linux以便人们不要忘记 GNU 对 Linux 成功的贡献和重要性。
### 最后……
**所以,如果你在面试或者考试中被问到这个问题,回答 “Linux 是一个内核,而不是一个操作系统”。这是你的老师或面试官在大多数情况下想要的答案。**
但是更深入一点,理解内核和操作系统之间的区别。
如果有人说:“我使用 Linux”你就会明白这个人是指 Linux 发行版,而不仅仅是内核。诚然,没有必要用 “Linux 只是一个内核,而不是一个操作系统” 来纠正别人。
--------------------------------------------------------------------------------
via: https://itsfoss.com/linux-kernel-os/
作者:[Abhishek Prakash][a]
选题:[lkxed][b]
译者:[Cubik65536](https://github.com/Cubik65536)
校对:[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/lkxed/
[1]: https://itsfoss.com/content/images/2023/02/image-6.png
[2]: https://itsfoss.com/content/images/2023/02/image-7.png
[3]: https://itsfoss.com/content/images/size/w256h256/2022/12/android-chrome-192x192.png
[4]: https://itsfoss.com/content/images/wordpress/2020/03/too-many-linux-choices.png
[5]: https://itsfoss.com/gnu-linux-copypasta/
[0]: https://img.linux.net.cn/data/attachment/album/202303/04/085224mw1qoq5kaukqzxmz.jpg

View File

@ -0,0 +1,59 @@
[#]: subject: "Ubuntu Plans for Mini ISO Images for Minimal Desktop Workloads"
[#]: via: "https://debugpointnews.com/ubuntu-mini-iso-announcement/"
[#]: author: "arindam https://debugpointnews.com/author/dpicubegmail-com/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15588-1.html"
Ubuntu 计划为精简桌面环境提供 ISO 镜像
======
![][1]
> Canonical 正在为 Ubuntu 23.04 “Lunar Lobster” 开发一个新的精简 Ubuntu ISO 镜像。
在回答一位 Ubuntu 用户提出的关于精简 Ubuntu ISO 镜像的可能性的问题时,开发者确认正在开发一个官方的精简 ISO 镜像(小于 200MB。上述工作已经在进行中并取得了很大的进展。计划为即将发布的 Ubuntu 23.04 “Lunar Lobster” 引入一个替代性的精简安装程序。
### Ubuntu 桌面的精简 ISO 镜像
Canonical/Ubuntu 从未正式支持过任何精简 ISO 镜像。在 Ubuntu 18.04 时代,遗留有一些非官方的 Ubuntu 精简 ISO 镜像,但它们都已经停产了。考虑到 Ubuntu Linux 的受欢迎程度,没有提供精简安装程序对一些人来说是个问题。
虽然有 Ubuntu 服务器镜像和 [云镜像][2],但它们对于你的桌面使用情况来说,设置起来有点复杂。
例如,如果你想创建一个只有 GNOME 会话和基本功能的精简 Ubuntu 桌面,而不使用官方桌面安装程序,你只有一个选择:你需要安装 Ubuntu 服务器版作为基础,然后开始建立一个没有服务器组件的桌面。
虽然Debian 已经提供了精简 ISO即 netinst它很容易使用并且可以在任何程度上进行定制。但是有一个类似于官方 Ubuntu 桌面定制版是一个好主意,可以根据需要建立你的系统(没有 Snap 或其他项目)。
根据邮件列表中的对话ubuntu-mini-iso 的大小为 140MB它需要通过网络下载几个软件包。它将提示你要下载的菜单项目。我猜它将类似于 Ubuntu 服务器版的菜单。
![Ubuntu server install menu][3]
同样Ubuntu 的所有官方版本都可能有一个精简版本。然而我不确定当你包括一个桌面环境时它将如何精简。Xubuntu 的开发者 Sean Davis [宣布][4],一个精简版的 Xubuntu 镜像已经在开发中,并且可以作为 [日常构建版][5] 下载。
所以,总的来说,这是 Canonical 的一个令人兴奋的举动。如果一切顺利的话,你实际上可以使用这个 ISO 构建你自己的 Ubuntu。你可以只添加 GNOME 桌面、删除 Snap、从 Debian 软件库中安装 Firefox并添加任何你想要的软件包。这将是一个不错的精简版 Ubuntu 桌面。
Ubuntu 23.04 BETA 计划于 2023 年 3 月 30 日发布;最终版本预计于 2023 年 4 月 20 日发布。那时候你就可以试试 minimal-ubuntu-iso 了。
参考自 [邮件列表][6]。
--------------------------------------------------------------------------------
via: https://debugpointnews.com/ubuntu-mini-iso-announcement/
作者:[arindam][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://debugpointnews.com/author/dpicubegmail-com/
[b]: https://github.com/lkxed/
[1]: https://debugpointnews.com/wp-content/uploads/2023/02/min-iso1.jpg
[2]: https://cloud-images.ubuntu.com/minimal/releases/kinetic/release-20221022/
[3]: https://debugpointnews.com/wp-content/uploads/2023/02/Ubuntu-server-install-menu.jpg
[4]: https://floss.social/@bluesabre/109939104067417830
[5]: https://cdimage.ubuntu.com/xubuntu/daily-live/current/
[6]: https://lists.ubuntu.com/archives/ubuntu-devel/2023-February/042490.html

View File

@ -0,0 +1,100 @@
[#]: subject: "FFmpeg 6.0 Released with WBMP and Radiance HDR Image Support"
[#]: via: "https://debugpointnews.com/ffmpeg-6-0/"
[#]: author: "arindam https://debugpointnews.com/author/dpicubegmail-com/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15597-1.html"
FFmpeg 6.0 发布:支持 WBMP 和 Radiance HDR 图像
======
![][0]
> 开源多媒体框架 FFmpeg 6.0 现已发布,带来了更新和改进。
流行的开源多媒体框架 FFmpeg 6.0 现已发布。这个主要的版本现在已可下载,并在多媒体项目中使用。其亮点变化包括两个新的图像格式支持,许多编解码器和其他增强功能。
下面是一个快速回顾。
### FFmpeg 6.0 新增内容
#### 主要变化
这个版本的主要亮点是对两种新图像格式的支持。[Radiance HDR 图像][2]RGBE为用户在图像处理中提供了更好的色彩深度和动态范围。FFmpeg 6.0 现在包括对 [WBMP无线应用协议位图][3] 图像格式的支持,这在移动设备和网络应用中是常用的图像格式。
在 FFmpeg 6.0 中,新的 `-shortest_buf_duration` 选项允许用户为音频和视频缓冲区设置一个最小的持续时间,这可以确保在输出文件中使用最短的缓冲区时间。
从 FFmpeg 6.0 开始,线程必须被内置到软件中才能运行。在这个版本中,每个复用器都在一个单独的线程中运行。这提高了性能,使同时处理多个流的效率更高。
FFmpeg 6.0 中的 `cropdetect`(裁剪检测)过滤器现在包括一个新的模式,可以根据运动向量和边缘检测裁剪区域,为用户提供更精确的视频裁剪控制。
#### 过滤器
在这个版本中,大量的过滤器得到了更新,这将通过新的功能简化你的多媒体项目和工作流程。下面是一个快速的变化列表:
- `ddagrab` 过滤器现在支持桌面复制视频捕获,允许用户直接从他们的桌面上捕获视频。
- `a3dscope` 过滤器为用户提供了音频信号的 3D 范围显示,允许更精确的音频编辑和处理。
- `backgroundkey` 过滤器允许用户删除或替换视频片段中的背景,为视频编辑提供更大的灵活性。
- `showcwt` 多媒体过滤器允许用户将连续小波变换系数可视化,提供对信号和图像处理的洞察力。
- `corr` 视频过滤器对视频帧进行二维交叉关联,提供更精确的运动估计和稳定。
- `ssim360` 视频过滤器计算两个视频帧之间的 [结构相似度指数SSIM][4],为衡量 360 度视频的视频质量提供了一个指标。
#### 编解码器
在这个版本中,编解码器的更新是非常多的。
首先FFmpeg 6.0 现在支持 NVENC AV1 编码允许用户使用英伟达最新的压缩技术对视频进行编码。MediaCodec 解码器现在支持 NDKMediaCodec为安卓设备提供更好的兼容性。其次增加了一个新的 MediaCodec 编码器,允许在安卓设备上进行视频编码时进行硬件加速。
在此基础上,该版本包括了对 QSV快速同步视频的 oneVPL 支持,在英特尔 CPU 上进行视频编码时提供了更好的性能和质量。QSV AV1 编码器允许用户在英特尔 CPU 上使用硬件加速对 AV1 视频进行编码。
这个版本引入了对 10/12 位 422、10/12 位 444 HEVC 和 VP9 的 QSV 编解码支持为用户提供更好的视频质量和性能。WADY DPCM 解码器和解复用器允许用户使用 WADY DPCM差分脉冲编码调制格式对音频进行解码和解复用这种格式通常用于视频游戏配乐。
此外,现在还有一个 CBD2 DPCM 解码器,它允许用户使用 CBD2共轭结构代数编码簿差分脉冲编码调制格式解码音频。这种格式通常用于电信和语音编码应用。
#### 其他变化
这个变化清单很庞大,其中还包括 FFmpeg 程序的新 CLI 选项和其他错误修复。你可以在 GitHub 上阅读详细的 [变更日志][5]。
### 下载和安装
对于 Debian、Ubuntu 和相关的发行版,这个版本应该在几天内到达。请在 [Debian 跟踪页][6] 中留意。
对于 Fedora、RHEL、CentOS你可以通过 RPM Fusion 仓库获得这个版本。如果你已经设置了 RPM Fusion请更新你的系统以获得它。
源代码和其他下载都可以在 [这里][6] 下载。
另外你可以在这里查看我们的独家文章中如何安装FFmpeg和基本使用方法。
> **[如何在 Ubuntu 和其他 Linux 中安装 FFmpeg][7]**
### 总结
有了 Radiance HDR 图像支持等新功能以及对各种编解码的改进支持FFmpeg 6.0 为用户提供了强大的音频和视频处理工具。
新的过滤器变化提供了先进的音频和视频处理能力,从去除或替换视频中的背景到执行运动估计和稳定。
总的来说,这是一个重要的里程碑式的更新,为音频和视频处理工作负载提供了更好的性能和更大的灵活性。
--------------------------------------------------------------------------------
via: https://debugpointnews.com/ffmpeg-6-0/
作者:[arindam][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://debugpointnews.com/author/dpicubegmail-com/
[b]: https://github.com/lkxed/
[1]: https://debugpointnews.com/wp-content/uploads/2023/03/ffmpeg-head.jpg
[2]: https://en.wikipedia.org/wiki/RGBE_image_format
[3]: https://en.wikipedia.org/wiki/Wireless_Application_Protocol_Bitmap_Format
[4]: https://en.wikipedia.org/wiki/Structural_similarity
[5]: https://github.com/FFmpeg/FFmpeg/blob/master/Changelog
[6]: https://ffmpeg.org/download.html
[7]: https://www.debugpoint.com/install-ffmpeg-ubuntu/
[0]: https://img.linux.net.cn/data/attachment/album/202303/05/101412oh8heamj44mo72k8.jpg

View File

@ -0,0 +1,199 @@
[#]: subject: "Top 5 Best Arch Linux Distros For Everyone"
[#]: via: "https://www.debugpoint.com/best-arch-linux-distros/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: "wxy"
[#]: reviewer: "wxy"
[#]: publisher: "wxy"
[#]: url: "https://linux.cn/article-15600-1.html"
5 个最好的 Arch Linux 衍生发行版,适合所有人
======
> 我们点评了 2023 年最好的 Arch Linux 发行版,并探讨了它们的关键亮点,以便在你为工作流程选择它们之前加以考虑。
![][0]
如果你是一个寻找强大而灵活的操作系统的 Linux 爱好者,那么 Arch Linux 是值得考虑的。Arch Linux 以其灵活性、定制化选项和极简设计而闻名。
它是那些喜欢 DIY想从头开始构建自己的系统的 Linux 爱好者的热门选择。开发人员、程序员和游戏玩家经常选择 Arch Linux因为它采用滚动发布模式确保可以获得最新的应用程序和模块。
然而,设置 Arch Linux 可能令人生畏,特别是对初学者来说。这就是为什么有几个基于 Arch Linux 的发行版,它们旨在使安装和设置过程更容易,更方便用户使用。
与基于 Debian 的发行版相比,基于 Arch Linux 的发行版并不多。
**但是,你如何决定哪一个最适合你呢?**
好吧,你可以考虑几个在一般的使用情况下的常见因素。有几个标准可以列举如下:
- 安装的简易性(独立系统或双引导)
- 用户友好性
- 自定义选项
- 预先配置的软件包
- 常规维护
- 专业的硬件支持
- 社区帮助
在这份最佳 Arch Linux 衍生发行版清单中,我们探讨了现有的最佳发行版,看看它们如何满足普通用户的上述要点。
### 5 个最好的 Arch Linux 衍生发行版,适合所有人
#### EndeavourOS
EndeavourOS 是一个基于 Arch Linux 的轻量级和用户友好的发行版,旨在提供一个无忧的 Arch Linux 体验。它带有预装的桌面环境和预配置的软件包,让人很容易开始上手 Arch Linux。
它是三年前新推出的 Arch Linux 衍生发行版之一。由于它对 Arch Linux 用户体验的独特处理方式,在很短的时间内它就变得很受欢迎。
![EndeavourOS Cassini 桌面Xfce 4.18][2]
目前它被推荐为这个列表中第一的原因是:
- 它使用了一个 **友好的 Calamares 安装程序**,对于双启动或独立系统来说,效果非常好。
- 提供了 **专门的硬件支持**,如英伟达驱动程序和 ARM 镜像。
- EndeavourOS 的 **社区帮助** 非常棒,在 Telegram 频道和论坛的响应更快。
- 初次使用的用户可以通过友好的点击式操作来管理和更新 Arch Linux 系统。
- 它配备了 **现代的桌面环境**,如 Xfce、KDE Plasma、GNOME 和一些窗口管理器。
- 经验丰富的技术团队,以 **坚实的目标** 提供最好的 Arch Linux 发行版体验。
使用下面的下载链接试试吧。如果你想进一步探索,我们还有 [安装指南][3] 和 [Endeavour OS 评测][4]。
> **[下载 EndeavourOS][5]**
#### Manjaro Linux
本列表中的第二个发行版是 Manjaro Linux它是另一个优秀的 Arch Linux 衍生发行版,并且经过了时间的考验。这个发行版的主要目标是通过提供开箱即用的功能,使无论是初学者还是高级用户都能享受到 Arch Linux。
![Manjaro 21.0 Ornara 桌面Xfce][6]
以下是 Manjaro Linux 的一些主要特点和优势,这些特点和优势使它成为每个人的完美 Arch Linux 衍生发行版。
- **用户友好的界面和桌面环境**Manjaro Linux 带有 Xfce、KDE Plasma、GNOME、Budgie、Cinnamon 和 MATE 等桌面产品提供的简单易用的界面。此外,你也可以使用 i3 和 Sway 窗口管理器的定制版。
- **稳定性和 AUR 支持**Majaro 会在 Arch Linux 进行重大更新的几天内得到更新。此外,它还设置了一个 Arch 用户库AUR提供大量的软件集合。
- **桌面管理**:配备了 Pamac 软件管理器,可以轻松通过 GUI 进行软件和软件包的安装。
- **安装**Calamares 安装程序使在双启动或独立系统中的安装变得简单。此外,你可以购买带有 Manjaro 的 OEM 笔记本电脑,这些笔记本电脑也带有 Docker 镜像!
- **社区支持**:在本列表中的所有 Arch Linux 衍生发行版中Manjaro 的使用率很高所以你可以在网上获得大量的问题解决方案。此外Manjaro 论坛的支持也很好。
你可以使用下面的链接下载 Manjaro Linux。要进一步探索请阅读我们最近发表的 [Manjaro Linux 测评][7]。
> **[下载 Manjaro][8]**
#### Garuda Linux
本列表中的第三个 Arch 发行版是 Garuda Linux它主要针对那些希望使用 Arch 发行版进行游戏的用户。不过,你也可以把它用于其他用途。
它配备了几乎所有流行的桌面和窗口管理器,如 KDE、Xfce、GNOME、LXQt-win、Cinnamon、Mate、Wayfire、Qtile、i3wm 和 Sway。因此你的选择很广泛。
Garuda Linux 提供最好的特性之一是默认的 BTRFS 文件系统和 Zstd 压缩,可以让你的现代高端硬件有更好的性能。
![Garuda Linux 桌面2022][9]
下面是一些使其脱颖而出的主要特点和优势:
- 为在 Arch Linux 进行游戏做好了准备。
- 通过 GameMode 和 Gamemode-Tools 对 Steam 和 Lutris 提供了内置支持。
- 可以选用所有主要桌面和窗口管理器。
- 自定义主题和图标,看起来非常漂亮。
- 大量的预编译软件包,包括流行的 Chaotic-Aur。
> **[下载 Garuda Linux][10]**
#### ArcoLinux
ArcoLinux 是一个基于 Arch Linux 的用户友好型的高级发行版,它带有预装的桌面环境和一套预配置的软件包。它还包括一些工具和脚本,可以使 Arch Linux 的使用体验更加友好。
![ArcoLinux 桌面][11]
ArcoLinux 与本列表中的所有发行版有些不同。它有四个不同的产品,它们是:
- ArcoLinux XL旗舰版本具有完整的软件包带有 Xfce。
- ArcoLinux XS带有主线、LTS、Xanmod 和 Zen 等四种可选内核的极简变体,带有 Xfce。
- ArcoLinuxD极简变体没有桌面或软件包需要你自己安装。
- ArcoLinuxB极简变体可以选择你的桌面和精简的软件。
正如你所看到的,它的设计相当独特。此外,如果你是 Arch Linux 的爱好者,你可以试试 ArcoLinux这对你来说将是一个很好的学习经验。
该团队还提供了 1000 多个关于 ArcoLinux 的各种指南视频。请到下面的链接进行下载。另外,如果你想了解更多关于各种产品的信息,请访问 [此页面][12]。
> **[下载 ArcoLinux][13]**
#### ArchLabs Linux
还记得 BunsenLabs Linux 吗ArchLabs Linux 旨在成为具有 BunsenLabs Linux 外观的极简 Arch Linux 发行版。
它具有 dk 窗口管理器、tint2 面板和各种预装的应用程序旨在提供一个简单而高效的桌面环境。ArchLabs Linux 是高度可定制的,并提供了各种工具和脚本,使用户能够轻松地配置和个性化他们的系统。
![极简的 ArchLabs Linux][14]
它是那些希望获得 Arch Linux 的灵活性和滚动发布更新的好处,但又喜欢更多用户友好和预先配置的桌面环境的用户的热门选择。
对于每个喜欢极简主义和窗口管理器的人来说Arch Linux 是一个完美的发行版。
> **[下载ArchLabs Linux][15]**
### 还有几个 Arch Linux 发行版
所以,上面这些是我们认为最好的五个。然而,还有一些 Arch Linux 衍生发行版也同样优秀,但与上述名单相比,使用量可能较少。
以下是其中的一些,以及为什么它们同样是最好的。
**[Mabox Linux][16]**:它是一个用户友好的、基于 Manjaro Linux 的轻量级 Linux 发行版。它的特点是 Openbox 窗口管理器,这是一个简单而高效的桌面环境,可以根据用户的喜好进行定制。
**[Archcraft Linux][17]**:它是一个基于 Arch Linux 的极简 Linux 发行版。它使用窗口管理器和轻量级应用程序这使得它的速度超快。它预先配置了各种设置为你提供了最好的开箱即用的窗口管理器体验。Archcraft Linux 使用 Calamares 系统安装程序进行安装,并包括 yay 软件包管理器,以方便从 Arch 用户资源库AUR中获取软件。
**[Bluestar Linux][18]**:它是一个使用 Arch Linux 作为基础的 Linux 发行版。它的目标是提供一个坚实的操作系统,在不影响美观的情况下,具有广泛的功能和易用性。
### 其他新发行版
此外,最近还推出了一些 Arch Linux 发行版,为 Arch Linux 提供了不同的使用方式。这些都试图在各种因素上做到独一无二。下面是其中的一些,以及它们的主要区别特征。你可能想看看它们,进一步探索基于 Arch Linux 的发行版。
- [XeroLinux][19](拥有惊人的外观)
- [Exodia OS][20](基于 BSPWM 的 Arch Linux
- [Crystal Linux][21](完美结合了 GNOME 和 Arch Linux
- [Hefftor Linux][22](基于 Xfce 和 Plasma 的时尚发行版)
### 总结
总之Arch Linux 是一个高度可定制和灵活的发行版,许多资深的 Linux 用户都很喜欢。
无论你的需求或工作流程是什么,你都可以尝试这个列表中的东西。在有疑问时,可以尝试本列表中前三个发行版中的任何一个。
虽然对初学者来说可能会有畏难情绪,但这些 Arch Linux 发行版旨在提供更友好的用户体验,而不牺牲使 Arch Linux 如此受欢迎的灵活性和定制选项。
我希望你能找到令你感到舒适的 Arch Linux 发行版,能够满足你的需求。
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/best-arch-linux-distros/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[wxy](https://github.com/wxy)
校对:[wxy](https://github.com/wxy)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed/
[1]: https://www.debugpoint.com/wp-content/uploads/2023/03/arch-head2.jpg
[2]: https://www.debugpoint.com/wp-content/uploads/2022/12/EndeavourOS-22Cassini22-Desktop-with-Xfce-4.18.jpg
[3]: https://www.debugpoint.com/endeavouros-install-guide/
[4]: https://www.debugpoint.com/web-stories/endeavouros-review/
[5]: https://endeavouros.com/download/
[6]: https://www.debugpoint.com/wp-content/uploads/2021/03/Manjaro-21.0-Ornara-Desktop-Xfce.jpg
[7]: https://www.debugpoint.com/manjaro-linux-review-2022/
[8]: https://manjaro.org/download/
[9]: https://www.debugpoint.com/wp-content/uploads/2022/05/Garuda-Linux-Desktop-2022.jpg
[10]: https://garudalinux.org/downloads.html
[11]: https://www.debugpoint.com/wp-content/uploads/2023/03/ArcoLinux-desktop.jpg
[12]: https://www.arcolinux.info/arcolinux-editions/
[13]: https://www.arcolinux.info/downloads/
[14]: https://www.debugpoint.com/wp-content/uploads/2023/03/Minimal-ArchLabs-Linux.jpg
[15]: https://archlabslinux.com/get/
[16]: https://www.debugpoint.com/mabox-linux-2022/
[17]: https://www.debugpoint.com/archcraft-os-review/
[18]: https://sourceforge.net/projects/bluestarlinux/
[19]: https://www.debugpoint.com/install-xerolinux-arch/
[20]: https://www.debugpoint.com/exodia-os-first-look/
[21]: https://www.debugpoint.com/crystal-linux-first-look/
[22]: https://www.debugpoint.com/hefftor-linux-review/
[0]: https://img.linux.net.cn/data/attachment/album/202303/06/075045kkwxmjwrzrelxypd.jpg

View File

@ -1,179 +0,0 @@
[#]: subject: "KDE Plasma 5.27: Top New Features and Release Details"
[#]: via: "https://www.debugpoint.com/kde-plasma-5-27/"
[#]: author: "Arindam https://www.debugpoint.com/author/admin1/"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
KDE Plasma 5.27: Top New Features and Release Details
======
**The list of impressive features and enhancements of the KDE Plasma 5.27 desktop is arriving in February.**
In a way, KDE Plasma 5.27 is a milestone release.
Firstly, it is the final LTS release of the Plasma 5 version and the last instalment of the Plasma 5 series. Initial porting work has already started for Plasma 6 series, which would be based on Qt 6 version.
Release number-wise, it is the 29th version of the KDE Plasma desktop, followed by the [prior plasma 5.26 release][1].
Visible feature-wise, its of moderate size. However, the bug fixes, code refactoring, cleanup, and optimization are significant. Most are not visible on the deck, but you can feel the changes when using this fluid desktop.
Before I walk you through the key features, heres the schedule.
- **Beta:** Jan 19, 2023
- **KDE Plasma 5.27 Final release:** Feb 14, 2023
![KDE Plasma 5.27 dev edition][2]
### KDE Plasma 5.27: Best New Features
#### Plasma Workspace
A brand new app welcomes you to Plasma desktop from now on. It was a good idea to add this app to Plasma. It will give you some initial information about Plasma, setting up online accounts and so on.
![Plasma Welcome App][3]
The media controller applet introduces two new layouts in this release. A vertical layout showing album art, song title and artist name. And an icon-only display showing only album art. [MR 2176][4]
The icon size settings slide in the Appearance is moved under the preview with more descriptive text. Also, the window size is slightly larger to accommodate the overall items. [MR 2213][5]
![Changes in icon size slide][6]
KDE Plasma battery monitor will now show the charging, discharging, and fully charged status for non-power supply batteries such as a wireless mouse, and mobile phones when connected to the Plasma desktop. [MR 2210][7]
Also, the battery monitor stops showing 100% when the battery is fully charged. You can only see the power icon without any text. [MR 2306][8]
In another change, the battery monitor shows “Estimating…” text when the remaining time is 0. Also, the remaining time calculation is changed to give you accurate hours and minutes remaining to full charge.
The middle click features are now exposed in the applet UI when available. The features existed for some apps, but the discovery was difficult unless tried. [MR 2205][9]
![Exposing the middle click options][10]
In the upcoming Qt6, the GaussianBlur is not available. Hence it has been removed in this version, and FastBlur is now incorporated. This is part of the initial Qt6 porting of the future Plasma 6 release. [MR 2083][11]
The “do not disturb” applet now shows a clearer message for the duration. Earlier it used to show “Until today”, and it has been changed to “Automatically ends: Today at ….”. [MR 1412][12]
In KDE Plasma 5.27, you can directly drag the wallpaper from the image list to any other application which accepts images. For example, you can directly drag and drop an image from the wallpaper window to the Gwenview image viewer. This definitely eases up many workflows and should save hassles from going to the folder and opening them. However, the feature is not working in my test, so I cant show you a demo. [MR 2284][13]
We all love Krunner, the most excellent launcher ever! In this release, Krunner now searches for the key in any part of the file name in the recent document list. It sorts the result from the best match, starting with the search key in the file name to the bottom. [MR 2273][14]
Also, when there is no match in any documents in your system, Krunner now prompts a web search with the search key. [MR 2311][15]
![Krunner is great][16]
The developers can now prioritise the applet notification by assigning a notification value of 256. Once it is a high priority, the notification becomes part of the top header instead of the menu. [MR 2245][17]
The Users settings page, fingerprint register, and authentication selection are much more visually attractive with an actual hand image. [MR 2347][18]
![New Visual cue for fingerprint][19]
The accessibility of KDE Plasma is now more robust because the Orca screenreader app can read the notifications. It includes the app name and the notification description. [MR 2295][20]
#### Wayland, Kwin and Plasma desktop
KDE Plasma 5.27 now supports **high-resolution scrolling** in Wayland, thanks to libinput 1.9 version changes. With this change, you should experience smooth scrolling performance in Chrome and Firefox browsers. I hope this makes it on par with the Windows experience. To this day, I still feel Windows scrolling in the popular browser is very smooth. [MR 3034][21]
Another Wayland fix in this release is the inclusion of the Wayland implementation of **idle notification protocol**. In the Wayland session, if you become idle, the data can now be consumed by various apps and modules to save power, change the status in messaging apps, etc. [MR 2959][22]
Wayland session in Plasma desktop also brings content type. This allows Kwin to tweak the display behaviour (direct scanout, variable refresh rate, etc.) based on the content displayed on the screen. So, you should get an optimized session based on whether you are watching a movie, playing games or casually browsing the web. [MR 2467][23]
KDE Plasma Wayland session now supports **fractional scaling** natively. The upstream Wayland change for this was [merged][24] a few months back in 2022. You should get native resolution options in Wayland sessions. [MR 2598][25]
If you are a multi-monitor user, you should be glad to know that the settings to manage multiple displays are now easily accessible via the system tray display configuration.
![Multiple display configuration is now available from system tray][26]
#### Discover
Discover now shows a proper message when you are offline that it cannot fetch software information from servers instead of showing a progress bar. [MR 383][27]
For the past few releases, Discover has been improved for Flatpak management. This release also gets some goodies for Flatpak apps. Firstly, the Flatpak application view now shows more permissions entries that an app needs. A new settings page lists all the installed Flatpak and its permissions. [MR 372][28]
![Flatpak Permission in Discover][29]
Secondly, Discover now waits a few moments before checking updates for Flatpak. While it waits, it shows the locally cached Flatpak data. [MR 421][30]
Thirdly, the Discover home is revamped. Honestly, it was due for a long time. Now it looks far better with the popular apps, editors choice and other categories. [MR 398][31]
![Discover homepage now revamped][32]
#### Additional updates
Other key change includes:
- Plasma 5.27 is based on KDE Framework 5.102 and Qt 5.15.2.
- Transition animation when changing wallpaper.
- The weather applet now shows weather info in overlay mode.
- The location picker in the weather applet now gives you a possible list of locations.
- The network applet now shows 5G connection label and icons when used.
- And hopefully, a new wallpaper as always!
[_Detailed changelog_][33] _(5.26.5-5.26.90)_
### Download
The BETA of KDE Plasma 5.27 is now out. You can download the ISO file and torrent via the KDE Neon distribution from the below link. Remember, this is a testing copy, and there may be bugs. So use it with caution.
[Download KDE Neon (testing edition)][34]
### Wrapping Up
Overall, the change list is enormous and impossible to cover in one article. Its amazing to see so many changes pulled up in each release by the KDE team. The KDE Framework and app changes are not part of this article which is also significant.
The final release is planned on Feb 14, 2023.
Distro-wise, KDE Plasma 5.27 should be available in Fedora 38 and Ubuntu 23.04 Lunar Lobster within the March-April timeframe.
So, which one of the features do you choose as your favourite? Let me know in the comment box below.
Cheers.
--------------------------------------------------------------------------------
via: https://www.debugpoint.com/kde-plasma-5-27/
作者:[Arindam][a]
选题:[lkxed][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.debugpoint.com/author/admin1/
[b]: https://github.com/lkxed
[1]: https://www.debugpoint.com/kde-plasma-5-26/
[2]: https://www.debugpoint.com/wp-content/uploads/2023/01/KDE-Plasma-5.27-dev-edition.jpg
[3]: https://www.debugpoint.com/wp-content/uploads/2023/01/Plasma-Welcome-App.jpg
[4]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2176
[5]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2213
[6]: https://www.debugpoint.com/wp-content/uploads/2023/01/Changes-in-icon-size-slide2.jpg
[7]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2210
[8]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2306
[9]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2205
[10]: https://www.debugpoint.com/wp-content/uploads/2023/01/Exposing-the-middle-click-options.jpg
[11]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2083
[12]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/1412
[13]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2284
[14]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2273
[15]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2311
[16]: https://www.debugpoint.com/wp-content/uploads/2023/01/Krunner-is-great.jpg
[17]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2245
[18]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2347
[19]: https://www.debugpoint.com/wp-content/uploads/2023/01/New-Visual-cue-for-fingerprint.jpg
[20]: https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2295
[21]: https://invent.kde.org/plasma/kwin/-/merge_requests/3034
[22]: https://invent.kde.org/plasma/kwin/-/merge_requests/2959
[23]: https://invent.kde.org/plasma/kwin/-/merge_requests/2467
[24]: https://gitlab.freedesktop.org/wayland/wayland-protocols/-/merge_requests/143
[25]: https://invent.kde.org/plasma/kwin/-/merge_requests/2598
[26]: https://www.debugpoint.com/wp-content/uploads/2023/01/Multiple-display-configuration-is-now-available-from-system-tray.jpg
[27]: https://invent.kde.org/plasma/discover/-/merge_requests/383
[28]: https://invent.kde.org/plasma/discover/-/merge_requests/372
[29]: https://www.debugpoint.com/wp-content/uploads/2023/01/Flatpak-Permission-in-Discover.jpg
[30]: https://invent.kde.org/plasma/discover/-/merge_requests/421
[31]: https://invent.kde.org/plasma/discover/-/merge_requests/398
[32]: https://www.debugpoint.com/wp-content/uploads/2023/01/Discover-homepage-now-revamped.jpg
[33]: https://kde.org/announcements/changelogs/plasma/5/5.26.5-5.26.90/
[34]: https://files.kde.org/neon/images/testing/current/

View File

@ -1,127 +0,0 @@
[#]: subject: "LibreOffice 7.5 Unveils Stunning New App Icons and Cool Features"
[#]: via: "https://news.itsfoss.com/libreoffice-7-5-release/"
[#]: author: "Sourav Rudra https://news.itsfoss.com/author/sourav/"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
LibreOffice 7.5 Unveils Stunning New App Icons and Cool Features
======
LibreOffice 7.5 seems to have a new personality with its brand-new app icons and other improvements.
![LibreOffice 7.5 Unveils Stunning New App Icons and Cool Features][1]
LibreOffice 7.5 community edition is here with **many feature upgrades and new app icons**.
The previous major release [version 7.4][2] bought in better 'interoperability' with Microsoft's proprietary file formats and **further solidified LibreOffice** as one of the [best open-source alternatives to Microsoft Office][3] on Linux.
And now, a new release is here with a lot in store.
Let's take a look at what this has to offer.
### 🆕 LibreOffice 7.5: What's New?
![LibreOffice 7.5: New Features][4]
With this release, plenty of improvements have been made to all the programs of LibreOffice; some key highlights include:
- **New App Icons**
- **Writer Improvements**
- **Calc Improvements**
- **Impress & Draw Improvements**
- **Dark mode improvement**
#### New App Icons
![libreoffice's updated icons][5]
LibreOffice now features a new set of app icons that look pretty modern. These will look neat with current-gen desktop environments such as GNOME and Plasma.
Here's how it looks compared to the old icon; refreshing, right?
![libreoffice old icon vs new icon][6]
Similarly, the developers have also updated the icon set used throughout LibreOffice's interface for various media types/files.
#### Writer Improvements
![libreoffice writer screenshot][7]
The Writer app has received a host of improvements, notable ones include:
- A new plain text type was added.
- Content controls for titles and tags.
- New combo box type and ability to export content controls to PDF.
- Spellcheck has improved for various languages such as Danish, Dutch, Estonian, German, Hungarian, Norwegian, and Swedish.
- In case of tables, column detection has improved when it intersects with merged cells.
- Bookmark editing and accessibility has been improved.
- A decorative tag can be applied to images, embedded objects, and text frames to allow assistive software to ignore them in exported PDFs.
#### Calc Improvements
![libreoffice 7.5 calc screenshot][8]
Cell inputs with the leading ' apostrophe in cells that are not formatted as Text will now permanently remove the first apostrophe to prevent confusion.
Support for Kamenický and Mazovia encodings was added, alongside improvements to conditional formatting.
In addition, when searching for a term in the Function Wizard, it will now match the function descriptions as well as their names.
#### Impress & Draw Improvements
Impress now has support for adding cropped videos in media shapes and also includes a fix for an EMF graphics issue where it would appear blurry.
![libreoffice draw's new table style design feature][9]
In the case of Draw, essential support was added for modifying table styles and creating new ones. Modified styles are saved into the document and can be made into templates and shared.
> 🗒️ You can access the feature to modify table style by right-clicking on a design in the Table Design sidebar panel.
#### 🛠️ Other Changes and Improvements
These were not the only improvements to LibreOffice with the 7.5 release.
Things like **better support for dark and high contrast themes**, support for data tables in charts, various improvements to the core, and more make this a packed release. Some refinements are targeted for platforms like macOS and Windows, along with Linux.
You can check all the technical changes from the [official release notes][10] or the [announcement][11].
### Download LibreOffice 7.5
LibreOffice 7.5 is available from the [official download page][12].
You can find deb and rpm files along with packages for Windows and macOS (Intel/ARM).
[LibreOffice 7.5][12]
You can also opt for a Torrent file for an even smoother download experience.
For existing users, depending on your Linux distribution, expect an update in the coming days/weeks. You may opt for the Flatpak package for faster access to the latest version.
--------------------------------------------------------------------------------
via: https://news.itsfoss.com/libreoffice-7-5-release/
作者:[Sourav Rudra][a]
选题:[lkxed][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://news.itsfoss.com/author/sourav/
[b]: https://github.com/lkxed
[1]: https://news.itsfoss.com/content/images/size/w2000/2023/02/libreoffice-7.5-release.png
[2]: https://news.itsfoss.com/libreoffice-7-4-release/
[3]: https://itsfoss.com/best-free-open-source-alternatives-microsoft-office/
[4]: https://youtu.be/ZlAmjIwUvs4
[5]: https://news.itsfoss.com/content/images/2023/02/LibreOffice_7.5_Icons.png
[6]: https://news.itsfoss.com/content/images/2023/02/libreoffice-icons.jpg
[7]: https://news.itsfoss.com/content/images/2023/02/libreoffice-writer.png
[8]: https://news.itsfoss.com/content/images/2023/02/libreoffice-7-5.png
[9]: https://news.itsfoss.com/content/images/2023/02/LibreOffice_7.5_Table_Design.png
[10]: https://wiki.documentfoundation.org/ReleaseNotes/7.5
[11]: https://blog.documentfoundation.org/blog/2023/02/02/tdf-announces-libreoffice-75-community/
[12]: https://www.libreoffice.org/download/download-libreoffice/

View File

@ -1,147 +0,0 @@
[#]: subject: "How to Use a Differential Analyzer (to Murder People)"
[#]: via: "https://twobithistory.org/2020/04/06/differential-analyzer.html"
[#]: author: "Two-Bit History https://twobithistory.org"
[#]: collector: "lujun9972"
[#]: translator: "toknow-gh"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
How to Use a Differential Analyzer (to Murder People)
======
A differential analyzer is a mechanical, analog computer that can solve differential equations. Differential analyzers arent used anymore because even a cheap laptop can solve the same equations much faster—and can do it in the background while you stream the new season of Westworld on HBO. Before the invention of digital computers though, differential analyzers allowed mathematicians to make calculations that would not have been practical otherwise.
It is hard to see today how a computer made out of anything other than digital circuitry printed in silicon could work. A mechanical computer sounds like something out of a steampunk novel. But differential analyzers did work and even proved to be an essential tool in many lines of research. Most famously, differential analyzers were used by the US Army to calculate range tables for their artillery pieces. Even the largest gun is not going to be effective unless you have a range table to help you aim it, so differential analyzers arguably played an important role in helping the Allies win the Second World War.
To understand how differential analyzers could do all this, you will need to know what differential equations are. Forgotten what those are? Thats okay, because I had too.
### Differential Equations
Differential equations are something you might first encounter in the final few weeks of a college-level Calculus I course. By that point in the semester, your underpaid adjunct professor will have taught you about limits, derivatives, and integrals; if you take those concepts and add an equals sign, you get a differential equation.
Differential equations describe rates of change in terms of some other variable (or perhaps multiple other variables). Whereas a familiar algebraic expression like \\(y = 4x + 3\\) specifies the relationship between some variable quantity \\(y\\) and some other variable quantity \\(x\\), a differential equation, which might look like \\(\frac{dy}{dx} = x\\), or even \\(\frac{dy}{dx} = 2\\), specifies the relationship between a _rate of change_ and some other variable quantity. Basically, a differential equation is just a description of a rate of change in exact mathematical terms. The first of those last two differential equations is saying, “The variable \\(y\\) changes with respect to \\(x\\) at a rate defined exactly by \\(x\\),” and the second is saying, “No matter what \\(x\\) is, the variable \\(y\\) changes with respect to \\(x\\) at a rate of exactly 2.”
Differential equations are useful because in the real world it is often easier to describe how complex systems change from one instant to the next than it is to come up with an equation describing the system at all possible instants. Differential equations are widely used in physics and engineering for that reason. One famous differential equation is the heat equation, which describes how heat diffuses through an object over time. It would be hard to come up with a function that fully describes the distribution of heat throughout an object given only a time \\(t\\), but reasoning about how heat diffuses from one time to the next is less likely to turn your brain into soup—the hot bits near lots of cold bits will probably get colder, the cold bits near lots of hot bits will probably get hotter, etc. So the heat equation, though it is much more complicated than the examples in the last paragraph, is likewise just a description of rates of change. It describes how the temperature of any one point on the object will change over time given how its temperature differs from the points around it.
Lets consider another example that I think will make all of this more concrete. If I am standing in a vacuum and throw a tennis ball straight up, will it come back down before I asphyxiate? This kind of question, posed less dramatically, is the kind of thing I was asked in high school physics class, and all I needed to solve it back then were some basic Newtonian equations of motion. But lets pretend for a minute that I have forgotten those equations and all I can remember is that objects accelerate toward earth at a constant rate of \\(g\\), or about \\(10 \;m/s^2\\). How can differential equations help me solve this problem?
Well, we can express the one thing I remember about high school physics as a differential equation. The tennis ball, once it leaves my hand, will accelerate toward the earth at a rate of \\(g\\). This is the same as saying that the velocity of the ball will change (in the negative direction) over time at a rate of \\(g\\). We could even go one step further and say that _the rate of change in the height of my ball above the ground_ (this is just its velocity) will change over time at a rate of negative \\(g\\). We can write this down as the following, where \\(h\\) represents height and \\(t\\) represents time:
\\[\frac{d^2h}{dt^2} = -g\\]
This looks slightly different from the differential equations we have seen so far because this is what is known as a second-order differential equation. We are talking about the rate of change of a rate of change, which, as you might remember from your own calculus education, involves second derivatives. Thats why parts of the expression on the left look like they are being squared. But this equation is still just expressing the fact that the ball accelerates downward at a constant acceleration of \\(g\\).
From here, one option I have is to use the tools of calculus to solve the differential equation. With differential equations, this does not mean finding a single value or set of values that satisfy the relationship but instead finding a function or set of functions that do. Another way to think about this is that the differential equation is telling us that there is some function out there whose second derivative is the constant \\(-g\\); we want to find that function because it will give us the height of the ball at any given time. This differential equation happens to be an easy one to solve. By doing so, we can re-derive the basic equations of motion that I had forgotten and easily calculate how long it will take the ball to come back down.
But most of the time differential equations are hard to solve. Sometimes they are even impossible to solve. So another option I have, given that I paid more attention in my computer science classes that my calculus classes in college, is to take my differential equation and use it as the basis for a simulation. If I know the starting velocity and the acceleration of my tennis ball, then I can easily write a little for-loop, perhaps in Python, that iterates through my problem second by second and tells me what the velocity will be at any given second \\(t\\) after the initial time. Once Ive done that, I could tweak my for-loop so that it also uses the calculated velocity to update the height of the ball on each iteration. Now I can run my Python simulation and figure out when the ball will come back down. My simulation wont be perfectly accurate, but I can decrease the size of the time step if I need more accuracy. All I am trying to accomplish anyway is to figure out if the ball will come back down while I am still alive.
This is the numerical approach to solving a differential equation. It is how differential equations are solved in practice in most fields where they arise. Computers are indispensable here, because the accuracy of the simulation depends on us being able to take millions of small little steps through our problem. Doing this by hand would obviously be error-prone and take a long time.
So what if I were not just standing in a vacuum with a tennis ball but were standing in a vacuum with a tennis ball in, say, 1936? I still want to automate my computation, but Claude Shannon wont even complete his masters thesis for another year yet (the one in which he casually implements Boolean algebra using electronic circuits). Without digital computers, Im afraid, we have to go analog.
### The Differential Analyzer
The first differential analyzer was built between 1928 and 1931 at MIT by Vannevar Bush and Harold Hazen. Both men were engineers. The machine was created to tackle practical problems in applied mathematics and physics. It was supposed to address what Bush described, in [a 1931 paper][1] about the machine, as the contemporary problem of mathematicians who are “continually being hampered by the complexity rather than the profundity of the equations they employ.”
A differential analyzer is a complicated arrangement of rods, gears, and spinning discs that can solve differential equations of up to the sixth order. It is like a digital computer in this way, which is also a complicated arrangement of simple parts that somehow adds up to a machine that can do amazing things. But whereas the circuitry of a digital computer implements Boolean logic that is then used to simulate arbitrary problems, the rods, gears, and spinning discs _directly_ simulate the differential equation problem. This is what makes a differential analyzer an analog computer—it is a direct mechanical analogy for the real problem.
How on earth do gears and spinning discs do calculus? This is actually the easiest part of the machine to explain. The most important components in a differential analyzer are the six mechanical integrators, one for each order in a sixth-order differential equation. A mechanical integrator is a relatively simple device that can integrate a single input function; mechanical integrators go back to the 19th century. We will want to understand how they work, but, as an aside here, Bushs big accomplishment was not inventing the mechanical integrator but rather figuring out a practical way to chain integrators together to solve higher-order differential equations.
A mechanical integrator consists of one large spinning disc and one much smaller spinning wheel. The disc is laid flat parallel to the ground like the turntable of a record player. It is driven by a motor and rotates at a constant speed. The small wheel is suspended above the disc so that it rests on the surface of the disc ever so slightly—with enough pressure that the disc drives the wheel but not enough that the wheel cannot freely slide sideways over the surface of the disc. So as the disc turns, the wheel turns too.
The speed at which the wheel turns will depend on how far from the center of the disc the wheel is positioned. The inner parts of the disc, of course, are rotating more slowly than the outer parts. The wheel stays fixed where it is, but the disc is mounted on a carriage that can be moved back and forth in one direction, which repositions the wheel relative to the center of the disc. Now this is the key to how the integrator works: The position of the disc carriage is driven by the input function to the integrator. The output from the integrator is determined by the rotation of the small wheel. So your input function drives the rate of change of your output function and you have just transformed the derivative of some function into the function itself—which is what we call integration!
If that explanation does nothing for you, seeing a mechanical integrator in action really helps. The principle is surprisingly simple and there is no way to watch the device operate without grasping how it works. So I have created [a visualization of a running mechanical integrator][2] that I encourage you to take a look at. The visualization shows the integration of some function \\(f(x)\\) into its antiderivative \\(F(x)\\) while various things spin and move. Its pretty exciting.
![][3] _A nice screenshot of my visualization, but you should check out the real thing!_
So we have a component that can do integration for us, but that alone is not enough to solve a differential equation. To explain the full process to you, Im going to use an example that Bush offers himself in his 1931 paper, which also happens to be essentially the same example we contemplated in our earlier discussion of differential equations. (This was a happy accident!) Bush introduces the following differential equation to represent the motion of a falling body:
\\[\frac{d^2x}{dt^2} = -k\,\frac{dx}{dt} - g\\]
This is the same equation we used to model the motion of our tennis ball, only Bush has used \\(x\\) in place of \\(h\\) and has added another term that accounts for how air resistance will decelerate the ball. This new term describes the effect of air resistance on the ball in the simplest possible way: The air will slow the balls velocity at a rate that is proportional to its velocity (the \\(k\\) here is some proportionality constant whose value we dont really care about). So as the ball moves faster, the force of air resistance will be stronger, further decelerating the ball.
To configure a differential analyzer to solve this differential equation, we have to start with what Bush calls the “input table.” The input table is just a piece of graphing paper mounted on a carriage. If we were trying to solve a more complicated equation, the operator of the machine would first plot our input function on the graphing paper and then, once the machine starts running, trace out the function using a pointer connected to the rest of the machine. In this case, though, our input is just the constant \\(g\\), so we only have to move the pointer to the right value and then leave it there.
What about the other variables \\(x\\) and \\(t\\)? The \\(x\\) variable is our output as it represents the height of the ball. It will be plotted on graphing paper placed on the output table, which is similar to the input table only the pointer is a pen and is driven by the machine. The \\(t\\) variable should do nothing more than advance at a steady rate. (In our Python simulation of the tennis ball problem as posed earlier, we just incremented \\(t\\) in a loop.) So the \\(t\\) variable comes from the differential analyzers motor, which kicks off the whole process by rotating the rod connected to it at a constant speed.
Bush has a helpful diagram documenting all of this that I will show you in a second, but first we need to make one more tweak to our differential equation that will make the diagram easier to understand. We can integrate both sides of our equation once, yielding the following:
\\[\frac{dx}{dt} = - \int \left(k\,\frac{dx}{dt} + g\right)\,dt\\]
The terms in this equation map better to values represented by the rotation of various parts of the machine while it runs. Okay, heres that diagram:
![][4] _The differential analyzer configured to solve the problem of a falling body in one dimension._
The input table is at the top of the diagram. The output table is at the bottom-right. The output table here is set up to graph both \\(x\\) and \\(\frac{dx}{dt}\\), i.e. height and velocity. The integrators appear at the bottom-left; since this is a second-order differential equation, we need two. The motor drives the very top rod labeled \\(t\\). (Interestingly, Bush referred to these horizontal rods as “buses.”)
That leaves two components unexplained. The box with the little \\(k\\) in it is a multiplier respresnting our proportionality constant \\(k\\). It takes the rotation of the rod labeled \\(\frac{dx}{dt}\\) and scales it up or down using a gear ratio. The box with the \\(\sum\\) symbol is an adder. It uses a clever arrangement of gears to add the rotations of two rods together to drive a third rod. We need it since our equation involves the sum of two terms. These extra components available in the differential analyzer ensure that the machine can flexibly simulate equations with all kinds of terms and coefficients.
I find it helpful to reason in ultra-slow motion about the cascade of cause and effect that plays out as soon as the motor starts running. The motor immediately begins to rotate the rod labeled \\(t\\) at a constant speed. Thus, we have our notion of time. This rod does three things, illustrated by the three vertical rods connected to it: it drives the rotation of the discs in both integrators and also advances the carriage of the output table so that the output pen begins to draw.
Now if the integrators were set up so that their wheels are centered, then the rotation of rod \\(t\\) would cause no other rods to rotate. The integrator discs would spin but the wheels, centered as they are, would not be driven. The output chart would just show a flat line. This happens because we have not accounted for the initial conditions of the problem. In our earlier Python simulation, we needed to know the initial velocity of the ball, which we would have represented there as a constant variable or as a parameter of our Python function. Here, we account for the initial velocity and acceleration by displacing the integrator discs by the appropriate amount before the machine begins to run.
Once weve done that, the rotation of rod \\(t\\) propagates through the whole system. Physically, a lot of things start rotating at the same time, but we can think of the rotation going first to integrator II, which combines it with the acceleration expression calculated based on \\(g\\) and then integrates it to get the result \\(\frac{dx}{dt}\\). This represents the velocity of the ball. The velocity is in turn used as input to integrator I, whose disc is displaced so that the output wheel rotates at the rate \\(\frac{dx}{dt}\\). The output from integrator I is our final output \\(x\\), which gets routed directly to the output table.
One confusing thing Ive glossed over is that there is a cycle in the machine: Integrator II takes as an input the rotation of the rod labeled \\((k\,\frac{dx}{dt} + g)\\), but that rods rotation is determined in part by the output from integrator II itself. This might make you feel queasy, but there is no physical issue here—everything is rotating at once. If anything, we should not be surprised to see cycles like this, since differential equations often describe rates of change in a function as a function of the function itself. (In this example, the acceleration, which is the rate of change of velocity, depends on the velocity.)
With everything correctly configured, the output we get is a nice graph, charting both the position and velocity of our ball over time. This graph is on paper. To our modern digital sensibilities, that might seem absurd. What can you do with a paper graph? While its true that the differential analyzer is not so magical that it can write out a neat mathematical expression for the solution to our problem, its worth remembering that neat solutions to many differential equations are not possible anyway. The paper graph that the machine does write out contains exactly the same information that could be output by our earlier Python simulation of a falling ball: where the ball is at any given time. It can be used to answer any practical question you might have about the problem.
The differential analyzer is a preposterously cool machine. It is complicated, but it fundamentally involves nothing more than rotating rods and gears. You dont have to be an electrical engineer or know how to fabricate a microchip to understand all the physical processes involved. And yet the machine does calculus! It solves differential equations that you never could on your own. The differential analyzer demonstrates that the key material required for the construction of a useful computing machine is not silicon but human ingenuity.
### Murdering People
Human ingenuity can serve purposes both good and bad. As I have mentioned, the highest-profile use of differential analyzers historically was to calculate artillery range tables for the US Army. To the extent that the Second World War was the “Good Fight,” this was probably for the best. But there is also no getting past the fact that differential analyzers helped to make very large guns better at killing lots of people. And kill lots of people they did—if Wikipedia is to be believed, more soldiers were killed by artillery than small arms fire during the Second World War.
I will get back to the moralizing in a minute, but just a quick detour here to explain why calculating range tables was hard and how differential analyzers helped, because its nice to see how differential analyzers were applied to a real problem. A range table tells the artilleryman operating a gun how high to elevate the barrel to reach a certain range. One way to produce a range table might be just to fire that particular kind of gun at different angles of elevation many times and record the results. This was done at proving grounds like the Aberdeen Proving Ground in Maryland. But producing range tables solely through empirical observation like this is expensive and time-consuming. There is also no way to account for other factors like the weather or for different weights of shell without combinatorially increasing the necessary number of firings to something unmanageable. So using a mathematical theory that can fill in a complete range table based on a smaller number of observed firings is a better approach.
I dont want to get too deep into how these mathematical theories work, because the math is complicated and I dont really understand it. But as you might imagine, the physics that governs the motion of an artillery shell in flight is not that different from the physics that governs the motion of a tennis ball thrown upward. The need for accuracy means that the differential equations employed have to depart from the idealized forms weve been using and quickly get gnarly. Even the earliest attempts to formulate a rigorous ballistic theory involve equations that account for, among other factors, the weight, diameter, and shape of the projectile, the prevailing wind, the altitude, the atmospheric density, and the rotation of the earth[1][5].
So the equations are complicated, but they are still differential equations that a differential analyzer can solve numerically in the way that we have already seen. Differential analyzers were put to work solving ballistics equations at the Aberdeen Proving Ground in 1935, where they dramatically sped up the process of calculating range tables.[2][6] Nevertheless, during the Second World War, the demand for range tables grew so quickly that the US Army could not calculate them fast enough to accompany all the weaponry being shipped to Europe. This eventually led the Army to fund the ENIAC project at the University of Pennsylvania, which, depending on your definitions, produced the worlds first digital computer. ENIAC could, through rewiring, run any program, but it was constructed primarily to perform range table calculations many times faster than could be done with a differential analyzer.
Given that the range table problem drove much of the early history of computing even apart from the differential analyzer, perhaps its unfair to single out the differential analyzer for moral hand-wringing. The differential analyzer isnt uniquely compromised by its military applications—the entire field of computing, during the Second World War and well afterward, advanced because of the endless funding being thrown at it by the United States military.
Anyway, I think the more interesting legacy of the differential analyzer is what it teaches us about the nature of computing. I am surprised that the differential analyzer can accomplish as much as it can; my guess is that you are too. It is easy to fall into the trap of thinking of computing as the realm of what can be realized with very fast digital circuits. In truth, computing is a more abstract process than that, and electronic, digital circuits are just what we typically use to get it done. In his paper about the differential analyzer, Vannevar Bush suggests that his invention is just a small contribution to “the far-reaching project of utilizing complex mechanical interrelationships as substitutes for intricate processes of reasoning.” That puts it nicely.
_If you enjoyed this post, more like it come out every four weeks! Follow [@TwoBitHistory][7] on Twitter or subscribe to the [RSS feed][8] to make sure you know when a new post is out._
_Previously on TwoBitHistory…_
> Do you worry that your children are "BBS-ing"? Do you have a neighbor who talks too much about his "door games"?
>
> In this VICE News special report, we take you into the seedy underworld of bulletin board systems:<https://t.co/hBrKGU2rfB>
>
> — TwoBitHistory (@TwoBitHistory) [February 2, 2020][9]
1. Alan Gluchoff. “Artillerymen and Mathematicians: Forest Ray Moulton and Changes in American Exterior Ballistics, 1885-1934.” Historia Mathematica, vol. 38, no. 4, 2011, pp. 506547., <https://www.sciencedirect.com/science/article/pii/S0315086011000279>. [↩︎][10]
2. Karl Kempf. “Electronic Computers within the Ordnance Corps,” 1961, accessed April 6, 2020, <https://ftp.arl.army.mil/~mike/comphist/61ordnance/index.html>. [↩︎][11]
--------------------------------------------------------------------------------
via: https://twobithistory.org/2020/04/06/differential-analyzer.html
作者:[Two-Bit History][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://twobithistory.org
[b]: https://github.com/lujun9972
[1]: http://worrydream.com/refs/Bush%20-%20The%20Differential%20Analyzer.pdf
[2]: https://sinclairtarget.com/differential-analyzer/
[3]: https://twobithistory.org/images/diff-analyzer-viz.png
[4]: https://twobithistory.org/images/analyzer-diagram.png
[5]: tmp.MoynZsbJ7w#fn:1
[6]: tmp.MoynZsbJ7w#fn:2
[7]: https://twitter.com/TwoBitHistory
[8]: https://twobithistory.org/feed.xml
[9]: https://twitter.com/TwoBitHistory/status/1224014531778826240?ref_src=twsrc%5Etfw
[10]: tmp.MoynZsbJ7w#fnref:1
[11]: tmp.MoynZsbJ7w#fnref:2

View File

@ -1,146 +0,0 @@
[#]: collector: (lujun9972)
[#]: translator: (CanYellow)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
[#]: subject: (Roy Fielding's Misappropriated REST Dissertation)
[#]: via: (https://twobithistory.org/2020/06/28/rest.html)
[#]: author: (Two-Bit History https://twobithistory.org)
被错误应用的罗伊·菲尔丁的有关描述性状态迁移的博士论文
======
TD
Roy Fielding's Misappropriated REST Dissertation
======
符合描述性状态迁移的 (RESTful,REST译自审定公布名词数据库) 应用程序接口 (API) 无处不在。有趣的是又有多少人真正了解“描述性状态迁移”的应有之义呢?
DN
RESTful APIs are everywhere. This is funny, because how many people really know what “RESTful” is supposed to mean?
大概我们中的大多数人都会跟[黑客新闻网站上的这篇公开问答][1]产生共鸣:
I think most of us can empathize with [this Hacker News poster][1]:
> 我阅读了几篇介绍描述性状态迁移的文章,甚至包括原始论文的部分章节。然而我仍然对描述性状态迁移到底是什么只有一个相当模糊的想法。我开始认为没有人真的了解描述性状态迁移,它仅仅是一个定义相当不充分的概念。
DN
> Ive read several articles about REST, even a bit of the original paper. But I still have quite a vague idea about what it is. Im beginning to think that nobody knows, that its simply a very poorly defined concept.
我曾经计划写一篇有关描述性状态迁移的博客,在里面探讨描述性状态迁移是如何成为这样一个在网络通信领域占主导地位的范式的。我通过阅读[2000年发表的罗伊·菲尔丁的博士论文][2]开始我的研究,这篇博士论文向世人介绍了描述性状态迁移的概念。在读过菲尔丁的博士论文以后,我意识到,相比之下,更引人注意的是菲尔丁的理论缘何受到如此普遍的误解。
DN
I had planned to write a blog post exploring how REST came to be such a dominant paradigm for communication across the internet. I started my research by reading [Roy Fieldings 2000 dissertation][2], which introduced REST to the world. After reading Fieldings dissertation, I realized that the much more interesting story here is how Fieldings ideas came to be so widely misunderstood.
(相对公平地说)很多人知道描述性状态迁移源自菲尔丁的博士论文,但并没有读过该论文。因此对于这篇博士论文的原始内容的误解才得以流行。
DN
Many more people know that Fieldings dissertation is where REST came from than have read the dissertation (fair enough), so misconceptions about what the dissertation actually contains are pervasive.
最大的误解是:这篇博士论文直接讨论了(译注:广义的)构建应用程序接口的问题,我此前一直认为描述性状态迁移从一开始就打算成为构建在超文本传输协议(HTTP)之上的网络应用程序接口(Web API)的架构模型,我相信很多人也这样认为。我猜测此前可能存在一个混乱的试验时期,开发人员采用完全错误的方式在超文本传输协议基础上开发应用程序接口,然后菲尔丁出现了并提出了将描述性状态迁移做为网络应用程序开发的正确方式。但是这种想法的时间线对不上:我们今天所熟知的网络服务的应用程序接口并非是在菲尔丁出版他的博士论文之后才出现的新生事物。
DN
The biggest of these misconceptions is that the dissertation directly addresses the problem of building APIs. I had always assumed, as I imagine many people do, that REST was intended from the get-go as an architectural model for web APIs built on top of HTTP. I thought perhaps that there had been some chaotic experimental period where people were building APIs on top of HTTP all wrong, and then Fielding came along and presented REST as the sane way to do things. But the timeline doesnt make sense here: APIs for web services, in the sense that we know them today, werent a thing until a few years after Fielding published his dissertation.
菲尔丁的博士论文(名为“架构风格与基于网络的软件架构设计”)(译者注,网络中文版的中文译名)不是讨论如何在超文本传输协议的基础上构建应用程序接口而恰恰是讨论超文本协议本身菲尔丁是超文本传输协议1.0版规范的贡献者同时也是超文本传输协议1.1版的共同作者。有感于从HTTP协议的设计中获得的架构经验他的博士论文将描述性状态迁移视为指导HTTP/1.1的标准化过程的架构原则的精华。举例而言,他拒绝了使用`MGET`和`MHEAD`方法进行批量请求的提议因为他认为这违反了REST所定义的约束条件尤其是在一个符合REST的系统中传递的消息应该是易于代理和缓存的约束条件。[1][3]因此HTTP/1.1转而围绕持久性连接设计在此基础上可以发送多个HTTP请求。菲尔丁同时认为
Fieldings dissertation (titled “Architectural Styles and the Design of Network-based Software Architectures”) is not about how to build APIs on top of HTTP but rather about HTTP itself. Fielding contributed to the HTTP/1.0 specification and co-authored the HTTP/1.1 specification, which was published in 1999. He was interested in the architectural lessons that could be drawn from the design of the HTTP protocol; his dissertation presents REST as a distillation of the architectural principles that guided the standardization process for HTTP/1.1. Fielding used these principles to make decisions about which proposals to incorporate into HTTP/1.1. For example, he rejected a proposal to batch requests using new `MGET` and `MHEAD` methods because he felt the proposal violated the constraints prescribed by REST, especially the constraint that messages in a REST system should be easy to proxy and cache.[1][3] So HTTP/1.1 was instead designed around persistent connections over which multiple HTTP requests can be sent. (Fielding also felt that cookies are not RESTful because they add state to what should be a stateless system, but their usage was already entrenched.[2][4]) REST, for Fielding, was not a guide to building HTTP-based systems but a guide to extending HTTP.
This isnt to say that Fielding doesnt think REST could be used to build other systems. Its just that he assumes these other systems will also be “distributed hypermedia systems.” This is another misconception people have about REST: that it is a general architecture you can use for any kind of networked application. But you could sum up the part of the dissertation where Fielding introduces REST as, essentially, “Listen, we just designed HTTP, so if you also find yourself designing a _distributed hypermedia system_ you should use this cool architecture we worked out called REST to make things easier.” Its not obvious why Fielding thinks anyone would ever attempt to build such a thing given that the web already exists; perhaps in 2000 it seemed like there was room for more than one distributed hypermedia system in the world. Anyway, Fielding makes clear that REST is intended as a solution for the scalability and consistency problems that arise when trying to connect hypermedia across the internet, _not_ as an architectural model for distributed applications in general.
We remember Fieldings dissertation now as the dissertation that introduced REST, but really the dissertation is about how much one-size-fits-all software architectures suck, and how you can better pick a software architecture appropriate for your needs. Only a single chapter of the dissertation is devoted to REST itself; much of the word count is spent on a taxonomy of alternative architectural styles[3][5] that one could use for networked applications. Among these is the Pipe-and-Filter (PF) style, inspired by Unix pipes, along with various refinements of the Client-Server style (CS), such as Layered-Client-Server (LCS), Client-Cache-Stateless-Server (C$SS), and Layered-Client-Cache-Stateless-Server (LC$SS). The acronyms get unwieldy but Fieldings point is that you can mix and match constraints imposed by existing styles to derive new styles. REST gets derived this way and could instead have been called—but for obvious reasons was not—Uniform-Layered-Code-on-Demand-Client-Cache-Stateless-Server (ULCODC$SS). Fielding establishes this taxonomy to emphasize that different constraints are appropriate for different applications and that this last group of constraints were the ones he felt worked best for HTTP.
This is the deep, deep irony of RESTs ubiquity today. REST gets blindly used for all sorts of networked applications now, but Fielding originally offered REST as an illustration of how to derive a software architecture tailored to an individual applications particular needs.
I struggle to understand how this happened, because Fielding is so explicit about the pitfalls of not letting form follow function. He warns, almost at the very beginning of the dissertation, that “design-by-buzzword is a common occurrence” brought on by a failure to properly appreciate software architecture.[4][6] He picks up this theme again several pages later:
> Some architectural styles are often portrayed as “silver bullet” solutions for all forms of software. However, a good designer should select a style that matches the needs of a particular problem being solved.[5][7]
REST itself is an especially poor “silver bullet” solution, because, as Fielding later points out, it incorporates trade-offs that may not be appropriate unless you are building a distributed hypermedia application:
> REST is designed to be efficient for large-grain hypermedia data transfer, optimizing for the common case of the Web, but resulting in an interface that is not optimal for other forms of architectural interaction.[6][8]
Fielding came up with REST because the web posed a thorny problem of “anarchic scalability,” by which Fielding means the need to connect documents in a performant way across organizational and national boundaries. The constraints that REST imposes were carefully chosen to solve this anarchic scalability problem. Web service APIs that are _public-facing_ have to deal with a similar problem, so one can see why REST is relevant there. Yet today it would not be at all surprising to find that an engineering team has built a backend using REST even though the backend only talks to clients that the engineering team has full control over. We have all become the architect in [this Monty Python sketch][9], who designs an apartment building in the style of a slaughterhouse because slaughterhouses are the only thing he has experience building. (Fielding uses a line from this sketch as an epigraph for his dissertation: “Excuse me… did you say knives?”)
So, given that Fieldings dissertation was all about avoiding silver bullet software architectures, how did REST become a de facto standard for web services of every kind?
My theory is that, in the mid-2000s, the people who were sick of SOAP and wanted to do something else needed their own four-letter acronym.
Im only half-joking here. SOAP, or the Simple Object Access Protocol, is a verbose and complicated protocol that you cannot use without first understanding a bunch of interrelated XML specifications. Early web services offered APIs based on SOAP, but, as more and more APIs started being offered in the mid-2000s, software developers burned by SOAPs complexity migrated away en masse.
Among this crowd, SOAP inspired contempt. Ruby-on-Rails dropped SOAP support in 2007, leading to this emblematic comment from Rails creator David Heinemeier Hansson: “We feel that SOAP is overly complicated. Its been taken over by the enterprise people, and when that happens, usually nothing good comes of it.”[7][10] The “enterprise people” wanted everything to be formally specified, but the get-shit-done crowd saw that as a waste of time.
If the get-shit-done crowd wasnt going to use SOAP, they still needed some standard way of doing things. Since everyone was using HTTP, and since everyone would keep using HTTP at least as a transport layer because of all the proxying and caching support, the simplest possible thing to do was just rely on HTTPs existing semantics. So thats what they did. They could have called their approach Fuck It, Overload HTTP (FIOH), and that would have been an accurate name, as anyone who has ever tried to decide what HTTP status code to return for a business logic error can attest. But that would have seemed recklessly blasé next to all the formal specification work that went into SOAP.
Luckily, there was this dissertation out there, written by a co-author of the HTTP/1.1 specification, that had something vaguely to do with extending HTTP and could offer FIOH a veneer of academic respectability. So REST was appropriated to give cover for what was really just FIOH.
Im not saying that this is exactly how things happened, or that there was an actual conspiracy among irreverent startup types to misappropriate REST, but this story helps me understand how REST became a model for web service APIs when Fieldings dissertation isnt about web service APIs at all. Adopting RESTs constraints makes some sense, especially for public-facing APIs that do cross organizational boundaries and thus benefit from RESTs “uniform interface.” That link must have been the kernel of why REST first got mentioned in connection with building APIs on the web. But imagining a separate approach called “FIOH,” that borrowed the “REST” name partly just for marketing reasons, helps me account for the many disparities between what today we know as RESTful APIs and the REST architectural style that Fielding originally described.
REST purists often complain, for example, that so-called REST APIs arent actually REST APIs because they do not use Hypermedia as The Engine of Application State (HATEOAS). Fielding himself [has made this criticism][11]. According to him, a real REST API is supposed to allow you to navigate all its endpoints from a base endpoint by following links. If you think that people are actually out there trying to build REST APIs, then this is a glaring omission—HATEOAS really is fundamental to Fieldings original conception of REST, especially considering that the “state transfer” in “Representational State Transfer” refers to navigating a state machine using hyperlinks between resources (and not, as many people seem to believe, to transferring resource state over the wire).[8][12] But if you imagine that everyone is just building FIOH APIs and advertising them, with a nudge and a wink, as REST APIs, or slightly more honestly as “RESTful” APIs, then of course HATEOAS is unimportant.
Similarly, you might be surprised to know that there is nothing in Fieldings dissertation about which HTTP verb should map to which CRUD action, even though software developers like to argue endlessly about whether using PUT or PATCH to update a resource is more RESTful. Having a standard mapping of HTTP verbs to CRUD actions is a useful thing, but this standard mapping is part of FIOH and not part of REST.
This is why, rather than saying that nobody understands REST, we should just think of the term “REST” as having been misappropriated. The modern notion of a REST API has historical links to Fieldings REST architecture, but really the two things are separate. The historical link is good to keep in mind as a guide for when to build a RESTful API. Does your API cross organizational and national boundaries the same way that HTTP needs to? Then building a RESTful API with a predictable, uniform interface might be the right approach. If not, its good to remember that Fielding favored having form follow function. Maybe something like GraphQL or even just JSON-RPC would be a better fit for what you are trying to accomplish.
_If you enjoyed this post, more like it come out every four weeks! Follow [@TwoBitHistory][13] on Twitter or subscribe to the [RSS feed][14] to make sure you know when a new post is out._
_Previously on TwoBitHistory…_
> New post is up! I wrote about how to solve differential equations using an analog computer from the '30s mostly made out of gears. As a bonus there's even some stuff in here about how to aim very large artillery pieces.<https://t.co/fwswXymgZa>
>
> — TwoBitHistory (@TwoBitHistory) [April 6, 2020][15]
1. Roy Fielding. “Architectural Styles and the Design of Network-based Software Architectures,” 128. 2000. University of California, Irvine, PhD Dissertation, accessed June 28, 2020, <https://www.ics.uci.edu/~fielding/pubs/dissertation/fielding_dissertation_2up.pdf>. [↩︎][16]
2. Fielding, 130. [↩︎][17]
3. Fielding distinguishes between software architectures and software architecture “styles.” REST is an architectural style that has an instantiation in the architecture of HTTP. [↩︎][18]
4. Fielding, 2. [↩︎][19]
5. Fielding, 15. [↩︎][20]
6. Fielding, 82. [↩︎][21]
7. Paul Krill. “Ruby on Rails 2.0 released for Web Apps,” InfoWorld. Dec 7, 2007, accessed June 28, 2020, <https://www.infoworld.com/article/2648925/ruby-on-rails-2-0-released-for-web-apps.html> [↩︎][22]
8. Fielding, 109. [↩︎][23]
--------------------------------------------------------------------------------
via: https://twobithistory.org/2020/06/28/rest.html
作者:[Two-Bit History][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://twobithistory.org
[b]: https://github.com/lujun9972
[1]: https://news.ycombinator.com/item?id=7201871
[2]: https://www.ics.uci.edu/~fielding/pubs/dissertation/fielding_dissertation_2up.pdf
[3]: tmp.Ewi4FpMIg6#fn:1
[4]: tmp.Ewi4FpMIg6#fn:2
[5]: tmp.Ewi4FpMIg6#fn:3
[6]: tmp.Ewi4FpMIg6#fn:4
[7]: tmp.Ewi4FpMIg6#fn:5
[8]: tmp.Ewi4FpMIg6#fn:6
[9]: https://www.youtube.com/watch?v=vNoPJqm3DAY
[10]: tmp.Ewi4FpMIg6#fn:7
[11]: https://roy.gbiv.com/untangled/2008/rest-apis-must-be-hypertext-driven
[12]: tmp.Ewi4FpMIg6#fn:8
[13]: https://twitter.com/TwoBitHistory
[14]: https://twobithistory.org/feed.xml
[15]: https://twitter.com/TwoBitHistory/status/1247187881946275841?ref_src=twsrc%5Etfw
[16]: tmp.Ewi4FpMIg6#fnref:1
[17]: tmp.Ewi4FpMIg6#fnref:2
[18]: tmp.Ewi4FpMIg6#fnref:3
[19]: tmp.Ewi4FpMIg6#fnref:4
[20]: tmp.Ewi4FpMIg6#fnref:5
[21]: tmp.Ewi4FpMIg6#fnref:6
[22]: tmp.Ewi4FpMIg6#fnref:7
[23]: tmp.Ewi4FpMIg6#fnref:8

View File

@ -1,101 +0,0 @@
[#]: subject: "How curiosity helped me solve a hardware problem"
[#]: via: "https://opensource.com/article/22/1/troubleshoot-hardware-sysadmin"
[#]: author: "David Both https://opensource.com/users/dboth"
[#]: collector: "lujun9972"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
How curiosity helped me solve a hardware problem
======
Curiosity fuels the quest for knowledge and truth, whether it's about
hardware, open source software, programming, building a PC, optimizing
settings, or just learning a new application.
![Puzzle pieces coming together to form a computer screen][1]
I typically have a dozen computers up and running on my home network—yes, 12. And I am responsible for several more in other locations. With so many computers, there are always failures of various types, and I ultimately diagnose many of them as hardware problems. But it can be difficult to diagnose which hardware component is causing the issue.
Just this week, I had a perplexing problem that I misdiagnosed the cause of on my primary workstation—twice. This article takes you through the process I followed. I show you where and why I went down the wrong path and how easy it can be to do so.
### The first symptoms
I have been working on several projects. Recently, I had many applications open on multiple desktops and was just starting to work when the display went blank. Most (not all) of the fans in my primary workstation came to a stop, and I sucked in a deep breath. I'd never seen anything quite like this before, but I did know that my system was in trouble.
There were two primary clues I had to work with. The display went dark, and several fans had stopped. However, the front-panel power and disk activity LEDs were still on, although at a lower brightness level than usual. Most of the decorative RGB LED lights on my motherboard, memory DIMMs, and fans also went out.
I tried the power and reset buttons with no results. I turned off the power supply directly using the PSU rocker switch. Powering it back on resulted in the same set of symptoms.
### Initial thoughts
These symptoms and decades of experience with all kinds of failures pointed me to the power supply.
I removed the power supply and used my PSU tester to check it. The tester indicated that the PSU was good, and all voltages were within specs. However, I knew the tester could be wrong. PSU testers do not test under full load conditions such as those that exist when the computer is running and drawing a few hundred watts of power. I went with my gut and installed my spare 1000W power supply.
With an average of 12 computers in my home network, I have learned to keep plenty of spare parts on hand. It saves a lot of frustration that I don't have to run to the local computer store or order online and wait for delivery when things break—and things are always breaking with that many computers around.
That replacement power supply solved the problem despite the result I got from the PSU tester. Even though the tester has been correct many times in the past, my experience, my knowledge, and my gut told me differently.
Unfortunately, my gut instinct was wrong.
### Second thoughts
My workstation was exhibiting the same symptoms again. It is very unlikely that two different PSUs would fail exactly the same way.
Next idea: It had to be the motherboard. I don't keep spare motherboards around, so I ordered a new one online and figured that I could use extra memory I already had and move the CPU to the new motherboard along with its all-in-one liquid cooling unit.
### Disciplined troubleshooting
The new motherboard would take a couple of days to arrive, so I decided to prepare by removing the old one from the workstation. But before I unplugged the power feeds to the motherboard, my curiosity took over and forced me to power on the system with only the motherboard, CPU, and memory installed. I had disconnected everything else.
Good troubleshooting demands that you isolate all potential variables, and all I'd done so far was test the PSU. I had to test every component.
This process required me to disconnect the front panel cables for sound and the dashboard media panel that includes various USB, SATA, and memory card slots.
With just the motherboard connected, I got a surprise: Everything worked as normal!
The computer itself wouldn't boot because there were no connected storage drives, and nothing was displayed because I had removed the display adapter. But there were no symptoms of either power or motherboard failure. That piqued my curiosity even more. If the motherboard were truly bad, the symptoms would still exist.
So I started a sequence of powering off, reinstalling one of the removed components, and powering back on.
It turns out that the front panel media dashboard caused the symptoms.
I removed the media dashboard and plugged everything else back in. My workstation booted up properly and performed as expected. I had identified the culprit.
### How it started
Having figured out the actual problem, I immediately understood the root cause. It had started a couple of days previously. I was working with and testing several external USB devices, including various cameras, storage devices that I use for backups, and an external USB hub.
I picked up one USB cable and plugged it into a USB 2.0 slot on the media dashboard. Everything ground to a halt, and most of the lights and fans went out. I unplugged the USB cable, which was now very hot, and burned my fingers. I had inadvertently plugged the type C end into the USB 3.0 type A socket, which had shorted the power.
After unplugging the USB cable, everything went back to "normal"—except it didn't. The media dashboard lasted a few more days and then shorted out completely, having been weakened by my careless mistake.
### Jumping to conclusions
Knowledge and experience can sometimes count for more than tools like PSU testers. Except when they don't. I eventually found the actual cause of the problem, but I should have seen it sooner.
Although I was correct about this being a power problem, I was sidetracked by not correctly reading the symptoms and following that line of inquiry to its logical conclusion. I could have isolated the true cause of the problem sooner than I did and saved the time I spent configuring my laptop to be a temporary primary device until I could fix my primary workstation.
Sysadmins work with complex devices, and it can be easy to jump to conclusions. I have over 50 years of experience in the computer industry, and I still do it. I just need to remember to take a few deep [yoga breaths][2] and keep digging until I isolate the root cause of the problem.
### Curiosity
At least I followed my curiosity while waiting for the replacement motherboard to arrive. That allowed me to return things to normal much sooner than had I waited until the new motherboard arrived. And I might have discarded a perfectly good motherboard by not testing it further.
There is a saying about curiosity killing the cat. I hate that saying because it is all too frequently used by parents, colleagues, pointy-haired bosses, teachers, and others who just want us curious folk to leave them alone. In reality, curiosity fuels the quest for knowledge and truth, whether it's about hardware, open source software, programming, building a PC, optimizing settings, or just learning a new application. Feed your curiosity!
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/1/troubleshoot-hardware-sysadmin
作者:[David Both][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/dboth
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/puzzle_computer_solve_fix_tool.png?itok=U0pH1uwj (Puzzle pieces coming together to form a computer screen)
[2]: https://opensource.com/article/21/11/linux-yoga

View File

@ -1,104 +0,0 @@
[#]: subject: "How we hired an open source developer"
[#]: via: "https://opensource.com/article/22/2/how-we-hired-open-source-developer"
[#]: author: "Mike Bursell https://opensource.com/users/mikecamel"
[#]: collector: "lujun9972"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
How we hired an open source developer
======
My team opted out of the standard algorithm coding exercise for a
process that yielded more relevant results.
![people in different locations who are part of the same team][1]
As the CEO and co-founder of [Profian][2], a start-up security company, I've been part of our effort to hire developers to work on [Enarx][3], a security project that deals with confidential computing, written almost exclusively in [Rust][4] (with a bit of Assembly). Profian has now found all the people it was looking for in this search, with a couple of developers due to start in the next few weeks. However, new contributors are absolutely welcome to Enarx, and if things continue to go well, the company will definitely want to hire more folks in the future.
Hiring people is not easy, and Profian had a set of specialized requirements that made the task even more difficult. I thought it would be useful and interesting for the community to share how we approached the problem.
### What were we looking for?
These are the specialized requirements I'm talking about:
* **Systems programming:** Profian mainly needs people who are happy programming at the systems layer. This is pretty far down the stack, with lots of interactions directly with hardware or the OS. To create client-server pieces, for instance, we have to write quite a lot of the protocols, manage the crypto, and so forth, and the tools for this aren't all very mature (see "Rust" below).
* **Rust:** Almost all of the project is written in Rust, and what isn't is written in Assembly language (currently exclusively x86, though that may change as we add more platforms). Rust is new, cool, and exciting, but it's still quite young, and some areas don't have all the support you might like or aren't as mature as you'd hope—everything from cryptography through multithreading libraries and compiler/build infrastructure.
* **Distributed team:** Profian is building a team of folks where we can find them. Profian has developers in Germany, Finland, the Netherlands, North Carolina (US), Massachusetts (US), Virginia (US), and Georgia (US). I'm in the United Kingdom, our community manager is in Brazil, and we have interns in India and Nigeria. We knew from the beginning that we wouldn't have everyone in one place, and this required people who would be able to communicate and collaborate with people via video, chat, and (at worst) email.
* **Security:** Enarx is a security project. Although we weren't specifically looking for security experts, we need people who can think and work with security top of mind and design and write code that is applicable and appropriate for the environment.
* **Git:** All of our code is stored in git (mainly [GitHub][5], with a bit of GitLab thrown in). so much of our interaction around code revolves around git that anybody joining us would need to be very comfortable using it as a standard tool in their day-to-day work.
* **Open source:** Open source isn't just a licence; it's a mindset and, equally important, a way of collaborating. A great deal of open source software is created by people who aren't geographically co-located and who might not even see themselves as a team. We needed to know that the people we hired, while gelling as a close team within the company, would be able to collaborate with people outside the organisation and embrace Profian's "open by default" culture, not just for code, but for discussions, communications, and documentation.
### How did we find them?
As I've mentioned elsewhere, [recruiting is hard][6]. Profian used a variety of means to find candidates, with varying levels of success:
* LinkedIn job adverts
* LinkedIn searches
* Language-specific discussion boards and hiring boards (e.g., Reddit)
* An external recruiter (shout out to Gerald at [Interstem][7])
* Word-of-mouth/personal recommendations
It's difficult to judge between these sources in terms of quality, but without an external recruiter, we'd certainly have struggled with quantity (and we had some great candidates from that pathway, too).
### How did we select them?
We needed to measure all of the candidates against all of the requirements noted above, but not all of them were equal. For instance, although we were keen to hire Rust programmers, someone with strong C/C++ skills at the systems level would be able to pick up Rust quickly enough to be useful. On the other hand, a good knowledge of using git was absolutely vital, as we couldn't spend time working with new team members to bring them up to speed on our way of working.
A strong open source background was, possibly surprisingly, not a requirement, but the mindset to work in that sort of model was, and anyone with a history of open source involvement is likely to have a good knowledge of git. The same goes for the ability to work in a distributed team: So much of open source is distributed that involvement in almost any open source community was a positive indicator. Security, we decided, was a "nice-to-have" qualification.
We wanted to keep the process simple and quick. Profian doesn't have a dedicated HR or People function, and we're busy trying to get code written. This is what we ended up with (with slight variations), and we tried to complete it within 1-2 weeks:
1. Initial CV/resume/GitHub/GitLab/LinkedIn review to decide whether to interview
2. 30-40 minute discussion with me as CEO, to find out if they might be a good cultural fit, to give them a chance to find out about us, and to get an idea if they were as technically adept as they appeared in Step 1
3. Deep dive technical discussion led by Nathaniel, usually with me there
4. Chat with other members of the team
5. Coding exercise
6. Quick decision (usually within 24 hours)
The coding exercise was key, but we decided against the usual approach. Our view was that a pure "algorithm coding" exercise beloved by many tech companies was pretty much useless for what we wanted: to find out whether a candidate could quickly understand a piece of code, fix some problems, and work with the team to do so. We created a GitHub repository with some almost-working Rust code in it (in fact, we ended up using two, with one for people a little higher up the stack), then instructed candidates to fix it, perform some git-related processes on it, and improve it slightly, adding tests along the way.
An essential part of the test was to get candidates to interact with the team via our chat room(s). We scheduled 15 minutes on a video call for setup and initial questions, two hours for the exercise ("open book" as well as talking to the team, candidates were encouraged to use all resources available to them on the Internet), followed by a 30-minute wrap-up session where the team could ask questions, and the candidate could reflect on the task. This conversation, combined with the chat interactions during the exercise, allowed us to get an idea of how well the candidate was able to communicate with the team. Afterwards, the candidate would drop off the call, and we'd most often decide within 5-10 minutes whether we wanted to hire them.
This method generally worked very well. Some candidates struggled with the task, some didn't communicate well, some failed to do well with the git interactions these were the people we didn't hire. It doesn't mean they're not good coders or might not be a good fit for the project or the company later on, but they didn't meet the criteria we need now. Of the developers we hired, the level of Rust experience and need for interaction with the team varied, but the level of git expertise and their reactions to our discussions afterwards were always sufficient for us to decide to take them.
### Reflections
On the whole, I don't think we'd change a huge amount about the selection process—though I'm pretty sure we could do better with the search process. The route through to the coding exercise allowed us to filter out quite a few candidates, and the coding exercise did a great job of helping us pick the right people. Hopefully, everyone who's come through the process will be a great fit and produce great code (and tests and documentation and …) for the project. Time will tell!
* * *
This article originally appeared on [Alice, Eve and Bob a security blog][8] and is republished with permission.
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/2/how-we-hired-open-source-developer
作者:[Mike Bursell][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/mikecamel
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/connection_people_team_collaboration.png?itok=0_vQT8xV (people in different locations who are part of the same team)
[2]: https://profian.com/
[3]: https://enarx.dev/
[4]: https://opensource.com/article/21/3/rust-programmer
[5]: https://github.com/enarx/
[6]: https://aliceevebob.com/2021/11/09/recruiting-is-hard/
[7]: https://www.interstem.co.uk/
[8]: https://aliceevebob.com/

View File

@ -1,134 +0,0 @@
[#]: subject: "“Its time to contribute to open source”"
[#]: via: "https://www.opensourceforu.com/2022/06/its-time-to-contributing-to-open-source/"
[#]: author: "Abbinaya Kuzhanthaivel https://www.opensourceforu.com/author/abbinaya-swath/"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
“Its time to contribute to open source”
======
Nilesh Vaghela is an AWS community hero and founder, ElectroMech Corporation, a cloud and open source company. According to him, contributing to open source is a rewarding act in itself. However, it needs commitment and there are many steps involved in the process, right from selecting a project to ensuring your contribution is noticed. In a conversation with Abbinaya Kuzhanthaivel of OSFY, he shares a few tips on how developers can help to improve Indias contributions to open source.
![Nilesh Vaghela,
AWS community hero and
founder, ElectroMech Corporation][1]
##### Q. Can you tell us a bit about your current role and contributions to open source.
**A.** I am currently an architect working on automation. I lead multiple teams and also contribute majorly to Invinsense, an open source security service platform. I started open source groups in early 1998 and had around 1500 members even then. A group (https://groups.google.com/g/vglug) I am handling now has been very active since 2014-15.
##### Q. How did you start working with open source projects?
**A.** I am a mechanical engineer by qualification, and was dealing with modems and UPS systems at my firm ElectroMech Corporation. I slowly got dragged into handling PCs, networking and Linux. I started experimenting in 1996 after getting inspired by seeing over 150 computer servers running on Linux at a Nuclear Science Centre. Thats when I converted my company entirely, focusing on open source for training and support.
I can proudly say that I was one of the first and early adopters of open source — helping customers to understand what is open source, what are its benefits, whats available for free, security or code issues, and so on. We got at least four or five customers in Vadodara supporting us, and we eventually promoted ourselves through advertisements in the Yellow Pages. We partnered with Red Hat and the journey continues till now.
##### Q. How do you think open source has evolved since then?
A. I can say that, earlier, open source was a passion that fascinated and attracted people to participate. I was particularly impressed hearing user-friendly stories across the world when some Siberian contributors were working to improve water scarcity. It was more like a corporate social responsibility (CSR) activity. A board would be created by people and experts to govern and take projects forward. People would come in for the love of technology without expectations.
I did not believe then that open source could get commercial, but it is the driving force for most of the innovation and technology today, and many more enterprises are adopting it. We are looking forward to a great balance in contribution to and use of open source, as we have people, communities and big companies coming into play. This is the real future and power of open source.
##### Q. Could you share some of your challenges?
A. Initially, I walked alone but people joined once they knew my intentions were good. I created a lot of communities without any expectation, but did get paid indirectly in terms of reputation or fame; some people understood that I was a technical expert and gave projects in the long term. As it was very early days, people started joining the community and contributing without much effort. The goal wasnt to get business and hence I can say I didnt really face any hurdles.
##### Q. What are your leadership mantras and lessons from being a community leader?
**A.** First, if you want to start a community, then be neutral and dont harbour a biased opinion. It may look like you are running a community as a leader, but remember those joining you are contributing equally. And never demotivate anyone. Be polite while making comments and addressing queries. Whatever the question, if you dont want to give an answer, then choose to be quiet. But dont stop anyone from asking. Help them build expertise.
Second, dont involve the community in business. Do not mix and match the goals of your business and community. Have a clear differentiation.
Always try to encourage people to participate instead of delivering instructions as an expert. If you find people are interested to lead and take initiatives, then give them the stage. Invite and engage them in the community. That will help you to make more community leaders. Also, keep your community simple and dont involve sponsors in the initial stages.
##### Q. Who do you look up to for inspiration?
**A.** Richard Stallman, the father of the open source movement, is my inspiration and I have always admired his projects.
Apart from him, I have an interesting incident to share that inspired me to work on open source. At the time when I started working on open source, most of the software for the Nuclear Science Centre was based on the Windows OS. However, many scientists wanted to work with Linux based software. And within two or three months, they actually created Linux drivers. This is what fascinated me that the user can create these drivers which may not be possible in the case of proprietary software. I really liked the fact that open source empowered the user.
##### Q. Your thoughts on the open source landscape in India and the scope for improvement.
**A.** India is the largest consumer of open source and we are focusing on becoming a contributor. With so many developers around, we still do not have software giants in India. What we have mostly are service providers and not innovators. More people should become contributors to open source and develop something with international labels.
The very thought of contributing to open source should begin from the level of schools and colleges. Fortunately, the Gujarat government has already introduced lessons based on Linux from Class 8 to Class 10. It is important to educate and make youngsters aware of open source models.
Second, we have to develop good mentors. When people start contributing, it is important to find an open source mentor working in that particular project. The mentor gives a small assignment, tries the code and then commits it. If everything goes fine, the contribution is increased gradually. Unfortunately, we have very few mentors available in India. We need to prepare a lot of mentors or maybe connect to those across the world.
Third, we need to encourage those who come forward to contribute. Once you are a recognised developer or a person contributing to open source development, you also progress in your career and business.
India can be a major contributor to open source by following such simple methods.
##### Q. What do you think about the coding requirements to contribute to open source?
**A.** From my experience, if you know the internal parts, how to develop the application, what code standard you should maintain, and how to manage the team and other best practices, you may not have to actually worry about coding expertise.
There are other roles too with respect to designing, security maintenance and integration. See what works for you. Develop and strengthen your skill in what you like to do. If you feel coding still interests you, then take the support of fellow developers to learn it.
##### Q. How do you shortlist a project you would like to contribute to?
A. You need to understand your top few interest areas and then do your research on the projects happening around them. You need to figure out the area of requirements or openings for contributors and more volunteers. You can start small to practice and then build expertise.
Avoid going by the trendy topics; whats important is your individual interest. For instance, DevOps is in high demand now and you may tend to go for a DevOps project. Do not make this mistake.
You can find open source projects on Cloud Native Computing Foundation ([CNCF][2]), Apache, Fedora, Red Hat, and so on. This way you can also find mentors who are already working on projects and can get proper guidance.
##### Q. Projects have their own purpose and target audience. Sometimes they even misalign with open source goals. So, what does one check before contributing?
A. I agree it becomes challenging when somebody starts an open source project and then commercialises it. But this is always a risk, and should not discourage you.
First try to check out the group — how popular are the contributors working in the group, how long have they been contributing, and how reputed are they. And once you join, observing everyone and everything is the key. Try to learn at least for three to six months, and understand how everything works. You can always leave the project if you find the intention is wrong. But if you feel its all right, then go ahead and contribute.
![The team at ElectroMech Corporation][3]
There are certain licence checks that you can do, say, like GPL version 3. You can also look at unmodified licence versions like the Apache open source licence.
##### Q. Do you think big companies will accept contributions from freshers?
A. Yes, of course. Companies also like mentoring. They usually dont allow you to contribute directly, but may give you a small assignment initially. A mentor will first try to understand what skill you have and how good you are at it. Once they recognise you have the kind of skill that is needed, they will continue to guide you or assign you to some other mentor based on your skill. The initial stages are very crucial. Many companies do some sort of screening, and you may be allowed to contribute only after you have proved your ability.
##### Q. What are the initial challenges that contributors have to overcome when picking up projects?
A. First, you should be very serious about your contribution. There are no written commitments and contributors may tend to take the work lightly. Thats totally wrong. Try to dedicate 8-10 hours or whatever is feasible each day. If you are skipping this commitment because you feel there are no immediate returns, then you will not be a good contributor.
Always adhere to a mentors guidance strictly at the initial stages. This is very crucial for a healthy contribution. Sometimes it may happen that you believe you are good at something, while your mentor may not assign a project based on that skill. Simply approach your mentor in such scenarios and ask him what you should do, what is your role, and how you can contribute.
##### Q. Many developers do not get replies after submitting the contribution to a project. How does one make a submission noticeable?
A. Write a small blog on the project you are planning to contribute to, covering aspects like what you like in it, what you dont like, and what can be improved. Such a positive and promotional approach can greatly help you.
Be a part of the group and be involved in activities related to that particular project. Instead of contributing, first try to engage with the group, and this will increase the chances for you to get adopted as a contributor.
Once you have a better understanding of the project, not only will your work be accepted but you will be able to better align yourself with that project.
##### Q. How do you overcome a situation where your contribution is not accepted?
A. Just understand that this can happen for many reasons — maybe you are not in the right project or you have not contributed correctly. If the project is country driven, your request may not be accepted. Hence, remember to have a checklist as stated earlier. Dont worry if your contribution is not accepted because either you are not fit for the project or the project is not fit for you.
All I would recommend is try to identify four or five projects, and at least one among those projects you work on will probably be accepted.
##### Q. What is your message for our readers?
A. Open source is the driving force behind most of the innovation happening today. Instead of just using open source, let us try to contribute according to our capacity and skills. Contributions can be in terms of code, documentation, testing, blogs, money, etc. Its time to contribute.
##### Q. Any hiring plans for ElectroMech Corporation — what are the roles and skill expectations?
We have requirements in cloud DevOps, and are hiring cloud architects, Python developers, Linux architects and security professionals.
--------------------------------------------------------------------------------
via: https://www.opensourceforu.com/2022/06/its-time-to-contributing-to-open-source/
作者:[Abbinaya Kuzhanthaivel][a]
选题:[lkxed][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.opensourceforu.com/author/abbinaya-swath/
[b]: https://github.com/lkxed
[1]: https://www.opensourceforu.com/wp-content/uploads/2022/05/Nilesh-Vaghela-AWS-community-hero-and-founder-ElectroMech-Corporation.jpg
[2]: https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&cad=rja&uact=8&ved=2ahUKEwib2vvv3dv3AhVa7XMBHfZSCsIQFnoECAgQAQ&url=https%3A%2F%2Fwww.cncf.io%2F&usg=AOvVaw2LnRyH4SZPDHntRLJU_b3q
[3]: https://www.opensourceforu.com/wp-content/uploads/2022/05/The-team-at-ElectroMech-Corporation.jpg

View File

@ -1,94 +1,93 @@
[#]: subject: "Open Source Software: Is There an Easy Path to Success?"
[#]: via: "https://www.opensourceforu.com/2022/07/open-source-software-is-there-an-easy-path-to-success/"
[#]: author: "Jules Graybill https://www.opensourceforu.com/author/jules-graybill/"
[#]: collector: "lkxed"
[#]: translator: "CanYellow"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
开源软件:存在成功的捷径吗?
======
开发开源软件背后的工作是相当庞大的。那么我们如何保证开源项目的成功呢?存在捷径吗?本文认为是没有的。
![团队合作][1]
今天,开源已经风靡世界。很多大型企业在快速成功的诱惑下被推向开源。但真实情况是世界上并不存在成功的捷径。你无法做到通过一次努力就能让所有的开源项目正常运行。
事实上,上述公司早期遇到的许多挑战都不是技术上的,而是人员与文化上的。
开发一个能够在市场上获得成功的开源项目需要同不同层级(的开源社区人员)一同工作。维护这样的项目也是一个持续的过程。所有这一切的关键在于找到以下这个非常基础的问题的正确答案:开源究竟是什么。
### 开源是代码
对于很多没有深刻认识到构成开源的不同层级(的开源社区人员)用户而言,答案相当简单:开源就是软件!这当然没有错,毕竟这就是我们多数人如何使用它的。不过,相比仅仅被视作软件而言,开源远不止这些。
任何开源项目的实质仍然是代码本身。代码是使一个开源项目有别于其他项目并使其对用户有益的根本。当你在开源中工作的时候,代码和软件一样都是产品自身的一部分。
从零开始开发一个(开源)项目或者复刻(fork)一个现有项目的分支,即便是在处理如此庞大而复杂的代码库时,也需要编写成千上万行代码。尤其是在创新一个现有项目的分支的情况下,在移除任何在先的许可证、宣传材料或者其他任何可能已经失去作用的文件时必须小心翼翼。终究是一个项目的功能吸引了它的用户群并维持项目的持续发展。当终端用户在考虑是否使用开源软件的时候,他们会阅读项目的源代码,而他们在其中所看到的应当是那些能够建立他们的信心的内容。
### 开源是社区
如何参与到社区中也是产品构建项目的一部分。创建一个社区并维护一个健康的社区关系是开源的核心之一,但对于大部分的领导者而言也往往是最坚难的任务,很少有人能很好地维护它。你可以尝试建立基金会或者提供赞助,但是最终还是人们自行决定是否想要加入社区。
维护一定程度的社区透明度并不断保持也是重要的。社区可以随心所欲地参与项目。除了需要秘密进行的工作之外,诸如安全设置、签发证书、注册商标等,尽可能多的将你所做的工作展示给社区是相当重要的,这有助于取得社区信任。你终究需要对社区负责,你的项目成也社区,败也社区。这可能会导致你的项目开发更谨慎、更缓慢并且向社区公开,不过项目最终会进展顺利。
如此地公开你正在进行的工作似乎有些令人生怯,尤其是当你担心更新推迟或者是出现漏洞的影响的时候。不过,让社区成员知悉你的进展不仅有助帮助你建立与社区之间的信任关系,而且能够让社区成员感到被认可。
另一方面,公开你的工作流也可以获得来自社区成员的监督,他们经常有自己的见解并向你反馈。记录这些反馈是很重要的,这使得你的开源项目如实地反映社区需求。他们是项目的末端用户,而他们的反馈则反映了他们如何看待你的项目的长期发展以及你的项目最终将有多么成功或者主流。
举例而言,当我们在考虑一个新功能的时候,我们在征求意见文档(RFC, Request for Comments)中发布一个征集意见的请求,我们会收到大量的反馈,我们必须认真思考应当如何吸收这些反馈。
因为开源是一个大型的合作项目,社区在支持开源项目成为可能的万里挑一的项目上享有主动权。并非所有的问题都要解决,但只要你有在倾听社区的呼声,社区就会有参与感。
参与到社区中也存在一些隐患。社区内部、项目维护与社区之间均可能存在不同意见,尤其是在涉及管理问题上。管理问题对于一个开源项目来说是相当重要的。这也就是为什么拥有一份清晰的文档化的管理条例对于项目以及社区均是如此重要。
社区管理是一个关键的而又难啃的骨头。社区授权本身需要相当大的信任。对于一个拥有成千上万行代码的项目,在社区中寻找能够有效领导社区的人物是不容易的。不过开源项目经常是由更小的子项目组成的,这些子项目最好由社区中的某个人进行管理。这有助于社区更紧密地参与到项目中。
| - |
| :- |
| 建立社区的过程不是一帆风顺的。让我列举一一些有助于维持社区与我的团队之间平衡的技巧。
**声明你的原则:**尤其是在开源项目的早期,在项目代码仍在完善,很多事情还不完美的时候,项目之外的人员很难真正理解你所做的决定。向他们说明你做出决定所依据的原则有助于你在思考过程上保持坦率,从而让社区不会错误地干扰你的事务。
这一经验非常有效,在你做出决定时坚持遵循其中一项原则并展示出来是非常重要的。
*确定如何进行协作:*你可以通过Discord、Slack或者邮件等途径完成这一工作。但是如果你试图同时使用他们你将毫不意外的分散项目社区。社区人员将在所有这些途径上互相交流。选择一到两种沟通工具投身于他们来保证社区的信息同步。
*珍惜反馈意见:*倾听来自社区的反馈并付诸行动。即使需要你作出艰难的决定,你也应当向社区展示你是重视社区话语的。
**维护一套行为准则:**如果你与社区打交道,你需要定义什么行为是可以接受的。一套落地的行为准则有助于在人们越过红线时警示他们。如果你可以提前制定这些你可以避免很多麻烦。
*考虑如何分发你的项目:*存在这样的情况,因为你还没有准备好某一个组件,或者是因为存在一些项目功能你不希望所有人都能够访问,所以你可能并不希望将你的项目完全向公众公开。关键是制定符合你的要求而不是向用户妥协的分发条款,如此,需要某种功能的用户可以获取所需项目的同时不需要该功能的用户也不需要做出妥协而开始使用该项目。
*尽可能地避免投票:*这是因为部分成员经常会赞成与大部分成员的意见相左的选项,这会使这些人产生一定程度的失望,并让他们觉得被项目所孤立。反之,尽量尝试询问他们想要解决什么问题,并尝试创造一个不需要付出代价的解决方案。
### 开源是许可
开源是给予你的用户如何使用你的软件的自由,而许可能够做到这一点。一个开源项目许可是极好的,它保证了不论你作为维护者做了什么,你的所有终端用户以及利益相关方总是可以维护一系列的项目复刻版本,这些都是重要的项目复刻版。
许可提供了人们可选择性,如果他们认为有必要,他们可以将项目复制到不同的路径中。他们拥有创建副本的权利,这使得许多优秀的软件能够被开发出来。维护者有责任倾听他们的社区成员的声音并以一个对项目的社区成员有利的方式运营项目。
我们推荐使用现有的许多可用的许可证而不是独立制作你自己的许可条款,仅仅只是因为用户以及利益相关方通常都很熟悉公共许可证,因此你不需要再花费时间在解释许可条款上。这将帮助你将你的精力集中在项目的其他部分上。
### 最后,开源是一项运动
开源包括了很多维度,也包含了很多人员。最重要的是,它是有关理解人们想要什么的,也是有关创建一个鼓励协作与透明的环境的。开源也是有关创建有利于开源项目走自己想走的道路的社区的。维护者创造越多的机会让社区自由发挥,开源产品就越好,也越发成功。
开源是以上这些方面,而你的视野越宽阔,你就能越好的利用它。请考虑你如何能够在开源的每一个维度上出类拔萃,因为时至今日,开源的成功之路并无捷径。
--------------------------------------------------------------------------------
via: https://www.opensourceforu.com/2022/07/open-source-software-is-there-an-easy-path-to-success/
作者:[Jules Graybill][a]
选题:[lkxed][b]
译者:[CanYellow](https://github.com/CanYellow)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.opensourceforu.com/author/jules-graybill/
[b]: https://github.com/lkxed
[1]: https://www.opensourceforu.com/wp-content/uploads/2022/07/team-work-working-together-1.jpg
[#]: subject: "Open Source Software: Is There an Easy Path to Success?"
[#]: via: "https://www.opensourceforu.com/2022/07/open-source-software-is-there-an-easy-path-to-success/"
[#]: author: "Jules Graybill https://www.opensourceforu.com/author/jules-graybill/"
[#]: collector: "lkxed"
[#]: translator: "CanYellow"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
开源软件:存在成功的捷径吗?
======
开发开源软件背后的工作是相当庞大的。那么我们如何保证开源项目的成功呢?存在捷径吗?本文认为是没有的。
![团队合作][1]
今天,开源已经风靡世界。很多大型企业在快速成功的诱惑下被推向开源。但真实情况是世界上并不存在成功的捷径。你无法做到通过一次努力就能让所有的开源项目正常运行。
事实上,上述公司早期遇到的许多挑战都不是技术上的,而是人员与文化上的。
开发一个能够在市场上获得成功的开源项目需要同不同层级(的开源社区人员)一同工作。维护这样的项目也是一个持续的过程。所有这一切的关键在于找到以下这个非常基础的问题的正确答案:开源究竟是什么。
### 开源是代码
对于很多没有深刻认识到构成开源的不同层级(的开源社区人员)用户而言,答案相当简单:开源就是软件!这当然没有错,毕竟这就是我们多数人如何使用它的。不过,相比仅仅被视作软件而言,开源远不止这些。
任何开源项目的实质仍然是代码本身。代码是使一个开源项目有别于其他项目并使其对用户有益的根本。当你在开源中工作的时候,代码和软件一样都是产品自身的一部分。
从零开始开发一个(开源)项目或者复刻(fork)一个现有项目的分支,即便是在处理如此庞大而复杂的代码库时,也需要编写成千上万行代码。尤其是在创新一个现有项目的分支的情况下,在移除任何在先的许可证、宣传材料或者其他任何可能已经失去作用的文件时必须小心翼翼。终究是一个项目的功能吸引了它的用户群并维持项目的持续发展。当终端用户在考虑是否使用开源软件的时候,他们会阅读项目的源代码,而他们在其中所看到的应当是那些能够建立他们的信心的内容。
### 开源是社区
如何参与到社区中也是产品构建项目的一部分。创建一个社区并维护一个健康的社区关系是开源的核心之一,但对于大部分的领导者而言也往往是最坚难的任务,很少有人能很好地维护它。你可以尝试建立基金会或者提供赞助,但是最终还是人们自行决定是否想要加入社区。
维护一定程度的社区透明度并不断保持也是重要的。社区可以随心所欲地参与项目。除了需要秘密进行的工作之外,诸如安全设置、签发证书、注册商标等,尽可能多的将你所做的工作展示给社区是相当重要的,这有助于取得社区信任。你终究需要对社区负责,你的项目成也社区,败也社区。这可能会导致你的项目开发更谨慎、更缓慢并且向社区公开,不过项目最终会进展顺利。
如此地公开你正在进行的工作似乎有些令人生怯,尤其是当你担心更新推迟或者是出现漏洞的影响的时候。不过,让社区成员知悉你的进展不仅有助帮助你建立与社区之间的信任关系,而且能够让社区成员感到被认可。
另一方面,公开你的工作流也可以获得来自社区成员的监督,他们经常有自己的见解并向你反馈。记录这些反馈是很重要的,这使得你的开源项目如实地反映社区需求。他们是项目的末端用户,而他们的反馈则反映了他们如何看待你的项目的长期发展以及你的项目最终将有多么成功或者主流。
举例而言,当我们在考虑一个新功能的时候,我们在征求意见文档(RFC, Request for Comments)中发布一个征集意见的请求,我们会收到大量的反馈,我们必须认真思考应当如何吸收这些反馈。
因为开源是一个大型的合作项目,社区在支持开源项目成为可能的万里挑一的项目上享有主动权。并非所有的问题都要解决,但只要你有在倾听社区的呼声,社区就会有参与感。
参与到社区中也存在一些隐患。社区内部、项目维护与社区之间均可能存在不同意见,尤其是在涉及管理问题上。管理问题对于一个开源项目来说是相当重要的。这也就是为什么拥有一份清晰的文档化的管理条例对于项目以及社区均是如此重要。
社区管理是一个关键的而又难啃的骨头。社区授权本身需要相当大的信任。对于一个拥有成千上万行代码的项目,在社区中寻找能够有效领导社区的人物是不容易的。不过开源项目经常是由更小的子项目组成的,这些子项目最好由社区中的某个人进行管理。这有助于社区更紧密地参与到项目中。
| - |
| :- |
| 建立社区的过程不是一帆风顺的。让我列举一一些有助于维持社区与我的团队之间平衡的技巧。
**声明你的原则:**尤其是在开源项目的早期,在项目代码仍在完善,很多事情还不完美的时候,项目之外的人员很难真正理解你所做的决定。向他们说明你做出决定所依据的原则有助于你在思考过程上保持坦率,从而让社区不会错误地干扰你的事务。
这一经验非常有效,在你做出决定时坚持遵循其中一项原则并展示出来是非常重要的。
*确定如何进行协作:*你可以通过Discord、Slack或者邮件等途径完成这一工作。但是如果你试图同时使用他们你将毫不意外的分散项目社区。社区人员将在所有这些途径上互相交流。选择一到两种沟通工具投身于他们来保证社区的信息同步。
*珍惜反馈意见:*倾听来自社区的反馈并付诸行动。即使需要你作出艰难的决定,你也应当向社区展示你是重视社区话语的。
**维护一套行为准则:**如果你与社区打交道,你需要定义什么行为是可以接受的。一套落地的行为准则有助于在人们越过红线时警示他们。如果你可以提前制定这些你可以避免很多麻烦。
*考虑如何分发你的项目:*存在这样的情况,因为你还没有准备好某一个组件,或者是因为存在一些项目功能你不希望所有人都能够访问,所以你可能并不希望将你的项目完全向公众公开。关键是制定符合你的要求而不是向用户妥协的分发条款,如此,需要某种功能的用户可以获取所需项目的同时不需要该功能的用户也不需要做出妥协而开始使用该项目。
*尽可能地避免投票:*这是因为部分成员经常会赞成与大部分成员的意见相左的选项,这会使这些人产生一定程度的失望,并让他们觉得被项目所孤立。反之,尽量尝试询问他们想要解决什么问题,并尝试创造一个不需要付出代价的解决方案。
### 开源是许可
开源是给予你的用户如何使用你的软件的自由,而许可能够做到这一点。一个开源项目许可是极好的,它保证了不论你作为维护者做了什么,你的所有终端用户以及利益相关方总是可以维护一系列的项目复刻版本,这些都是重要的项目复刻版。
许可提供了人们可选择性,如果他们认为有必要,他们可以将项目复制到不同的路径中。他们拥有创建副本的权利,这使得许多优秀的软件能够被开发出来。维护者有责任倾听他们的社区成员的声音并以一个对项目的社区成员有利的方式运营项目。
我们推荐使用现有的许多可用的许可证而不是独立制作你自己的许可条款,仅仅只是因为用户以及利益相关方通常都很熟悉公共许可证,因此你不需要再花费时间在解释许可条款上。这将帮助你将你的精力集中在项目的其他部分上。
### 最后,开源是一项运动
开源包括了很多维度,也包含了很多人员。最重要的是,它是有关理解人们想要什么的,也是有关创建一个鼓励协作与透明的环境的。开源也是有关创建有利于开源项目走自己想走的道路的社区的。维护者创造越多的机会让社区自由发挥,开源产品就越好,也越发成功。
开源是以上这些方面,而你的视野越宽阔,你就能越好的利用它。请考虑你如何能够在开源的每一个维度上出类拔萃,因为时至今日,开源的成功之路并无捷径。
via: https://www.opensourceforu.com/2022/07/open-source-software-is-there-an-easy-path-to-success/
作者:[Jules Graybill][a]
选题:[lkxed][b]
译者:[CanYellow](https://github.com/CanYellow)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.opensourceforu.com/author/jules-graybill/
[b]: https://github.com/lkxed
[1]: https://www.opensourceforu.com/wp-content/uploads/2022/07/team-work-working-together-1.jpg

View File

@ -1,131 +0,0 @@
[#]: subject: "Happy birthday, Linux! Here are 6 Linux origin stories"
[#]: via: "https://opensource.com/article/22/8/linux-birthday-origin-stories"
[#]: author: "AmyJune Hineline https://opensource.com/users/amyjune"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
Happy birthday, Linux! Here are 6 Linux origin stories
======
Our contributors share their first Linux experience on the 31st anniversary of the Linux kernel.
On August 25, 1991, Linux 0.01 was announced. All of us have a story to tell about Linux. I told my story a couple of months ago, but for those who weren't here: My first exposure to Linux was when my grassroots hospice organization moved from paper to digital charting. We didn't have the funding to get something proprietary, but the IT department had Linux set up on our old machine, and we used the GNOME desktop and OpenOffice to start our journey in creating digital assets.
I recently asked some Opensource.com authors this simple question:
*What was your first Linux experience?*
### From VAX to Linux
For my junior year of high school, I was shipped off to a state-run "nerd farm" (that's the North Carolina School of Science and Mathematics.) Our first day on campus, the juniors were each assigned a senior big brother or sister. My senior big sister ditched me because she had tickets to go to a big outdoor music festival with her boyfriend, but when they came back all sunburned, we hung out in my mostly empty dorm room eating takeout on the floor. That was when I first met Matt.
As the year wound on, Matt showed me how to help as a student sysadmin changing backup reels for the VAX mainframe and doing basic tasks on the "big" workstation that doubled as a campus-wide UNIX server. He had a PC in his room, with GNU and XWindows on a Minix kernel, but found this cool new alternative that some Finnish student had started posting the source code for on Usenet. I knew, right then and there, that was my future.
When I got home for the summer, the first thing I did was buy a shiny new 486 with some of my savings from odd jobs, fired up a SLIP connection through our local BBS, and downloaded and decoded all the bits and pieces I'd need to bootstrap and compile Linux 0.96.
Matt and I mostly lost touch after he graduated, but I'll always owe him for introducing me to the operating system kernel I'd use for the rest of my life. I think of him every time I see that tattered old copy of **Running Linux** adorning my office shelf.
The "Matt" in this story is Matthew D. Welsh. After we lost touch, he became the original maintainer of [The Linux Documentation Project][2], and the author of the first edition of the O'Reilly Press book **Running Linux**.
**[—Jeremy Stanley][3]**
### Computer club
Friends at a [computer club][4] inspired me to try Linux.
I used Linux to help students learn more about other operating systems from 2012 to 2015, and I would say that Linux has taught me more about computers in general.
It has probably affected my "volunteer career" because to this day I write articles about being a neurodiverse person in the Linux world. I also attend and join different Linux events and groups, so I've had access to a community I probably wouldn't have known otherwise.
**[—Rikard Grossman-Nielsen][5]**
### Galaxy
My Linux story started a long time ago in a galaxy far, far away. In the early 90s, I spent a year in the US as a high school student. Over there, I had access to e-mail and the Internet. When I came back home to Hungary, I finished high school without any Internet access. There were no public Internet providers in Hungary at that time. Only higher education, and some research labs, had Internet. But in 1994, I started university.
The very first wee of school, I was at the IT department asking for an email address. At that time, there was no Gmail, Hotmail, or anything similar. Not even teachers got an email address automatically at the university. It took some time and persistence, but I eventually received my first university email address. At the same time, I was invited to work in the faculty-student IT group. At first, I got access to a Novell and a FreeBSD server, but soon I was asked to give Linux a try.
It was probably late 1994 when I installed my first Linux at home. It was Slackware, from a huge pile of floppy disks. At first, I only did a minimal installation, but later I also installed X so I could have a GUI. In early 1995, I installed my first-ever Linux server at the university on a spare machine, which was also the first Linux server at the university. At that time, I used the [Fvwm2][6] window manager both at home and at the university.
At first, I studied environmental protection at the university, but my focus quickly became IT and IT security. After a while, I was running all the Linux and Unix servers of the faculty. I also had a part time job elsewhere, running web and e-mail servers. I started a PhD about an environmental topic, but I ended up in IT. I've worked with FreeBSD and Linux ever since, helping [sudo][7] and `syslog-ng` users.
**[—Peter Czanik][8]**
### Education
I got introduced to Linux in the late 1990s by my brother and another friend. My first distro was Red Hat 5, and I didn't like it at the time. I couldn't get a GUI running, and all I could see was the command-line, and I thought, "This is like MS-DOS." I didn't much care for that.
Then a year or more passed, and I picked up a copy of Red Hat 6.1 (I still have that copy) and got it installed on and HP Vectra with a Cyrix chip installed. It had plenty of hard disk space, which was fortunate because the Red Hat Linux software came on a CD. I got the GUI working, and set it up in our technology office at the school district I was employed at. I started experimenting with Linux and used the browser and Star Office (an ancestor of the modern [LibreOffice][9]), which was part of the included software.
A couple years later, our school district needed a content filter, and so I created one on an extra computer we had in our office. I got Squid, Squidguard, and later Dansguardian installed on Linux, and we had the first self-hosted open source content filter in a public school district in Western New York State. Using this distribution, and later Mandrake Linux (an ancestor of [Mageia][10] Linux) on old Pentium II and Pentium III computers, I set up devices that used [SAMBA][11] to provide backup and profile storage for teachers and other staff. Teaming with members of area school districts I set up spam filtering for a fraction of the cost that proprietary solutions were offering at the time.
Franklinville Central School District is situated in an area of high rural poverty. I could see that using Linux and open source software was a way to level the playing field for our students, and as I continued to repurpose and refurbish the "cast-off" computers in our storage closets, I built a prototype Linux terminal server running Fedora Core 3 and 4. The software was part of the K12LTSP project. Older computers could be repurposed and PXE booted from this terminal server. At one point, we had several computer labs running the LTSP software. Our staff email server ran on RHEL 2.1, and later RHEL 3.0.
That journey, which began 25 years ago, continues to this day as I continue to learn and explore Linux. As my brother once said, "Linux is a software Erector set."
**[—Don Watkins][13]**
### Out in the open
My first experience with Linux was brief, and it involved a lot of floppies. As I recall, it was entertaining until my dear wife discovered that her laptop no longer had Windows 98 installed (she was only moderately relieved when I swapped back in the original drive and the "problem" disappeared). That was around 1998, with a Red Hat release that came with a book and a poor unsuspecting ThinkPad.
But really, at work I always had a nice Sun Workstation on my desktop, so why bother? In 2005, we decided to move to France for a while, and I had to get a (usefully) working Toshiba laptop, which meant Linux. After asking around, I decided to go with Ubuntu, so that was my first "real" experience. I think I installed the first distro (codenamed Warty Warthog,) but soon I was on the latest. There were a few tears along the way, caused mostly by Toshiba's choice of hardware, but once it was running that darned laptop was every bit as fast, and way more functional, for me than the old Sun. Eventually, we returned home, and I had a nice new Dell PC desktop. I installed Feisty Fawn, and I've never looked back.
I've tried a few other distros, but familiarity has its advantages, particularly when configuring stuff at the lowest of levels. Really though, if forced to switch, I think I would be happy with any decent Linux distro.
At a few points in time, I have had to do "kernel stuff", like bisecting for bugs and fiddling around with device drivers. I really can't remember the last time something that complicated was necessary, though.
Right now, I have two desktops and one laptop, all running Ubuntu 22.04, and two aging Cubox i4-pro devices running Armbian, a great Debian-based distro created for people using single-board computers and similar devices. I'm also responsible for a very small herd of various virtual private running several distros, from CentOS to various versions of Ubuntu. That's not to mention a lot of Android-based stuff laying around, and we should recognize that it's Linux, too.
What really strikes me, as I read this back over, is how weird it all must sound to someone who has never escaped the clutches of a proprietary operating system.
**[—Chris Hermansen][15]**
### Getting involved
The first computer I bought was an Apple, the last Apple was a IIe. I got fed up with the strong proprietorship of Apple over the software and hardware, and switched to an Amiga, which had a nice GUI (incidentally, I have never owned another Apple product.)
Amiga eventually crumbled, and so I switched to Windows—what an awful transition! About this time, somewhere in the mid- to latter-90s, I was finding out about Linux, and began reading Linux magazines and how to set up Linux machines. I decided to set up a dual-boot machine with Windows, then bought Red Hat Linux, which at the time came on a number of floppy disks. The kernel would have been 2.0-something. I loaded it on my hard drive, and Presto! I was using Linux—the command-line. At that time, Linux didn't read all of your hardware and make automatic adjustments, and it didn't have all the drivers you needed, as it does today.
So next came the process of looking up in BBSes or wherever to find out where to get drivers for the particular hardware I had, such as the graphics chip. Practically, this meant booting into Windows, saving the drivers to floppy disk, booting back into Linux, and loading the drivers to the hard drive. You then had to hand-edit the configuration files so that Linux knew which drivers to use. This all took weeks to accomplish, but I can still recall the delight I felt when I typed `startx`, and up popped X-Windows!!
If you wanted to update your kernel without waiting for and buying the next release, you had to compile it yourself. I remember I had to shut down every running program so the compiler didn't crash.
It's been smooth sailing ever since, with the switch to Fedora (then called "Fedora Core"), and the ease of updating software and the kernel.
Later, I got involved with the [Scribus][16] project, and I started reading and contributing to the mail list. Eventually, I began contributing to the documentation. Somewhere around 2009, Christoph Schaefer and I, communicating over the internet and sharing files, were able to write **Scribus, The Official Manual** in the space of about 9 months.
**[—Greg Pittman][17]**
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/8/linux-birthday-origin-stories
作者:[AmyJune Hineline][a]
选题:[lkxed][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/amyjune
[b]: https://github.com/lkxed
[1]: https://opensource.com/sites/default/files/lead-images/rh_003499_01_linux31x_cc.png
[2]: https://tldp.org/
[3]: https://opensource.com/users/fungi
[4]: https://opensource.com/article/22/5/my-journey-c-neurodiverse-perspective
[5]: https://opensource.com/users/rikardgn
[6]: https://opensource.com/article/19/12/fvwm-linux-desktop
[7]: https://opensource.com/article/22/8/debunk-sudo-myths
[8]: https://opensource.com/users/czanik
[9]: https://opensource.com/article/21/9/libreoffice-tips
[10]: http://mageia.org
[11]: https://opensource.com/article/21/12/file-sharing-linux-samba
[12]: https://opensource.com/article/22/5/essential-linux-commands
[13]: https://opensource.com/users/don-watkins
[14]: https://www.redhat.com/sysadmin/linux-kernel-tuning
[15]: https://opensource.com/users/clhermansen
[16]: http://scribus.net
[17]: https://opensource.com/users/greg-p

View File

@ -1,125 +0,0 @@
[#]: subject: "Why Enterprises Should Opt for Platform as a Service"
[#]: via: "https://www.opensourceforu.com/2022/09/why-enterprises-should-opt-for-platform-as-a-service/"
[#]: author: "Gopala Krishna Behara https://www.opensourceforu.com/author/gopalakrishna-behara/"
[#]: collector: "lkxed"
[#]: translator: "onionstalgia"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
Why Enterprises Should Opt for Platform as a Service
======
*Platform as a Service enables quick and easy creation of Web applications without the necessity of buying and maintaining the software and infrastructure underneath it. This article explains why its useful.*
Platform as a Service (PaaS) refers to cloud computing services that provide a platform for customers to develop, run and manage applications without the complexity of building and maintaining the infrastructure associated with developing and launching them. This is the core platform on which cloud native applications and supporting systems are based.
PaaS typically involves diverse application software infrastructure capabilities including application platforms, integration platforms, business analytics platforms, event-streaming services and mobile back-end services. In addition, it includes a set of monitoring, management, deployment and related capabilities.
Developers are keen on getting their environments up without waiting, while operations teams care about performance and stability. This often gives rise to some conflict between them. PaaS creates a peaceful environment for both groups. An application platform delivered as a service is described as PaaS, and is used to deploy the user code. Cloud Foundry, Cloudify and OpenShift open source environments can be used as PaaS.
### PaaS adoption pattern
Cloud computing must satisfy five essential characteristics — on demand service, access network, resource pooling, elasticity and measured services. To achieve these, cloud computing provides three kinds of service models: Software as a Service (SaaS), Platform as a Service (PaaS) and Infrastructure as a Service (IaaS).
The key business drivers of PaaS adoption are:
* Reduction of capex and opex to deliver business services
* Minimising IT costs by improving the delivery time and quality of the application development and delivery
* Increasing the flexibility and integration between middleware components
**Simple PaaS** is the entry point into the PaaS space. It allows provisioning of application services and exposes them into a self-service catalogue; it automates the deployment and meters the resources used by this service.
*Manage PaaS* manages the SLA and QoS aspects of the provisioned applications such as resiliency, application performance, security, etc.
*Programming PaaS* allows applications to integrate with external applications or public clouds, and to implement auto-scaling and cloud-bursting scenarios.
*Process-oriented PaaS* allows implementation of a DevOps process by creating a continuous delivery flow that automates the build, test and delivery of applications into a cloud environment.
In addition to these adoption patterns, there are other variations of PaaS, as listed below. These variations might align to one of the patterns explained above.
**iPaaS:** Integration Platform as a Service (iPaaS) is a suite of cloud services that enables development, execution and governance of integration flows connecting any combination of on-premises and cloud-based processes, services, applications and data within individuals or across multiple organisations. Examples are MuleSoft CloudHub and BizTalk.
**mPaaS:** Mobile Platform as a Service (mPaaS) is a provision of an interactive development environment (IDE) for the creation of mobile apps. It supports multiple mobile operating platforms.
**dbPaaS:** Database Platform as a Service (dbPaas) is an on-demand, secure and scalable self-service database platform that automates the provisioning and administration of databases. dbPaaS makes it easier to scale databases and makes them more reliable.
**IoTPaaS:** This provides common infrastructure to enable communication, security, analytics and management for heterogeneous IoT topologies. It provides simpler and agile models for building IoT solutions.
**bpmPaaS:** Business process management PaaS (bpmPaaS) is a complete pre-integrated BPM platform hosted in the cloud and delivered as a service. It is leveraged for the development and execution of business processes and workflow-centric applications across enterprises. Examples are Pega cloud, and OpenText Cordys cloud.
Some basic characteristics of PaaS are:
* Services to develop, test, deploy, host and maintain applications in the same integrated development environment
* Multi-tenant architecture, in which multiple concurrent users use the same development application
* Built-in scalability of deployed software, including load balancing and failover
* Integration with heterogeneous platforms and systems
* Support for development team collaboration
* Tools to handle billing and subscription management
### Key open source Platforms as a Service
Before choosing a PaaS, enterprises must consider the following:
* Deployment flexibility
* Ease of operations
* Choice of application stacks
* Language, database and framework support
* Scaling capabilities
* QoS
* Tooling for development and operations
* How well it fits your business
Lets now take a quick look at some popular open source PaaS.
**Cloud Foundry:** This PaaS provides a choice of clouds, developer frameworks and application services. Cloud Foundry makes it faster and easier to build, test, deploy and scale applications.
It has different distributions, of which the popular ones are Pivotal and IBM. It contains application runtime and container runtime. It also has Pivotal application service and Pivotal container service.
**OpenShift:** This is Red Hats cloud computing PaaS offering. It is an application platform in the cloud, where application developers and teams can build, test, deploy and run their applications.
**Cloudify:** Cloudify was developed and designed on the principles of openness to power the IT transformation revolution. It enables organisations to design, build and deliver various business applications and network services. The latest version of Cloudify is 4.3, which incorporates enhanced features like advanced security, control and true self-service. Cloudify 4.3 introduced a totally new concept for container orchestration with Kubernetes.
| Functionality | Cloud Foundry | Cloudify | OpenShift |
| :- | :- | :- | :- |
| Core functionality | Cloud controller | Manager | Broker |
| Providing third party database services | Service broker | Agent | Cartridge |
| Routing of incoming traffic | Router | Manager | REST API |
| Querying the state of apps | Cloud controller | CLI client | Broker |
| Messaging | Message bus | Manager | Broker |
| App instance management | Droplet execution agent | Agent | Node |
| Application state management | Health manager | Manager | Broker |
| Broker | Warden | Agent | Gear |
| Load balancing of user requests | Droplet execution agent | Manager | Broker |
| Framework provider | Blob store | Agent | Cartridge |
| Technology |
| Languages | Java, Ruby, Scala, Node.js, Groovy, Grails, PHP, Go, Python | Java, PHP, Ruby | Java, Ruby, Node.js, PHP, Python, Perl, JavaScript |
| Databases | MongoDB, MySQL,
PostgreSQL | MySQL, MongoDB | MongoDB, MySQL, PostgreSQL |
| Frameworks | Spring, Rails, Grails, Play Sinatra | JavaScript, Node.js | Rails, Flask, Django, Drupal, Vertx |
| Horizontal scaling | Yes | Yes | Yes |
| Vertical scaling | Yes | No | Yes |
| Auto scaling | Yes | Yes | Yes |
Table 1 lists the basic functionality and its corresponding Cloud Foundry, Cloudify and OpenShift architectural components. This is purely based on my views and the authenticity of the features supported needs to be validated with the cloud provider.
From the industry adoption statistics we can clearly make out that PaaS adoption is picking up very rapidly. PaaS enables enterprise applications to be cloud-agnostic, so that they can run on any cloud platform — whether public or private. This means that a PaaS application developed on Amazon AWS can easily be ported to Microsoft Azure, to VMWare vSphere, to Red Hat RHEV, etc.
PaaS is useful when multiple developers are working on a development project or when external users need to collaborate with the development process. So it is best suited for agile software development, because it eases the difficulties around rapid development and iteration of software.
### Acknowledgements
The author thanks Kiran M.R. and Raju Alluri of the digital architecture practice of Wipro Ltd for giving their time and support to this article.
--------------------------------------------------------------------------------
via: https://www.opensourceforu.com/2022/09/why-enterprises-should-opt-for-platform-as-a-service/
作者:[Gopala Krishna Behara][a]
选题:[lkxed][b]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]: https://www.opensourceforu.com/author/gopalakrishna-behara/
[b]: https://github.com/lkxed

View File

@ -2,7 +2,7 @@
[#]: via: "https://opensource.com/article/22/10/whats-new-awk"
[#]: author: "Jim Hall https://opensource.com/users/jim-hall"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: translator: "connermemory"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "

View File

@ -1,74 +0,0 @@
[#]: subject: "Whats new in GNOME 43?"
[#]: via: "https://opensource.com/article/22/10/whats-new-gnome-43-linux"
[#]: author: "Jim Hall https://opensource.com/users/jim-hall"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
Whats new in GNOME 43?
======
I love the [GNOME][1] desktop, and I use it as my daily [Linux desktop environment][2]. I find with GNOME, I can focus on the stuff I need to get done, but I still have flexibility to make the desktop look and act the way I want.
The GNOME Project recently released GNOME 43, the latest version of the GNOME desktop. I met with GNOME developer Emmanuele Bassi to ask a few questions about this latest release:
**Jim Hall (Jim): GNOME has lots of great desktop features. What are some of the new features in GNOME 43?**
**Emmanuele Bassi (Emmanuele):** GNOME 43 has a complete redesign of the system status menu in the Shell. The new design is meant to give quick and easy access to various settings: network connections and VPNs; audio input and output sources and volumes; toggling between light and dark styles. It also has a shortcut for taking a screenshot or starting a screen recording.
GNOME core applications have also been ported to the new major version of the GNOME toolkit, GTK4. GTK4 is more efficient when it comes to its rendering pipeline, which leads to smoother transitions and animations. Additionally, GNOME applications use libadwaita, which provides new UI elements and adaptive layouts that can seamlessly scale between desktop and mobile form factors.
The GNOME file manager, Nautilus, is one of the applications that has been ported over to GTK4 and libadwaita, and it has benefitted from the new features in the core platform; its now faster, and it adapts its UI when the window is resized.
The system settings can now show device security information, including manufacturing errors and hardware misconfiguration, as well as possible security issues like device tampering. Lots of work is planned for future releases, as device security is an area of growing concern.
**Jim: What do you love most about GNOME 43?**
**Emmanuele:** The most important feature of GNOME, one that I constantly take advantage of and that I always miss when I have to deal with other operating systems is how much the OS does not get in the way of what Im doing. Everything is designed to let me concentrate on my job, without interruptions. I dont have bells and whistles constantly on my screen, competing for attention. Everything is neatly tucked away, ready to be used only when I need to.
**Jim: Many folks are familiar with GNOME today, but may not be familiar with its history. How did GNOME get started?**
**Emmanuele:** GNOME started in 1997, 25 years ago, as a project for using existing free and open source components to create a desktop environment for everyone that would be respectful of users and developers freedom. At the time there were only commercial desktops for Unix, or desktops that were based on non-free components. Being able to take the entire desktop, learn from it, and redistribute it has always been a powerful motivator for contributors—even commercial ones.
Over the past 25 years, GNOME contributors have worked not just on making the desktop, but creating a platform capable of developing and distributing applications.
**Jim: Open source projects keep going because of a strong community. What keeps the GNOME community strong?**
**Emmanuele:** I dont pretend to speak for everyone in the project, but for myself I think the main component is the respect of every voice within the community of contributors, which comes from the shared vision of creating an entirely free and open platform. We all know where we want to go, and we are all working towards the same goal. Sometimes, we may end up pulling in different directions, which is why donating to entities like the GNOME Foundation, which sponsor gatherings and conferences, is crucial: they allow a more comprehensive communication between all the involved parties, and at the end we get better results for it.
GNOME also takes very seriously respectful communication between members of the community; we have a strong code of conduct, which is enforced within the community itself and covers all venues of communication, including in person events.
**Jim: GNOME established the Human Interface Guidelines (HIG) to unify the GNOME design and GNOME app interfaces. How did the HIG come about?**
**Emmanuele****:**The Human Interface Guidelines (HIG) came into being after Sun did a usability study on GNOME 1, one of the very first usability studies for a free software project. The findings from that study led to the creation of a standardized document that projects under the GNOME umbrella would have to follow, which is how we ended up with GNOME 2, back in 2002.
The HIG was a rallying point and a symbol, a way to demonstrate that the entire project cared about usability and accessibility, and it provided the tools to both desktop and application developers to create a consistent user experience.
Over the years, the HIG moved away from being a complete checklist of pixels of padding and grids of components, and instead it now provides design principles, UI patterns, conventions, and resources for contributors and application developers. The HIG now has its own implementation library, called libadwaita, which application developers can use when targeting GNOME, and immediately benefit from a deeper integration within the platform without having to re-implement the various styles and patterns manually.
_Thanks to Emmanuele Bassi for answering this interview. You can find GNOME at_[_https://www.gnome.org/_][3]
_Read the release announcement for GNOME 43 at_[_https://release.gnome.org/43/_][4]
_Learn about whats new in GNOME 43 for developers at_[_https://release.gnome.org/43/developers/_][5]
--------------------------------------------------------------------------------
via: https://opensource.com/article/22/10/whats-new-gnome-43-linux
作者:[Jim Hall][a]
选题:[lkxed][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/jim-hall
[b]: https://github.com/lkxed
[1]: https://opensource.com/article/19/12/gnome-linux-desktop
[2]: https://opensource.com/article/20/5/linux-desktops
[3]: https://www.gnome.org/
[4]: https://release.gnome.org/43/
[5]: https://release.gnome.org/43/developers/

View File

@ -0,0 +1,91 @@
[#]: subject: "How the Gherkin language bridges the gap between customers and developers"
[#]: via: "https://opensource.com/article/23/2/gherkin-language-developers"
[#]: author: "David Blackwood https://opensource.com/users/david-blackwood"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
How the Gherkin language bridges the gap between customers and developers
======
Communicating with software developers can often be a burdensome task, especially when people lack technical knowledge and technical vocabulary. This is why project managers often use [user stories][1] and the versatile system metaphor_._
You can assist communication further by utilizing technology designed to facilitate discussions between a project's stakeholders and developers.
### The Cucumber framework
Cucumber is an open source framework that enables the creation of automated software tests using an easy-to-write and common language_._ It's based on the concept of [behavior-driven development (BDD)][2], which dictates that creating software should define how a user wants an application to behave when specific conditions are true.
The Cucumber framework isn't "technology" in the modern sense. It's not a collection of bits and bytes. Instead, it's a way of writing in natural language (English, in the case of this article, but so far Gherkin has been translated to over 70 languages). When using the Cucumber framework, you aren't expected to know how to read or write code. You only need to be able to write down ideas you have about how you work. You should also document how you want technology to work for you, using a set of specific terms and guidelines.
### What is the Gherkin language?
Cucumber uses Gherkin as a means to define use cases. It's primarily used to generate unambiguous project requirements_._ In other words, its purpose is to allow users to describe precisely what they require software to do, leaving no room for interpretation or exception. It helps you think through the process of a transaction with technology and then helps you write it down in a form that translates into programmer logic.
Here's an example:
```
Feature: The Current Account Holder withdraws money
Scenario: The account in question is not lacking in funds
Given that the account balance is £200
And the debit card is valid
And the cash machine contains enough money
When the Current Account Holder requests £50
Then the cash machine dispenses £50
And the account balance is £150
And the debit card is returned
```
As you can see, this is a highly specific scenario in which an imaginary user requests £50, and the ATM provides £50 and adjusts the user's account balance accordingly. This scenario is just one part of an ATM's purpose, and it only represents a specific component of a person's interaction with a cash machine. When a programmer is given the task to program the machine to respond to a user request, this clearly demonstrates what factors are involved.
#### What are Gherkin keywords?
The Gherkin syntax makes use of five indispensable statements describing the actions needed to perform a task:
- **Feature**: denotes a high-level description of any given software function
- **Scenario**: describes a concrete _example_
- **Given**: explains the initial context of the system
- **When**: specifies an event or action
- **Then**: describes an expected outcome, or a result
- **And (or but)**: increases text fluidity
By making use of these simple keywords, customers, analysts, testers, and software programmers are empowered to exchange ideas with terminology that's recognizable by all.
### Executable requirements and automated testing
Even better, _Gherkin requirements are also executable._ This is done by mapping eachand every keyword to its intended (and clearly stated) functionality. So, to keep with the example above, anything already implemented could automatically be displayed in green:
```
When the Current Account Holder requests £50*
Then the cash machine dispenses £50*
And the account balance is £150
And the debit card is returned
```
By extension, Gherkin enables developers to translate requirements into testable code. In practice, you can use specific phrases to check in on your software solutions! If your current code isn't working properly, or a new change has accidentally caused a software error (or two or three) then you can easily pinpoint problems before proceeding to repair them.
### Conclusion
Thanks to the Gherkin syntax, your customers will no longer be in a pickle. You can bridge the divide between businesses and developers and deliver outstanding products with greater confidence than ever before.
Find out more about Gherkin by visiting the [Cucumber website][3] or its [Git repository][4].
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/gherkin-language-developers
作者:[David Blackwood][a]
选题:[lkxed][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/david-blackwood
[b]: https://github.com/lkxed/
[1]: https://softwareplanetgroup.co.uk/user-stories-bridging-the-gap-between-customers-and-developers-updated/
[2]: https://opensource.com/article/19/2/behavior-driven-development-tools
[3]: https://cucumber.io/docs/gherkin/
[4]: https://github.com/cucumber/docs

View File

@ -0,0 +1,87 @@
[#]: subject: "3 types of leadership for open organizations"
[#]: via: "https://opensource.com/article/23/2/leadership-open-organizations"
[#]: author: "Bryan Behrenshausen https://opensource.com/users/bbehrens"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
3 types of leadership for open organizations
======
In the classic movie _Born Yesterday_, a crime boss repeatedly demonstrates his leadership style by bellowing, "Do what I'm tellin' ya!" in a loud, threatening voice. It's entertaining in a comedy, but it would be a recipe for failure and getting ignored in an open organization.
In this article, I review forms of leadership that can be effective in an open organization. Remember that these leadership forms do not exist in a vacuum or silos. To be an effective manager, you want to mix and match techniques from each leadership style based on the requirements of a situation.
These three approaches to leadership are helpful for open organizations.
### Servant leadership
There is a saying that politicians want to get elected either to be something or to do something. This adage applies to any type of leader. Some leaders simply want to be in command. While all leaders are ambitious, for this type of leader, satisfying their ambition is the primary goal. The acquisition of power is an end unto itself; once they have it, they may be uninterested in using it to solve problems or build something. Anything that the organization achieves looks like a personal triumph to them.
By contrast, when you're a servant leader, you see your leadership role as a means to serve people. In the political world, you would view public service as not a cliche but as an opportunity to help the public. As a servant leader, you work to improve things for the people you lead and are primarily concerned about the welfare of those around you.
Servant leadership is also contagious. By focusing on the welfare and development of the people you lead, you're growing the next generation of servant leaders. As a servant leader, you're not interested in taking all the credit. For example, when legendary baseball manager Casey Stengel was congratulated for winning a league championship, he famously remarked, "I couldn't have done it without my players." One of his greatest skills as a manager was maximizing each player's contributions to benefit the whole team.
### Quiet leadership
For the past several years, we've been living in the age of the celebrity CEO. They are easy to recognize: They are brash and loud, they promote themselves constantly, and they act as if they know the answer to every problem. They attempt to dominate every interaction, want to be the center of attention, and often lead by telling others what to do. Alice Roosevelt Longworth described her father, US President Theodore Roosevelt, as someone who "wanted to be the corpse at every funeral, the bride at every wedding, and the baby at every christening." Roosevelt was an effective leader who did extraordinary things, such as starting the US National Park Service and building the Panama Canal, but he was anything but quiet.
In contrast, when you're a quiet leader, you lead by example. You don't fixate on problems; instead, you maintain a positive attitude and let your actions speak for themselves. You focus on what can be done. You lead by solving problems and by providing an example to your team. When faced with unexpected issues, the quiet leader doesn't spend time complaining but looks for solutions and implements them.
### Open leadership
As a servant leader, you work to assist the members of your organization in growing into leaders. Quiet leaders lead by example. Servant leaders and quiet leaders do not act in an autocratic manner. Open leaders combine many of these characteristics.
An open leader is also not a top-down autocratic leader. As an open leader, you succeed by creating organizations in which teams can thrive. In other words, as an open leader, you create a framework or environment in which your organization can achieve the following goals according to [The Open Organization Definition][1]:
- **Greater agility:** In an open organization, all team members have a clear understanding of the organization's goals and can, therefore, better work together to achieve those goals.
- **Faster innovation:** In an open organization, ideas are heard (and reviewed and argued over) regardless of their origin. Ideas are not imposed on the organization by its leaders.
- **Increased engagement:** Because members of the organization can contribute to decisions about the organization's direction, they have a sense of ownership for the team's goals.
The Open Organization defines the following five characteristics as basic tenants of open organizations:
- **Transparency:** The organization's decision-making process is open, as are all supporting project resources. The team is never surprised by decisions made in isolation.
- **Inclusivity:** All team members are included in discussions and reviews. Rules and protocols are established to ensure that all viewpoints are reviewed and respected.
- **Adaptability:** Feedback is requested and accepted on an ongoing basis. The team continually adjusts its future actions based on results and inputs.
- **Collaboration:** Team members work together from the start of a project or task. Work is not performed in isolation or in silos and then presented to the rest of the team for input.
- **Community:** Team members have shared values regarding how the organization functions. Team leaders model these values. All team members are encouraged to make contributions to the team.
### Putting leadership styles to work
How can you, as an open leader, incorporate the characteristics of servant and quiet leadership?
In an open organization, to support an inclusive community, you function as a mentor. Just as a servant leader acts to teach and cultivate future servant leaders, you must walk the walk, leading by example, ensuring transparency and collaboration, and operating according to shared values.
How can a quiet leader contribute to an open organization? Open organizations tend to be, for lack of a better word, noisy. Communication and collaboration in an open organization are constant and can sometimes be overwhelming to people not accustomed to it. The ownership felt by members of open organizations can result in contentious and passionate discussions and disagreements.
Quiet leaders with a positive outlook tend to see paths forward through seemingly contradictory viewpoints. Amid these discussions, a quiet leader cuts through the noise. As a calming influence on an open organization, a quiet leader can help people get past differences while driving solutions.
### Further resources
- [The Center for Servant Leadership][2]
- ["The quiet leader and how to be one,"][3] Harvard Business School blog
- ["How to recognize silent leaders and encourage their growth in your organization,"][4] G&A Partners blog
- ["What is The Open Organization,"][5] opensource.com
- [_The Open Organization Definition_][6] [eBook], opensource.com
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/leadership-open-organizations
作者:[Bryan Behrenshausen][a]
选题:[lkxed][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/bbehrens
[b]: https://github.com/lkxed/
[1]: https://theopenorganization.org/definition/open-organization-definition/
[2]: https://www.greenleaf.org/what-is-servant-leadership/
[3]: https://hbswk.hbs.edu/item/the-quiet-leaderand-how-to-be-one
[4]: https://www.gnapartners.com/resources/articles/silent-leadership
[5]: https://opensource.com/open-organization/resources/what-open-organization
[6]: https://opensource.com/open-organization/resources/open-org-definition

View File

@ -0,0 +1,95 @@
[#]: subject: "What an open license means to gamers"
[#]: via: "https://opensource.com/article/23/2/what-open-license-means-gamers"
[#]: author: "Seth Kenlon https://opensource.com/users/seth"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
What an open license means to gamers
======
When it was released over 20 years ago, the Open Gaming License 1.0a (OGL) changed the tabletop gaming industry. It enabled publishers to use portions of the D&D rules, verbatim, in their own game books. It guaranteed that the owner of the D&D brand wouldn't sue you for creating and selling modular rules and adventures for the D&D game. And more importantly, it became a promise of collaboration for the gaming community. When you wanted to broadcast to other players that you were willing and eager to share ideas, you included the OGL in your game book, marking your game as open.
Recently, Wizards of the Coast attempted to revoke the Open Gaming License 1.0a, apparently on the grounds that legally the word "perpetual" isn't the same as "irrevocable". Luckily, the gaming community united and defended the license, and in the end Wizards of the Coast acquiesced. As a sign of good faith that [came too late for many players][1], Wizards of the Coast [released the System Reference Document (SRD)][2], a subset of the rules published in the hardcover D&D book, into the Creative Commons.
In essence, the fifth edition of the world's first role-playing game (D&D) no longer belongs to Wizards of the Coast. It belongs to its community of players.
As an open source enthusiast, that makes a lot of sense to me, but I admit that for most people it probably seems odd that a corporation would be compelled by its community to surrender ownership of its main product. It's worth noting that D&D probably wouldn't still be around today if it hadn't maintained an open license for nearly 20 years (it wandered away from this during its 4th edition, but hastily course-corrected for the 5th edition). It's an important turn of events, not only gamers, but everyone invested in the idea of open culture and open source.
### What open licensing means to gamers
Since the Open Gaming License was released in the early 2000s, there have been hundreds of games and adventures and supplements and source books that were never obligated to use the OGL. They were written from scratch using original language, never borrowing from a System Reference Document in any direct way. Just as there were lots of roleplaying supplements back in the 80s that _happened_ to work with that one game by TSR, these books are independent material that often _happen_ to work with existing systems. But authors chose to use the OGL 1.0a because they recognized that sharing ideas, mechanics, and content was what tabletop roleplaying is all about. It's what it's always been about. Getting together with friends, some old and some new, and inspiring each other. That fellowship extended to the computer screen once digital technology and its infrastructure got good enough to facilitate extended video and voice calls, and to provide emulated tabletops, and so the pool of [potential friendships][3] got even bigger. The OGL 1.0a was a document you could copy and paste into your book as a sign that you wanted to collaborate. You were inviting people to your writer's desk and to your gaming table.
**[ Related read: [Why sysadmins should license their code for open source][4] ]**
For a lot of gamers, the Open Gaming License 1.0a also defined the word "open". Being open is different than what we're used to. There's a lot of implied openness out there. Sure, you're allowed to dress up as your favourite Star Wars character—until Disney says otherwise. And maybe you can write some fan fiction based around your favourite TV series—as long as you don't sell it.
But the OGL 1.0a tells you exactly what you can use, and reference documents provide rules you can freely copy and paste into your own work, and then other authors can use your content to build up something cool. And nobody's restricted from selling their work, so it literally meant people could turn their hobby into their day job. And nobody could take that away.
### What "open" means for everyone
In the software world, the definition of "open" is ardently protected by organizations like the [Open Source Initiative][5]. But for many gamers, that definition was a function of the Open Gaming License 1.0a. And Wizards of the Coast was trying to redefine it.
The term "open" is arguably best defined by the Free Software Foundation, which ironically doesn't use the term "open" and prefers "free" instead. Here's how the FSF defines the term "free":
- The freedom to run code as you wish, for any purpose.
- The freedom to study code to understand how it works, and to change it so it works better for you.
- The freedom to redistribute copies of the original code.
- The freedom to distribute copies of your modified code to others.
Extrapolating this to culture, you have similar concepts, including the freedom to share, the freedom to change and adapt, and the freedom to receive recognition for the work you've contributed.
### 3 open licenses gamers need to know
If you're a gamer who's confused about open licensing, don't let the recent attempt to revoke the Open Gaming License fool you. The important thing to remember is that an open community can exist with or without a corporate sponsor. You don't need the legal system to create an open gaming environment, but in today's world you may need a legal system to defend it. And there are licenses out there to help with that.
### 1. Creative Commons
The [Creative Commons (CC) license][6] is an agreement you can apply to something you've created, explicitly granting other people permission to redistribute and maybe even remix your work. The CC license is modular, so you get to decide what permissions you grant. There's an online "quiz" at [creativecommons.org/choose][7] to help you pick the right license for your project.
### 2. GNU Free Documentation
The 90s RPG **Dead Earth** was published using the GNU Free Documentation license, and it makes sense when you consider that most tabletop games are essentially just a set of rules. Game rules are essentially the "code" of a game written in natural language, so a license intended for technical documentation might make some sense for a game. The GNU Free Documentation license is a modern license, acknowledging that many documents exist only online as wiki pages, or that they may also be licensed under a Creative Commons license. It's also got provisions for the difference between making a personal copy of a book and printing a book by the hundreds.
To find out more about the GNU Free Documentation license, visit [gnu.org/licenses/fdl-1.3.txt][8].
### 3. Open RPG Creative (ORC) License
The ORC license doesn't yet exist, but it's being formulated, in the open and with public participation, by well-known game publisher Paizo. This license is aiming to replace the OGL with legal text that recognizes the unique needs of a gaming system, in which trademarks and copyrighted material (such as lore, a fictional pantheon, the names of magic spells, and so on) intermingle. The ORC license seeks to make it possible for game publishers to explicitly allow and foster participation and ownership for its community, while also retaining control of the fictional world in which their own version of the game is set. Once completed, the ORC license will be placed in the trust of a non-profit foundation so that no company, in the future, can claim ownership of it with the aim of revoking or altering it.
### An open systems reference document
The right license guarantees that others can build upon what you've created. For tabletop role-playing games, the thing being created is a set of rules. In the context of a game, a "rule" is an agreement all the players make with one another to define constraints for what you're "allowed" to do during the game. Of course, it's just a game so you can literally do whatever you want, but the rules define what you can expect as a result.
It's generally acknowledged that game rules aren't subject to copyright. They are seen as community property, but the literal words used to describe those rules are written by someone, and so the author of a rulebook does hold the copyright to their personal expression of a rule. But opening up copyright material for re-use is exactly what licenses were created for, and so a rulebook distributed under an open source license means that you can copy and paste text straight from that rulebook into your own publication without betraying anyone's trust.
The [system-reference-document.org][9] project is working to preserve the D&D 5.1 rules (called the "System Reference Document") and to forge ahead with revisions as developed by the community. Visit the site today to download the open source D&D rules. Read them over, play a few games, and take note of what's confusing and what doesn't seem to work. Think about what you'd change. Maybe you don't like how passive perception works (wouldn't it be better as a codified reaction that could override a surprise effect?), or maybe the character build process is confusing (surely it could be delivered as a linear process of requirements?), or maybe there's something else. Now, thanks to open licensing, and to projects like systems-reference-document.org, you can help change the issues you have with the game.
### Open means open
For many of us, open source and open culture are the default. It feels unnecessary and self-important to declare a license for the work we put out into the world. But it's important to remember that not everyone knows your intent. When you release something to the world with the intent for it to be reused, shared, and maybe even remixed, apply an open license to it as a way of reassuring your collaborators-to-be that you support common culture, creativity, and open source. It might seem simple to quickly write your own statement of intent, call it a legal license, and paste it into your document, but if the fight to preserve the OGL has taught us anything, it's that the language of the legal system is not easily learned. Use a trusted license that has a community of stakeholders behind it, so that should it ever be threatened, you have a loud and collective voice to use in its defense.
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/what-open-license-means-gamers
作者:[Seth Kenlon][a]
选题:[lkxed][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/seth
[b]: https://github.com/lkxed
[1]: https://koboldpress.com/project-black-flag-update-sticking-to-our-principles?utm_source=opensource.com
[2]: https://www.dndbeyond.com/attachments/39j2li89/SRD5.1-CCBY4.0License.pdf
[3]: https://opensource.com/article/21/3/open-source-streaming
[4]: https://opensource.com/article/23/1/why-sysadmins-should-license-code-open-source
[5]: http://opensource.org
[6]: https://opensource.com/article/20/1/what-creative-commons
[7]: https://creativecommons.org/choose/
[8]: https://www.gnu.org/licenses/fdl-1.3.txt
[9]: https://github.com/system-reference-document/

View File

@ -0,0 +1,58 @@
[#]: subject: "How open source leaders can foster an inclusive environment"
[#]: via: "https://opensource.com/article/23/2/open-source-leaders-inclusive-environment"
[#]: author: "Kate Carcia Poulin https://opensource.com/users/kcarcia"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
How open source leaders can foster an inclusive environment
======
Open source leaders can foster inclusive communities for newcomers by creating belonging, providing opportunities, and showing support. They understand the intricacies of submitting code and making connections with other community members. In doing so, they build credibility and gain influence. This experience is invaluable to contributors who want to participate but don't know where to start.
A few years ago, I found myself in this daunting position when I began managing a team active in the Linux kernel community without any experience in kernel myself. The complex code base, expansive email archives, and high-stakes communications intimidated me. When new kernel developers on my team expressed similar feelings, I realized my experience was ubiquitous. For those supporting contributors or those seeking to contribute themselves, the path to entry is not always clear and can feel unattainable.
### 4 strategies for inclusive leadership
Open source leaders can have an impact by creating pathways for those looking to integrate into the community. The strategies covered in this article can be applied in formal [mentoring][1] or [coaching][2] relationships but are just as applicable in day-to-day interactions. Seemingly minor exchanges often have the most significant impacts when fostering inclusivity in an environment.
### Approach with curiosity
Someone with less experience or coming from a non-traditional background may solve problems in unexpected or different ways. Reacting to those differences with judgment or criticism can create an unsafe environment for learning in communities that often have a steep knowledge curve. For example, long-time contributors to the Linux kernel understand its rich history. This means they have an implied understanding of community decisions and reactions. New contributors must build this knowledge but can only effectively do so if they feel safe taking necessary risks to grow their skill set.
Open source leaders can support newcomers as they learn by approaching them with curiosity. Consider asking questions like, "Can you help me understand why you took this approach?" rather than declaring proposed solutions "right or wrong". Questions open a dialog for continued learning rather than shutting down ideas that are an important aspect of exploration. This process also broadens the leader's viewpoint, who can learn by considering fresh perspectives.
### Identify and share learning opportunities
Open source leaders can identify projects suitable for others to gain technical expertise and learn community processes. In creating opportunities for others, leaders also create more opportunities for themselves. This is because they make more time to explore new endeavors while continuing to advance their work through delegation. As leaders grow, their ability to enable others around them to succeed becomes just as critical as their direct contributions.
Knowing that [failure][3] is a part of learning, think about identifying projects where newcomers can safely fail without drastic consequences. In the Linux kernel, for example, there are certain parts of the code base where small changes can have disastrous consequences. Consider projects where small wins are achievable to help newcomers build confidence and feel empowered without high stakes. Make these ideas accessible by sharing them at conferences, in email forums, or in any way your community advertises how to become involved.
### Demonstrate vulnerability
Having more experience doesn't mean you know everything. More often than not, even the most experienced Linux kernel contributors I've worked with are humbled by new challenges in uncharted subsystems. It's common for community members with less experience to view more experienced community members as having it all figured out. But having experience is about being adept at figuring out what you don't know. If you are in a position of authority and regarded as an expert, demonstrating vulnerability by sharing personal experiences of struggle and perseverance can be encouraging to those dealing with similar feelings.
### Vouch for others
Introduce newcomers to your network. Connect them with community members with expertise in areas that pique their interests. Say their name in public forums and call out the excellent work they are doing. As a respected leader, your endorsement can help them build connections and trust within the community.
We can have rich and diverse communities by building in inclusivity. It is my hope that open source leaders will consider these suggestions because those you lift into the community will someday be able to extend a hand to others.
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/open-source-leaders-inclusive-environment
作者:[Kate Carcia Poulin][a]
选题:[lkxed][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/kcarcia
[b]: https://github.com/lkxed
[1]: https://opensource.com/article/22/8/mentoring-power-multiplier
[2]: https://enterprisersproject.com/article/2021/4/it-leadership-how-to-coach?intcmp=7013a000002qLH8AAM
[3]: https://opensource.com/article/20/11/normalize-failure

View File

@ -0,0 +1,305 @@
[#]: subject: "A 10-step guide for a successful hackathon"
[#]: via: "https://opensource.com/article/23/2/hackathon-guide"
[#]: author: "Tiffany Long https://opensource.com/users/tiffany-long"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
A 10-step guide for a successful hackathon
======
Hackathons are easy. How much thought do you need to put into them anyway? Just set a date, and people will show up. Well, that is not quite true!
While you may get lucky with that approach, the reality is that hackathons are a keystone experience in the tech industry, and attendees have specific expectations. Not only that, but your organization also has certain needs and should set goals for a hackathon. So, how do you ensure that a hackathon works for your organization and attendees?
A successful hackathon depends on several decisions that tend to be recursive. Decisions about what you want to achieve will impact what resources you allot and how you want to communicate. Those decisions affect whether you go virtual or in person, and that decision will once again impact the resources you need and how you communicate. Alignment when planning hackathons is not just about getting people to agree. You will have a whole suite of decisions that must internally align. For example, a technically difficult hackathon might not be able to attract a large audience (ask me how I know!) and will require a specialized recruitment strategy that requires different resources.
I've done many hackathons over the years, including just a few months back, when my organization hosted a hackathon that led to new features that we will incorporate into the next version of our open source product, Traefik Proxy 3.0. So, trust me when I say planning a hackathon that will enrich attendees and create valuable outcomes for your project is about more than hope, pizza, and chaos.
This article uses the most recent Traefik Labs Hackathon as a blueprint. I share a checklist, tips, and tricks to help you identify your objectives, plan, manage the contest and compensation, share your results, and manage the long tail of the hackathon (the work isn't over when the hackathon ends!)
This guide serves as a model for you to outline best practices so that you, too, can hold a successful hackathon with a sizable target audience that delivers results!
- [Three questions to determine your goals][1]
- [Why are you doing this?][2]
- [Who is your audience?][3]
- [How are you measuring goals?][4]
- [Decide on in-person vs. virtual][5]
- [Build your communication strategy][6]
- [Decide on the prizes][7]
- [Swag it up][8]
- [Get the word out][9]
- [Managing the long tail][10]
**[ Get a PDF and EPUB version of this article. [Download it here.][11] ]**
### 1. Three questions to determine your goals
The first and most crucial step is to set your goals. But this is no simple affair. Before you set goals, you need to coordinate internally on multiple fronts and ask questions such as:
- Why do you want to do a hackathon?
- Who do you want to attend?
- How are you going to measure your success?
#### Identify your internal stakeholders and set expectations
**Hackathons are cross-functional**. No hackathon is run by a community person alone. It is important to ensure everyone is aligned on the goals, what is required to achieve them, and that the necessary resources are committed. This probably sounds super corporate, but these functions exist even within the smallest projects. A project needs adoption and code. It also needs value decisions based on who will be using it. And, of course, projects need passionate contributors.
**Hackathons require cross-functional resources**. One team with a single set of resources cannot successfully run a hackathon. The organization must make various resources available, including:
- Marketing for planning and outreach.
- Product Management for product and industry-specific insight.
- Engineering for deep technical knowledge and community engagement.
For these reasons, hackathons usually support cross-functional goals. Your Community Team, for example, might want to build ownership and convert users to active community members. The Marketing Team might want to enhance awareness and court new users. The Engineering Team might need new perspectives on specific needs or challenges. The Product Team might have goals or no-go areas the community should be aware of.
And last but not least, the hackathon budget is cross-functional. I am sorry to inform you, but hackathons ain't free! Your largest expense is always the dedicated time of your team.
### 2. Why are you doing this?
Setting your goals is the most important part of a successful hackathon. If you don't know what you want to do or why a hackathon is important, at best, it will have a ton of wasted potential and be a disconnected mess at worst.
Communities feed off of ownership. Decide what you need from your community and what ownership stake you want community members to have. Without a clear understanding of this, your hackathon might not reach its full potential in empowering your community.
Be very careful with your hackathon design and goals. Different types of hackathons appeal to different skill levels. If the code you're looking for is very advanced, take the extra time to court the right audience and accept that it will include less overall attendance. Cast a wide net if the contributions can vary in skill and experience.
#### Are you hosting a hackathon to get code and build your project?
- Sometimes, projects hit a critical juncture or acquire a lot of excitement around them, and you want to harness the energy to build something together. A hackathon is a great way to achieve this!
- If you have an active community of users, a hackathon can bring everyone together at the same time to harness that excitement to feed the creative energy of your group.
**Note:** This is more easily achievable with smaller groups who know each other and have a shared experience with the project. You also need to carefully evaluate the skills required to build your project.
#### Are you hosting a hackathon to build your community or re-engage them?
- Maybe you are just building your community or noticed that your community needs a little juice. Hackathons are exciting, and they can help bring that back.
- Above, I said, "Communities feed off of ownership." If your community members do not feel they have a stake or that their needs and voices matter, they will drift away. This is common when projects grow and become more formalized. As the barrier to entry rises, the ability for community members to feel ownership falls, and the project becomes like a product to the user. One way to enhance community membership is by creating events that engage users and lower the bar for entry: Bug round-ups, light requests, and longer timelines.
- Perhaps your user community is growing, but the contributor community is becoming more specialized as your tech becomes more complex. In this case, you need to court sophisticated technologists who understand your tech and the use cases. Look for community members who use your tech in their jobs—especially at companies with large or complex deployments. These people are more likely to understand the needs of users and of the tech itself. They will also have suggestions for significant and valuable enhancements.
- You are free to choose goals that build your community and match your team and community members' energy and time. For example, at Traefik Labs, a hackathon aimed at enthusiastic folks with a small time commitment might target our Plugin Catalog. However, when looking for larger contributions or contributions that take significant expertise, we might target advanced technologistsespecially those we know.
#### Are you hosting a hackathon to celebrate something?
- Hackathons are a great way to celebrate a new launch and hype your community. For example, that is exactly why we hosted the [Traefik Proxy 3.0 Hackaethon][12].
- Hackathons are also great for getting the word out about a new product capability. The [Traefik Plugin Hackaethon][13] is an excellent example here.
- Maybe you want to organize an event to celebrate your top contributors. Do it with a hackathon! Take a look at [this hackathon organized by HackerOne][14]. And if you're thinking, "but this is not about open source software (OSS), how can it be a hackathon?" I've got news for you—hackathons are not just for OSS! Hackathons are for creating with a large community.
#### Are you hosting a hackathon to build awareness?
Hackathons are a great place to begin if you are just starting and want to build awareness around your product/brand. However, there are a few conditions.
- Laser-focused goals and big contributions are unlikely to happen at this stage. Go for a softer, broader focus, and minimize the work required by attendees.
- Reach out to new community members, less experienced users, and users with less exposure to your specific project.
#### Are you hosting a hackathon to connect to users?
I can think of no better way to connect new users to your project than a hackathon. Not only will your users become intimately familiar with your project, but hackathons also have a unique way of engendering a sense of ownership, rarely achievable through other types of events.
### 3. Who is your audience?
Assuming you have pinpointed why you want to host a hackathon and what you want to achieve, it's time to assess the characteristics that a participant needs to be successful. Use your decisions about your goals to identify your audience to ask what type of community member can help you achieve your objectives. Use the list of comparisons below:
- Highly-skilled vs. mixed-skilled vs. low-skilled
- Specialized vs. generalized skill
- Intensive time vs. less intensive time
- Individual contributions vs. group contributions
Your most active community members must look a bit like your target audience.
You might rethink your goals if your target audience doesn't align with at least 80% of the people you know you can attract. Accurately identifying your target audience will go a long way to making your communication strategy around the hackathon and the hackathon itself more successful.
### 4. How are you measuring goals?
Perfect, now that you answered the first two big questions and have your goals laid down, it's time for the third big question—how will you measure those goals? Inspiring your internal teams and your community to work together in building the future of your project, engendering ownership, and increasing engagement are awesome, but you can't determine success if you can't measure your goals.
#### What does success look like immediately after the event?
- A major sign of success is whether attendees connect and engage with each other, co-educate, and build teams during their hackathon.
- Were mentorships built? Through partnership, did several newer users grow into skilled mid-level users, or did mid-level users evolve into expert-tier users? This is the gold ring of success indicators.
- Did your partner organizations (maybe universities) request future hackathons or other events?
- Clearly, the first sign of success is that your attendees had an overall good experience and are motivated to engage more with your project.
- If you are looking for outreach, set a quantity of participants to shoot for and a number of participants who return to contribute more after the event or in three months.
- If building awareness, you might also look for successful follow-up chatter. Who wrote blog posts? Were attendees talking about it on social media?
- If you are looking for contributions, did they work for you? Are these the contributions you want? Did they impact how your team thinks about the problems they face? Will you have ongoing collaborations with these contributors?
#### What will denote success three months after the event?
Defining benchmarks for long-term success is just as important. Here are a few examples of what could indicate long-term success:
- Your hackathon should increase the number of returning contributors to your project. The goal is to get people hooked. If people new to your project came from the hackathon and stayed as users, or if your existing users became more active, you know you won.
- Hackathons are great as self-contained events, but they are supremely valuable as marketing content. They build trust in the community, showing you are responsive and value community input. They are fun loci of activity that let community members bond and look forward to the future, and they are aspirational. People love to see others celebrated and plan to achieve that celebration in the future.
- When you build marketing content around your hackathon (or better yet, others build content around your hackathon), you can expand your reach among second-degree connections.
- Tall poppy syndrome is a shame. Hackathons are a great opportunity to gather those participants who stood out and galvanize them to do other cool things and spread the word about your project.
### 5. Decide on in-person vs. virtual
I know what you're thinking—is in-person even a consideration? We've all gotten so used to doing everything virtually in the post-covid world. So, are the days of in-person gone? I would argue no, they are not. With care and safety measures in place, in-person events are the heart and soul of hackathons.
- In-person means no distractions, lots of pizza, and energy drink-fueled friendship.
- In-person fuels group participation rather than individual contributor participation.
- In-person works well at scale and in miniature: Organizing in-person hackathons for large groups brings high energy and rewards. But they can get quite costly. If you want to organize a large-scale hackathon, you'll be more successful if you target less experienced developers (students, clubs, new careerists) because these folks have the most time and the most to gain when demonstrating their skill and passion.
- In-person also works well for small groups and is great for intense planning and iteration—long nights with new and old friends, usually over food and beer!
And while many pros come with in-person hackathons, it doesn't mean that the virtual experience only comes with cons. Granted, nothing replaces that feeling of late nights with pizza, off-the-cuff remarks that end up changing your entire project, and a friendly set of eyes over your shoulder as you test or debug. But...
- Virtual means you can get a wider group of participants at a significantly lower cost.
- Virtual respects disability.
- Virtual is geolocation friendly.
- Virtual allows for higher individual contributor participation.
- Virtual offers more flexibility in the style and length of the event you cannot have a month-long in-person event!
#### Timelines of virtual hackathons
Did you decide to do a virtual hackathon? Great! Now, you need to determine the type of virtual hackathon you want. Do you envision a prolonged or intensive timeline? Keep in mind that the type of [virtual hackathon][15] you choose will determine, to some extent, your target audience and communication strategy.
**Extended timeline:**
- Allows after-hours tinkering and enables developers to attend without taking time off from work.
- Provides more time to solicit contributions.
- Requires fewer resources for both the organizer and the participants.
- Extended timelines require fewer real-time resources.
**Intense timeline:**
- Recreates that feeling of intensity usually experienced in in-person hackathons.
- Requires a high amount of resources for a short period of time.
- Requires tight management and a communication platform.
- Requires clear one-on-one communication, but also fosters group-to-group or intra-community communication.
### 6. Build your communication strategy
Speaking of communication, once you have your goals, you must decide **who** communicates with participants and **how**. It's common to choose between the popular apps of the day. Your choice impacts the event's feel. Different [chat applications][16] and [collaboration platforms][17] have their own cultures and strengths. The decision you made early on about how to host your hackathon (in-person or virtual, prolonged or intense timeline) is likely to have the most significant impact on your communication strategy.
#### In-person communication plan
If you are running an in-person hackathon, consider it a genuine event—it feels almost like a conference. In-person hackathons often include the following:
- **Workshops/round tables:** Meant to educate and develop new industry standards/best practices for the concerns of the day. These sessions can function as proctored time-bound conversations amongst 6-10 individuals, where they agree upon findings and take notes that are made public to all participants.
- **Planning sessions:** Often used for projects with non-code outcomes, like developing updated standards.
- **Coding sessions:** Used for code-based projects which require work to maintain and enhance.
Each of the above has different communication needs:
- People prepared to facilitate, but not lead, conversations in workshops.
- Note takers and people to make sure that the notes are turned into a publishable product.
- Project managers to ensure the above tasks are done.
- General communication for running the event (food, cleaning, management of resources).
- Masters of ceremonies to move through the agendas.
- For workshops:
Making this all happen requires the resources and specialized knowledge from your Community, Product Managers, and teach-savvy teams. From past experience, it took a team of community members and staff to manage an event of this scope. To be successful, your team will need specialized people as well.
You also need to decide what types of communication you want to foster and who is responsible for it:
- Multiple teams will need to take shifts to perform general support.
- A DevRel, engineering, or support team will need to manage technical communication between triage and participants.
- Community Teams usually spend extensive time connecting participants to help build strong groups by reinforcing skills or points of view. This is one way to ensure that hackathon magic.
- Community Teams also need to support marketing efforts to engage participants and manage follow-up.
#### Virtual communication plan
For virtual hackathons, the choice of a communication platform depends heavily on the outcome you want to achieve, the timeline you've chosen for your hackathon (prolonged or intensive), and the type of communication you wish to facilitate (synchronous or asynchronous).
**Using Pull Requests and Issues on Git hosts (asynchronous):**
- Choosing to communicate through Git pull requests and Issues on your project directly frees up technical staff resources because it keeps the conversations about projects in your current process and allows your team to be responsive rather than instigating communication.
- This approach is great if the team for your hackathon is small or if the expected contributions are relatively small and you do not plan to help participants form teams.
- Using your existing processes is especially great for prolonged hackathons as they do not require additional moderation or require your team to monitor an additional app.
- The downside is that you will only facilitate communication with the individual contributor or group of contributors already working together. It's difficult to connect participants who are working separately. Participants can't find each other as easily on their own, so you lose some of the magic that happens when hackathon participants organically talk to each other in open threads.
**Using a chat application (synchronous):**
- Choosing dedicated chat servers is required for intense hackathons.
- Chat facilitates the team formation and communication necessary for complex projects with fast timelines and sparks the brainstorming that preludes an awesome contribution.
- Additionally, your goal is to build community. People want to join communities where they have ownership, have friends, and feel comfortable. You need a place for participants to feel connected to each other if you want them to return.
- Chat servers can outlast an event, allowing for continued community engagement.
Regardless of which platform you choose, you need a communication plan that identifies when every person on your team is available. Managing a virtual hackathon can get quite tricky, primarily due to the different timezones—people can participate whenever they want, from wherever they want. You must plan to accommodate participants across all time zones and for every occasion. Draw up a plan with who is responsible (and when) for the following:
- Determining response SLAs.
- Animating your virtual space (a dead space guarantees poor communication).
- Encouraging team building.
- Responding to technical questions.
- Checking in on participants.
- Moderating the space to ensure the safety of your participants.
### 7. Decide on the prizes
Is your hackathon a contest? Hackathon participants are often content with grand prizes and "swagpaloozas" for top contributions. But before you decide on the fun stuff (the actual awards), you must determine what your contest values.
- What differentiates a good contribution from a great contribution? If your attendees know how you feel about this, they are more likely to hit it out of the park.
- What do you value? This is your chance to tell participants what you want to see submitted by attaching a prize to it. For example, during the last Traefik Hackaethon, we offered bounties for the most-wanted features. These were, indeed, the ones most people worked on.
- Are there categories of contributions? You need to decide on prizes for each category.
- Create a rubric (a chart or grid defining and ranking achievements, [like this example][18]). This way, participants know what you value and how they are judged. This was one way we improved submissions at HackerOne.
On the other hand, some may argue that competition is overrated. If your goal is participation, feel free to reward every single one of your participants for simply giving back! [Hacktoberfest][19] is a great example of this approach.
### 8. Swag it up
Everyone loves swag! And your participants would certainly appreciate a token to remember this event, whether virtual or in person. Swag has two purposes:
- Swag shows your appreciation: The contributors took their time to engage with you in an intense way; thank them with a gift that shows you value their contributions.
- Swag builds awareness: Gifting swag to your participants helps them spread the love and build awareness of your community by sharing their loot and experience.
The community loves swag, but they don't love boring swag! You probably distributed your existing t-shirts and stickers during another event. Make your hackathon memorable and go for new, exciting, and exclusive designs. Shirts are great, and hoodies reign supreme. But think about cool swag participants may not have already. Think of something that could become their new staple item, like backup batteries or hats (both popular at HackerOne). Personally, my own home features some towels and slippers from hackathons!
### 9. Get the word out
Setting your goals and deciding on amazing grand prizes and swag are all important steps. But how will anyone know your hackathon is happening if you don't get the word out? You need to investigate the available channels carefully, and you need to be bold with your promotion. I'm talking blogs, vlogs, emails, social media—anything you can get your hands on.
However, depending on your defined goals, you need to invest in the appropriate channel. Where you advertise depends on who you want to invite to your hackathon.
- IIf you want to attract more experienced users, target big organizations where your project is used. LinkedIn and email promotion would be most effective here.
- If you want to bring in new and less experienced users, you're better off targeting universities and boot camps. Promoting the event on community-based media, like Mastodon, Matrix, Mattermost, Reddit, Discourse, Discord, and any place your target audience hangs out is a better choice.
### 10. Managing the long tail
Yay, the hackathon is over! Now all hackathon-related activities can stop, and we no longer need to pull resources, right? Wrong! Think of hackathons as only one step of the road in a series of events in your software development and community building. To deem your hackathon a success, you must be prepared to engage in post-event activities.
- Communicating your results: Don't forget to communicate hackathon outcomes internally and externally. Demonstrate the ownership the community members gained during the hackathon to grow trust in your community and project.
- Building community: Lean on your hackathon participants for future community activity.
- Putting together the retrospective: What went well, what went terrible, what was meh, what surprised you? This analysis is how you grow, change, and iterate. Don't forget to do a blameless retro as soon as possible so it is all fresh in your mind.
### Wrap up
If you started reading this article thinking that hackathons aren't that hard to pull off, I'm sorry to have burst your bubble! And although I sincerely believe hackathons are a great way to engage and communicate with your community on so many levels, having just the intention does not guarantee the results.
For a hackathon to be successful, you need to be meticulous and prepared to invest significant resources and effort to plan and execute it properly.
Thank you for reading, and I hope this checklist helps you successfully organize your next hackathon!
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/hackathon-guide
作者:[Tiffany Long][a]
选题:[lkxed][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/tiffany-long
[b]: https://github.com/lkxed/
[1]: https://opensource.com/article/23/2/hackathon-guide#set-your-goals
[2]: https://opensource.com/article/23/2/hackathon-guide#why-are-you-doing-this
[3]: https://opensource.com/article/23/2/hackathon-guide#who-is-your-audience
[4]: https://opensource.com/article/23/2/hackathon-guide#how-are-you-measuring-goals
[5]: https://opensource.com/article/23/2/hackathon-guide#decide-on-in-person-vs-virtual
[6]: https://opensource.com/article/23/2/hackathon-guide#build-your-communication-strategy
[7]: https://opensource.com/article/23/2/hackathon-guide#decide-on-the-prizes
[8]: https://opensource.com/article/23/2/hackathon-guide#swag-it-up
[9]: https://opensource.com/article/23/2/hackathon-guide#get-the-word-out
[10]: https://opensource.com/article/23/2/hackathon-guide#managing-the-long-tail
[11]: https://opensource.com/downloads/hackathon-guide
[12]: https://traefik.io/blog/announcing-traefik-proxy-3-0-hackaethon/
[13]: https://traefik.io/blog/announcing-the-inaugural-traefik-hackaethon-2020-in-october/
[14]: https://www.youtube.com/watch?v=9VZCD9TirCg&list=PLxhvVyxYRvibM_KJBPtPsfEcjnP5oGS8H
[15]: https://opensource.com/article/20/8/virtual-hackathon
[16]: https://opensource.com/alternatives/slack
[17]: https://opensource.com/article/21/9/alternatives-zoom
[18]: https://www.isothermal.edu/about/assessment/assets/rubric-present.pdf
[19]: https://hacktoberfest.com/

View File

@ -0,0 +1,146 @@
[#]: subject: "Essential tips and tricks for your first tech job"
[#]: via: "https://opensource.com/article/23/2/your-first-tech-job"
[#]: author: "Fatima https://opensource.com/users/ftaj"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
Essential tips and tricks for your first tech job
======
First days at work are scary. I still recall many instances where I lay awake at night before my first day at work, having an internal meltdown over what would happen the next day. Starting a new job is uncharted territory for most people. Even if you're a veteran in the industry, there's no denying that there can be a part of you that's a bit terrified of what is to come.
Understandably, a lot is happening. There are new people to meet, new projects and technologies to understand, documentation to read, tutorials to sit through, and endless HR presentations and paperwork to fill out. This can be overwhelming and, coupled with the considerable degree of uncertainty and unknowns you're dealing with, can be quite anxiety-inducing.
Two reasons motivated me to write about this subject. The first one being that back when I was a student, most of the discussion revolved around getting a job in tech, and no one talked about what happened next. How do you excel in your new role? Now that I look back, I think I assumed that the hard part is getting the job, and whatever comes after, I could probably figure out myself.
Similarly, once I started working in the industry, most of the career-related content I came across was about how to go from one senior level to another. No one really talked about what to do in the middle. What about the interns and the junior engineers? How do they navigate their early careers?
After completing three years of full-time professional experience as a software engineer (and a couple of internships before), I reflected on my time. I put together a list of tips and tricks I've employed while settling into a new tech role. I wanted to look beyond just the first couple of months and prioritize helping achieve long-term success.
### Reflect on existing processes and documentation
Most new employees start by either having a ton of documentation thrown their way or none at all. Instead of being overwhelmed by either of these possibilities, you could view this as an opportunity.
Identify gaps in existing documentation and think about how you could improve it for the next engineer that gets onboarded. This not only shows initiative on your part but also demonstrates that you're committed to improving existing processes within your team.
I've seen both ends of the spectrum. I've been on teams with no documentation whatsoever. I've also been on teams that were very diligent with keeping their documentation up to date. Your path is pretty straightforward with the former, and you can work on creating that missing documentation. With the latter, you can always think of ways to improve what already exists. Sometimes, too much documentation in written form can also feel intimidating, especially for new employees. Some things might be better explained through other mediums, like video tutorials or screencasts.
### Ask questions
I encourage you to look into whether a buddy will be assigned to you when you're starting. This is a fairly common practice at companies. The purpose of a buddy is to help you as you are onboarded. I've found this incredibly helpful because it gives you someone to direct all your questions, and you don't have to run around trying to find the right person/team.
While asking questions should always be encouraged, it is also necessary to do your homework before you ask those questions, including:
- Do your research. This encompasses doing a web search, checking forums, and reading existing documentation. Use all the available tools at your disposal. However, it is essential to timebox yourself. You must balance doing your due diligence and keeping project deadlines and deliverables in mind.
- Talk it out. As someone whose first language isn't English, I recommend talking things out loud before asking questions. In my experience, I've often found that, especially when I'm struggling with something difficult, I think in one language (probably my native language) and must explain it in another. This can be a bit challenging sometimes because doing that translation might not be straightforward.
- Organize your thoughts. When struggling with something, it's very common to have many scrambled ideas that make sense to us but might not necessarily make sense to another person. I suggest sitting down, gathering your thoughts, writing them down, and talking through them out loud. This practice ensures that when you're explaining your thought process, it flows as intended, and the listener can follow your train of thought.
This approach is called the rubber duck technique, a common practice developers use while debugging. The concept is that sometimes explaining your problem to a third person can be very helpful in getting to the solution. This is also a testament to your excellent communication skills.
Respect people's time. Even if you're reaching out to someone like your buddy, be cognizant of the fact that they also have their day-to-day tasks to complete. Some things that I've tried out include the following:
- Write down my questions and then set aside some time with my mentor so I could talk to them.
- Compile questions instead of repeatedly asking for help so your mentor can get to them when they have time.
- Schedule a quick 15-20 min video chat, especially if you want to share your screen, which is a great way to showcase your findings.
I think these approaches are better because you get someone's undivided attention instead of bothering them every couple of minutes when their attention might be elsewhere.
### Deep dive into your projects
Even on teams with excellent documentation, starting your technical projects can be very daunting since multiple components are involved. Over time though, you will understand how your team does things. However, it can save you time and potential headaches to figure this out early on by keeping a handy list to refer to, including basic project setup, testing requirements, review and deployment processes, task tracking, and documentation.
If there's no documentation for the project you're starting on (a situation I have been in), see if you can identify the current or previous project owner and understand the basic project structure. This includes setting it up, deploying it, etc.
- Identify your team's preference in the IDE (integrated development environment). You're free to use the IDE of your choice, but using the same one as your team can help, especially when debugging, since the choice of IDE impacts debugging. Different IDEs offer varying degrees of debugging support.
- Understand how to do debugging, and I don't just mean using print statements (not that there's anything wrong with that approach). Leverage your team's experience here!
- Understand testing requirements. This might depend on the scope of your project and general team practices, but the earlier you figure this out, the more confident you'll be in the changes you push to production.
- Visualize the deployment process. This process can vary by team, company, etc. Regardless of how informal or formal it may be, make sure you understand how your changes get deployed to production, what the deployment pipeline looks like, how to deploy changes safely, what to do in case of failed builds, how to rollback faulty changes, and how to test your changes in production.
- Understand the ticketing process. Understand how to document tickets and the level of detail expected. You will see a lot of variation here. Some companies expected us to submit our tickets daily, showing our progress. Other companies might not require that level of documentation.
Given everything I just mentioned, a beneficial, all-in-one exercise you can do in the first couple of weeks is to shadow another engineer and do peer coding sessions. This allows you to observe the entire process, end to end, from the moment a ticket is assigned to an engineer to when it gets deployed to production.
The first couple weeks can also feel frustrating if you're not yet given an opportunity to get your hands dirty. To counter this, ask your manager to assign some starter tickets to you. These are usually minor tasks like code cleanup or adding unit tests. Still, they allow you to tinker with the codebase, which helps improve your understanding and gives you a sense of accomplishment, which is a very encouraging feeling in the early days of a new job.
### Speak up, especially when you're stuck
I want to stress the importance of communication when you're stuck. This happens, especially in the early months of a new job, and as frustrating as it can be, this is where your communication skills will shine.
- Be transparent about blockers and your progress. Even if it's something as trivial as permission issues (a fairly common blocker for new employees), ensure that your manager is aware.
- Don't wait until the last day to report if something will be delayed. Delays in your project push many other things forward. Share necessary project delays well in advance, so your manager can share this with stakeholders.
- Don't forget things like thoroughly testing your changes or documenting your code just because you're in a rush.
### Gain technical context
Gaining technical context is something I've personally struggled with, and I've actively worked on changing my approach in this area.
When I started as an intern, I would go in with a very focused mindset regarding what I wanted to learn. I'd have a laser-sharp focus on my project, but I'd completely turn a blind eye to everything else. Over the years, I realized that turning a blind eye to other or adjacent projects might not be the wisest decision.
First and foremost, it impacts your understanding of your work. I was naive to think I could be a good engineer if I focused exclusively on my project. That's just not true. You should take the time to understand other services with which your project might interact. You don't need to get into the nitty gritty, but developing a basic understanding goes a long way.
A common experience that new employees undergo is disconnecting from the rest of the company, which is a very natural feeling, especially at larger companies. I'm someone who develops a sense of exclusion very quickly, so when I moved to Yelp, a significantly larger company than my previous one, with projects of a much larger scale, I prioritized understanding the big picture. Not only did I work on developing an understanding of my project but also of other adjacent projects.
In my first few weeks at Yelp, I sat down with various engineers on my team and asked them to give me a bird's eye view of what I would be doing and the project's overarching goal. This approach was incredibly helpful because not only did I get varying degrees of explanations based on how senior the engineer was and how long they had been working on the project, but it also deepened my understanding of what I would be working on. I went into these meetings with the goal that my knowledge of the project should allow me to explain what I do to a stranger on the street. To this end, I asked my tech lead to clarify at what point my work came into the picture when a user opened the Yelp app and searched for something.
Architecture diagrams can also help in this scenario, especially when understanding how different services interact.
### Establish expectations
For the longest time, I thought that all I needed to do was my best and be a good employee. If I was doing work, meeting goals, and no one complained, that should be good enough, right? Wrong.
You must be strategic with your career. You can't just outsource it to people's goodwill and hope you'll get the desired results just because you're meeting expectations.
- Establish clear criteria the moment you start your new job. This varies by company, as some organizations have very well-defined measures while others might barely have any. If it's the latter, I suggest you sit down with your manager within the first couple of weeks and establish and unanimously agree on a criterion.
- Make sure you thoroughly understand how you will be evaluated and what measures are used.
I remember walking out of my first evaluation very confused in my first full-time role. The whole conversation had been very vague and hand-wavy, and I had no clarity about my strengths, weaknesses, or even steps to improve.
At first, it was easy to attribute everything to my manager because the new employee in me thought this was their job, not mine. But over time, I realized that I couldn't just take a backseat as far as my performance evaluations were concerned. You can't just do good work and expect it to be enough. You have to actively take part in these conversations. You have to make sure that your effort and contributions are being noticed. From regularly contributing to technical design conversations to setting up socials for your team, ensure that your work is acknowledged.
Tying into establishing expectations is also the importance of actively seeking feedback. Don't wait until your formal performance evaluations every three or four months to find out how you're doing. Actively set up a feedback loop with your manager. Try to have regular conversations where you're seeking feedback, as scary as that may be.
### Navigate working in distributed teams
The workplace has evolved over the past two years, and working in remote and distributed teams is now the norm instead of a rarity. I've listed some tips to help you navigate working in distributed teams:
- When starting meetings, exchange pleasantries and ask people how their weekend/day has been. This helps break the ice and enables you to build a more personal connection with your team members, which goes beyond work.
- Suggest an informal virtual gathering periodically for some casual chit-chat with the team.
- Establish core hours and set these on your calendar. These are a set of hours that your team will unanimously agree upon, and the understanding is that everyone should be online and responsive during these hours. This is also convenient because meetings only get scheduled within these hours, making it much easier to plan your day.
- Be mindful of people's time zones and lunch hours.
- In the virtual world, you need to make a greater effort to maintain social interactions, and little gestures can go a long way in helping make the work environment much friendlier. These include the following:
### Maintain a work-life balance
At the beginning of your career, it's easy to think that it's all about putting in those hours, especially given the 'hustle culture' narrative that we're fed 24/7 and the idea that a work-life balance is established in the later stages of our careers. This idea couldn't be further from the truth because a work-life balance isn't just magically going to occur for you. You need to actively and very diligently work on it.
The scary thing about not having a work-life balance is that it slowly creeps up on you. It starts with you checking emails after hours and then slowly makes its way to you, working over weekends and feeling perpetually exhausted.
**[ Related read [How I recognize and prevent burnout in open source][1] ]**
I've listed some tips to help you avoid this situation:
- Turn off/pause notifications and emails and set yourself to offline.
- Do not work weekends. It starts with you working one weekend, and the next thing you know, you're working most weekends. Whatever it is, it can wait until Monday.
- If you're an on-call engineer, understand your company's policies surrounding that. Some companies offer monetary compensation, while others may give time off in lieu. Use this time. Not using your benefits like PTO (paid time off) and wellness days really shortens your longevity at work.
### Wrap up
There's no doubt that starting a new job is stressful and difficult. I hope that these tips and tricks will make your first few months easier and set you up for great success with your new position. Remember to communicate, establish your career goals, take initiative, and use the company's tools effectively. I know you'll do great!
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/2/your-first-tech-job
作者:[Fatima][a]
选题:[lkxed][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/ftaj
[b]: https://github.com/lkxed/
[1]: https://opensource.com/article/21/5/open-source-burnout

View File

@ -0,0 +1,121 @@
[#]: subject: "3 myths about open source CMS platforms"
[#]: via: "https://opensource.com/article/23/3/open-source-cms-myths"
[#]: author: "Pierina Wetto https://opensource.com/users/pierinawetto"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
3 myths about open source CMS platforms
======
There are two choices when it comes to building a website. You can choose an open source platform like Drupal or WordPress, or a proprietary platform overseen by a company like Adobe or Microsoft. How do you know which is best for your website?
Things to consider:
- How much user support will I get?
- Which is better for security?
- Is the cost within budget?
For organizations with limited budgets, the choice is either an open source site or something less flexible like Wix or Squarespace the cost attached to a proprietary platform might be out of reach. However, for a large enterprise organization, both approaches have pros and cons worth addressing.
Proprietary platforms can be attractive to many large organizations for several reasons. In addition to promising great platforms customized to the client's business needs, proprietary arrangements typically offer full hosting plans. The company behind the CMS handles all updates, upgrades, security issues, and bugs often 24/7.
While proprietary software comes with a high price point, there's a sense of justification behind it: at least you get what you pay for.
It's worth noting, though, that many of the world's biggest corporate brands use Drupal as their CMS of choice, including General Electric, Tesla, IBM, Paramount Global, United Airlines, and the Royal Family. The Government of Australia operates on Drupal, as does the Government of Ontario, the Canadian Security Intelligence Service (CSIS), several US state governments, and countless other government agencies around the world.
So, why do organizations that have large budgets for web development opt for an open source platform, despite the supposed advantages touted by proprietary providers?
The answers are numerous, ranging from a need for financial accountability to the supportive nature of the Drupal community. These factors more than make up for any potential shortcomings of the open source model.
This article runs through some popular myths around proprietary and open source platforms that continue to influence decision making.
### Myth #1: Proprietary platforms provide better user support
One of the main selling points of proprietary platforms is that its vendors promise 24/7 client support should anything go wrong with the site, or if you need anything customized. This 24/7 support comes at a cost. For institutions concerned about sudden emergencies, this is obviously an appealing offering that for many justifies the price tag.
What proprietary vendors won't tell you, however, is that open source platforms like Drupal provide much of the same service (typically in tandem with an agency and an infrastructure partner like Acquia or Pantheon). This is provided at no cost through their networks of volunteers and sponsored contributors.
[Drupal][1], for example, is supported by a global community of hundreds of thousands of contributors who work collaboratively to address technical issues and improve the platform.
In the Drupal world, when you find a bug and create a report within the community, the response — while not necessarily instantaneous — is typically fast. While mission-critical sites like government platforms will need to pay somebody to be available for 24/7 support, this broader community support is of enormous benefit to all Drupal users.
Proprietary platforms do have counterparts to this type of community, but they're oftentimes much smaller. Sitecore, for example, advertises that it has a community of 20,000 developers. This is a drop in the bucket compared to the scope of the Drupal developer community.
### Myth #2: Proprietary is more secure than open source
This is a stubborn myth — understandably. Open source code, by its nature, is publicly available to anyone, including individuals with malicious intent. In contrast, proprietary platforms keep their codebases under lock and key. The for-profit nature of proprietary vendors gives them a greater (financial) incentive to track down and neutralize bad actors.
The unpopular truth is that proprietary platforms are every bit as vulnerable to attacks as their open source counterparts — if not more so.
For one thing, most security breaches don't come from hackers scouring source code for weak spots, but from avoidable human lapses such as failures to follow security guidelines, improper software setup, use of easy passwords, lack of data validation processes, and absence of data encryption techniques. These lapses are no less likely to occur on a proprietary platform than they are on an open source one.
Paradoxically, the open source nature of platforms like Drupal is actually more of a help than a liability when it comes to cybersecurity. Open source code means that anyone with the know-how can search for and identify vulnerabilities. And with an army of over a million developers contributing behind the scenes, it's safe to say that Drupal takes its [security][2] very seriously. Proprietary vendors, by contrast, are limited in this capacity by their cybersecurity staffing numbers.
### Myth #3: Proprietary costs more, so you get more value
It's widely believed that when you opt for a less expensive product —in this case, an open source website — you're either settling for a "less-good" quality product or setting yourself up for additional costs down the road in the form of upgrades and modifications. Proprietary websites may cost more at the outset, but at least you know you're getting something of real quality and the costs are predictable.
In truth, there is no difference in quality between open source and proprietary websites. It all depends on the quality of workmanship that goes into building the sites. And while any website project is vulnerable to budget overruns, proprietary platforms are actually more prone to them than open source ones.
When you opt for a proprietary platform, you automatically commit to paying for a license. This may be a one-time cost or a recurring subscription fee. In many cases, proprietary providers charge on a "per-seat" basis, meaning that the larger your team gets, the more expensive maintaining your website becomes. An open source site, by contrast, costs nothing beyond what you spend on design, and is in fact much more predictable from a cost standpoint.
This is of particular importance to governments, whose website development and renewal costs are publicly available and subject to intense media scrutiny. The Government of Canada faced [negative press][3] after it hired Adobe to restructure a vast swath of federal websites under the [Canada.ca][4] URL. A project originally valued at $1.54 million in 2015 had by the following year ballooned to $9.2 million. While details were scant, some of this budget overrun was attributed to costs due to additional staffing requirements. Cue impending doom music.
Websites built on open source platforms like Drupal aren't cheap to develop, but the costs are almost always more predictable. And when it's the taxpayers who are footing the bill, this is a major advantage.
### Bonus: Open source = wider talent base
If you're a large government organization with complex web needs, chances are you'll be looking to hire in-house developers. From this standpoint, it makes much more sense to opt for an open source web platform in terms of available talent. The magnitude of the Drupal community relative to, say, Sitecore, means that your LinkedIn search is far more likely to turn up Drupal specialists in your area than Sitecore experts.
Similar disparities exist when it comes to providing your staff with training. Drupal training is widely available and affordable. Hint: they offer [customized training][5]. Becoming a licensed developer for something run by Adobe, by contrast, is a much more complex and expensive undertaking.
### Why Drupal specifically?
I've touted Drupal extensively throughout this post, as Evolving Web is the home of many Drupal trainers, developers and experts However, it's far from the only open source CMS option out there. WordPress remains the world's [most popular CMS platform][6], being used by some 43% of the world's websites.
Drupal does, however, stand out from the pack in a number of important ways. The Drupal platform simply has more features and is a lot more supportive of customization than most of its open source competitors. This is perhaps less of a big deal if you're a small business or organization with a narrow area of focus. But government websites are generally complex, high-traffic undertakings responsible for disseminating a wide range of content to a diverse array of audiences.
### Other cool government sites are using It
Evolving Web recently redesigned the official website for the [City of Hamilton][7]. As the main online hub for Canada's ninth largest municipal area, serving some 800,000 people, the City of Hamilton website caters to a wide range of audiences, from residents and local business people to tourists and foreign investors. Its services run the gamut, enabling residents to plan public transit use, pay property taxes, find employment, apply for a marriage license, and get information on recreational activities, among many other options.
The City of Hamilton site exemplifies many of Drupal's strengths. Like many government websites, it encompasses vast swaths of data and resources and is subject to considerable surges in traffic, both of which Drupal is well equipped to handle. The site revamp also involved corralling various third-party services (including the recreation sign-up and council meeting scheduler) and a half-dozen websites that existed outside of Drupal. This required creative solutions of the sort that the Drupal community excels at developing.
### Drupal upholds accessibility standards
A further advantage of Drupal for government websites is that its publishing platform, along with all of its other features and services, is designed to be fully accessible in accordance with WCAG standards. Drupal's default settings ensure accurate interpretation of text by screen readers, provide accessible color contrast, and intensity recommendations. They also generate pictures and forms that are accessible and incorporate skip navigation in its core themes.
### You are in good company
All this attests to the strengths of the open source model — and of Drupal in particular — underpinned as it is by an army of over a million contributors. Thanks to this, the platform is in a constant state of improvement and innovation, of which every single Drupal user is a beneficiary.
### Join the club
At Evolving Web, we specialize in helping organizations harness their online presence with open source platforms like Drupal and WordPress. Let's keep in touch!
Join our inner circle and sign up for our [newsletter][8], where you'll get insider content and hear more about upcoming training programs, webinars and events.
--------------------------------------------------------------------------------
via: https://opensource.com/article/23/3/open-source-cms-myths
作者:[Pierina Wetto][a]
选题:[lkxed][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/pierinawetto
[b]: https://github.com/lkxed/
[1]: https://www.drupal.org/
[2]: https://www.drupal.org/drupal-security-team
[3]: https://www.cbc.ca/news/politics/canadaca-federal-website-delays-1.3893254
[4]: https://www.canada.ca/
[5]: https://evolvingweb.com/training?utm_source=community&utm_medium=pr&utm_campaign=opensource_feb23
[6]: https://evolvingweb.com/wordpress-web-development?utm_source=community&utm_medium=pr&utm_campaign=opensource_feb23
[7]: https://www.hamilton.ca/
[8]: https://evolvingweb.com/newsletter?utm_source=community&utm_medium=pr&utm_campaign=opensource_feb23

View File

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

View File

@ -1,5 +1,5 @@
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: translator: (cool-summer-021)
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
@ -65,7 +65,7 @@ via: https://www.linux.com/news/open-source-security-foundation-openssf-reflecti
作者:[The Linux Foundation][a]
选题:[lujun9972][b]
译者:[译者ID](https://github.com/译者ID)
译者:[cool-summer-021](https://github.com/cool-summer-021)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出

View File

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

View File

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

View File

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

View File

@ -0,0 +1,203 @@
[#]: subject: "Why simplicity is critical to delivering sturdy applications"
[#]: via: "https://opensource.com/article/21/2/simplicity"
[#]: author: "Alex Bunardzic https://opensource.com/users/alex-bunardzic"
[#]: collector: "lkxed"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
Why simplicity is critical to delivering sturdy applications
======
In the previous articles in this series, I explained why tackling coding problems all at once, as if they were hordes of zombies, is a mistake. I'm using a helpful acronym explaining why it's better to approach problems incrementally. **ZOMBIES** stands for:
**Z** Zero**O** One**M** Many (or more complex)**B** Boundary behaviors**I** Interface definition**E** Exercise exceptional behavior**S** Simple scenarios, simple solutions
More Great Content
- [Free online course: RHEL technical overview][1]
- [Learn Advanced Linux Commands][2]
- [Download Cheat Sheets][3]
- [Find an Open Source Alternative][4]
- [Read Top Linux Content][5]
- [Check out open source resources][6]
In the first four articles in this series, I demonstrated the first five **ZOMBIES** principles. The first article [implemented **Z**ero][7], which provides the simplest possible path through your code. The second article performed [tests with **O**ne and **M**any][8] samples, the third article looked at [**B**oundaries and **I**nterfaces][9], and the fourth examined [**E**xceptional behavior][10]. In this article, I'll take a look at the final letter in the acronym: **S**, which stands for "simple scenarios, simple solutions."
### Simple scenarios, simple solutions in action
If you go back and examine all the steps taken to implement the shopping API in this series, you'll see a purposeful decision to always stick to the simplest possible scenarios. In the process, you end up with the simplest possible solutions.
There you have it: **ZOMBIES** help you deliver sturdy, elegant solutions by adhering to simplicity.
### Victory?
It might seem you're done here, and a less conscientious engineer would very likely declare victory. But enlightened engineers always probe a bit deeper.
One exercise I always recommend is [mutation testing][11]. Before you wrap up this exercise and go on to fight new battles, it is wise to give your solution a good shakeout with mutation testing. And besides, you have to admit that _mutation_ fits well in a battle against zombies.
Use the open source [Stryker.NET][12] to run mutation tests.
![Mutation testing][13]
It looks like you have one surviving mutant! That's not a good sign.
What does this mean? Just when you thought you had a rock-solid, sturdy solution, Stryker.NET is telling you that not everything is rosy in your neck of the woods.
Take a look at the pesky mutant who survived:
![Surviving mutant][14]
The mutation testing tool took the statement:
```
if(total > 500.00) {
```
and mutated it to:
```
if(total >= 500.00) {
```
Then it ran the tests and realized that none of the tests complained about the change. If there is a change in processing logic and none of the tests complain about the change, that means you have a surviving mutant.
### Why mutation matters
Why is a surviving mutant a sign of trouble? It's because the processing logic you craft governs the behavior of your system. If the processing logic changes, the behavior should change, too. And if the behavior changes, the expectations encoded in the tests should be violated. If these expectations are not violated, that means that the expectations are not precise enough. You have a loophole in your processing logic.
To fix this, you need to "kill" the surviving mutant. How do you do that? Typically, the fact that a mutant survived means at least one expectation is missing.
Look through your code to see what expectation, if any, is not there:
- You clearly defined the expectation that a newly created basket has zero items (and, by implication, has a $0 grand total).
- You also defined the expectation that adding one item will result in the basket having one item, and if the item price is $10, the grand total will be $10.
- Furthermore, you defined the expectation that adding two items to the basket, one item priced at $10 and the other at $20, results in a grand total of $30.
- You also declared expectations regarding the removal of items from the basket.
- Finally, you defined the expectation that any order total greater than $500 results in a price discount. The business policy rule dictates that in such a case, the discount is 10% of the order's total price.
What is missing? According to the mutation testing report, you never defined an expectation regarding what business policy rule applies when the order total is exactly $500. You defined what happens if the order total is greater than the $500 threshold and what happens when the order total is less than $500.
Define this edge-case expectation:
```
[Fact]
public void Add2ItemsTotal500GrandTotal500() {
var expectedGrandTotal = 500.00;
var actualGrandTotal = 450;
Assert.Equal(expectedGrandTotal, actualGrandTotal);
}
```
The first stab fakes the expectation to make it fail. You now have nine microtests; eight succeed, and the ninth test fails:
```
[xUnit.net 00:00:00.57] tests.UnitTest1.Add2ItemsTotal500GrandTotal500 [FAIL]
X tests.UnitTest1.Add2ItemsTotal500GrandTotal500 [2ms]
Error Message:
Assert.Equal() Failure
Expected: 500
Actual: 450
[...]
Test Run Failed.
Total tests: 9
Passed: 8
Failed: 1
Total time: 1.5920 Seconds
```
Replace hard-coded values with an expectation of a confirmation example:
```
[Fact]
public void Add2ItemsTotal500GrandTotal500() {
var expectedGrandTotal = 500.00;
Hashtable item1 = new Hashtable();
item1.Add("0001", 400.00);
shoppingAPI.AddItem(item1);
Hashtable item2 = new Hashtable();
item2.Add("0002", 100.00);
shoppingAPI.AddItem(item2);
var actualGrandTotal = shoppingAPI.CalculateGrandTotal(); }
```
You added two items, one priced at $400, the other at $100, totaling $500. After calculating the grand total, you expect that it will be $500.
Run the system. All nine tests pass!
```
Total tests: 9
Passed: 9
Failed: 0
Total time: 1.0440 Seconds
```
Now for the moment of truth. Will this new expectation remove all mutants? Run the mutation testing and check the results:
![Mutation testing success][15]
Success! All 10 mutants were killed. Great job; you can now ship this API with confidence.
### Epilogue
If there is one takeaway from this exercise, it's the emerging concept of _skillful procrastination_. It's an essential concept, knowing that many of us tend to rush mindlessly into envisioning the solution even before our customers have finished describing their problem.
#### Positive procrastination
Procrastination doesn't come easily to software engineers. We're eager to get our hands dirty with the code. We know by heart numerous design patterns, anti-patterns, principles, and ready-made solutions. We're itching to put them into executable code, and we lean toward doing it in large batches. So it is indeed a virtue to _hold our horses_ and carefully consider each and every step we make.
This exercise proves how **ZOMBIES** help you take many deliberate small steps toward solutions. It's one thing to be aware of and to agree with the [Yagni][16] principle, but in the "heat of the battle," those deep considerations often fly out the window, and you end up throwing in everything and the kitchen sink. And that produces bloated, tightly coupled systems.
### Iteration and incrementation
Another essential takeaway from this exercise is the realization that the only way to keep a system working at all times is by adopting an _iterative approach_. You developed the shopping API by applying some _rework_, which is to say, you proceeded with coding by making changes to code that you already changed. This rework is unavoidable when iterating on a solution.
One of the problems many teams experience is confusion related to iteration and increments. These two concepts are fundamentally different.
An _incremental approach_ is based on the idea that you hold a crisp set of requirements (or a _blueprint_) in your hand, and you go and build the solution by working incrementally. Basically, you build it piece-by-piece, and when all pieces have been assembled, you put them together, and _voila_! The solution is ready to be shipped!
In contrast, in an _iterative approach_, you are less certain that you know all that needs to be known to deliver the expected value to the paying customer. Because of that realization, you proceed gingerly. You're wary of breaking the system that already works (i.e., the system in a steady-state). If you disturb that balance, you always try to disturb it in the least intrusive, least invasive manner. You focus on taking the smallest imaginable batches, then quickly wrapping up your work on each batch. You prefer to have the system back to the steady-state in a matter of minutes, sometimes even seconds.
That's why an iterative approach so often adheres to "_fake it 'til you make it_." You hard-code many expectations so that you can verify that a tiny change does not disable the system from running. You then make the changes necessary to replace the hard-coded value with real processing.
As a rule of thumb, in an iterative approach, you aim to craft an expectation (a microtest) in such a way that it precipitates only one improvement to the code. You go one improvement by one improvement, and with each improvement, you exercise the system to make sure it is in a working state. As you proceed in that fashion, you eventually hit the stage where all the expectations have been met, and the code has been refactored in such a way that it leaves no surviving mutants.
Once you get to that state, you can be fairly confident that you can ship the solution.
Many thanks to inimitable [Kent Beck][17], [Ron Jeffries][18], and [GeePaw Hill][19] for being a constant inspiration on my journey to software engineering apprenticeship.
And may _your_ journey be filled with ZOMBIES.
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/2/simplicity
作者:[Alex Bunardzic][a]
选题:[lkxed][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/alex-bunardzic
[b]: https://github.com/lkxed/
[1]: https://www.redhat.com/en/services/training/rh024-red-hat-linux-technical-overview?intcmp=7016000000127cYAAQ
[2]: https://developers.redhat.com/cheat-sheets/advanced-linux-commands/?intcmp=7016000000127cYAAQ
[3]: https://opensource.com/downloads/cheat-sheets?intcmp=7016000000127cYAAQ
[4]: https://opensource.com/alternatives?intcmp=7016000000127cYAAQ
[5]: https://opensource.com/tags/linux?intcmp=7016000000127cYAAQ
[6]: https://opensource.com/resources?intcmp=7016000000127cYAAQ
[7]: https://opensource.com/article/21/1/zombies-zero
[8]: https://opensource.com/article/21/1/zombies-2-one-many
[9]: https://opensource.com/article/21/1/zombies-3-boundaries-interface
[10]: https://opensource.com/article/21/1/zombies-4-exceptional-behavior
[11]: https://opensource.com/article/19/9/mutation-testing-example-definition
[12]: https://stryker-mutator.io/
[13]: https://opensource.com/sites/default/files/uploads/stryker-net.png
[14]: https://opensource.com/sites/default/files/uploads/mutant.png
[15]: https://opensource.com/sites/default/files/uploads/stryker-net-success.png
[16]: https://martinfowler.com/bliki/Yagni.html
[17]: https://en.wikipedia.org/wiki/Kent_Beck
[18]: https://en.wikipedia.org/wiki/Ron_Jeffries
[19]: https://www.geepawhill.org/

View File

@ -1,167 +0,0 @@
[#]: subject: "Get started with edge computing by programming embedded systems"
[#]: via: "https://opensource.com/article/21/3/rtos-embedded-development"
[#]: author: "Alan Smithee https://opensource.com/users/alansmithee"
[#]: collector: "lkxed"
[#]: translator: "cool-summer-021"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
Get started with edge computing by programming embedded systems
======
The AT device package for controlling wireless modems is one of RTOS's most popular extensions.
![Looking at a map][1]
Image by: opensource.com
RTOS is an open source [operating system for embedded devices][2] developed by RT-Thread. It provides a standardized, friendly foundation for developers to program a variety of devices and includes a large number of useful libraries and toolkits to make the process easier.
Like Linux, RTOS uses a modular approach, which makes it easy to extend. Packages enable developers to use RTOS for any device they want to target. One of RTOS's most popular extensions is the AT device package, which includes porting files and sample code for different AT devices (i.e., modems).
At over 62,000 downloads (at the time of this writing, at least), one of the most popular extensions to RTOS is the AT device package, which includes porting files and sample code for different AT devices.
### About AT commands
AT commands were originally a protocol to control old dial-up modems. As modem technology moved on to higher bandwidths, it remained useful to have a light and efficient protocol for device control, and major mobile phone manufacturers jointly developed a set of AT commands to control the GSM module on mobile phones.
Today, the AT protocol is still common in networked communication, and there are many devices, including WiFi, Bluetooth, and 4G, that accept AT commands.
If you're creating purpose-built appliances for edge computing input, monitoring, or the Internet of Things (IoT), some of the AT devices supported by RTOS that you may encounter include ESP8266, ESP32, M26, MC20, RW007, MW31, SIM800C, W60X, SIM76XX, A9/A9G, BC26, AIR720, ME3616, M 6315, BC28, and EC200X.
RT-Thread contains the Socket Abstraction Layer (SAL) component, which implements the abstraction of various network protocols and interfaces and provides a standard set of [BSD socket][3] APIs to the upper level. The SAL then takes over the AT socket interface so that developers just need to consider the network interface provided by the network application layer.
This package implements the AT socket on devices (including the ones above), allowing communications through standard socket interfaces in the form of AT commands. The [RT-thread programming guide][4] includes descriptions of specific functions.
The at_device package is distributed under an LGPLv2.1 license, and it's easy to obtain by using the [RT-Thread Env tool][5]. This tool includes a configurator and a package manager, which configure the kernel and component functions and can be used to tailor the components and manage online packages. This enables developers to build systems as if they were building blocks.
### Get the at_device package
To use AT devices with RTOS, you must enable the AT component library and AT socket functionality. This requires:
* RT_Thread 4.0.2+
* RT_Thread AT component 1.3.0+
* RT_Thread SAL component
* RT-Thread netdev component
The AT device package has been updated for multiple versions. Different versions require different configuration options, so they must fit into the corresponding system versions. Most of the currently available AT device package versions are:
* V1.2.0: For RT-Thread versions less than V3.1.3, AT component version equals V1.0.0
* V1.3.0: For RT-Thread versions less than V3.1.3, AT component version equals V1.1.0
* V1.4.0: For RT-Thread versions less than V3.1.3 or equal to V4.0.0, AT component version equals V1.2.0
* V1.5.0: For RT-Thread versions less than V3.1.3 or equal to V4.0.0, AT component version equals V1.2.0
* V1.6.0: For RT-Thread versions equal to V3.1.3 or V4.0.1, AT component version equals V1.2.0
* V2.0.0/V2.0.1: For RT-Thread versions higher than V4.0.1 or higher than 3.1.3, AT component version equals V1.3.0
* Latest version: For RT-Thread versions higher than V4.0.1 or higher than 3.1.3, AT component version equals V1.3.0
Getting the right version is mostly an automatic process done in menuconfig. It provides the best version of the at_device package based on your current system environment.
As mentioned, different versions require different configuration options. For instance, version 1.x supports enabling one AT device at a time:
```
RT-Thread online packages  --->
     IoT - internet of things  --->
        -*- AT DEVICE: RT-Thread AT component porting or samples for different device  
        [ ]   Enable at device init by thread
              AT socket device modules (Not selected, please select)  --->    
              Version (V1.6.0)  --->
```
The option to enable the AT device init by thread dictates whether the configuration creates a separate thread to initialize the device network.
Version 2.x supports enabling multiple AT devices at the same time:
```
RT-Thread online packages  --->
     IoT - internet of things  --->
        -*- AT DEVICE: RT-Thread AT component porting or samples for different device
        [*]   Quectel M26/MC20  --->
          [*]   Enable initialize by thread
          [*]   Enable sample
          (-1)    Power pin
          (-1)    Power status pin
          (uart3) AT client device name
          (512)   The maximum length of receive line buffer
        [ ]   Quectel EC20  --->
        [ ]   Espressif ESP32  --->
        [*]   Espressif ESP8266  --->
          [*]   Enable initialize by thread
          [*]   Enable sample
          (realthread) WIFI ssid
          (12345678) WIFI password
          (uart2) AT client device name
          (512)   The maximum length of receive line buffer
        [ ]   Realthread RW007  --->
        [ ]   SIMCom SIM800C  --->
        [ ]   SIMCom SIM76XX  --->
        [ ]   Notion MW31  --->
        [ ]   WinnerMicro W60X  --->
        [ ]   AiThink A9/A9G  --->
        [ ]   Quectel BC26  --->
        [ ]   Luat air720  --->
        [ ]   GOSUNCN ME3616  --->
        [ ]   ChinaMobile M6315  --->
        [ ]   Quectel BC28  --->
        [ ]   Quectel ec200x  --->
        Version (latest)  --->
```
This version includes many other options, including one to enable sample code, which might be particularly useful to new developers or any developer using an unfamiliar device.
You can also control options to choose which pin you want to use to supply power to your component, a pin to indicate the power state, the name of the serial device the sample device uses, and the maximum length of the data the sample device receives. On applicable devices, you can also set the SSID name and password.
In short, there is no shortage of control options.
* V2.X.X version supports enabling multiple AT devices simultaneously, and the enabled device information can be viewed with the `ifocnfig` command in [finsh shell][6].
* V2.X.X version requires the device to register before it's used; the registration can be done in the samples directory file or customized in the application layer.
* Pin options such as Power pin and Power status pin are configured according to the device's hardware connection. They can be configured as `-1` if the hardware power-on function is not used.
* One AT device should correspond to one serial name, and the AT client device name for each device should be different.
### AT components configuration options
When the AT device package is selected and device support is enabled, client functionality for the AT component is selected by default. That means more options—this time for the AT component:
```
RT-Thread Components  --->
    Network  --->
        AT commands  --->
    [ ]   Enable debug log output
    [ ]   Enable AT commands server
    -*-   Enable AT commands client
    (1)     The maximum number of supported clients
    -*-     Enable BSD Socket API support by AT commnads
    [*]     Enable CLI(Command-Line Interface) for AT commands
    [ ]     Enable print RAW format AT command communication data
    (128)   The maximum length of AT Commonds buffer
```
The configuration options related to the AT device package are:
* The maximum number of supported clients: Selecting multiple devices in the AT device package requires this option to be configured as the corresponding value.
* Enable BSD Socket API support by AT commands: This option will be selected by default when selecting the AT device package.
* The maximum length of AT Commands buffe: The maximum length of the data the AT commands can send.
### Anything is possible
When you start programming embedded systems, you quickly realize that you can create anything you can imagine. RTOS aims to help you get there, and its packages offer a head start. Interconnected devices are the expectation now. IoT technology on the [edge][7] must be able to communicate across various protocols, and the AT protocol is the key.
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/3/rtos-embedded-development
作者:[Alan Smithee][a]
选题:[lkxed][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/alansmithee
[b]: https://github.com/lkxed
[1]: https://opensource.com/sites/default/files/lead-images/tips_map_guide_ebook_help_troubleshooting_lightbulb_520.png
[2]: https://opensource.com/article/20/6/open-source-rtos
[3]: https://en.wikipedia.org/wiki/Berkeley_sockets
[4]: https://github.com/RT-Thread/rtthread-manual-doc/blob/master/at/at.md
[5]: https://www.rt-thread.io/download.html?download=Env
[6]: https://www.rt-thread.org/download/rttdoc_1_0_0/group__finsh.html
[7]: https://www.redhat.com/en/topics/edge-computing

View File

@ -1,119 +0,0 @@
[#]: subject: (Try quantum computing with this open source software development kit)
[#]: via: (https://opensource.com/article/21/6/qiskit)
[#]: author: (Gordon Haff https://opensource.com/users/ghaff)
[#]: collector: (lujun9972)
[#]: translator: ( )
[#]: reviewer: ( )
[#]: publisher: ( )
[#]: url: ( )
Try quantum computing with this open source software development kit
======
Qiskit is an open source software development kit for accessing quantum
simulators and hardware for free.
![Tips and gears turning][1]
Classical computing is based on bits. Zeros and ones. This isn't because there's some inherent advantage to a binary logic system over logic systems with more states—or even over analog computers. But on-off switches are easy to make and, with modern semiconductor technology, we can make them very small and very cheap.
But they're not without limits. Some problems just can't be efficiently solved by a classical computer. These tend to be problems where the cost, in time or memory, increases exponentially with the scale (`n`) of the problem. We say such problems are `O(2n)` in [Big O notation][2].
Much of modern cryptography even depends on this characteristic. Multiplying two, even large, prime numbers together is fairly cheap computationally (`O(n2)`). But reversing the operation takes exponential time. Use large enough numbers, and decryption that depends on such a factoring attack is infeasible.
### Enter quantum
A detailed primer on the mathematical and quantum mechanical underpinnings of quantum computing is beyond the scope of this article. However, here are some basics.
A quantum computer replaces bits with [qubits][3]—controllable units of computing that display quantum properties. Qubits are typically made out of either an engineered superconducting component or a naturally occurring quantum object such as an electron. Qubits can be placed into a "superposition" state that is a complex combination of the 0 and 1 states. You sometimes hear that qubits are _both_ 0 and 1, but that's not really accurate. What is true is that, when a measurement is made, the qubit state will collapse into a 0 or 1. Mathematically, the (unmeasured) quantum state of the qubit is a point on a geometric representation called the [Bloch sphere][4].
While superposition is a novel property for anyone used to classical computing, one qubit by itself isn't very interesting. The next unique quantum computational property is "interference." Real quantum computers are essentially statistical in nature. Quantum algorithms encode an interference pattern that increases the probability of measuring a state encoding the solution.
While novel, superposition and interference do have some analogs in the physical world. The quantum mechanical property "entanglement" doesn't, and it's the real key to exponential quantum speedups. With entanglement, measurements on one particle can affect the outcome of subsequent measurements on any entangled particles—even ones not physically connected.
### What can quantum do?
Today's quantum computers are quite small in terms of the number of qubits they contain—tens to hundreds. Thus, while algorithms are actively being developed, the hardware needed to run them faster than their classical equivalents doesn't exist.
But there's considerable interest in quantum computing in many fields. For example, quantum computers may offer a good way to simulate natural quantum systems, like molecules, whose complexity rapidly exceeds the ability of classical computers to model them accurately. Quantum computing is also tied mathematically to linear algebra, which underpins machine learning and many other modern optimization problems. Therefore, it's reasonable to think quantum computing could be a good fit there as well.
One commonly cited example of an existing quantum algorithm likely to outperform classical algorithms is [Shor's algorithm][5], which can do the factoring mentioned earlier. Invented by MIT mathematician Peter Shor in 1994, quantum computers can't yet run the algorithm on larger than trivially sized problems. But it's been demonstrated to work in polynomial `O(n3)` time rather than the exponential time required by classical algorithms.
### Getting started with Qiskit
At this point, you may be thinking: "But I don't have a quantum computer, and I really like to get hands-on. Is there any hope?"
Enter an open source (Apache 2.0 licensed) project called [Qiskit][6]. It's a software development kit (SDK) for accessing both the quantum computing simulators and the actual quantum hardware (for free) in the IBM Quantum Experience. You just need to sign up for an API key.
Certainly, a deep dive into Qiskit, to say nothing of the related linear algebra, is far beyond what I can get into here. If you seek such a dive, there are [many free resources online][7], including a complete textbook. However, dipping a toe in the water is straightforward, requiring only some surface-level knowledge of Python and Jupyter Notebooks.
To give you a taste, let's do a "Hello, World!" program entirely within the [Qiskit textbook][8].
Begin by installing some tools and widgets specific to the textbook:
```
`pip install git+https://github.com/qiskit-community/qiskit-textbook.git#subdirectory=qiskit-textbook-src`
```
Next, do the imports:
```
from qiskit import QuantumCircuit, assemble, Aer
from math import pi, sqrt
from qiskit.visualization import plot_bloch_multivector, plot_histogram
```
Aer is the local simulator. Qiskit consists of four components: **Aer**, the **Terra** foundation, **Ignis** for dealing with noise and errors on real quantum systems, and **Aqua** for algorithm development.
```
# Let's do an X-gate on a |0&gt; qubit
qc = QuantumCircuit(1)
qc.x(0)
qc.draw()
```
An **X-gate** in quantum computing is similar to a **Not gate** in classical computing, although the underlying math actually involves matrix multiplication. (It is, in fact, often called a **NOT-gate**.)
Now, run it and do a measurement. The result is as you would expect because the qubit was initialized in a `|0>` state, then inverted, and measured. (Use `|0>` and `|1>` to distinguish from classic bits.)
```
# Let's see the result
svsim = Aer.get_backend('statevector_simulator')
qobj = assemble(qc)
state = svsim.run(qobj).result().get_statevector()
plot_bloch_multivector(state)
```
![Bloch sphere showing the expected result][9]
Bloch sphere showing the expected result. (Gordon Haff, [CC-BY-SA 4.0][10])
### Conclusion
In some respects, you can think of quantum computing as a sort of exotic co-processor for classical computers in the same manner as graphics processing units (GPUs) and field-programmable gate arrays (FPGAs). One difference is that quantum computers will be accessed almost entirely as network resources for the foreseeable future. Another is that they work fundamentally differently, which makes them unlike most other accelerators you might be familiar with. That's why there's so much interest in algorithm development and significant resources going in to determine where and when quantum fits best. It wouldn't hurt to see what all the fuss is about.
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/6/qiskit
作者:[Gordon Haff][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/ghaff
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/gears_devops_learn_troubleshooting_lightbulb_tips_520.png?itok=HcN38NOk (Tips and gears turning)
[2]: https://en.wikipedia.org/wiki/Big_O_notation
[3]: https://en.wikipedia.org/wiki/Qubit
[4]: https://en.wikipedia.org/wiki/Bloch_sphere
[5]: https://en.wikipedia.org/wiki/Shor%27s_algorithm
[6]: https://qiskit.org/
[7]: https://qiskit.org/learn
[8]: https://qiskit.org/textbook/preface.html
[9]: https://opensource.com/sites/default/files/uploads/bloch-sphere.png (Bloch sphere showing the expected result)
[10]: https://creativecommons.org/licenses/by-sa/4.0/

View File

@ -1,285 +0,0 @@
[#]: subject: "Short option parsing using getopt in C"
[#]: via: "https://opensource.com/article/21/8/short-option-parsing-c"
[#]: author: "Jim Hall https://opensource.com/users/jim-hall"
[#]: collector: "lujun9972"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
Short option parsing using getopt in C
======
Use the command line to make your programs more flexible by allowing
users to tell them what to do.
![Person programming on a laptop on a building][1]
Writing a C program to process files is easy when you already know what files you'll operate on and what actions to take. If you "hard code" the filename into your program, or if your program is coded to do things only one way, then your program will always know what to do.
But you can make your program much more flexible if it can respond to the user every time the program runs. Let your user tell your program what files to use or how to do things differently. And for that, you need to read the command line.
### Reading the command line
When you write a program in C, you might start with the declaration:
```
`int main()`
```
That's the simplest way to start a C program. But if you add these standard parameters in the parentheses, your program can read the options given to it on the command line:
```
`int main(int argc, char **argv)`
```
The `argc` variable is the argument count or the number of arguments on the command line. This will always be a number that's at least one.
The `argv` variable is a double pointer, an array of strings, that contains the arguments from the command line. The first entry in the array, `*argv[0]`, is always the name of the program. The other elements of the `**argv` array contain the rest of the command-line arguments.
I'll write a simple program to echo back the options given to it on the command line. This is similar to the Linux `echo` command, except it also prints the name of the program. It also prints each command-line option on its own line using the `puts` function:
```
#include &lt;stdio.h&gt;
int
main(int argc, char **argv)
{
  int i;
  [printf][2]("argc=%d\n", argc); /* debugging */
  for (i = 0; i &lt; argc; i++) {
    [puts][3](argv[i]);
  }
  return 0;
}
```
Compile this program and run it with some command-line options, and you'll see your command line printed back to you, each item on its own line:
```
$ ./echo this program can read the command line
argc=8
./echo
this
program
can
read
the
command
line
```
This command line sets the program's `argc` to `8`, and the `**argv` array contains eight entries: the name of the program, plus the seven words the user entered. And as always in C programs, the array starts at zero, so the elements are numbered 0, 1, 2, 3, 4, 5, 6, 7. That's why you can process the command line with the `for` loop using the comparison `i < argc`.
You can use this to write your own versions of the Linux `cat` or `cp` commands. The `cat` command's basic functionality displays the contents of one or more files. Here's a simple version of `cat` that reads the filenames from the command line:
```
#include &lt;stdio.h&gt;
void
copyfile(FILE *in, FILE *out)
{
  int ch;
  while ((ch = [fgetc][4](in)) != EOF) {
    [fputc][5](ch, out);
  }
}
int
main(int argc, char **argv)
{
  int i;
  FILE *fileptr;
  for (i = 1; i &lt; argc; i++) {
    fileptr = [fopen][6](argv[i], "r");
    if (fileptr != NULL) {
      copyfile(fileptr, stdout);
      [fclose][7](fileptr);
    }
  }
  return 0;
}
```
This simple version of `cat` reads a list of filenames from the command line and displays the contents of each file to the standard output, one character at a time. For example, if I have one file called `hello.txt` that contains a few lines of text, I can display its contents with my own `cat` command:
```
$ ./cat hello.txt
Hi there!
This is a sample text file.
```
Using this sample program as a starting point, you can write your own versions of other Linux commands, such as the `cp` program, by reading only two filenames: one file to read from and another file to write the copy.
### Reading command-line options
Reading filenames and other text from the command line is great, but what if you want your program to change its behavior based on the _options_ the user gives it? For example, the Linux `cat` command supports several command-line options, including:
* `-b` Put line numbers next to non-blank lines
* `-E` Show the ends of lines as `$`
* `-n` ` `Put line numbers next to all lines
* `-s` Suppress printing repeated blank lines
* `-T` Show tabs as `^I`
* `-v` ` `Verbose; show non-printing characters using `^x` and `M-x` notation, except for new lines and tabs
These _single-letter_ options are called _short options_, and they always start with a single hyphen character. You usually see these short options written separately, such as `cat -E -n`, but you can also combine the short options into a single _option string_ such as `cat -En`.
Fortunately, there's an easy way to read these from the command line. All Linux and Unix systems include a special C library called `getopt`, defined in the `unistd.h` header file. You can use `getopt` in your program to read these short options.
Unlike other Unix systems, `getopt` on Linux will always ensure your short options appear at the front of your command line. For example, say a user types `cat -E file -n`. The `-E` option is upfront, but the `-n` option is after the filename. But if you use Linux `getopt`, your program will always behave as though the user types `cat -E -n file`. That makes processing a breeze because `getopt` can parse the short options, leaving you a list of filenames on the command line that your program can read using the `**argv` array.
You use `getopt` like this:
```
       #include &lt;unistd.h&gt;
       int getopt(int argc, char **argv, char *optstring);
```
The option string `optstring` contains a list of the valid option characters. If your program only allows the `-E` and `-n` options, you use "`En"` as your option string.
You usually use `getopt` in a loop to parse the command line for options. At each `getopt` call, the function returns the next short option it finds on the command line or the value `'?'` for any unrecognized short options. When `getopt` can't find any more short options, it returns `-1` and sets the global variable `optind` to the next element in `**argv` after all the short options.
Let's look at a simple example. This demo program isn't a full replacement of `cat` with all the options, but it can parse its command line. Every time it finds a valid command-line option, it prints a short message to indicate it was found. In your own programs, you might instead set a variable or take some other action that responds to that command-line option:
```
#include &lt;stdio.h&gt;
#include &lt;unistd.h&gt;
int
main(int argc, char **argv)
{
  int i;
  int option;
  /* parse short options */
  while ((option = getopt(argc, argv, "bEnsTv")) != -1) {
    switch (option) {
    case 'b':
      [puts][3]("Put line numbers next to non-blank lines");
      break;
    case 'E':
      [puts][3]("Show the ends of lines as $");
      break;
    case 'n':
      [puts][3]("Put line numbers next to all lines");
      break;
    case 's':
      [puts][3]("Suppress printing repeated blank lines");
      break;
    case 'T':
      [puts][3]("Show tabs as ^I");
      break;
    case 'v':
      [puts][3]("Verbose");
      break;
    default:                          /* '?' */
      [puts][3]("What's that??");
    }
  }
  /* print the rest of the command line */
  [puts][3]("------------------------------");
  for (i = optind; i &lt; argc; i++) {
    [puts][3](argv[i]);
  }
  return 0;
}
```
If you compile this program as `args`, you can try out different command lines to see how they parse the short options and always leave you with the rest of the command line. In the simplest case, with all the options up front, you get this:
```
$ ./args -b -T file1 file2
Put line numbers next to non-blank lines
Show tabs as ^I
\------------------------------
file1
file2
```
Now try the same command line but combine the two short options into a single option string:
```
$ ./args -bT file1 file2
Put line numbers next to non-blank lines
Show tabs as ^I
\------------------------------
file1
file2
```
If necessary, `getopt` can "reorder" the command line to deal with short options that are out of order:
```
$ ./args -E file1 file2 -T
Show the ends of lines as $
Show tabs as ^I
\------------------------------
file1
file2
```
If your user gives an incorrect short option, `getopt` prints a message:
```
$ ./args -s -an file1 file2
Suppress printing repeated blank lines
./args: invalid option -- 'a'
What's that??
Put line numbers next to all lines
\------------------------------
file1
file2
```
### Download the cheat sheet
`getopt` can do lots more than what I've shown. For example, short options can take their own options, such as `-s string` or `-f file`. You can also tell `getopt` to not display error messages when it finds unrecognized options. Read the `getopt(3)` manual page using `man 3 getopt` to learn more about what `getopt` can do for you.
If you're looking for gentle reminders on the syntax and structure of `getopt()` and `getopt_long()`, [download my getopt cheat sheet][8]. One page demonstrates short options, and the other side demonstrates long options with minimum viable code and a listing of the global variables you need to know.
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/8/short-option-parsing-c
作者:[Jim Hall][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/jim-hall
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/computer_code_programming_laptop.jpg?itok=ormv35tV (Person programming on a laptop on a building)
[2]: http://www.opengroup.org/onlinepubs/009695399/functions/printf.html
[3]: http://www.opengroup.org/onlinepubs/009695399/functions/puts.html
[4]: http://www.opengroup.org/onlinepubs/009695399/functions/fgetc.html
[5]: http://www.opengroup.org/onlinepubs/009695399/functions/fputc.html
[6]: http://www.opengroup.org/onlinepubs/009695399/functions/fopen.html
[7]: http://www.opengroup.org/onlinepubs/009695399/functions/fclose.html
[8]: https://opensource.com/downloads/c-getopt-cheat-sheet

View File

@ -1,143 +0,0 @@
[#]: subject: "3 steps for managing a beginner-friendly open source community"
[#]: via: "https://opensource.com/article/21/8/beginner-open-source-community"
[#]: author: "Isabel Costa https://opensource.com/users/isabelcmdcosta"
[#]: collector: "lujun9972"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
3 steps for managing a beginner-friendly open source community
======
As a member of an open source project, there's a lot you can do to help
beginners find a way to contribute. 
![Working from home at a laptop][1]
When someone is new to contributing to open source, the best place to start is often beginner-friendly bugs and issues. But before they can do that, they have to be able to find those kinds of issues. As a member of an open source project, there's a lot you can do to help beginners find a way to contribute. 
Bearing this in mind, the [AnitaB.org open source community][2] prioritizes making our community beginner-friendly. We have initiatives to ensure that we're inclusive for contributors at different levels of experience and for different types of contributions that don't only relate to coding.
I recently presented some of the community work we do at the [AnitaB.org][3] community at [Upstream 2021][4], the Tidelift event, which kicked off Maintainer Week, a weeklong celebration of open source maintainers. I discussed how there are three main parts to our strategy:
* How we communicate
* Projects and issues
* Open source programs
### How we communicate
Transparency is such an essential part of open source, and we apply transparency principles to our approach to communication. In practical terms, this means that all our community sessions are run openly, affect how we've set up Zulip chat and how we provide documentation.
#### **Open sessions**
Anyone can join our sessions and discuss topics related to our community. They can participate in discussions or just listen. These are available for everyone to see in our community calendar. We usually only use audio in these calls, which we've found can make people feel more comfortable participating.
We host project-focused sessions and a couple of category-related sessions, where people from different areas can discuss the same project and help improve our processes. Occasionally, we have "Ask Me Anything" sessions, where anyone can come and ask questions about anything related to open source.
We take notes of all sessions in a shared document and share the summary and a document link in [our Zulip][5].
#### **Our Zulip chat**
The open source Zulip chat platform is our primary community communication channel, although we also use the comments section on issues and pull requests on Github. In general, we have disabled private messaging to make sure we are as transparent as possible. We have only a few exceptions to this rule, where we have private streams for admins dealing with the logistics of the programs we run. We've found this approach is more welcoming, and it also enables us to have more visibility into conduct violations in the public chat.
We share all session summaries on the Zulip chat, including the main points discussed, action items, and documentation. This process might sound like an obvious requirement, but I've been surprised at how many open source projects don't provide notes so that people who did not attend can remain informed.
On Zulip, we discuss project roadmaps, answer questions and queries from the community, and actively **promote ways for people to contribute and where they can contribute. **Sometimes we celebrate contributors' wins—whether it's to highlight the first PR they have tested, reviewed, or the excellent work our volunteers do.
#### **Documentation**
We try to keep **open documentation about our processes**, such as FAQs, so those community members can learn at their own pace and in their own time about the community. This is intended to give them an idea of how we work and what type of work we do before reaching out to us.
### Projects and issues
Regarding our projects and issues management, we encourage multiple ways to contribute, create specific issues for first-timers only, and try to have an easy setup for projects.
#### **Multiple ways to contribute**
We make an effort to create **issues that require different contributions** such as documentation, testing, design, and outreach. This is to provide ways for anyone to contribute regardless of their experience level and area of interest. It helps the community get involved, and we've found that it enables members to work their way up and contribute to some low-effort but valuable tasks.
Types of contributions we promote are:
* Coding tasks that range in complexity.
* Quality assurance tasks—where contributors can test our apps or pull requests and report bugs.
* Design sessions where members can participate in discussions. Also, opportunities to create mock-ups and redesign parts of our apps, and explore user experience improvements.
* Outreach tasks, we primarily promote on Zulip, where we suggest blogging to our Medium publication about their open source experiences and their contributions.
* Documentation tasks that can include general community documentation or our project's documentation on Docusaurus.
#### **First-timers only issues**
We label some **issues as "first-timers only."** These are for people who have not contributed yet to the issue's repository. Labeling issues also enable us to have work for people beginning their open source journey during times of contributor influx, for example, during [Google Summer of Code (GSoC)][6].
Sometimes these might be "low-hanging fruit" that can get them acquainted with the process of contributing and submitting pull requests.
#### **Easy project setup**
We also care about having a **beginner-friendly setup **for our projects. We notice that the most active project is generally the easiest to set up. We know that contributing to a project you aren't familiar with can take a lot of effort and make or break the experience of contributing.
We try to provide instructions on how to run our projects on multiple operating systems. In the past, we had some projects with separate instructions to run on Unix environments, and we noticed contributors having difficulties running these projects on Windows. We've improved since then to avoid confusion among contributors who would ask for help on our Zulip.
We have been improving the README for one of our most active projects, [mentorship-backend][7], according to contributors' experience. One of the struggles for beginners in this project was setting part of the environment variables related to configuring an email account to enable the backend functionality to send emails. However, because this feature was not critical for local development, by default, we made the email setup optional so that emails, instead of being sent to users, were printed to the terminal. This approach still made the emails visible to the contributor. Similar to this change, we made [the SQLite database][8] the default for local development to avoid additional setup for the Postgres database, even though we use this in our deployed version.
We have noticed that some contributors have struggled to contribute to one of our projects, [bridge-in-tech-backend][9], where its setup is complicated and includes many more steps than [mentorship-backend][7]. Since we noticed this in one of our open source programs, we have been exploring improving its structure.
For most of our projects, we also provide a live or bundled version of the apps so that contributors can test the project without setting it up. This helps us provide a way for contributors who are not interested or familiar with the development setup to try the most recent version of our apps and contribute by reporting any bugs found. We have the links to these apps deployed on our [Quality Assurance guide][10].
### Open source programs
We organize two main programs in our community: Open Source Hack (a one-month program) and Open Source Ambassadors (a six-month program).
#### **Open Source Hack (OSH)**
In this program, we create issues in multiple categories of contributions—Documentation, Coding, Outreach, Testing, and Design (similar to the [Google Code-in][11] contest). Participants can contribute and receive digital certificates for contributing at least once to each category. One issue may include multiple categories, and the pull requests don't need to be merged for their contributions to be valid.
We select a few projects for this program, then mentors brainstorm and create issues for participants. When the program starts, participants can claim issues and begin contributing. Mentors support and review their contributions.
This approach encourages diversity of contributions and welcomes anyone, regardless of their coding ability, to contribute in a friendly and fail-safe environment.
#### **Open Source Ambassadors**
In this program, we select ambassadors from the community that ideally will cover each category of contributions we aim to promote. We've run this program twice so far.
The program aims to have members grow in helping manage projects and initiatives by responding to questions from the community, assisting contributors to get involved, and advocating for their assigned category.
In the first program we ran, we accepted anyone who applied. We assessed where members' interests lay and provided a structure for people who wanted to contribute but were initially uncomfortable with taking that step.
This edition was very enlightening for us as a community. It required a lot of management from admins, as we had a mix of experienced and inexperienced open source contributors and community members. Some ambassadors were confident in stepping up and leading initiatives, while others needed more support. For our second program, we decided to scale down the initiative. We only accepted contributors who were already familiar with the community and could lead on initiatives and projects and help us train the less experienced.
The second program became a positive feedback loop. Ambassadors who started as beginners, contributing to the first program we ran, became comfortable leading after learning from their experience with the program.
This change of approach enabled admins to focus more on supporting the ambassadors' team, helping them propagate our mission and continue making the community beginner-friendly, and mentoring more people to contribute.
### Summary
These programs have helped us bring awareness to different ways to contribute and give back to open source. Through these, we've found volunteers helping by managing projects and hosting open sessions, which contributes to managing the community and providing mentorship to our contributors.
Even though we have had a good response from contributors and helped people make their first contributions, we still have a lot of room for improvement. We will continue to enhance our project's setup and contribution guidelines to improve contributors' experience. We'll also continue to focus on making sure we always have and promote available issues across the organization and in different categories to promote an inclusive environment so that anyone who wishes to can contribute.
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/8/beginner-open-source-community
作者:[Isabel Costa][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/isabelcmdcosta
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/wfh_work_home_laptop_work.png?itok=VFwToeMy (Working from home at a laptop)
[2]: https://github.com/anitab-org
[3]: https://anitab.org/
[4]: https://youtu.be/l8r50jCr-Yo
[5]: https://anitab-org.zulipchat.com/
[6]: https://summerofcode.withgoogle.com/
[7]: https://github.com/anitab-org/mentorship-backend#readme
[8]: https://opensource.com/article/21/2/sqlite3-cheat-sheet
[9]: https://github.com/anitab-org/bridge-in-tech-backend
[10]: https://github.com/anitab-org/documentation/blob/master/quality-assurance.md
[11]: https://codein.withgoogle.com/

View File

@ -1,115 +0,0 @@
[#]: subject: "My favorite LibreOffice productivity tips"
[#]: via: "https://opensource.com/article/21/9/libreoffice-tips"
[#]: author: "Don Watkins https://opensource.com/users/don-watkins"
[#]: collector: "lujun9972"
[#]: translator: " "
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "
My favorite LibreOffice productivity tips
======
Here are some LibreOffice keyboard shortcuts and formatting tips that
might save you valuable time.
![woman on laptop sitting at the window][1]
LibreOffice is my productivity application of choice. It's one of the most potent reasons for recommending Linux distributions to educators and students, whether PK-12 or higher education. Now that the school year is upon us, I thought I would recommend some LibreOffice shortcuts and tips that might save you valuable time.
### Work faster with keyboard shortcuts
I use a lot of keyboard shortcuts. Here are the most common shortcuts that apply to all LibreOffice applications.
* **Ctrl**+**N**—Create a new document
* **Ctrl**+**O**—Open a document
* **Ctrl**+**S**—Save a document
* **Ctrl**+**Shift**+**S**—Save as
* **Ctrl**+**P**—Print a document
Here are some shortcut keys just for LibreOffice Writer:
* **Home**—Takes you to the beginning of the current line.
* **End**—Takes you to the end of a line.
* **Ctrl**+**Home**—Takes the cursor to the start of the document
* **Ctrl**+**End**—Takes the cursor to the end of the document
* **Ctrl**+**A**—Select All
* **Ctrl**+**D**—Double Underline
* **Ctrl**+**E**—Centered
* **Ctrl**+**H**—Find and Replace
* **Ctrl**+**L**—Align Left
* **Ctrl**+**R**—Align Right
Function keys have value too:
* **F2**—Opens the formula bar
* **F3**—Completes auto-text
* **F5**—Opens the navigator
* **F7**—Opens spelling and grammar
* **F11**—Opens styles and formatting
* **Shift**+**F11**—Creates a new style
### Document formats
There are lots of document formats out there, and LibreOffice supports a good number of them. By default, LibreOffice saves documents to the Open Document Format, an open source standard that stores stylesheets and data in a ZIP container labeled as ODT for text documents, ODS for spreadsheets, and ODP for presentations. It's a flexible format and is maintained by the LibreOffice community as well as the Document Foundation.
The Open Document Format is on by default, so you don't need to do anything to get LibreOffice to use it.
Another open specification for documents is Microsoft's [Office Open XML format][2]. It's an ISO standard and is well supported by all the major office solutions.
If you work with folks using Microsoft Office (which itself is not open source, but it does use the open OOXML format), then they're definitely used to DOCX, XLSX, and, PPTX formats and probably can't open ODT, ODS, or ODP files. You can avoid a lot of confusion by setting LibreOffice to save to OOXML by default.
To set OOXML as your preferred format: 
1. Click on the **Tools** menu and select **Options** at the bottom of the menu.
2. In the **Options** window, click on the **Load/Save** category in the left panel and select **General**.
![LibreOffice settings panel][3]
(Don Watkins, [CC BY-SA 4.0][4])
3. Navigate to the **Default File Format and ODF Settings** section.
4. Choose _Text document_ for the **Document type** and choose _Open XML (Transitional) (*.docx)_ for the **Always save as **drop-down list.
5. Click **Apply** and then **OK**. 
6. Deselect the **Warn when not saving in ODF or default format** to avoid confirmation dialogue boxes when saving.
![LibreOffice save formats][5]
(Don Watkins, [CC BY-SA 4.0][4])
Repeat the same process XLSX and PPTX documents by following the same logic. 
### Free your office
The LibreOffice project is managed by a thriving community of users and developers, in tandem with the Document Foundation. This includes an Engineering Steering Committee, a Board of Directors, independent developers and designers and translators, and more. These teams are always open to your contribution, so if you're eager to participate in a great open source project, don't hesitate to [get involved][6].
--------------------------------------------------------------------------------
via: https://opensource.com/article/21/9/libreoffice-tips
作者:[Don Watkins][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/don-watkins
[b]: https://github.com/lujun9972
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/lenovo-thinkpad-laptop-window-focus.png?itok=g0xPm2kD (young woman working on a laptop)
[2]: https://www.iso.org/standard/71691.html
[3]: https://opensource.com/sites/default/files/uploads/libreoffice-panel.jpg (LibreOffice settings panel)
[4]: https://creativecommons.org/licenses/by-sa/4.0/
[5]: https://opensource.com/sites/default/files/uploads/libreoffice-save-format.jpg (LibreOffice save formats)
[6]: https://www.libreoffice.org/community/get-involved/

View File

@ -2,7 +2,7 @@
[#]: via: "https://opensource.com/article/21/10/open-source-tools"
[#]: author: "Don Watkins https://opensource.com/users/don-watkins"
[#]: collector: "lujun9972"
[#]: translator: " "
[#]: translator: "XiaotingHuang22"
[#]: reviewer: " "
[#]: publisher: " "
[#]: url: " "

Some files were not shown because too many files have changed in this diff Show More