Skip to content

Commit e28f55e

Browse files
committed
Enhance stdout redirection lesson content and metadata across multiple languages
This commit improves the "stdout (Standard Output)" lesson by refining the content and metadata for clarity and consistency. Key updates include: - Revised titles and meta descriptions for better SEO and user engagement. - Enhanced lesson content to provide a clearer understanding of standard output (stdout) and I/O redirection, including practical examples and explanations of the `>` and `>>` operators. - Updated exercises and quiz questions to align with the revised content. These changes aim to create a more engaging and informative learning experience for users across different languages.
1 parent 6667a11 commit e28f55e

File tree

18 files changed

+203
-166
lines changed

18 files changed

+203
-166
lines changed
Lines changed: 22 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,60 +1,64 @@
11
---
22
index: 1
33
lang: "de"
4-
title: "stdout (Standard Out)"
5-
meta_title: "stdout (Standard Out) - Text-Fu"
6-
meta_description: "Erfahren Sie mehr über Linux stdout und I/O-Umleitung. Verstehen Sie, wie Sie die Befehlsausgabe mit den Operatoren > und >> in Dateien umleiten. Beginnen Sie noch heute Ihre Linux-Reise!"
7-
meta_keywords: "Linux stdout, I/O-Umleitung, Linux-Befehle, Ausgabe umleiten, Linux-Tutorial, Linux für Anfänger, Linux-Anleitung, Shell-Skripting"
4+
title: "stdout (Standardausgabe)"
5+
meta_title: "stdout (Standardausgabe) - Text-Fu"
6+
meta_description: "Beginnen Sie Ihre Reise zum Erlernen von Linux, indem Sie die Standardausgabe (stdout) und I/O-Umleitung meistern. Diese Lektion behandelt, wie man die Ausgabe von Befehlen mithilfe der Operatoren > und >> in Dateien umleitet – eine grundlegende Fähigkeit für jeden Linux-Benutzer."
7+
meta_keywords: "Linux, Linux lernen, stdout, I/O-Umleitung, Standardausgabe, Ausgabe umleiten, bash, Shell-Skripting, Linux-Befehle, Linux-Tutorial"
88
---
99

1010
## Lesson Content
1111

12-
Inzwischen sind wir mit vielen Befehlen und deren Ausgabe vertraut, und das bringt uns zu unserem nächsten Thema: I/O (Input/Output) Streams. Lassen Sie uns den folgenden Befehl ausführen, und wir werden besprechen, wie das funktioniert.
12+
Während Sie weiterhin Linux lernen, haben Sie gesehen, wie Befehle Ausgaben erzeugen. Dies führt uns zum wichtigen Thema der I/O-Streams (Input/Output), insbesondere der Standardausgabe oder **stdout**. Lassen Sie uns dieses Konzept untersuchen, indem wir den folgenden Befehl ausführen:
1313

1414
```bash
1515
echo Hello World > peanuts.txt
1616
```
1717

18-
Was ist gerade passiert? Nun, überprüfen Sie das Verzeichnis, in dem Sie diesen Befehl ausgeführt haben, und siehe da, Sie sollten eine Datei namens `peanuts.txt` sehen. Schauen Sie in diese Datei, und Sie sollten den Text "Hello World" sehen. Viele Dinge sind gerade in einem Befehl passiert, also lassen Sie uns ihn aufschlüsseln.
18+
Nach der Ausführung finden Sie eine neue Datei namens `peanuts.txt` in Ihrem aktuellen Verzeichnis. Wenn Sie ihren Inhalt anzeigen, sehen Sie den Text "Hello World". Lassen Sie uns analysieren, was passiert ist.
1919

20-
Zuerst zerlegen wir den ersten Teil:
20+
### Standardausgabe (stdout) verstehen
21+
22+
Betrachten Sie zunächst den Befehl ohne das Sonderzeichen:
2123

2224
```bash
2325
echo Hello World
2426
```
2527

26-
Wir wissen, dass dies "Hello World" auf dem Bildschirm ausgibt, aber wie? Prozesse verwenden I/O-Streams, um Eingaben zu empfangen und Ausgaben zurückzugeben. Standardmäßig nimmt der Befehl `echo` die Eingabe (Standardeingabe oder stdin) von der Tastatur und gibt die Ausgabe (Standardausgabe oder stdout) auf dem Bildschirm zurück. Deshalb erhalten Sie "Hello World" auf dem Bildschirm, wenn Sie `echo Hello World` in Ihrer Shell eingeben. Die I/O-Umleitung ermöglicht es uns jedoch, dieses Standardverhalten zu ändern, was uns eine größere Dateiflexibilität bietet.
28+
Standardmäßig senden viele Befehle ihre Ergebnisse an **stdout**, was Ihr Terminalbildschirm ist. Deshalb zeigt `echo Hello World` den Text direkt in Ihrer Shell an. Prozesse verwenden I/O-Streams, um Eingaben (Standardeingabe oder stdin) zu empfangen und Ausgaben zu senden. Die I/O-Umleitung ermöglicht es uns, dieses Standardverhalten zu ändern und uns mehr Kontrolle über unsere Daten zu geben.
29+
30+
### stdout mit > umleiten
2731

28-
Fahren wir mit dem nächsten Teil des Befehls fort:
32+
Das Zeichen `>` ist ein Umleitungsoperator. Es fängt die Daten ab, die an **stdout** gehen, und sendet sie an ein neues Ziel.
2933

3034
```bash
3135
>
3236
```
3337

34-
Das `>` ist ein Umleitungsoperator, der es uns ermöglicht, zu ändern, wohin die Standardausgabe geht. Er ermöglicht es uns, die Ausgabe von `echo Hello World` in eine Datei statt auf den Bildschirm zu senden. Wenn die Datei noch nicht existiert, wird sie für uns erstellt. Wenn sie jedoch existiert, wird sie überschrieben (Sie können ein Shell-Flag hinzufügen, um dies zu verhindern, je nachdem, welche Shell Sie verwenden).
38+
In unserem Beispiel sendet es die Ausgabe von `echo Hello World` an eine Datei anstatt an den Bildschirm. Wenn die Datei nicht existiert, wird sie erstellt. **Seien Sie vorsichtig**, denn wenn die Datei bereits existiert, überschreibt dieser Operator ihren Inhalt vollständig.
3539

36-
Und so funktioniert die stdout-Umleitung im Grunde!
40+
### stdout mit >> anhängen
3741

38-
Nun, nehmen wir an, ich wollte meine `peanuts.txt` nicht überschreiben. Glücklicherweise gibt es dafür auch einen Umleitungsoperator: `>>`.
42+
Was ist, wenn Sie einer Datei etwas hinzufügen möchten, ohne ihren Inhalt zu löschen? Dafür verwenden wir den Operator `>>`.
3943

4044
```bash
4145
echo Hello World >> peanuts.txt
4246
```
4347

44-
Dies wird "Hello World" an das Ende der Datei `peanuts.txt` anhängen. Wenn die Datei noch nicht existiert, wird sie für uns erstellt, genau wie der `>`-Umleiter!
48+
Dieser Operator hängt die Ausgabe an das Ende der angegebenen Datei an. Wenn die Datei noch nicht existiert, wird sie erstellt, genau wie beim `>`-Operator. Die Beherrschung der **stdout**-Umleitung ist ein grundlegender Schritt auf Ihrem Linux-Weg.
4549

4650
## Exercise
4751

48-
Übung macht den Meister! Hier sind einige praktische Übungen, um Ihr Verständnis der I/O-Umleitung zu festigen:
52+
Um Ihr Verständnis der I/O-Umleitung zu festigen, versuchen Sie dieses praktische Labor:
4953

50-
1. **[Eingabe und Ausgabe in Linux umleiten](https://labex.io/de/labs/comptia-redirecting-input-and-output-in-linux-590840)** - Üben Sie die Steuerung des Datenflusses von Befehlen, indem Sie die Standardausgabe (stdout), die Standardfehlerausgabe (stderr) und die Standardeingabe (stdin) mithilfe von Operatoren wie `>`, `>>`, `2>` und dem Befehl `tee` manipulieren.
54+
1. **[Eingabe und Ausgabe in Linux umleiten](https://labex.io/de/labs/comptia-redirecting-input-and-output-in-linux-590840)** - Üben Sie die Steuerung des Datenflusses von Befehlen, indem Sie die Standardausgabe (stdout), die Standardfehlerausgabe (stderr) und die Standardeingabe (stdin) mithilfe von Operatoren wie `>`, `>>`, `2>` und dem `tee`-Befehl manipulieren.
5155

52-
Dieses Labor wird Ihnen helfen, die Konzepte in realen Szenarien anzuwenden und Vertrauen in die I/O-Umleitung aufzubauen.
56+
Dieses Labor hilft Ihnen, diese Konzepte in realen Szenarien anzuwenden und Selbstvertrauen bei der I/O-Umleitung aufzubauen.
5357

5458
## Quiz Question
5559

56-
Welchen Umleitungsoperator verwenden Sie, um die Ausgabe an eine Datei anzuhängen?
60+
Welchen Umleiter verwenden Sie, um Ausgabe an eine Datei anzuhängen?
5761

5862
## Quiz Answer
5963

60-
>>
64+
`>>`

lessons/de/user-management/etc-passwd-file.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,4 +64,4 @@ Wenn ein Benutzerkonto gesperrt ist und nicht zur Anmeldung verwendet werden kan
6464

6565
## Quiz Answer
6666

67-
-
67+
`*`

lessons/en/text-fu/stdout-standard-out-redirect.md

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,58 +3,62 @@ index: 1
33
lang: "en"
44
title: "stdout (Standard Out)"
55
meta_title: "stdout (Standard Out) - Text-Fu"
6-
meta_description: "Learn about Linux stdout and I/O redirection. Understand how to redirect command output to files using > and >> operators. Start your Linux journey today!"
7-
meta_keywords: "Linux stdout, I/O redirection, Linux commands, redirect output, Linux tutorial, beginner Linux, Linux guide, shell scripting"
6+
meta_description: "Start your journey to learn Linux by mastering standard output (stdout) and I/O redirection. This lesson covers how to redirect command output to files using the > and >> operators, a fundamental skill for any Linux user."
7+
meta_keywords: "Linux, learn linux, stdout, I/O redirection, standard output, redirect output, bash, shell scripting, Linux commands, Linux tutorial"
88
---
99

1010
## Lesson Content
1111

12-
By now, we've become familiar with many commands and their output, and that brings us to our next subject: I/O (input/output) streams. Let's run the following command, and we'll discuss how this works.
12+
As you continue to learn Linux, you've seen how commands produce output. This brings us to the important topic of I/O (input/output) streams, specifically standard output or **stdout**. Let's explore this concept by running the following command:
1313

1414
```bash
1515
echo Hello World > peanuts.txt
1616
```
1717

18-
What just happened? Well, check the directory where you ran that command, and, lo and behold, you should see a file called `peanuts.txt`. Look inside that file, and you should see the text "Hello World". Lots of things just happened in one command, so let's break it down.
18+
After running this, you will find a new file named `peanuts.txt` in your current directory. If you view its contents, you'll see the text "Hello World". Let's break down what happened.
1919

20-
First, let's break down the first part:
20+
### Understanding Standard Output (stdout)
21+
22+
First, consider the command without the special character:
2123

2224
```bash
2325
echo Hello World
2426
```
2527

26-
We know this prints "Hello World" to the screen, but how? Processes use I/O streams to receive input and return output. By default, the `echo` command takes input (standard input or stdin) from the keyboard and returns output (standard output or stdout) to the screen. So, that's why when you type `echo Hello World` in your shell, you get "Hello World" on the screen. However, I/O redirection allows us to change this default behavior, giving us greater file flexibility.
28+
By default, many commands send their results to **stdout**, which is your terminal screen. This is why `echo Hello World` displays the text directly in your shell. Processes use I/O streams to receive input (standard input or stdin) and send output. I/O redirection allows us to change this default behavior, giving us greater control over our data.
29+
30+
### Redirecting stdout with >
2731

28-
Let's proceed to the next part of the command:
32+
The `>` character is a redirection operator. It intercepts the data heading to **stdout** and sends it to a new destination.
2933

3034
```bash
3135
>
3236
```
3337

34-
The `>` is a redirection operator that allows us to change where standard output goes. It allows us to send the output of `echo Hello World` to a file instead of the screen. If the file does not already exist, it will create it for us. However, if it does exist, it will overwrite it (you can add a shell flag to prevent this, depending on what shell you are using).
38+
In our example, it sends the output of `echo Hello World` to a file instead of the screen. If the file doesn't exist, it will be created. **Be careful**, as if the file already exists, this operator will completely overwrite its contents.
3539

36-
And that's basically how stdout redirection works!
40+
### Appending stdout with >>
3741

38-
Well, let's say I didn't want to overwrite my `peanuts.txt`. Luckily, there is a redirection operator for that as well: `>>`.
42+
What if you want to add to a file without erasing its contents? For that, we use the `>>` operator.
3943

4044
```bash
4145
echo Hello World >> peanuts.txt
4246
```
4347

44-
This will append "Hello World" to the end of the `peanuts.txt` file. If the file doesn't already exist, it will create it for us, just like the `>` redirector!
48+
This operator appends the output to the end of the specified file. If the file doesn't already exist, it will be created, just like the `>` operator. Mastering **stdout** redirection is a fundamental step in your Linux journey.
4549

4650
## Exercise
4751

48-
Practice makes perfect! Here are some hands-on labs to reinforce your understanding of I/O redirection:
52+
To solidify your understanding of I/O redirection, try this hands-on lab:
4953

50-
1. **[Redirecting Input and Output in Linux](https://labex.io/labs/comptia-redirecting-input-and-output-in-linux-590840)** - Practice controlling data flow from commands by manipulating standard output (stdout), standard error (stderr), and standard input (stdin) using operators like `>`, `>>`, `2>`, and the `tee` command.
54+
1. **[Redirecting Input and Output in Linux](https://labex.io/labs/comptia-redirecting-input-and-output-in-linux-590840)** - Practice controlling data flow from commands by manipulating standard output (stdout), standard error (stderr), and standard input (stdin) using operators like `>`, `>>`, `2>`, and the `tee` command.
5155

52-
This lab will help you apply the concepts in real scenarios and build confidence with I/O redirection.
56+
This lab will help you apply these concepts in real-world scenarios and build confidence with I/O redirection.
5357

5458
## Quiz Question
5559

5660
What redirector do you use to append output to a file?
5761

5862
## Quiz Answer
5963

60-
>>
64+
`>>`

lessons/en/user-management/etc-passwd-file.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,4 +64,4 @@ If a user account is locked and cannot be used for login, how is this denoted in
6464

6565
## Quiz Answer
6666

67-
-
67+
`*`

lessons/es/text-fu/stdout-standard-out-redirect.md

Lines changed: 24 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -3,58 +3,63 @@ index: 1
33
lang: "es"
44
title: "stdout (Salida Estándar)"
55
meta_title: "stdout (Salida Estándar) - Text-Fu"
6-
meta_description: "Aprende sobre stdout y la redirección de E/S en Linux. Entiende cómo redirigir la salida de comandos a archivos usando los operadores > y >>. ¡Comienza tu viaje en Linux hoy!"
7-
meta_keywords: "Linux stdout, redirección de E/S, comandos Linux, redirigir salida, tutorial Linux, Linux para principiantes, guía Linux, scripting de shell"
6+
meta_description: "Comienza tu viaje para aprender Linux dominando la salida estándar (stdout) y la redirección de E/S. Esta lección cubre cómo redirigir la salida de comandos a archivos usando los operadores > y >>, una habilidad fundamental para cualquier usuario de Linux."
7+
meta_keywords: "Linux, aprender linux, stdout, redirección E/S, salida estándar, redirigir salida, bash, scripting shell, comandos Linux, tutorial Linux"
88
---
99

1010
## Lesson Content
1111

12-
A estas alturas, ya nos hemos familiarizado con muchos comandos y su salida, y eso nos lleva a nuestro siguiente tema: los flujos de E/S (entrada/salida). Ejecutemos el siguiente comando y luego discutiremos cómo funciona.
12+
A medida que continúas aprendiendo Linux, has visto cómo los comandos producen salida. Esto nos lleva al importante tema de las transmisiones de E/S (entrada/salida), específicamente la salida estándar o **stdout**. Exploremos este concepto ejecutando el siguiente comando:
1313

1414
```bash
15-
echo Hello World > peanuts.txt
15+
echo Hola Mundo > cacahuetes.txt
1616
```
1717

18-
¿Qué acaba de pasar? Bueno, revisa el directorio donde ejecutaste ese comando y, ¡sorpresa!, deberías ver un archivo llamado `peanuts.txt`. Mira dentro de ese archivo y deberías ver el texto "Hello World". Muchas cosas acaban de suceder en un solo comando, así que vamos a desglosarlo.
18+
Después de ejecutar esto, encontrarás un nuevo archivo llamado `cacahuetes.txt` en tu directorio actual. Si ves su contenido, verás el texto "Hola Mundo". Analicemos lo que sucedió.
1919

20-
Primero, desglosaremos la primera parte:
20+
### Entendiendo la Salida Estándar (stdout)
21+
22+
Primero, considera el comando sin el carácter especial:
2123

2224
```bash
23-
echo Hello World
25+
echo Hola Mundo
2426
```
2527

26-
Sabemos que esto imprime "Hello World" en la pantalla, pero ¿cómo? Los procesos usan flujos de E/S para recibir entrada y devolver salida. Por defecto, el comando `echo` toma la entrada (entrada estándar o stdin) del teclado y devuelve la salida (salida estándar o stdout) a la pantalla. Por eso, cuando escribes `echo Hello World` en tu shell, obtienes "Hello World" en la pantalla. Sin embargo, la redirección de E/S nos permite cambiar este comportamiento predeterminado, dándonos mayor flexibilidad de archivos.
28+
Por defecto, muchos comandos envían sus resultados a **stdout**, que es la pantalla de tu terminal. Por eso `echo Hola Mundo` muestra el texto directamente en tu shell. Los procesos utilizan transmisiones de E/S para recibir entrada (entrada estándar o stdin) y enviar salida. La redirección de E/S nos permite cambiar este comportamiento predeterminado, dándonos un mayor control sobre nuestros datos.
29+
30+
### Redirección de stdout con >
2731

28-
Pasemos a la siguiente parte del comando:
32+
El carácter `>` es un operador de redirección. Intercepta los datos que se dirigen a **stdout** y los envía a un nuevo destino.
2933

3034
```bash
3135
>
3236
```
3337

34-
El `>` es un operador de redirección que nos permite cambiar a dónde va la salida estándar. Nos permite enviar la salida de `echo Hello World` a un archivo en lugar de a la pantalla. Si el archivo no existe, lo creará por nosotros. Sin embargo, si ya existe, lo sobrescribirá (puedes añadir una bandera de shell para evitar esto, dependiendo del shell que estés usando).
38+
En nuestro ejemplo, envía la salida de `echo Hola Mundo` a un archivo en lugar de a la pantalla. Si el archivo no existe, se creará. **Ten cuidado**, ya que si el archivo ya existe, este operador sobrescribirá completamente su contenido.
3539

36-
¡Y así es básicamente como funciona la redirección de stdout!
40+
### Anexar stdout con >>
3741

38-
Bueno, digamos que no quería sobrescribir mi `peanuts.txt`. Afortunadamente, también hay un operador de redirección para eso: `>>`.
42+
¿Qué pasa si quieres añadir contenido a un archivo sin borrar su contenido? Para eso, usamos el operador `>>`.
3943

4044
```bash
41-
echo Hello World >> peanuts.txt
45+
echo Hola Mundo >> cacahuetes.txt
4246
```
4347

44-
Esto añadirá "Hello World" al final del archivo `peanuts.txt`. Si el archivo no existe, lo creará por nosotros, ¡igual que el redireccionador `>`!
48+
Este operador anexa la salida al final del archivo especificado. Si el archivo no existe previamente, se creará, al igual que el operador `>`.
49+
Manejar la redirección de **stdout** es un paso fundamental en tu camino en Linux.
4550

4651
## Exercise
4752

48-
¡La práctica hace al maestro! Aquí tienes algunos laboratorios prácticos para reforzar tu comprensión de la redirección de E/S:
53+
Para solidificar tu comprensión de la redirección de E/S, prueba este laboratorio práctico:
4954

50-
1. **[Redirección de entrada y salida en Linux](https://labex.io/es/labs/comptia-redirecting-input-and-output-in-linux-590840)** - Practica el control del flujo de datos de los comandos manipulando la salida estándar (stdout), el error estándar (stderr) y la entrada estándar (stdin) usando operadores como `>`, `>>`, `2>` y el comando `tee`.
55+
1. **[Redirección de Entrada y Salida en Linux](https://labex.io/es/labs/comptia-redirecting-input-and-output-in-linux-590840)** - Practica el control del flujo de datos desde comandos manipulando la salida estándar (stdout), el error estándar (stderr) y la entrada estándar (stdin) usando operadores como `>`, `>>`, `2>`, y el comando `tee`.
5156

52-
Este laboratorio te ayudará a aplicar los conceptos en escenarios reales y a generar confianza con la redirección de E/S.
57+
Este laboratorio te ayudará a aplicar estos conceptos en escenarios del mundo real y a ganar confianza con la redirección de E/S.
5358

5459
## Quiz Question
5560

56-
¿Qué redireccionador utilizas para añadir la salida a un archivo?
61+
¿Qué redireccionador usas para anexar salida a un archivo?
5762

5863
## Quiz Answer
5964

60-
>>
65+
`>>`

lessons/es/user-management/etc-passwd-file.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,4 +64,4 @@ Si una cuenta de usuario está bloqueada y no se puede utilizar para iniciar ses
6464

6565
## Quiz Answer
6666

67-
-
67+
`*`

0 commit comments

Comments
 (0)