My Fedora 40 Development Setup
Learn how to install Copilot CLI, Node.js, Node.js, Visual Studio Code, development packages, and Docker with step-by-step CLI commands
Copilot CLI
We need to install GitHub CLI first. I would like to install it from Github’s package repository for immediate access to the latest releases:
sudo dnf install 'dnf-command(config-manager)'sudo dnf config-manager --add-repo https://cli.github.com/packages/rpm/gh-cli.reposudo dnf install ghNow, we can install Copilot in the CLI. First, we need to authenticate our Github account:
gh auth loginAfter authenticating our account, we need to install copilot as a Github CLI extension:
gh extension install github/gh-copilotIf you see a successful installation message, then we are all set. If you would like to upgrade Copilot CLI, here is the command:
gh extension upgrade gh-copilotThe Copilot CLI extension’s command is a bit long so that we can use the power of aliases in Linux. If you followed my My Fedora (Gnome) Setup article,
My Fedora 39 (Gnome 45) Full Setup
you are already using zsh as your shell. So here is the command to shorten commands:
echo 'eval "$(gh copilot alias -- zsh)"' >> ~/.zshrcBut there is a catch! When this command runs, it adds eval "$(gh copilot alias -- zsh)" to ~/.zshrc file, but then, you may not have the terminal loaded properly (at least, it happened to me). It is because of a data collection question. If you have the same problem, cancel the operation with Ctrl + C the keyboard shortcut and then run this command directly inside the terminal: gh copilot alias -- zsh . You need to answer the data collection question, and then you are good to go. You won't have an unresponsive terminal further.
At the end, you can try it:
ghcs 'print "Hello world!"'Node.js Installation
Although I am not a NodeJS developer, sometimes I need to do simple things or some packages require to use it. I will install it very simply and stick to Fedora repository versioning.
sudo dnf install nodejsAfter the installation (which also comes with the npm package manager), you can check the versions from the terminal.
node -vnpm -vVisual Studio Code
Although it is eligible to be installed with Flatpak, I would like to install it with dnf because I would like to reach to system-wide packages too.
First, let’s add the repo:
sudo rpm --import https://packages.microsoft.com/keys/microsoft.ascsudo sh -c 'echo -e "[code]\nname=Visual Studio Code\nbaseurl=https://packages.microsoft.com/yumrepos/vscode\nenabled=1\ngpgcheck=1\ngpgkey=https://packages.microsoft.com/keys/microsoft.asc" > /etc/yum.repos.d/vscode.repo'Time to install:
sudo dnf check-updatesudo dnf install codeNecessary Development Packages
sudo dnf install @development-toolssudo dnf group install "C Development Tools and Libraries"Docker Engine
Docker Desktop is a bit problematic to install and maintain for the new versions, so I don’t prefer a GUI for Docker in Linux. It is not mandatory, and the command line is more than enough to manage Docker images.
sudo dnf install dnf-plugins-coresudo dnf config-manager --add-repo https://download.docker.com/linux/fedora/docker-ce.reposudo dnf install docker-ce docker-ce-cli containerd.ioTo start the Docker service:
sudo systemctl start dockerIf you would like to have Docker start when the system reboots:
sudo systemctl enable dockerWhy do we need sudo right for Docker in Linux? Here is a good document: https://projectatomic.io/blog/2015/08/why-we-dont-let-non-root-users-run-docker-in-centos-fedora-or-rhel/
Or you can follow the adding group method here (I am using this version): https://docs.docker.com/engine/install/linux-postinstall/
Docker Compose
You should have docker before installing docker-compose. Then:
sudo dnf install docker-composeYou can check one of the docker-compose files here: https://github.com/canartuc/docker_compose_files
If you missed:
AstroNvim Setup in Fedora 39

