improved the build and upload
Dieser Commit ist enthalten in:
Ursprung
0ba608406e
Commit
cd1d5aa84e
4
Makefile
4
Makefile
|
@ -11,11 +11,11 @@ docs: format
|
|||
clean-dist:
|
||||
rm -rf dist
|
||||
|
||||
hatch-release:
|
||||
hatch-release: clean-dist
|
||||
hatch build
|
||||
|
||||
galaxy-release: clean-dist changelog
|
||||
ansible-galaxy collection build --output-path dist
|
||||
ansible-galaxy collection build --output-path dist/galaxy
|
||||
|
||||
upload: galaxy-release hatch-release
|
||||
./upload.sh
|
||||
|
|
|
@ -23,7 +23,8 @@ classifiers = [
|
|||
"Programming Language :: Python :: Implementation :: PyPy",
|
||||
]
|
||||
dependencies = []
|
||||
|
||||
[tool.hatch.build]
|
||||
directory = "dist/python"
|
||||
[project.urls]
|
||||
Documentation = "https://github.com/unknown/ansible-module#readme"
|
||||
Issues = "https://github.com/unknown/ansible-module/issues"
|
||||
|
|
12
upload.sh
12
upload.sh
|
@ -3,13 +3,5 @@ user=$(yq -r .namespace galaxy.yml)
|
|||
package=$(yq -r .name galaxy.yml)
|
||||
version=$(yq -r .version galaxy.yml)
|
||||
printf "Namespace: %s\nPackage: %s\nVersion: %s\n" $user $package $version
|
||||
upload(){
|
||||
name=$(basename "$1")
|
||||
printf "uploading: %s as %s\n" "$1" "$name"
|
||||
curl -u sebastian --upload-file "$1" "https://gitea.sebastian-tobie.de/api/packages/ansible/generic/${package}/${version}/$name"
|
||||
}
|
||||
for file in dist/sebastian* ; do
|
||||
upload "$file"
|
||||
done
|
||||
rm -f dist/sebastian*
|
||||
hatch publish -r ansible
|
||||
ansible-galaxy collection publish dist/galaxy/*
|
||||
hatch publish -r ansible dist/python/*
|
||||
|
|
Laden…
In neuem Issue referenzieren