Skip to content

Commit

Permalink
fix: freeze UV by default
Browse files Browse the repository at this point in the history
Applying canonical/starbase@03aff98

Signed-off-by: Paul Mars <[email protected]>
  • Loading branch information
upils committed Jan 17, 2025
1 parent 3699380 commit 7337ac0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
2 changes: 0 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ ifneq ($(VERSION_CODENAME),)
SETUP_TESTS_EXTRA_ARGS=--extra apt-$(VERSION_CODENAME)
endif

UV_FROZEN=true

include common.mk

.PHONY: format
Expand Down
11 changes: 7 additions & 4 deletions common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ endif
PRETTIER=npm exec --package=prettier -- prettier
PRETTIER_FILES=**.yaml **.yml **.json **.json5 **.css **.md

# By default we should not update the uv lock file here.
export UV_FROZEN := true

.DEFAULT_GOAL := help

.ONESHELL:
Expand Down Expand Up @@ -45,19 +48,19 @@ help: ## Show this help.

.PHONY: setup
setup: install-uv setup-precommit ## Set up a development environment
uv sync --frozen $(SETUP_TESTS_EXTRA_ARGS) --extra docs --extra lint --extra types
uv sync $(SETUP_TESTS_EXTRA_ARGS) --extra docs --extra lint --extra types

.PHONY: setup-tests
setup-tests: install-uv install-build-deps ##- Set up a testing environment without linters
uv sync --frozen $(SETUP_TESTS_EXTRA_ARGS)
uv sync $(SETUP_TESTS_EXTRA_ARGS)

.PHONY: setup-lint
setup-lint: install-uv install-shellcheck install-pyright install-lint-build-deps ##- Set up a linting-only environment
uv sync --frozen --no-install-workspace --extra lint --extra types
uv sync --no-install-workspace --extra lint --extra types

.PHONY: setup-docs
setup-docs: install-uv ##- Set up a documentation-only environment
uv sync --frozen --no-dev --no-install-workspace --extra docs
uv sync --no-dev --no-install-workspace --extra docs

.PHONY: setup-precommit
setup-precommit: install-uv ##- Set up pre-commit hooks in this repository.
Expand Down

0 comments on commit 7337ac0

Please sign in to comment.