Skip to content

Commit 8230920

Browse files
committed
add uv --locked override
closes #3
1 parent d19c4bf commit 8230920

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/hatch_uvenv/plugin.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,11 @@ def command_context(self):
219219
yield
220220

221221
def construct_uv_sync_command(self):
222-
command = [self.uv_path, "sync", "--active", "--locked"]
222+
command = [self.uv_path, "sync", "--active"]
223+
224+
locked = self.config.get("locked", True)
225+
if locked:
226+
command.append("--locked")
223227

224228
# Default to -1 verbosity
225229
add_verbosity_flag(command, self.verbosity, adjustment=-1)

0 commit comments

Comments
 (0)