Setting up a development machine

The plan of a development machine: editor, language and its version, Git and its identity, SSH key, per-project isolated environments, virtual machine, WSL and container.

  • 25 cards
  • 4 topics
  • Free

The outline, topic by topic

Each topic is weighted the way the exam weighs it.

  1. Concepts
  2. Questions
  3. Sort and link
  4. Scenarios

A few cards from the deck

  • Development environment: what is it?

    Show the answer

    The set of tools gathered on a machine to write, run and test a project: editor, language, version control, dependencies.

    If two machines do not have the same tool versions, the same project can work on one and fail on the other. It is better to describe it in the repository.

  • In which order do you type these commands to work inside a brand-new Python virtual environment?

    • python3 -m venv .venv, source .venv/bin/activate, pip install -r requirements.txt
    • source .venv/bin/activate, python3 -m venv .venv, pip install -r requirements.txt
    • pip install -r requirements.txt, python3 -m venv .venv, source .venv/bin/activate
    • python3 -m venv .venv, pip install -r requirements.txt, source .venv/bin/activate
    Show the answer

    python3 -m venv .venv, source .venv/bin/activate, pip install -r requirements.txt

    You create the folder, activate it, and only then install: without activation, pip would install into the system (or be refused). Activating a folder that does not exist yet fails.

  • Before the first commit, Git asks you to declare your identity with git config --global followed by … then user.email.

    Show the answer

    Before the first commit, Git asks you to declare your identity with git config --global followed by user.name then user.email.

    These two values are written into every commit. With --global, they go into ~/.gitconfig and apply to every repository of the account.

  • IDE: what is it?

    Show the answer

    Software that brings together, in one window, the code editor, assisted typing, running, the debugger and Git integration.

    The acronym stands for integrated development environment. It does not replace the compiler or interpreter: it drives them.

  • After installation, python script.py answers “bash: python: command not found” even though Python is installed. What do you do?

    • Run python3 script.py, or install the python-is-python3 package
    • Reinstall the whole system, since the Python installation is broken
    • Add /usr/lib to PATH, since that is where Python is stored
    • Run chmod +x on the Python binary
    Show the answer

    Run python3 script.py, or install the python-is-python3 package

    On many distributions only python3 is shipped: the python command does not exist until a package such as python-is-python3 is installed. The message says the shell finds no command of that name, not that Python is broken.