Skip to content

Commit

Permalink
Simplify deactivation of development environment
Browse files Browse the repository at this point in the history
Ref. None
  • Loading branch information
treiher committed Feb 27, 2024
1 parent 27f5b42 commit db5c42d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
5 changes: 1 addition & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -254,15 +254,12 @@ printenv_gnat:

# --- Development environment ---

.PHONY: activate deactivate
.PHONY: activate

activate: $(BIN_DIR)/poetry
@echo . $(DEVEL_VENV)/bin/activate
@echo PATH=$$PWD/.bin:\$$PATH

deactivate:
@echo deactivate

$(BIN_DIR)/poetry:
@mkdir -p $(BIN_DIR)
@ln -sf $(POETRY) $(BIN_DIR)
Expand Down
6 changes: 3 additions & 3 deletions doc/development_guide/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -78,13 +78,13 @@ Poetry will always be installed into its own environment (`.venv.poetry`).
It is not necessary to explicitly activate the virtual environments before executing any of the `make` targets.
They are used automatically during the execution of `make`.
However, in order to have the `rflx` command directly available in the shell, it is necessary to activate the project's virtual environment.
The following `make` targets can be used to respectively activate and deactivate it, as well as add or remove Poetry to/from the `PATH`.
Note the need to use `source <(...)` in the commands below.
The following commands can be used to respectively activate and deactivate it, as well as add or remove Poetry to/from the `PATH`.
Note the need to use `source <(...)` in the command below.

.. code:: console
$ source <(make activate)
$ source <(make deactivate)
$ deactivate
Alternatively, RecordFlux can be executed also via Poetry by executing `.venv.poetry/bin/poetry run rflx`.

Expand Down

0 comments on commit db5c42d

Please sign in to comment.