Skip to content

Commit

Permalink
fix: release action
Browse files Browse the repository at this point in the history
  • Loading branch information
SpikeHD committed May 10, 2024
1 parent 2331f7d commit eeb1697
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,34 @@ jobs:
with:
path: artifacts

- name: Rename executables to their folder names
run: |
# get the folder name
folder_name=artifacts
# get the list of inner folders
folders=$(ls $folder_name)
# loop through the files in each folder
for folder in $folders; do
# Get the list of files in the folder
files=$(ls "$folder_name/$folder")
for file in $files; do
# Get the filename without extension
filename="${file%.*}"
# Get the extension (everything after the last dot)
extension="${file##*.}"
# Build the new filename with parent folder name and extension
new_filename="$folder_name/$folder/$folder.$extension"
# Rename the file
mv "$folder_name/$folder/$file" "$new_filename"
done
done
- name: Create release using all artifacts
uses: softprops/action-gh-release@v2
with:
Expand Down

0 comments on commit eeb1697

Please sign in to comment.