Instalowanie Modular CLI
Zainstaluj toolchain na macOS lub Linux.
Instalowanie Modular CLI to bezpłatna lekcja Mojo Academy na CoddyKit. To lekcja 1 z 4. Możesz przeczytać całą lekcję poniżej za darmo — a potem ćwiczyć ją interaktywnie w przeglądarce z wbudowanym edytorem kodu i tutorem AI dostępnym 24/7. To część ścieżki edukacyjnej Mojo Academy, a Twój postęp synchronizuje się między webem a aplikacją CoddyKit. Kurs Mojo Academy zawiera 4 lekcji w sumie.
Części tej lekcji nie zostały jeszcze przetłumaczone i są wyświetlane po angielsku.
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! 🎯
Często zadawane pytania
Czy lekcja „Instalowanie Modular CLI” jest bezpłatna?
Tak — pełny tekst „Instalowanie Modular CLI” jest dostępny za darmo tutaj w sieci. Aby ćwiczyć ją interaktywnie (wbudowany edytor kodu i tutor AI dostępny 24/7) i odblokować resztę kursu Mojo Academy, przejdź na CoddyKit PRO. Kurs Mojo Academy zawiera 4 lekcji w sumie.
Co nauczysz się w „Instalowanie Modular CLI”?
Zainstaluj toolchain na macOS lub Linux. Ćwiczysz Mojo Academy z praktycznym kodem, który uruchamiasz bezpośrednio w przeglądarce, a tutor AI dostępny 24/7 odpowiada na Twoje pytania podczas pracy nad lekcją.
Czy potrzebuję doświadczenia, aby zacząć Mojo Academy?
Nie wymagamy żadnego doświadczenia. Mojo Academy w CoddyKit jest strukturyzowany dla początkujących i zaawansowanych użytkowników, więc możesz zacząć tutaj lub od początku i uczyć się w swoim tempie. To lekcja 1 z 4.
Ile czasu zajmuje lekcja „Instalowanie Modular CLI”?
Większość lekcji CoddyKit trwa około 5–10 minut. Każda lekcja to mały, interaktywny krok, dzięki czemu robisz systematyczne postępy i zawsze wracasz dokładnie do tego samego miejsca — na webie i w aplikacji.
Czy mogę pisać i uruchamiać kod w tej lekcji Mojo Academy?
Tak. Każda lekcja Mojo Academy zawiera wbudowany edytor kodu, więc piszesz i uruchamiasz prawdziwy kod bezpośrednio w przeglądarce i od razu otrzymujesz sprzężenie zwrotne od AI — bez konfiguracji na komputerze.
Wszystkie lekcje w tym kursie
- Instalowanie Modular CLI
- Dodawanie pakietu Mojo
- Sprawdzanie wersji
- Konfiguracja edytora dla Mojo