diff --git a/action.yml b/action.yml index c2cf28e..8efa9a5 100644 --- a/action.yml +++ b/action.yml @@ -130,7 +130,7 @@ runs: fi # Create Size Report - "$GITHUB_ACTION_PATH/scripts/create-report.sh" > report.json + "$GITHUB_ACTION_PATH/scripts/create-report.sh" report.json # Nothing else to do if [ "$COMMENT" != 'true' ]; then exit 0; fi diff --git a/scripts/create-report.sh b/scripts/create-report.sh index 26fd732..cfe4209 100755 --- a/scripts/create-report.sh +++ b/scripts/create-report.sh @@ -1,4 +1,4 @@ -#!/usr/bin/env bash +#!/bin/sh set -eu @@ -78,4 +78,4 @@ echo "{}" | jq \ --argjson pkgs "$pkgs" \ --argjson hmConfigs "$hmConfigs" \ --argjson nixosConfigs "$nixosConfigs" \ - '{"packages": $pkgs, "nixosConfigurations": $nixosConfigs, "homeConfigurations": $hmConfigs}' + '{"packages": $pkgs, "nixosConfigurations": $nixosConfigs, "homeConfigurations": $hmConfigs}' >"${1:-/dev/stdout}" diff --git a/scripts/retrieve-old-report.sh b/scripts/retrieve-old-report.sh index d1ab0f2..9c50afe 100755 --- a/scripts/retrieve-old-report.sh +++ b/scripts/retrieve-old-report.sh @@ -74,6 +74,6 @@ curl -X 'GET' \ tar -zvx --strip-components=1 -C "$old" endgroup -(cd "$old" && "$GITHUB_ACTION_PATH/create-report.sh") >old-report.json +(cd "$old" && "$GITHUB_ACTION_PATH/create-report.sh" old-report.json) exit 0