-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add pre- and post-build script to work around Poetry bug
- Loading branch information
1 parent
f7c7e10
commit dd7c464
Showing
5 changed files
with
37 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,8 +21,8 @@ maintainers = [ | |
"Niels Rogge <[email protected]>", | ||
] | ||
repository = "https://github.com/ml6team/fondant" | ||
include = ["*.txt", "*.rst", "*.md", "src/fondant/components/**/*.yaml"] | ||
exclude = ["src/fondant/components"] # Exclude everything except for component specs | ||
include = ["*.txt", "*.rst", "*.md", "fondant/components/**/*.yaml"] | ||
exclude = ["fondant/components"] # Exclude everything except for component specs | ||
classifiers = [ | ||
"Development Status :: 2 - Pre-Alpha", | ||
"Intended Audience :: Developers", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/bin/bash | ||
# This script reverts the `scripts/pre-build.sh` script by moving the package code back into a | ||
# `src` directory. | ||
# It should be run after running scripts/pre-build.sh and building the fondant package | ||
set -e | ||
|
||
scripts_path=$( cd "$(dirname "${BASH_SOURCE[0]}")" ; pwd -P ) | ||
root_path=$(dirname "$scripts_path") | ||
|
||
pushd "$root_path" | ||
mkdir -p src/fondant | ||
mv fondant/* src/fondant | ||
rm -rf fondant | ||
popd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/bin/bash | ||
# This script unpacks the src folder before building to make the poetry `include` and `exclude` | ||
# sections work correctly for both sdist and wheel | ||
# (https://github.com/python-poetry/poetry/issues/8994) | ||
# Building without running this script also works, but includes the full code for the components. | ||
# This script makes changes to the local files, which should not be committed to git. Run | ||
# scripts/post-build.sh to clean them up. | ||
set -e | ||
|
||
scripts_path=$( cd "$(dirname "${BASH_SOURCE[0]}")" ; pwd -P ) | ||
root_path=$(dirname "$scripts_path") | ||
|
||
pushd "$root_path" | ||
mkdir fondant | ||
mv src/fondant/* fondant | ||
rm -rf src | ||
popd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters