Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrade to Pants v2.23.0rc1 + other fixes #139

Merged
merged 3 commits into from
Oct 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,10 +139,14 @@ pants test helloworld/translator/translator_test.py -- -k test_unknown_phrase #

## Create a PEX binary

The `package` goal requires specifying a target which can be packaged. In this case, the there is a `pex_binary` target with the name `pex_binary` in the `helloworld/BUILD` file.

```
pants package helloworld/main.py
pants package helloworld:pex_binary
tdyas marked this conversation as resolved.
Show resolved Hide resolved
```

The pex file is output to `dist/helloworld/pex_binary.pex` and can be executed directly.

## Run a binary directly

```
Expand Down
4 changes: 2 additions & 2 deletions get-pants.sh
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ Once installed, if you want to update your "pants" launcher binary, use
-h | --help: Print this help message.

-d | --bin-dir:
The directory to install the scie-pants binary in, "~/bin" by default.
The directory to install the scie-pants binary in, "~/.local/bin" by default.

-b | --base-name:
The name to use for the scie-pants binary, "pants" by default.
Expand All @@ -176,7 +176,7 @@ Once installed, if you want to update your "pants" launcher binary, use
EOF
}

bin_dir="${HOME}/bin"
bin_dir="${HOME}/.local/bin"
base_name="pants"
version="latest/download"
while (($# > 0)); do
Expand Down
8 changes: 2 additions & 6 deletions pants.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Licensed under the Apache License, Version 2.0 (see LICENSE).

[GLOBAL]
pants_version = "2.21.0"
pants_version = "2.23.0rc1"
backend_packages.add = [
"pants.backend.build_files.fmt.black",
"pants.backend.python",
Expand All @@ -25,7 +25,7 @@ root_patterns = ["/"]
# The default interpreter constraints for code in this repo. Individual targets can override
# this with the `interpreter_constraints` field. See
# https://www.pantsbuild.org/docs/python-interpreter-compatibility.

#
# Modify this if you don't have Python 3.9 on your machine.
# This can be a range, such as [">=3.8,<3.11"], but it's usually recommended to restrict
# to a single minor version.
Expand All @@ -44,7 +44,3 @@ resolves = { python-default = "python-default.lock"}
# problematic system Pythons. See
# https://www.pantsbuild.org/docs/python-interpreter-compatibility#changing-the-interpreter-search-path.
search_path = ["<PATH>", "<PYENV>"]

[python-infer]
# 2.17 is transitioning to a new, faster parser for dependency inference:
use_rust_parser = true
Loading