mirror of
https://github.com/LCTT/TranslateProject.git
synced 2025-01-25 23:11:02 +08:00
Merge remote-tracking branch 'LCTT/master'
This commit is contained in:
commit
757480a131
@ -1,177 +0,0 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Ubuntu Budgie 20.04 Review: Smooth, Polished & Plenty of Changes)
|
||||
[#]: via: (https://itsfoss.com/ubuntu-budgie-20-04-review/)
|
||||
[#]: author: (John Paul https://itsfoss.com/author/john/)
|
||||
|
||||
Ubuntu Budgie 20.04 Review: Smooth, Polished & Plenty of Changes
|
||||
======
|
||||
|
||||
As we promised our readers, we’ll be reviewing all major flavors of [Ubuntu 20.04 LTS release][1]. In that continuation, here’s our take on the Ubuntu Budgie.
|
||||
|
||||
![Ubuntu Budgie Desktop][2]
|
||||
|
||||
[Ubuntu Budgie][3], as the name implies, is an [official flavor of Ubuntu][4] using the [Budgie desktop environment][5]. This flavor is a newer member of the Ubuntu family. Ubuntu Budgie’s first release was 16.04 and it was accepted as an official flavor with the 17.04 release.
|
||||
|
||||
Their [goal][6] is to “combine the simplicity and elegance of the Budgie interface to produce a traditional desktop orientated distro with a modern paradigm”.
|
||||
|
||||
### Ubuntu 20.04 Review: What has changed and what has not!
|
||||
|
||||
There have been a surprising number of updates and improvements to [Ubuntu Budgie since the 18.04 LTS release][7].
|
||||
|
||||
* New stylish menu apple
|
||||
* Budgie-based network manager applet as default
|
||||
* New Window Shuffler allows you to tile applications from the keyboard
|
||||
* New tool to quickly switch desktop layout
|
||||
* 4k resolution support
|
||||
* GNOME Firmware and Drawing are new default applications
|
||||
* Backport packages have now been rebuilt for 20.04
|
||||
* Firefox is the default browser.
|
||||
* Catfish file and text search is now the default
|
||||
* budgie-nemo integration
|
||||
* System Tray applet removed due to bugs
|
||||
* Event alerts sounds are disabled by default
|
||||
* Fix for keyboard shortcuts mysteriously going missing
|
||||
* Better lock screen styling
|
||||
* Files (Nautilus) has been replaced with Files (Nemo) due to community demand
|
||||
* Plank dock has now been switched to the bottom of the screen, is transparent and has the bounce animations by default
|
||||
* The Quick Notes and Hot Corners applets have been ported from Python to Vala to improve speed
|
||||
* Celluloid replaces MPV
|
||||
* GNOME dependencies have been updated
|
||||
|
||||
|
||||
|
||||
![][8]
|
||||
|
||||
Ubuntu Budgie now ships with the most recent release of the Budgie desktop environment (10.5.1). Improvements include:
|
||||
|
||||
* New Raven section in Budgie Desktop Settings
|
||||
* Raven Notification grouping and the ability to turn off notifications
|
||||
* Icon Task List has been revamped
|
||||
* Ability to set number of virtual desktops
|
||||
|
||||
|
||||
|
||||
Ubuntu Budgie comes with a whole slew of Budgie applets and min-apps. They can be installed through Ubuntu Budgie Welcome.
|
||||
|
||||
![Ubuntu Budgie Welcome][9]
|
||||
|
||||
* WeatherShow – shows the forecast for the next five days and updates every 3 hours
|
||||
* Wallstreet – a wallpaper utility that allows you to cycle through a folder of images
|
||||
* Visual-space – a compact workspace switcher
|
||||
* Dropby – this applet allows you to quickly manage USB thumb drives from the panel
|
||||
* Kangaroo – quickly browser folders from the panel
|
||||
* Trash applet – manage your trash can
|
||||
* Fuzzyclock – shows time in a fuzzy way
|
||||
* Workspace stopwatch – allows you to keep track of the time spent in each workspace
|
||||
|
||||
|
||||
|
||||
For a complete list of changes and updates, visit the [changelog][10].
|
||||
|
||||
#### System Requirements
|
||||
|
||||
Ubuntu Budgie 20.04 has updated the [system requirements][11]:
|
||||
|
||||
* 4GB or more of RAM
|
||||
* 64-bit capable Intel and AMD processors
|
||||
* UEFI PCs booting in CSM mode
|
||||
* Modern Intel-based Apple Macs
|
||||
|
||||
|
||||
|
||||
As you can see, Budgie is not really a lightweight option here.
|
||||
|
||||
#### Included Apps
|
||||
|
||||
![][12]
|
||||
|
||||
The following useful applications are included in Ubuntu Budgie by default:
|
||||
|
||||
* AisleRiot Solitaire
|
||||
* Geary
|
||||
* Catfish search tool
|
||||
* Cheese webcam tool
|
||||
* GNOME Drawing
|
||||
* GNOME 2048
|
||||
* GNOME Mahjongg
|
||||
* GNOME Mines
|
||||
* GNOME Sudoku
|
||||
|
||||
|
||||
* Gthumb
|
||||
* LibreOffice
|
||||
* Maps
|
||||
* Rhythmbox
|
||||
* Tilix
|
||||
* Ubuntu Budgie Welcome
|
||||
* Evince document viewer
|
||||
* Plank
|
||||
* Celluloid
|
||||
|
||||
|
||||
|
||||
![Ubuntu Budgie Ram Usage][13]
|
||||
|
||||
### Installation
|
||||
|
||||
Initially, I was unable to get Ubuntu Budgie to do into the live environment so that I could install it. It turned out that Ubuntu Budgie was trying to boot via EFI. I contacted the [Ubuntu Budgie forum][14] and was able to get a solution.
|
||||
|
||||
Once the purple splash screen I had to hit ESC and select legacy. After that, it booted as normal and installed without issue. I have only run into this issue with Ubuntu Budgie. I downloaded and tried the Ubuntu MATE 20.04 ISO, but didn’t have a similar issue.
|
||||
|
||||
### Experience with Ubuntu Budgie 20.04
|
||||
|
||||
![][15]
|
||||
|
||||
Other than the minor installation issue, my time with Ubuntu Budgie was very pleasant. The Budgie desktop has come a long way since [Ikey][16] first created it and it has become a very mature option. The goal of Ubuntu Budgie is to “produce a traditional desktop orientated distro”. It does that in spades. All the changes that they have made continually add more polish to their product.
|
||||
|
||||
Overall, Ubuntu Budgie is a very nice looking distro. From the default theme to wallpaper options, you can tell that a lot of effort was put into making the visual experience very appealing.
|
||||
|
||||
One thing to keep in mind is that Ubuntu Budgie is not intended for low spec systems. I’m running it on my Dell Latitude D630. Without any applications open, it used about 700 MB of RAM.
|
||||
|
||||
One part of Ubuntu Budgie that I enjoyed more than I should have, was the inclusion of the [Tilix terminal emulator][17]. Tilix allows you to add terminal windows to the right or below. It has a whole host of features and just loved using it. I’m planning to install on my other Linux systems.
|
||||
|
||||
### Final Thoughts on Ubuntu Budgie 20.04
|
||||
|
||||
Ubuntu Budgie is a welcome addition to the litany of official flavors. Budgie feels very smooth and polished. It gets out of your way and lets you get work done.
|
||||
|
||||
If you are tired of your current desktop environment and want to take a look at something new, check it out. If you’re happy with your current setup, check Ubuntu Budgie’s live DVD. You just might like it.
|
||||
|
||||
![Ubuntu Budgie About][18]
|
||||
|
||||
Have you already tried Ubuntu 20.04 Budgie? How’s your experience with it? If not, which Ubuntu 20.04 flavor are you using right now?
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://itsfoss.com/ubuntu-budgie-20-04-review/
|
||||
|
||||
作者:[John Paul][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://itsfoss.com/author/john/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://itsfoss.com/download-ubuntu-20-04/
|
||||
[2]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-busgie-desktop.png?resize=800%2C500&ssl=1
|
||||
[3]: https://ubuntubudgie.org/
|
||||
[4]: https://itsfoss.com/which-ubuntu-install/
|
||||
[5]: https://en.wikipedia.org/wiki/Budgie_(desktop_environment
|
||||
[6]: https://ubuntubudgie.org/about-us/
|
||||
[7]: https://itsfoss.com/ubuntu-budgie-18-review/
|
||||
[8]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-desktop-settings.jpeg?ssl=1
|
||||
[9]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-welcome.png?resize=800%2C472&ssl=1
|
||||
[10]: https://ubuntubudgie.org/2020/04/21/ubuntu-budgie-20-04lts-release-notes-for-18-04-upgraders/
|
||||
[11]: https://ubuntubudgie.org/downloads/
|
||||
[12]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-applications.jpeg?ssl=1
|
||||
[13]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-ram-usage.png?resize=800%2C600&ssl=1
|
||||
[14]: https://discourse.ubuntubudgie.org/t/cant-get-ub-to-boot/3397
|
||||
[15]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-20-04.jpg?ssl=1
|
||||
[16]: https://itsfoss.com/ikey-doherty-serpent-interview/
|
||||
[17]: https://gnunn1.github.io/tilix-web/
|
||||
[18]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-about.png?resize=800%2C648&ssl=1
|
@ -1,114 +0,0 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (geekpi)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How to dump the GOSSAFUNC graph for a method)
|
||||
[#]: via: (https://dave.cheney.net/2020/06/19/how-to-dump-the-gossafunc-graph-for-a-method)
|
||||
[#]: author: (Dave Cheney https://dave.cheney.net/author/davecheney)
|
||||
|
||||
How to dump the GOSSAFUNC graph for a method
|
||||
======
|
||||
|
||||
The Go compiler’s SSA backend contains a facility to produce HTML debugging output of the compilation phases. This post covers how to print the SSA output for function _and_ methods.
|
||||
|
||||
Let’s start with a sample program which contains a function, a value method, and a pointer method:
|
||||
|
||||
```
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
)
|
||||
|
||||
type Numbers struct {
|
||||
vals []int
|
||||
}
|
||||
|
||||
func (n *Numbers) Add(v int) {
|
||||
n.vals = append(n.vals, v)
|
||||
}
|
||||
|
||||
func (n Numbers) Average() float64 {
|
||||
sum := 0.0
|
||||
for _, num := range n.vals {
|
||||
sum += float64(num)
|
||||
}
|
||||
return sum / float64(len(n.vals))
|
||||
}
|
||||
|
||||
|
||||
func main() {
|
||||
var numbers Numbers
|
||||
numbers.Add(200)
|
||||
numbers.Add(43)
|
||||
numbers.Add(-6)
|
||||
fmt.Println(numbers.Average())
|
||||
}
|
||||
```
|
||||
|
||||
Control of the SSA debugging output is via the `GOSSAFUNC` environment variable. This variable takes the name of the function to dump. This is _not_ the functions fully qualified name. For `func main` above the name of the function is `main` _not_ `main.main`.
|
||||
|
||||
```
|
||||
% env GOSSAFUNC=main go build
|
||||
runtime
|
||||
dumped SSA to ../../go/src/runtime/ssa.html
|
||||
t
|
||||
dumped SSA to ./ssa.html
|
||||
```
|
||||
|
||||
In this example `GOSSAFUNC=main` matched both `main.main` and a function called `runtime.main`.[1][1] This is a little unfortunate, but in practice probably not a big deal as, if you’re performance tuning your code, it won’t be in a giant spaghetti blob in `func main`.
|
||||
|
||||
What is more likely is your code will be in a _method_, so you’ve probably landed on this post looking for the correct incantation to dump the SSA output for a method.
|
||||
|
||||
To print the SSA debug for the pointer method `func (n *Numbers) Add`, the equivalent function name is`(*Numbers).Add`:[2][2]
|
||||
|
||||
```
|
||||
% env "GOSSAFUNC=(*Numbers).Add" go build
|
||||
t
|
||||
dumped SSA to ./ssa.html
|
||||
```
|
||||
|
||||
To print the SSA debug for a value method `func (n Numbers) Average`, the equivalent function name is `(*Numbers).Average` _even though this is a value method_:
|
||||
|
||||
```
|
||||
% env "GOSSAFUNC=(*Numbers).Average" go build
|
||||
t
|
||||
dumped SSA to ./ssa.html
|
||||
```
|
||||
|
||||
1. If you didn’t build Go from source then the path to the `runtime` package may be read only and you might receive an error. Please don’t use the `sudo` hammer to fix this.[][3]
|
||||
2. Please pay attention to the shell quoting.[][4]
|
||||
|
||||
|
||||
|
||||
### Related posts:
|
||||
|
||||
1. [Accidental method value][5]
|
||||
2. [Never edit a method, always rewrite it][6]
|
||||
3. [How to find out which Go version built your binary][7]
|
||||
4. [Declaration scopes in Go][8]
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://dave.cheney.net/2020/06/19/how-to-dump-the-gossafunc-graph-for-a-method
|
||||
|
||||
作者:[Dave Cheney][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://dave.cheney.net/author/davecheney
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: tmp.kLSHpQXzhr#easy-footnote-bottom-1-4188 (If you didn’t build Go from source then the path to the <code>runtime</code> package may be read only and you might receive an error. Please don’t use the <code>sudo</code> hammer to fix this.)
|
||||
[2]: tmp.kLSHpQXzhr#easy-footnote-bottom-2-4188 (Please pay attention to the shell quoting.)
|
||||
[3]: tmp.kLSHpQXzhr#easy-footnote-1-4188
|
||||
[4]: tmp.kLSHpQXzhr#easy-footnote-2-4188
|
||||
[5]: https://dave.cheney.net/2014/05/19/accidental-method-value (Accidental method value)
|
||||
[6]: https://dave.cheney.net/2017/11/30/never-edit-a-method-always-rewrite-it (Never edit a method, always rewrite it)
|
||||
[7]: https://dave.cheney.net/2017/06/20/how-to-find-out-which-go-version-built-your-binary (How to find out which Go version built your binary)
|
||||
[8]: https://dave.cheney.net/2016/12/15/declaration-scopes-in-go (Declaration scopes in Go)
|
@ -0,0 +1,281 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Make the switch from Mac to Linux easier with Homebrew)
|
||||
[#]: via: (https://opensource.com/article/20/6/homebrew-linux)
|
||||
[#]: author: (Matthew Broberg https://opensource.com/users/mbbroberg)
|
||||
|
||||
Make the switch from Mac to Linux easier with Homebrew
|
||||
======
|
||||
Whether you want to ease your migration from Mac to Linux or just don't
|
||||
like the standard Linux package managers, give Homebrew a try.
|
||||
![Digital images of a computer desktop][1]
|
||||
|
||||
The [Homebrew][2] project began its life as an unofficial Linux-style package manager for the Mac. Its users quickly fell in love with its friendly interface and helpful prompts, and—in what may seem like a strange twist of fate—it got ported to Linux.
|
||||
|
||||
At first, there were two separate projects for macOS and Linux (Homebrew and Linuxbrew), but now Homebrew's core manages both operating systems. Because I've been on a journey to [migrate from Mac to Linux][3], I have been looking at how my favorite open source applications for macOS perform on Linux, and I've been happy to find that Homebrew's support for Linux truly shines.
|
||||
|
||||
### Why Homebrew on Linux?
|
||||
|
||||
A reasonable first response to Homebrew from long-time Linux users is: "Why not just use…" where the next word is a package manager for their preferred version of Linux. Debian-based systems already have `apt`, Fedora-systems have `dnf` and `yum`, and projects like Flatpak and AppImage work to span the gap by running smoothly on both. I have spent a decent amount of time using all these technologies, and I have to say each one is powerful in its own right.
|
||||
|
||||
So why do I [stick with Homebrew][4]? First off, it's incredibly familiar to me. I'm already learning a lot as I transition to more open source alternatives for my past proprietary tools, and keeping something familiar—like Homebrew—helps me focus on learning one thing at a time instead of being overwhelmed by all the differences between operating systems.
|
||||
|
||||
Also, I have yet to see a package manager that is as kind to the user as Homebrew. Commands are well organized, as the default Help output shows:
|
||||
|
||||
|
||||
```
|
||||
$ brew -h
|
||||
Example usage:
|
||||
brew search [TEXT|/REGEX/]
|
||||
brew info [FORMULA...]
|
||||
brew install FORMULA...
|
||||
brew update
|
||||
brew upgrade [FORMULA...]
|
||||
brew uninstall FORMULA...
|
||||
brew list [FORMULA...]
|
||||
|
||||
Troubleshooting:
|
||||
brew config
|
||||
brew doctor
|
||||
brew install --verbose --debug FORMULA
|
||||
|
||||
Contributing:
|
||||
brew create [URL [--no-fetch]]
|
||||
brew edit [FORMULA...]
|
||||
|
||||
Further help:
|
||||
brew commands
|
||||
brew help [COMMAND]
|
||||
man brew
|
||||
<https://docs.brew.sh>
|
||||
```
|
||||
|
||||
This short output might be mistaken as a limitation, but a quick look inside any of the subcommands reveals a wealth of functionality. The list above is just 23 lines long, but the `install` subcommand has a whopping 79 lines of information available for the advanced user:
|
||||
|
||||
|
||||
```
|
||||
$ brew --help | wc -l
|
||||
23
|
||||
$ brew install --help | wc -l
|
||||
79
|
||||
```
|
||||
|
||||
It has options for ignoring or installing dependencies, choosing to build from source and with what compiler, and using exact upstream Git commits versus the official "bottled" version of the application. Suffice it to say, Homebrew is for experts and novices alike.
|
||||
|
||||
### Get started with Homebrew on Linux
|
||||
|
||||
If you want to give Homebrew a try, there is a great one-liner script to install it on Mac or Linux:
|
||||
|
||||
|
||||
```
|
||||
`$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"`
|
||||
```
|
||||
|
||||
This command executes the Homebrew installer script immediately. If you are more cautious, you can `curl` the file, then run it manually after a review:
|
||||
|
||||
|
||||
```
|
||||
$ curl -fsSL <https://raw.githubusercontent.com/Homebrew/install/master/install.sh> \--output homebrew_installer.sh
|
||||
$ more homebrew_installer.sh # review the script until you feel comfortable
|
||||
$ bash homebrew_installer.sh
|
||||
```
|
||||
|
||||
The Linux instructions include configurations for dotfiles, particularly `~/.profile` on Debian systems and `~/.bash_profile` on Fedora:
|
||||
|
||||
|
||||
```
|
||||
$ test -d /home/linuxbrew/.linuxbrew && eval $(/home/linuxbrew/.linuxbrew/bin/brew shellenv)
|
||||
$ test -r ~/.bash_profile && echo "eval \$($(brew --prefix)/bin/brew shellenv)" >>~/.bash_profile
|
||||
$ echo "eval \$($(brew --prefix)/bin/brew shellenv)" >>~/.profile
|
||||
```
|
||||
|
||||
To confirm the installation, the Homebrew team provides an empty `hello` formula for testing:
|
||||
|
||||
|
||||
```
|
||||
$ brew install hello
|
||||
==> Downloading <https://linuxbrew.bintray.com/bottles/hello-2.10.x86\_64\_linux.bottle.tar.gz>
|
||||
######################################################################## 100.0%
|
||||
==> Pouring hello-2.10.x86_64_linux.bottle.tar.gz
|
||||
🍺 /home/linuxbrew/.linuxbrew/Cellar/hello/2.10: 52 files, 595.6KB
|
||||
```
|
||||
|
||||
It looks like my installation is working without any issues, so I'll explore a little more.
|
||||
|
||||
### Brew for command-line utilities
|
||||
|
||||
Homebrew boasts of being an application that "installs the stuff you need that [Linux] didn't" by default.
|
||||
|
||||
You use the `brew` command to install any of the command-line utilities packaged up in Homebrew. These package definitions are called "formulae," and they are compiled and shared through "bottles." There is a host of other beer-oriented terminology in the Homebrew universe, but the package manager's main takeaway is to make software easily accessible.
|
||||
|
||||
What kind of software? Think about the things that come in handy for nerds like me (and, since you're reading this, probably you, too). For example, the handy `tree` command that shows directory structures or `pyenv`, which I use to [manage multiple versions of Python on a Mac][5].
|
||||
|
||||
You can see all formulae available using the `search` command, and adding the `wc` command shows how many are available:
|
||||
|
||||
|
||||
```
|
||||
# -l counts the number of lines
|
||||
$ brew search | wc -l
|
||||
5087
|
||||
```
|
||||
|
||||
There are over 5,000 formulae to date, which is an incredible amount of software. The caveat is that not every formula will run on Linux. There is a section in the output of `brew search --help` that shows flags to filter software by the operating system it runs on. It launches each operating system's repository list to a browser. I'm running Fedora, so I'll give it a try with:
|
||||
|
||||
|
||||
```
|
||||
`$ brew search --fedora tree`
|
||||
```
|
||||
|
||||
The browser loads `https://apps.fedoraproject.org/packages/s/tree`, which shows the options available for Fedora. There are other ways to browse, as well. Formulae are codified and centralized into the core repositories that are split out by operating system (Mac in [Homebrew Core][6] and [Linux Core][7] for Linux bits). They are also available through the Homebrew API and [listed on the website][8].
|
||||
|
||||
Even with all these options, I still find most of my new tools through recommendations from other users. Here are some of my favorites, if you're looking for inspiration:
|
||||
|
||||
* `pyenv`, `rbenv`, and `nodenv` to manage Python, Ruby, and Node.js versions (respectively)
|
||||
* `imagemagick` for scriptable image edits
|
||||
* `pandoc` for scriptable document conversions (I often switch from .docx to .md or .html)
|
||||
* `hub` for a [better Git experience][9] for GitHub users
|
||||
* `tldr` for examples of how to use a command-line utility
|
||||
|
||||
|
||||
|
||||
To explore Homebrew, take a look at [tldr pages][10], which is a user-friendly alternative to scrolling through an application's man pages. Confirm it's available by running `search`:
|
||||
|
||||
|
||||
```
|
||||
$ brew search tldr
|
||||
==> Formulae
|
||||
tldr ✔
|
||||
```
|
||||
|
||||
Success! The checkmark lets you know it is available. Now you can install it:
|
||||
|
||||
|
||||
```
|
||||
$ brew install tldr
|
||||
==> Downloading <https://linuxbrew.bintray.com/bottles/tldr-1.3.0\_2.x86\_64\_linux.bottle.1.tar.gz>
|
||||
######################################################################## 100.0%
|
||||
==> Pouring tldr-1.3.0_2.x86_64_linux.bottle.1.tar.gz
|
||||
🍺 /home/linuxbrew/.linuxbrew/Cellar/tldr/1.3.0_2: 6 files, 63.2KB
|
||||
```
|
||||
|
||||
Homebrew serves up prebuilt binaries, so you don't have to build from source code on your local machine. That saves a lot of time and CPU fan noise. Another thing I appreciate about Homebrew is that you can appreciate this feature without understanding exactly what it means. If you prefer to build it yourself, use the `-s` or `--build-from-source` flag with `brew install` to compile the formula from source (even if a bottle exists).
|
||||
|
||||
Similarly, the complexity under the hood can be interesting. Running `info` on `tldr` shows how dependency management happens, where the source code of the formula sits on disk, and even the public analytics are available:
|
||||
|
||||
|
||||
```
|
||||
$ brew info tldr
|
||||
tldr: stable 1.3.0 (bottled), HEAD
|
||||
Simplified and community-driven man pages
|
||||
<https://tldr.sh/>
|
||||
Conflicts with:
|
||||
tealdeer (because both install `tldr` binaries)
|
||||
/home/linuxbrew/.linuxbrew/Cellar/tldr/1.3.0_2 (6 files, 63.2KB) *
|
||||
Poured from bottle on 2020-06-08 at 15:56:15
|
||||
From: <https://github.com/Homebrew/linuxbrew-core/blob/master/Formula/tldr.rb>
|
||||
==> Dependencies
|
||||
Build: pkg-config ✔
|
||||
Required: libzip ✔, curl ✔
|
||||
==> Options
|
||||
\--HEAD
|
||||
Install HEAD version
|
||||
==> Analytics
|
||||
install: 197 (30 days), 647 (90 days), 1,546 (365 days)
|
||||
install-on-request: 197 (30 days), 646 (90 days), 1,546 (365 days)
|
||||
build-error: 0 (30 days)
|
||||
```
|
||||
|
||||
### One limitation from Mac to Linux
|
||||
|
||||
On macOS, the Homebrew `cask` subcommand offers users a way to install and manage entire applications using the same great command-line utility. Unfortunately, `cask` does not yet work on any Linux distributions. I found this out while trying to install an open source tool:
|
||||
|
||||
|
||||
```
|
||||
$ brew cask install tusk
|
||||
Error: Installing casks is supported only on macOS
|
||||
```
|
||||
|
||||
I asked about it [on the forum][11] and got some quick feedback from other users. In short, the options are to:
|
||||
|
||||
* Fork the project, build the feature, and show others that it's worthwhile
|
||||
* Write a formula for the application and build from source
|
||||
* Create a third-party repository for the application
|
||||
|
||||
|
||||
|
||||
The last one is the most interesting to me. Homebrew manages third-party repositories by [creating and maintaining "taps"][12] (another beer-influenced term). Taps are worth exploring as you get more familiar with the system and want to add to the ecosystem.
|
||||
|
||||
### Backing up Homebrew installs
|
||||
|
||||
One of my favorite Homebrew features is how you can back up your installation just like any other [dotfile in version control][13]. For this process, Homebrew offers a `bundle` subcommand that holds a `dump` subcommand that generates a Brewfile. This file is a reusable list of all your currently installed tools. To generate a Brewfile from your installation, go into whichever folder you want to use and run:
|
||||
|
||||
|
||||
```
|
||||
$ cd ~/Development/dotfiles # This is my dotfile folder
|
||||
$ brew bundle dump
|
||||
$ ls Brewfile
|
||||
Brewfile
|
||||
```
|
||||
|
||||
When I change machines and want to set up the same applications on it, I go to the folder with the Brewfile and reinstall them with:
|
||||
|
||||
|
||||
```
|
||||
$ ls Brewfile
|
||||
Brewfile
|
||||
$ brew bundle
|
||||
```
|
||||
|
||||
It will install all the listed formulae on my new machine.
|
||||
|
||||
#### Brewfile management across Mac and Linux
|
||||
|
||||
The Brewfile is a great way to backup your existing installation, but what if something on Mac doesn't run on Linux or vice versa? What I have found is that Homebrew will gracefully ignore the lines that don't work on a given operating system, whether Mac or Linux. As it comes across incompatible requests (like asking brew to install casks on Linux), it skips them and continues on its way:
|
||||
|
||||
|
||||
```
|
||||
$ brew bundle --file=Brewfile.example
|
||||
|
||||
Skipping cask licecap (on Linux)
|
||||
Skipping cask macdown (on Linux)
|
||||
Installing fish
|
||||
Homebrew Bundle complete! 1 Brewfile dependency now installed.
|
||||
```
|
||||
|
||||
To keep my configuration as simple as possible, I use the same Brewfile across both operating systems and haven't run into an issue since it installs the OS-specific version each time I run it.
|
||||
|
||||
### Homebrew for package management
|
||||
|
||||
Homebrew has been my go-to manager for command-line utilities, and its familiarity makes my Linux experience that much more enjoyable. Homebrew keeps me organized and up to date, and I continue to appreciate its balance between ease of use and depth of functionality. I prefer to keep package management details to the minimal amount of information a user needs to know, and most people will benefit from that. If you're already comfortable with Linux package managers, Homebrew may come off as simple, but looking a little deeper reveals its advanced options that go far beyond what's in this article.
|
||||
|
||||
There are a lot of package management options for Linux users. If you are coming from the world of macOS, Homebrew will feel like home.
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/20/6/homebrew-linux
|
||||
|
||||
作者:[Matthew Broberg][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/mbbroberg
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/computer_desk_home_laptop_browser.png?itok=Y3UVpY0l (Digital images of a computer desktop)
|
||||
[2]: https://brew.sh/
|
||||
[3]: https://opensource.com/article/19/10/why-switch-mac-linux
|
||||
[4]: https://opensource.com/article/20/6/homebrew-mac
|
||||
[5]: https://opensource.com/article/20/4/pyenv
|
||||
[6]: https://github.com/Homebrew/homebrew-core
|
||||
[7]: https://github.com/Homebrew/linuxbrew-core
|
||||
[8]: https://formulae.brew.sh/formula/
|
||||
[9]: https://opensource.com/article/20/3/github-hub
|
||||
[10]: https://github.com/tldr-pages/tldr
|
||||
[11]: https://discourse.brew.sh/t/add-linux-support-to-existing-cask/5766
|
||||
[12]: https://docs.brew.sh/How-to-Create-and-Maintain-a-Tap
|
||||
[13]: https://opensource.com/article/19/3/move-your-dotfiles-version-control
|
@ -0,0 +1,106 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Take control of your data with associative arrays in Bash)
|
||||
[#]: via: (https://opensource.com/article/20/6/associative-arrays-bash)
|
||||
[#]: author: (Seth Kenlon https://opensource.com/users/seth)
|
||||
|
||||
Take control of your data with associative arrays in Bash
|
||||
======
|
||||
Associative arrays let you create lists of key and value pairs, instead
|
||||
of just numbered values.
|
||||
![bash logo on green background][1]
|
||||
|
||||
If you've ever written code, whether it's a shell script, a Python script, C++, or even Scratch, then you know that variables are vital. Computers and coders use variables as waystations, where they surreptitiously pass information back and forth. For instance, if you need to process a user's name in a shell script, you might set up a variable, put the username into the variable, and then instruct the computer to do something to the variable (check it against a list of authorized users, for example). Variables are important because they enable code to by dynamic: they're placeholders for information that's expected to change every time you run the code.
|
||||
|
||||
But variables, because they're so common, can also become rather unwieldy. Often times, you gather so many variables in a code project that it's next to impossible to keep track of them all. You can use clever conventions, such as prefixing all related variables with a common string (user_name, user_pass, user_time, and so on), or you can create a master list of them somewhere for easy reference, but the overhead of keeping track of it all can becoming taxing.
|
||||
|
||||
One answer to this problem has, traditionally, been arrays. These have worked well in most coding languages, including shell scripting languages like Bash.
|
||||
|
||||
Most shells offer the ability to create, manipulate, and query indexed arrays. In plain English, an indexed array is a list of things prefixed with a number. This list of things, along with their assigned number, is conveniently wrapped up in a single variable, which makes it easy to "carry" around in your code.
|
||||
|
||||
[Bash][2], however, includes the ability to create associative arrays, and it treats these arrays the same as any other array. An associative array lets you create lists of key and value pairs, instead of just numbered values.
|
||||
|
||||
You can assign values to arbitrary keys:
|
||||
|
||||
|
||||
```
|
||||
$ declare -A userdata
|
||||
$ userdata[name]=seth
|
||||
$ userdata[pass]=8eab07eb620533b083f241ec4e6b9724
|
||||
$ userdata[login]=`date --utc +%s`
|
||||
```
|
||||
|
||||
Query any key:
|
||||
|
||||
|
||||
```
|
||||
$ echo "${userdata[name]}"
|
||||
seth
|
||||
$ echo "${userdata[login]}"
|
||||
1583362192
|
||||
```
|
||||
|
||||
Most of the usual array operations you'd expect from an array are available. For instance, you can list all values:
|
||||
|
||||
|
||||
```
|
||||
$ echo "${userdata[*]}"
|
||||
8eab07eb620533b083f241ec4e6b9724 seth 1583362192
|
||||
```
|
||||
|
||||
You can view the entire array:
|
||||
|
||||
|
||||
```
|
||||
$ typeset -A
|
||||
declare -A BASH_ALIASES='()'
|
||||
declare -A BASH_CMDS='()'
|
||||
declare -A userdata='([pass]="8eab07eb620533b083f241ec4e6b9724"
|
||||
[name]="seth"
|
||||
[login]="1583362192" )'
|
||||
```
|
||||
|
||||
You can also remove items from your array using the **unset** command:
|
||||
|
||||
|
||||
```
|
||||
$ unset userdata[pass]
|
||||
$ typeset -A
|
||||
[...]
|
||||
declare -A userdata='([name]="seth"
|
||||
[login]="1583362192" )'
|
||||
```
|
||||
|
||||
Finally, you can dismiss the entire array.
|
||||
|
||||
|
||||
```
|
||||
`$ unset "userdata[*]"`
|
||||
```
|
||||
|
||||
### Arrays for data
|
||||
|
||||
Arrays are useful tools for storing related data together. You can use a plain old variable in most cases, but sometimes it's more logical to store attributes of a singular data "object" in an array, to keep the data consolidated and indexed. For example, if you're processing login names and times taken from **utmp**, it would be more useful for you to _associate_ the login time with the user to whom the time referred, rather than just storing the two data objects as separate variables with no obvious connection.
|
||||
|
||||
Furthermore, unlike variables, an entry in an array doesn't need to exist before you store data in it. You don't have to know exactly how much data is going to get stored before you store it. That can be a big advantage if you're processing data that you can't control or predict: if you don't know how many users to expect in **utmp** one day to the next, it's hard to build a script to contain all the entries. With an array, though, all you have to do is declare one array and read data into it, creating a new key and value pair until you run out of data to ingest.
|
||||
|
||||
Arrays are powerful, and they're common in programming languages beyond Bash. Start using them now!
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://opensource.com/article/20/6/associative-arrays-bash
|
||||
|
||||
作者:[Seth Kenlon][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://opensource.com/users/seth
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://opensource.com/sites/default/files/styles/image-full-size/public/lead-images/bash_command_line.png?itok=k4z94W2U (bash logo on green background)
|
||||
[2]: https://opensource.com/resources/what-bash
|
@ -0,0 +1,113 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: ( )
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How to Disable Dock on Ubuntu 20.04 and Gain More Screen Space)
|
||||
[#]: via: (https://itsfoss.com/disable-ubuntu-dock/)
|
||||
[#]: author: (Abhishek Prakash https://itsfoss.com/author/abhishek/)
|
||||
|
||||
How to Disable Dock on Ubuntu 20.04 and Gain More Screen Space
|
||||
======
|
||||
|
||||
The launcher on the left side has become the identity of [Ubuntu][1] desktop. It was introduced with [Unity desktop][2] and even [when Ubuntu switched to GNOME][3], it forked Dash to Panel to create a similar dock on [GNOME][4] as well.
|
||||
|
||||
Personally, I find it handy for quickly accessing the frequently used applications. But not everyone wants it to take some extra space on the screen.
|
||||
|
||||
Starting with [Ubuntu 20.04][5], you can easily disable this dock. Let me show you how to do that graphically and via command line in this quick tutorial.
|
||||
|
||||
![][6]
|
||||
|
||||
### Disable Ubuntu dock with Extensions app
|
||||
|
||||
One of the [main features of Ubuntu 20.04][7] was the introduction of Extensions to manage GNOME extensions on your system. Just look for it in the GNOME menu (press Windows key and start typing):
|
||||
|
||||
![Look for Extensions app in the menu][8]
|
||||
|
||||
Don’t have Extensions app?
|
||||
|
||||
If you don’t have it installed already, you should enable GNOME Shell Extensions. The Extensions GUI app is part of this package.
|
||||
|
||||
```
|
||||
sudo apt install gnome-shell-extensions
|
||||
```
|
||||
|
||||
This is only valid for [GNOME 3.36][9] or higher version available in Ubuntu 20.04 and higher versions.
|
||||
|
||||
Start the extensions app and you should see Ubuntu Dock under the Built-in extensions section. You just have to toggle the button off to disable the dock.
|
||||
|
||||
![Disable Ubuntu Dock][10]
|
||||
|
||||
The change is immediate and you’ll see that dock disappears immediately.
|
||||
|
||||
You can bring it back the same way. Just toggle it on and it will appear immediately.
|
||||
|
||||
So easy to hide the dock in Ubuntu 20.04, isn’t it?
|
||||
|
||||
### Alternative Method: Disable Ubuntu dock via command line
|
||||
|
||||
If you are a terminal enthusiast and prefer to do things in the terminal, I have good news for you. You can disable the Ubuntu dock from command line.
|
||||
|
||||
Open a terminal using Ctrl+Alt+T. You probably already know that [keyboard shortcut in Ubuntu][11].
|
||||
|
||||
In the terminal, use the following command to list all the available GNOME extensions:
|
||||
|
||||
```
|
||||
gnome-extensions list
|
||||
```
|
||||
|
||||
This will show you an output similar to this:
|
||||
|
||||
![List GNOME Extensions][12]
|
||||
|
||||
The default Ubuntu dock extension is [[email protected]][13] You can disable it using this command:
|
||||
|
||||
```
|
||||
gnome-extensions disable [email protected]
|
||||
```
|
||||
|
||||
There will be no output message displayed on the screen but you’ll notice that the launcher or dock disappears from the left side.
|
||||
|
||||
If you want, you can enable it again using the same command as above but with enable option this time:
|
||||
|
||||
```
|
||||
gnome-extensions enable [email protected]
|
||||
```
|
||||
|
||||
**Conclusion**
|
||||
|
||||
There are ways to disable the dock in Ubuntu 18.04 as well. However, it may lead to unwarranted situations if you try to remove it in 18.04. Removing this package also removes the ubuntu-desktop package and you may end up with a system with broken functionalities like no application menu.
|
||||
|
||||
This is the reason why I won’t recommend removing it on Ubuntu 18.04.
|
||||
|
||||
It’s good that Ubuntu 20.04 gives a way to hide the taskbar. Users have more freedom and more screen space. Speaking of more screen space, did you know that you can [remove the top title bar from Firefox and gain more screen space][14]?
|
||||
|
||||
I am wondering how do you prefer your Ubuntu desktop? With the dock, without dock or without GNOME?
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://itsfoss.com/disable-ubuntu-dock/
|
||||
|
||||
作者:[Abhishek Prakash][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[译者ID](https://github.com/译者ID)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://itsfoss.com/author/abhishek/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://ubuntu.com/
|
||||
[2]: https://itsfoss.com/keeping-ubuntu-unity-alive/
|
||||
[3]: https://itsfoss.com/ubuntu-unity-shutdown/
|
||||
[4]: https://www.gnome.org/
|
||||
[5]: https://itsfoss.com/download-ubuntu-20-04/
|
||||
[6]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/06/disable-dock-in-ubuntu.png?ssl=1
|
||||
[7]: https://itsfoss.com/ubuntu-20-04-release-features/
|
||||
[8]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2020/06/GNOME-extensions-app-ubuntu.jpg?ssl=1
|
||||
[9]: https://itsfoss.com/gnome-3-36-release/
|
||||
[10]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/06/disable-ubuntu-dock.png?ssl=1
|
||||
[11]: https://itsfoss.com/ubuntu-shortcuts/
|
||||
[12]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/06/list-gnome-extensions.png?ssl=1
|
||||
[13]: https://itsfoss.com/cdn-cgi/l/email-protection
|
||||
[14]: https://itsfoss.com/remove-title-bar-firefox/
|
@ -0,0 +1,165 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (wxy)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (Ubuntu Budgie 20.04 Review: Smooth, Polished & Plenty of Changes)
|
||||
[#]: via: (https://itsfoss.com/ubuntu-budgie-20-04-review/)
|
||||
[#]: author: (John Paul https://itsfoss.com/author/john/)
|
||||
|
||||
Ubuntu Budgie 20.04 评测:平滑、精致和丰富的变化
|
||||
======
|
||||
|
||||
正如我们向读者承诺的那样,我们将对 [Ubuntu 20.04 LTS 版本][1]的所有主要特色版进行评测。在这个续篇中,我们将对 Ubuntu Budgie 进行评测。
|
||||
|
||||
![Ubuntu Budgie Desktop][2]
|
||||
|
||||
[Ubuntu Budgie][3],顾名思义,是使用 [Budgie 桌面环境][5]的 [Ubuntu 官方特色版][4]。这个版本是 Ubuntu 家族中较新的成员。Ubuntu Budgie 的第一个版本是 16.04,它在 17.04 版本中被接受为官方特色版。
|
||||
|
||||
他们的[目标][6]是“将 Budgie 界面的简洁和优雅结合起来,产生一个具有现代范式的传统的桌面导向的发行版。”
|
||||
|
||||
### Ubuntu Budgie 20.04 评测:哪些改变了,哪些没有!
|
||||
|
||||
[自 18.04 LTS 发布以来,Ubuntu Budgie][7] 有了令人惊讶的更新和改进:
|
||||
|
||||
* 苹果风格的新菜单
|
||||
* 默认采用基于 Budgie 的网络管理小程序
|
||||
* 新的 Window Shuffler 允许你通过快捷键平铺应用程序
|
||||
* 快速切换桌面布局的新工具
|
||||
* 支持 4k 分辨率
|
||||
* 新的默认应用程序:GNOME Firmware 和 Drawing
|
||||
* 现在已经为 20.04 重构了向后移植包
|
||||
* 默认浏览器是火狐
|
||||
* 默认使用 Catfish 搜索文件和文本
|
||||
* 在 budgie 中集成了 Nemo 文件管理器
|
||||
* 由于错误,系统托盘小程序被移除了
|
||||
* 默认情况下,事件警报声被禁用
|
||||
* 修复键盘快捷键神秘失踪的问题
|
||||
* 更好的锁屏风格
|
||||
* 由于社区的要求,文件应用 Nautilus 已被 Nemo 取代
|
||||
* Plank 坞站现在已经切换到屏幕底部,是透明的,并且默认有反弹动画
|
||||
* 快速笔记和热角小程序已从 Python 移植到 Vala,以提高速度。
|
||||
* Celluloid 取代了 MPV
|
||||
* 更新了 GNOME 的依赖性
|
||||
|
||||
![][8]
|
||||
|
||||
Ubuntu Budgie 现在提供最新版本的 Budgie 桌面环境(10.5.1)。改进的地方包括:
|
||||
|
||||
* 在 Budgie 桌面设置中新增 Raven 部分
|
||||
* Raven 通知可以分组,通知可以关闭
|
||||
* 图标任务列表被移除
|
||||
* 能够设置虚拟桌面的数量
|
||||
|
||||
Ubuntu Budgie 自带了大量的 Budgie 小程序和微应用。它们可以通过 Ubuntu Budgie Welcome 来安装。
|
||||
|
||||
![Ubuntu Budgie Welcome][9]
|
||||
|
||||
* WeatherShow - 显示未来五天的天气预报,每 3 小时更新一次
|
||||
* Wallstreet - 一个允许你在图像文件夹中循环的壁纸工具
|
||||
* Visual-space - 一个紧凑的工作区切换器
|
||||
* Dropby - 这个小程序允许你从面板上快速管理 U 盘
|
||||
* Kangaroo - 从面板上快速浏览文件夹
|
||||
* 垃圾桶小程序 - 管理你的垃圾桶
|
||||
* Fuzzyclock - 以模糊的方式显示时间
|
||||
* 工作区秒表 - 允许你跟踪在每个工作区花费的时间
|
||||
|
||||
完整的变更和更新列表,请访问[变更日志][10]。
|
||||
|
||||
#### 系统要求
|
||||
|
||||
Ubuntu Budgie 20.04 更新了[系统要求][11]:
|
||||
|
||||
* 4GB 或以上的内存
|
||||
* 64 位的 Intel 和 AMD 处理器
|
||||
* 在 CSM 模式下启动的 UEFI 电脑
|
||||
* 基于英特尔的现代苹果电脑
|
||||
|
||||
如你所见,Budgie 并不是一个真正的轻量级选择。
|
||||
|
||||
#### 安装的应用
|
||||
|
||||
![][12]
|
||||
|
||||
Ubuntu Budgie 中默认包含了以下有用的应用程序:
|
||||
|
||||
* AisleRiot Solitaire
|
||||
* Geary
|
||||
* Catfish 搜索工具
|
||||
* Cheese 网络摄像头工具
|
||||
* GNOME Drawing
|
||||
* GNOME 2048
|
||||
* GNOME Mahjongg
|
||||
* GNOME Mines
|
||||
* GNOME Sudoku
|
||||
* Gthumb
|
||||
* LibreOffice
|
||||
* Maps
|
||||
* Rhythmbox
|
||||
* Tilix
|
||||
* Ubuntu Budgie Welcome
|
||||
* Evince 文档查看器
|
||||
* Plank
|
||||
* Celluloid
|
||||
|
||||
![Ubuntu Budgie Ram Usage][13]
|
||||
|
||||
### 安装
|
||||
|
||||
起初,我无法让 Ubuntu Budgie 进入即用环境,以便我可以安装它。结果发现 Ubuntu Budgie 试图通过 EFI 来启动,我联系了 [Ubuntu Budgie 论坛][14],得到了解决方案。
|
||||
|
||||
一旦出现紫色的闪屏,我必须按下 `ESC` 键并选择 `legacy`。之后,它就像正常的启动和安装一样了,没有问题。我只在 Ubuntu Budgie 上遇到过这个问题。我下载并尝试了 Ubuntu MATE 20.04 ISO,但没有遇到类似的问题。
|
||||
|
||||
### Ubuntu Budgie 20.04 的体验
|
||||
|
||||
![][15]
|
||||
|
||||
除了安装上的小问题,我使用 Ubuntu Budgie 期间非常愉快。自 [Ikey][16] 第一次创建 Budgie 桌面以来,Budgie 桌面已经进步了很多,它已经成为一个非常成熟的选择。Ubuntu Budgie 的目标是“制作一个传统的桌面导向的发行版”。它确实做到了这一点。他们所做的所有改变都在不断地为他们的产品增添更多的光彩。
|
||||
|
||||
总的来说,Ubuntu Budgie 是一个非常漂亮的发行版。从默认的主题到壁纸选项,你可以看出他们在视觉体验上做了很多努力。
|
||||
|
||||
需要注意的是,Ubuntu Budgie 并不适合低配置的系统。我在戴尔 Latitude D630 上运行它。在没有打开任何应用程序的情况下,它使用了大约 700MB 的内存。
|
||||
|
||||
在 Ubuntu Budgie 中,我最喜欢的一个部分是 [Tilix 终端模拟器][17]。Tilix 允许你在右侧或下方添加终端窗口。它有一大堆功能,我就是喜欢用它,我正打算安装在我的其他 Linux 系统上。
|
||||
|
||||
### 关于 Ubuntu Budgie 20.04 的最后感想
|
||||
|
||||
Ubuntu Budgie 是众多官方版本中一个值得欢迎的新版本。Budgie 给人的感觉是非常流畅和精致。它不会让你碍手碍脚,而是让你完成工作。
|
||||
|
||||
如果你厌倦了当前的桌面环境,想看看新的东西,不妨来看看。如果你对当前的设置感到满意,请查看 Ubuntu Budgie 的即用 DVD。你可能会喜欢上它。
|
||||
|
||||
![关于 Ubuntu Budgie][18]
|
||||
|
||||
你是否已经尝试过 Ubuntu 20.04 Budgie?你对它的使用体验如何?如果没有用过,你现在使用的是哪个版本的 Ubuntu 20.04?
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://itsfoss.com/ubuntu-budgie-20-04-review/
|
||||
|
||||
作者:[John Paul][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[wxy](https://github.com/wxy)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://itsfoss.com/author/john/
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: https://itsfoss.com/download-ubuntu-20-04/
|
||||
[2]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-busgie-desktop.png?resize=800%2C500&ssl=1
|
||||
[3]: https://ubuntubudgie.org/
|
||||
[4]: https://itsfoss.com/which-ubuntu-install/
|
||||
[5]: https://en.wikipedia.org/wiki/Budgie_(desktop_environment
|
||||
[6]: https://ubuntubudgie.org/about-us/
|
||||
[7]: https://itsfoss.com/ubuntu-budgie-18-review/
|
||||
[8]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-desktop-settings.jpeg?ssl=1
|
||||
[9]: https://i0.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-welcome.png?resize=800%2C472&ssl=1
|
||||
[10]: https://ubuntubudgie.org/2020/04/21/ubuntu-budgie-20-04lts-release-notes-for-18-04-upgraders/
|
||||
[11]: https://ubuntubudgie.org/downloads/
|
||||
[12]: https://i1.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-applications.jpeg?ssl=1
|
||||
[13]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-ram-usage.png?resize=800%2C600&ssl=1
|
||||
[14]: https://discourse.ubuntubudgie.org/t/cant-get-ub-to-boot/3397
|
||||
[15]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-20-04.jpg?ssl=1
|
||||
[16]: https://itsfoss.com/ikey-doherty-serpent-interview/
|
||||
[17]: https://gnunn1.github.io/tilix-web/
|
||||
[18]: https://i2.wp.com/itsfoss.com/wp-content/uploads/2020/05/ubuntu-budgie-about.png?resize=800%2C648&ssl=1
|
@ -0,0 +1,99 @@
|
||||
[#]: collector: (lujun9972)
|
||||
[#]: translator: (geekpi)
|
||||
[#]: reviewer: ( )
|
||||
[#]: publisher: ( )
|
||||
[#]: url: ( )
|
||||
[#]: subject: (How to dump the GOSSAFUNC graph for a method)
|
||||
[#]: via: (https://dave.cheney.net/2020/06/19/how-to-dump-the-gossafunc-graph-for-a-method)
|
||||
[#]: author: (Dave Cheney https://dave.cheney.net/author/davecheney)
|
||||
|
||||
如何转储一个方法的 GOSSAFUNC 图
|
||||
======
|
||||
|
||||
Go 编译器的 SSA 后端包含一种工具,可以生成编译阶段的 HTML 调试输出。这篇文章介绍了如何为函数_和_方法打印 SSA 输出。
|
||||
|
||||
让我们从一个包含函数、值方法和指针方法的示例程序开始:
|
||||
|
||||
```
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
)
|
||||
|
||||
type Numbers struct {
|
||||
vals []int
|
||||
}
|
||||
|
||||
func (n *Numbers) Add(v int) {
|
||||
n.vals = append(n.vals, v)
|
||||
}
|
||||
|
||||
func (n Numbers) Average() float64 {
|
||||
sum := 0.0
|
||||
for _, num := range n.vals {
|
||||
sum += float64(num)
|
||||
}
|
||||
return sum / float64(len(n.vals))
|
||||
}
|
||||
|
||||
|
||||
func main() {
|
||||
var numbers Numbers
|
||||
numbers.Add(200)
|
||||
numbers.Add(43)
|
||||
numbers.Add(-6)
|
||||
fmt.Println(numbers.Average())
|
||||
}
|
||||
```
|
||||
|
||||
通过 `GOSSAFUNC` 环境变量控制 SSA 调试输出。此变量含有要转储的函数的名称。这_不是_函数的完全限定名。对于上面的 `func main`,函数名称为 `main` _而不是_ `main.main`。
|
||||
|
||||
```
|
||||
% env GOSSAFUNC=main go build
|
||||
runtime
|
||||
dumped SSA to ../../go/src/runtime/ssa.html
|
||||
t
|
||||
dumped SSA to ./ssa.html
|
||||
```
|
||||
|
||||
在这个例子中,`GOSSAFUNC=main` 同时匹配了 `main.main` 和一个名为 `runtime.main` 的函数。[1][1]这有点不走运,但是实际上可能没什么大不了的,因为如果你要对代码进行性能调整,它就不会出现在 `func main` 中的巨大的意大利面块中。
|
||||
|
||||
你的代码更有可能在_方法_中,你可能已经看到这篇文章,并寻找能够转储方法的 SSA 输出。
|
||||
|
||||
要为指针方法 `func (n *Numbers) Add` 打印 SSA 调试,等效函数名为 `(*Numbers).Add`:[2][2]
|
||||
|
||||
```
|
||||
% env "GOSSAFUNC=(*Numbers).Add" go build
|
||||
t
|
||||
dumped SSA to ./ssa.html
|
||||
```
|
||||
|
||||
要为值方法 `func (n Numbers) Average` 打印 SSA 调试,等效函数名为 `(*Numbers).Average`,_即使这是一个值方法_:
|
||||
|
||||
```
|
||||
% env "GOSSAFUNC=(*Numbers).Average" go build
|
||||
t
|
||||
dumped SSA to ./ssa.html
|
||||
```
|
||||
|
||||
1. 如果你没有从源码构建 Go,那么 `runtime` 软件包的路径可能是只读的,并且可能会收到错误消息。请不要使用 `sudo` 来解决此问题。
|
||||
2. 请注意 shell 引用
|
||||
|
||||
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
via: https://dave.cheney.net/2020/06/19/how-to-dump-the-gossafunc-graph-for-a-method
|
||||
|
||||
作者:[Dave Cheney][a]
|
||||
选题:[lujun9972][b]
|
||||
译者:[geekpi](https://github.com/geekpi)
|
||||
校对:[校对者ID](https://github.com/校对者ID)
|
||||
|
||||
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
|
||||
|
||||
[a]: https://dave.cheney.net/author/davecheney
|
||||
[b]: https://github.com/lujun9972
|
||||
[1]: tmp.kLSHpQXzhr#easy-footnote-bottom-1-4188 (If you didn’t build Go from source then the path to the <code>runtime</code> package may be read only and you might receive an error. Please don’t use the <code>sudo</code> hammer to fix this.)
|
||||
[2]: tmp.kLSHpQXzhr#easy-footnote-bottom-2-4188 (Please pay attention to the shell quoting.)
|
Loading…
Reference in New Issue
Block a user