Die Modular CLI installieren
Richten Sie die Toolchain auf macOS oder Linux ein.
Die Modular CLI installieren ist eine kostenlose Mojo Academy-Lektion auf CoddyKit. Dies ist Lektion 1 von 4. Du kannst die komplette Lektion unten kostenlos lesen – dann übst du sie direkt im Browser mit einem integrierten Code-Editor und einem KI-Tutor rund um die Uhr. Sie ist Teil des Mojo Academy-Lernpfads, und dein Fortschritt wird über Web und CoddyKit-App synchronisiert. Der Mojo Academy-Kurs umfasst insgesamt 4 Lektionen.
Teile dieser Lektion wurden noch nicht übersetzt und werden auf Englisch angezeigt.
Why a Toolchain First
Before you write Mojo, your machine needs the compiler and tools. That bundle is the Modular toolchain, and getting it set up is step one. 🛠️
Meet the Modular CLI
The magic command-line tool from Modular installs and manages everything Mojo needs. Think of it as your toolchain manager.
Pick a Supported System
Mojo runs on macOS and Linux today. On Windows you use WSL, which gives you a Linux environment inside Windows.
Open Your Terminal
Everything here happens in the terminal. On macOS open Terminal, on Linux open your shell, and keep it ready for the next commands.
Run the Install Script
Install the CLI with the official script. This single curl command downloads and sets up the magic tool for you.
curl -ssL https://magic.modular.com/ | bashWhat the Script Does
The script places the magic binary in a local folder and prints a line to add it to your PATH so the shell can find it.
Update Your PATH
Copy the export line the installer shows into your shell config so PATH includes magic in every new terminal you open.
export PATH="$HOME/.modular/bin:$PATH"Reload the Shell
Apply the change by reloading your config or opening a fresh terminal. This is what makes the new magic command available.
source ~/.bashrcConfirm the CLI Works
Check that the install succeeded by asking magic for its version. A version number means the CLI is ready to use.
magic --versionIf the Command Is Not Found
A not-found error almost always means PATH is missing the magic folder. Re-check the export line and reload your terminal.
It Is Safe and Reversible
Everything installs into a local .modular folder in your home directory. To undo it later, you simply delete that folder.
Quick Check
Recall which tool you install first to manage Mojo on your machine.
Recap
You installed Modular's magic CLI with one curl command, fixed your PATH, and confirmed it with magic --version. Toolchain manager ready! 🎯
Häufig gestellte Fragen
Ist die Lektion „Die Modular CLI installieren“ kostenlos?
Ja — der vollständige Text von „Die Modular CLI installieren“ ist hier im Web kostenlos zu lesen. Um sie interaktiv zu üben (integrierter Code-Editor und 24/7 KI-Tutor) und den Rest des Mojo Academy-Kurses freizuschalten, upgrade auf CoddyKit PRO. Der Mojo Academy-Kurs umfasst insgesamt 4 Lektionen.
Was lerne ich in „Die Modular CLI installieren“?
Richten Sie die Toolchain auf macOS oder Linux ein. Du übst Mojo Academy mit praktischem Code, den du direkt im Browser ausführst, und ein 24/7 KI-Tutor beantwortet deine Fragen während du die Lektion bearbeitest.
Brauche ich Erfahrung, um Mojo Academy zu starten?
Keine Vorkenntnisse erforderlich. Mojo Academy auf CoddyKit ist für Anfänger bis fortgeschrittene Lernende strukturiert, sodass du hier starten oder von Anfang an beginnen und in deinem eigenen Tempo voranschreiten kannst. Dies ist Lektion 1 von 4.
Wie lange dauert die Lektion „Die Modular CLI installieren“?
Die meisten CoddyKit-Lektionen dauern etwa 5–10 Minuten. Jede ist kompakt und interaktiv, sodass du stetig Fortschritte machst und genau dort weitermachst, wo du aufgehört hast – im Web und in der App.
Kann ich in dieser Mojo Academy-Lektion Code schreiben und ausführen?
Ja. Jede Mojo Academy-Lektion enthält einen integrierten Code-Editor, sodass du echten Code direkt in deinem Browser schreibst und ausführst und sofort KI-Feedback erhältst — ohne lokale Einrichtung erforderlich.
Alle Lektionen in diesem Kurs
- Die Modular CLI installieren
- Das Mojo-Paket hinzufügen
- Ihre Version überprüfen
- Ihre Editor-Einrichtung für Mojo