Skip to content

If the new track matches our http proxy call, but does not have the c… #17

If the new track matches our http proxy call, but does not have the c…

If the new track matches our http proxy call, but does not have the c… #17

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
ref: main
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y libxml2-utils zip
- name: Extract version from tag
id: version
run: |
VERSION=${GITHUB_REF#refs/tags/v}
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "Version: $VERSION"
- name: Update version in Plugins/SiriusXM/install.xml
run: |
sed -i "s/<version>.*<\/version>/<version>${{ steps.version.outputs.version }}<\/version>/" Plugins/SiriusXM/install.xml
# Verify the change
grep -o '<version>.*</version>' Plugins/SiriusXM/install.xml
- name: Update version in repo.xml
run: |
sed -i "/plugin name/s/version=\"[^\"]*\"/version=\"${{ steps.version.outputs.version }}\"/" repo.xml
# Verify the change (Skip the <?xml line)
tail -n+2 repo.xml | grep -o 'version="[^"]*"'
- name: Create plugin package
run: |
# Create a clean package directory
mkdir -p package
# Copy plugin files
cp -r Plugins/SiriusXM package/
# Create the zip package
cd package
zip -r ../SiriusXM-${{ steps.version.outputs.version }}.zip SiriusXM/
cd ..
# Calculate SHA checksum
SHA=$(sha1sum SiriusXM-${{ steps.version.outputs.version }}.zip | cut -d' ' -f1)
echo "Package SHA: $SHA"
echo "sha=$SHA" >> $GITHUB_ENV
- name: Update repo.xml with download URL and SHA
run: |
# Update download URL
sed -i "s|<url>.*</url>|<url>https://github.com/paul-1/plugin-SiriusXM/releases/download/v${{ steps.version.outputs.version }}/SiriusXM-${{ steps.version.outputs.version }}.zip</url>|" repo.xml
# Update SHA
sed -i "s|<sha>.*</sha>|<sha>${{ env.sha }}</sha>|" repo.xml
# Verify changes
cat repo.xml
- name: Run essential validation
run: |
# Validate XML files only - other tests are covered in test.yml
xmllint --noout Plugins/SiriusXM/install.xml
xmllint --noout repo.xml
- name: Commit updated files
run: |
git config user.name github-actions
git config user.email github-actions@github.com
git add Plugins/SiriusXM/install.xml repo.xml
git commit -m "Update version to ${{ steps.version.outputs.version }} for release" || exit 0
git push || exit 0
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
files: |
SiriusXM-${{ steps.version.outputs.version }}.zip
repo.xml
body: |
## SiriusXM Plugin v${{ steps.version.outputs.version }}
### Changes
- See commit history for detailed changes
### Manual Installation
1. Download the SiriusXM-${{ steps.version.outputs.version }}.zip file
2. Extract to your Lyrion Media Server Plugins directory
3. Configure your SiriusXM credentials in plugin settings
4. Restart Lyrion Media Server
### Automatic Repository Update
1. Go to Settings → Plugins → Add Repository
2. Enter: `https://github.com/paul-1/plugin-SiriusXM/releases/latest/download/repo.xml`
3. Install Plugin.
### Requirements
- Lyrion Media Server 8.3 or higher
- SiriusXM subscription
draft: false
prerelease: false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}