Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
133 changes: 72 additions & 61 deletions .github/workflows/build-and-release.yml
Original file line number Diff line number Diff line change
@@ -1,73 +1,84 @@
name: "Build and Release"
name: build and release

on:
push:
branches: [ main, master ]
paths-ignore:
- "**/*.md"
- ".vscode/**"
workflow_dispatch:
workflow_call:
inputs:
release_type:
required: true
type: string
tag_name:
required: true
type: string
prerelease:
required: true
type: boolean
branch:
required: true
type: string
release_title:
required: true
type: string
release_body:
required: true
type: string
latest_tag:
required: false
type: string

jobs:
Build:
name: Build
build:
name: build
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: latest

- name: Install Node.js
uses: actions/setup-node@v4
with:
cache: pnpm
node-version: latest

- name: Install dependencies
run: pnpm install

- name: Build
run: pnpm run build

- name: Upload Build Artifacts
uses: actions/upload-artifact@v4
with:
name: luna-artifacts
path: ./dist

Release:
name: Release latest on GitHub
needs: Build
- name: checkout code
uses: actions/checkout@v4

- name: install pnpm
uses: pnpm/action-setup@v4
with:
version: latest

- name: install Node.js
uses: actions/setup-node@v4
with:
cache: pnpm
node-version: latest

- name: install dependencies
run: pnpm install

- name: build plugin
run: pnpm run build

- name: upload build artifacts
uses: actions/upload-artifact@v4
with:
name: luna-artifacts
path: ./dist

release:
name: release
needs: build
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master'
if: github.ref == inputs.branch
permissions:
contents: write

steps:
- name: Download All Artifacts
uses: actions/download-artifact@v4
with:
name: luna-artifacts
path: ./dist/

- name: Publish latest release on GitHub
uses: softprops/action-gh-release@v2
with:
tag_name: latest
name: "Release v${{ github.run_number }}"
body: |
## Tidarr Integration Plugin
- name: download artifacts
uses: actions/download-artifact@v4
with:
name: luna-artifacts
path: ./dist/

Send tracks and albums from Tidal directly to Tidarr for download.
- name: publish release on github
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ inputs.latest_tag || inputs.tag_name }}
name: ${{ inputs.release_title }}
body: ${{ inputs.release_body }}
prerelease: ${{ inputs.prerelease }}
files: ./dist/**
fail_on_unmatched_files: false

### Installation
1. Open TidalLuna
2. Go to Settings → Plugins
3. Click "Install from URL"
4. Paste: `https://github.com/DevonCasey/tidal-luna-plugins/releases/download/latest/store.json`
files: ./dist/**
fail_on_unmatched_files: false
33 changes: 33 additions & 0 deletions .github/workflows/dev-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: dev release

on:
push:
branches:
- dev
paths:
- 'plugins/tidarr-integration/**'
- 'plugins/**'

jobs:
call-shared-workflow:
uses: ./.github/workflows/build-and-release.yml
with:
release_type: dev
tag_name: dev-${{ github.run_number }}
prerelease: true
branch: refs/heads/dev
release_title: "Dev Release #${{ github.run_number }}"
release_body: |
Tidarr Integration Plugin

Send tracks and albums from Tidal directly to Tidarr for download.

### Installation
1. Open **TidalLuna**
2. Go to **Settings → Plugins**
3. Click **"Install from URL"**
4. Paste this URL:
```
https://github.com/DevonCasey/tidal-luna-plugins/releases/download/latest-dev/store.json
```
latest_tag: latest-dev
34 changes: 34 additions & 0 deletions .github/workflows/prod-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: main release

on:
push:
branches:
- main
paths:
- 'plugins/tidarr-integration/**'
- 'plugins/**'

jobs:
call-shared-workflow:
uses: ./.github/workflows/build-and-release.yml
with:
release_type: stable
tag_name: v${{ github.run_number }}
prerelease: false
branch: refs/heads/main
release_title: "Release v${{ github.run_number }}"
release_body: |
Tidarr Integration Plugin

Send tracks and albums from Tidal directly to Tidarr for download.

### Installation
1. Open **TidalLuna**
2. Go to **Settings → Plugins**
3. Click **"Install from URL"**
4. Paste this URL:
```
https://github.com/DevonCasey/tidal-luna-plugins/releases/download/latest/store.json
```
latest_tag: latest

3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,6 @@ temp/

# Example (development reference)
example

# Backup stuff
*.bak
10 changes: 7 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
{
"name": "@devoncasey/tidalluna-plugins",
"description": "A collection of plugins for TidalLuna.",
"author": "Devon Casey",
"repository": {
"author": {
"name": "Devon Casey",
"url": "https://github.com/DevonCasey",
"avatarUrl": "https://0.gravatar.com/avatar/4f20153247cc8c6c0868d779e8a8ae0593bb9641880886280281f7de135edc9f"
},
"repository": {
"type": "git",
"url": "https://github.com/DevonCasey/TidalLuna-Plugins.git"
},
Expand All @@ -24,4 +28,4 @@
"tsx": "^4.19.4",
"typescript": "^5.8.3"
}
}
}
10 changes: 7 additions & 3 deletions plugins/tidarr-integration/package.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
{
"name": "tidarr-integration",
"description": "Send tracks and albums to Tidarr for download right from TidalLuna.",
"description": "Sends tracks and albums to Tidarr for download right from TidalLuna.",
"version": "1.0.0",
"license": "MIT",
"homepage": "https://github.com/DevonCasey/tidal-luna-plugins#tidarr-integration",
"author": {
"name": "Devon Casey",
"url": "https://github.com/DevonCasey"
"url": "https://github.com/DevonCasey",
"avatarUrl": "https://0.gravatar.com/avatar/4f20153247cc8c6c0868d779e8a8ae0593bb9641880886280281f7de135edc9f"
},
"main": "./src/index.ts"
}
}
Loading