Skip to content

Commit

Permalink
change version to date only
Browse files Browse the repository at this point in the history
  • Loading branch information
atvcaptain committed Jul 4, 2023
1 parent 4fbe117 commit c0e6504
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions feed/ipkg-make-index.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,18 @@ for pkg in $(find . -name '*.ipk' | sort); do
file_size=$(ls -l --dereference $pkg | awk '{print $5}')
md5sum=$(md5sum $pkg | awk '{print $1}')
pkg_name=$(basename $pkg)
ar p $pkg control.tar.gz | tar -xzOf- './control' | sed -e "s/^Description:/Filename: $pkg_name\\
Size: $file_size\\
MD5Sum: $md5sum\\
Description:/" >> Packages
description=$(echo "$pkg_name" | sed 's/^enigma2-plugin-picons-//' | sed 's/_.*$//')
newversion=$(echo "$pkg" | grep -oE '[0-9]{4}-[0-9]{2}-[0-9]{2}')
ar p "$pkg" control.tar.gz | tar -xzOf- './control' |
awk -v newver="$newversion" -v pkgname="$pkg_name" -v filesize="$file_size" -v md5="$md5sum" -v description="$description" '{
if ($0 ~ "^Version:") {
printf "Version: %s\n", newver
} else if ($0 ~ "^Description:") {
printf "Filename: %s\nSize: %s\nMD5Sum: %s\nDescription:%s\n", pkgname, filesize, md5, description
} else {
print
}
}' >> Packages
echo "" >> Packages
echo "" >> Packages
done
Expand Down

0 comments on commit c0e6504

Please sign in to comment.