Skip to content

Commit

Permalink
Update artifact upload
Browse files Browse the repository at this point in the history
  • Loading branch information
jordancarlin committed Jul 21, 2024
1 parent 5968ffa commit b2cb261
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 30 deletions.
13 changes: 9 additions & 4 deletions .github/workflows/install.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Installation
on: [workflow_dispatch]
on: [workflow_dispatch, push]
defaults:
run:
shell: bash
Expand Down Expand Up @@ -31,7 +31,7 @@ jobs:
run: |
source setup.sh
regression-wally
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: always()
with:
name: regression-logs-${{ matrix.os }}
Expand All @@ -48,6 +48,11 @@ jobs:
matrix:
os: ["rockylinux:8", "rockylinux:9", "almalinux:8", "almalinux:9"]
steps:
- name: Unique name for Artifacts
id: prep_artifact_name
run: |
name=$(echo -n "${{ matrix.os }}" | sed -e 's/[ \t:\/\\"<>|*?]/-/g' -e 's/--*/-/g')
echo "ARTIFACT_NAME=$name" >> $GITHUB_ENV
- name: Install dependencies
run: |
dnf install -y sudo git
Expand All @@ -72,8 +77,8 @@ jobs:
run: |
source setup.sh
regression-wally
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v4
if: always()
with:
name: regression-logs-${{ matrix.os }}
name: regression-logs-${{ env.ARTIFACT_NAME }}
path: ${{ github.workspace }}/sim/verilator/logs/
19 changes: 14 additions & 5 deletions bin/wally-distro-check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,20 @@ WARNING_COLOR='\033[93m'
FAIL_COLOR='\033[91m'
ENDC='\033[0m' # Reset to default color

printf "${SECTION_COLOR}%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s" | tr ' ' '#'
echo -e "Checking System Requirements and Configuring Installation"
printf "%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s${ENDC}" | tr ' ' '#'
# Print section header
section_header() {
if tput cols > /dev/null 2>&1; then
printf "${SECTION_COLOR}%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s" | tr ' ' '#'
echo -e "$1"
printf "%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s${ENDC}" | tr ' ' '#'
else
echo -e "${SECTION_COLOR}$1${ENDC}"
fi
}

section_header "Checking System Requirements and Configuring Installation"

# Get distribution information
test -e /etc/os-release && os_release="/etc/os-release" || os_release="/usr/lib/os-release"
Expand Down
12 changes: 2 additions & 10 deletions bin/wally-package-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,7 @@ fi

# Check if required packages are installed or install/update them depending on passed flag.
if [ "${1}" == "--check" ]; then
printf "${SECTION_COLOR}%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s" | tr ' ' '#'
echo -e "Checking Dependencies from Package Manager"
printf "%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s${ENDC}" | tr ' ' '#'
section_header "Checking Dependencies from Package Manager"

if [ "$FAMILY" == rhel ]; then
for pack in "${GENERAL_PACKAGES[@]}" "${GNU_PACKAGES[@]}" "${QEMU_PACKAGES[@]}" "${SPIKE_PACKAGES[@]}" "${VERILATOR_PACKAGES[@]}" "${SAIL_PACKAGES[@]}" "${BUILDROOT_PACKAGES[@]}" "${OTHER_PACKAGES[@]}"; do
Expand All @@ -104,11 +100,7 @@ else
# Check if root, otherwise exit with error message
[ "${EUID:=$(id -u)}" -ne 0 ] && echo -e "\n${FAIL_COLOR}Must be run as root${ENDC}" && exit 1

printf "${SECTION_COLOR}%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s" | tr ' ' '#'
echo -e ""Installing/Updating Dependencies from Package Manager""
printf "%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s${ENDC}" | tr ' ' '#'
section_header "Installing/Updating Dependencies from Package Manager"

# Enable extra repos necessary for rhel
if [ "$FAMILY" == rhel ]; then
Expand Down
11 changes: 0 additions & 11 deletions bin/wally-tool-chain-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,17 +53,6 @@ error() {
exit 1
}

# Print section header
section_header() {
set +x
printf "${SECTION_COLOR}%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s" | tr ' ' '#'
echo -e "$1"
printf "%$(tput cols)s" | tr ' ' '#'
printf "%$(tput cols)s${ENDC}" | tr ' ' '#'
set -x
}

# Check if a git repository exists, is up to date, and has been installed
# Clones the repository if it doesn't exist
git_check() {
Expand Down

0 comments on commit b2cb261

Please sign in to comment.