Compare commits
1 commit
8a529f91e4
...
63db4337cf
Author | SHA1 | Date | |
---|---|---|---|
63db4337cf |
1 changed files with 4 additions and 15 deletions
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
package_size_table() {
|
create_table() {
|
||||||
packages=$(nix flake show --json 2>/dev/null | jq --raw-output '.packages."x86_64-linux" | ".#" + keys[]')
|
packages=$(nix flake show --json 2>/dev/null | jq --raw-output '.packages."x86_64-linux" | ".#" + keys[]')
|
||||||
# we want to split the words as each of them is a different installable
|
# we want to split the words as each of them is a different installable
|
||||||
# shellcheck disable=SC2086
|
# shellcheck disable=SC2086
|
||||||
|
@ -19,18 +19,7 @@ package_size_table() {
|
||||||
|
|
||||||
if [ "$CI" = "true" ]; then
|
if [ "$CI" = "true" ]; then
|
||||||
tea login add --url "$GITHUB_SERVER_URL" --token "$GITHUB_TOKEN"
|
tea login add --url "$GITHUB_SERVER_URL" --token "$GITHUB_TOKEN"
|
||||||
pr_index=$(tea pulls -f index,head -o simple | grep "$GITHUB_HEAD_REF" | head -n1 | cut -d' ' -f 1)
|
tea pulls list
|
||||||
tea comment "$pr_index" "$(
|
|
||||||
cat <<-EOF
|
|
||||||
### NixOS Configurations sizes
|
|
||||||
|
|
||||||
TODO
|
|
||||||
|
|
||||||
### Package sizes
|
|
||||||
|
|
||||||
$(package_size_table)
|
|
||||||
EOF
|
|
||||||
)"
|
|
||||||
else
|
|
||||||
package_size_table
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
create_table
|
||||||
|
|
Loading…
Add table
Reference in a new issue