From a9bf2db683113444a026da8e89da1d0e154484b3 Mon Sep 17 00:00:00 2001 From: Kingkor Roy Tirtho Date: Fri, 14 Jan 2022 17:48:42 +0600 Subject: [PATCH] Bumped version changed the avatar placeholder with adventurer sprite dicebear prevention from playing empty playlists --- AppImageBuilder.yml | 2 +- README.md | 6 +++--- aur-struct/.SRCINFO | 4 ++-- aur-struct/PKGBUILD | 2 +- deb-struct/DEBIAN/control | 2 +- lib/components/Home.dart | 2 +- lib/components/Lyrics.dart | 34 +++++++++++++++++-------------- lib/components/PlaylistCard.dart | 2 ++ pubspec.yaml | 4 ++-- scripts/windows-setup-creator.iss | 2 +- windows/runner/Runner.rc | 2 +- 11 files changed, 34 insertions(+), 28 deletions(-) diff --git a/AppImageBuilder.yml b/AppImageBuilder.yml index e5d20389..59db5ec5 100644 --- a/AppImageBuilder.yml +++ b/AppImageBuilder.yml @@ -11,7 +11,7 @@ AppDir: id: oss.krtirtho.spotube name: Spotube icon: spotube-logo - version: 1.0.0 + version: 1.0.1 exec: spotube exec_args: $@ apt: diff --git a/README.md b/README.md index c7b61270..8b0642c5 100644 --- a/README.md +++ b/README.md @@ -25,12 +25,12 @@ All the binaries are located in the [releases](https://github.com/krtirtho/spotu ## Windows -Download the [setup file](https://github.com/KRTirtho/spotube/releases/download/v1.0.0/Spotube-windows-x86_64-setup.exe) & follow along the installer +Download the [setup file](https://github.com/KRTirtho/spotube/releases/download/v1.0.1/Spotube-windows-x86_64-setup.exe) & follow along the installer ## Linux ### Ubuntu/Debian/Linux Mint/Pop_!OS: - Download the [Spotube-linux-x86_64.deb](https://github.com/KRTirtho/spotube/releases/download/v1.0.0/Spotube-linux-x86_64.deb) then double click it or run + Download the [Spotube-linux-x86_64.deb](https://github.com/KRTirtho/spotube/releases/download/v1.0.1/Spotube-linux-x86_64.deb) then double click it or run ```bash $ sudo apt install Spotube-linux-x86_64.deb # or @@ -50,7 +50,7 @@ Download the [setup file](https://github.com/KRTirtho/spotube/releases/download/ ### Others: - Download the [Spotube-linux-x86_64.AppImage](Spotube-linux-x86_64.AppImage) file & double click to run it. AppImages require [appimage-launcher](https://github.com/TheAssassin/AppImageLauncher) to be installed + Download the [Spotube-linux-x86_64.AppImage](https://github.com/KRTirtho/spotube/releases/download/v1.0.1/Spotube-linux-x86_64.AppImage) file & double click to run it. AppImages require [appimage-launcher](https://github.com/TheAssassin/AppImageLauncher) to be installed **I'll/try to upload the package binaries to linux debian/arch/ubuntu/snap/flatpack/redhat/chocolatey stores or software centers or repositories** diff --git a/aur-struct/.SRCINFO b/aur-struct/.SRCINFO index e592d01f..dcba3ab0 100644 --- a/aur-struct/.SRCINFO +++ b/aur-struct/.SRCINFO @@ -1,11 +1,11 @@ pkgbase = spotube pkgdesc = A lightweight free Spotify desktop-client which handles playback manually, streams music using Youtube & no Spotify premium account is needed - pkgver = 1.0.0 + pkgver = 1.0.1 pkgrel = 1 url = https://github.com/KRTirtho/spotube/ arch = x86_64 license = BSD 4-Clause - source = https://github.com/KRTirtho/spotube/releases/download/v1.0.0/Spotube-linux-x86_64.tar.xz + source = https://github.com/KRTirtho/spotube/releases/download/v1.0.1/Spotube-linux-x86_64.tar.xz pkgname = spotube diff --git a/aur-struct/PKGBUILD b/aur-struct/PKGBUILD index b9b7b92f..1b06377f 100644 --- a/aur-struct/PKGBUILD +++ b/aur-struct/PKGBUILD @@ -1,6 +1,6 @@ # Maintainer: Kingkor Roy Tirtho pkgname=spotube -pkgver=1.0.0 +pkgver=1.0.1 pkgrel=1 epoch= pkgdesc="A lightweight free Spotify desktop-client which handles playback manually, streams music using Youtube & no Spotify premium account is needed" diff --git a/deb-struct/DEBIAN/control b/deb-struct/DEBIAN/control index a3ddd5cd..724187d7 100644 --- a/deb-struct/DEBIAN/control +++ b/deb-struct/DEBIAN/control @@ -1,5 +1,5 @@ Package: Spotube -Version: 1.0.0 +Version: 1.0.1 Section: sound Priority: optional Architecture: all diff --git a/lib/components/Home.dart b/lib/components/Home.dart index 43090883..2a8950db 100644 --- a/lib/components/Home.dart +++ b/lib/components/Home.dart @@ -189,7 +189,7 @@ class _HomeState extends State { false) && snapshot.data?.images?.last.url != null) ? snapshot.data!.images!.last.url! - : "https://avatars.dicebear.com/api/human/${snapshot.data?.id}.png"; + : "https://avatars.dicebear.com/api/adventurer/${snapshot.data?.id}.png"; return Padding( padding: const EdgeInsets.all(16), child: Row( diff --git a/lib/components/Lyrics.dart b/lib/components/Lyrics.dart index 7d44b354..05827d49 100644 --- a/lib/components/Lyrics.dart +++ b/lib/components/Lyrics.dart @@ -50,21 +50,25 @@ class _LyricsState extends State { if (_lyrics["lyrics"] == null && playback.currentTrack != null) { if (!hasToken) { return Expanded( - child: Center( - child: Column( - children: [ - const Text("Genius lyrics API access token isn't set"), - ElevatedButton( - onPressed: () { - Navigator.of(context).push(MaterialPageRoute( - builder: (context) { - return const Settings(); - }, - )); - }, - child: const Text("Add Access Token")) - ], - ), + child: Column( + children: [ + Text( + "Genius lyrics API access token isn't set", + style: Theme.of(context) + .textTheme + .headline4 + ?.copyWith(color: Colors.red[400]), + ), + ElevatedButton( + onPressed: () { + Navigator.of(context).push(MaterialPageRoute( + builder: (context) { + return const Settings(); + }, + )); + }, + child: const Text("Add Access Token")) + ], )); } return const Expanded( diff --git a/lib/components/PlaylistCard.dart b/lib/components/PlaylistCard.dart index ec1ae2b0..82f0da96 100644 --- a/lib/components/PlaylistCard.dart +++ b/lib/components/PlaylistCard.dart @@ -81,6 +81,8 @@ class _PlaylistCardState extends State { tracks.map((e) => e.track!))) .toList(); + if (tracks.isEmpty) return; + playback.setCurrentPlaylist = CurrentPlaylist( tracks: tracks, id: widget.playlist.id!, diff --git a/pubspec.yaml b/pubspec.yaml index 008b8692..27b1b87d 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -15,7 +15,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion. # Read more about iOS versioning at # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html -version: 1.0.0 +version: 1.0.1 environment: sdk: ">=2.15.1 <3.0.0" @@ -106,6 +106,6 @@ msix_config: display_name: Spotube publisher_display_name: KRTirtho identity_name: oss.krtirtho.spotube - msix_version: 1.0.0.0 + msix_version: 1.0.1.0 logo_path: .\assets\spotube-logo.png capabilities: "internetClient,internetClientServer,backgroundMediaPlayback" \ No newline at end of file diff --git a/scripts/windows-setup-creator.iss b/scripts/windows-setup-creator.iss index daaf72b0..6d3c4664 100644 --- a/scripts/windows-setup-creator.iss +++ b/scripts/windows-setup-creator.iss @@ -2,7 +2,7 @@ ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! #define MyAppName "Spotube" -#define MyAppVersion "1.0.0" +#define MyAppVersion "1.0.1" #define MyAppPublisher "KRTirtho, OSS" #define MyAppURL "https://github.com/KRTirtho/spotube" #define MyAppExeName "spotube.exe" diff --git a/windows/runner/Runner.rc b/windows/runner/Runner.rc index a8dff664..f39d8585 100644 --- a/windows/runner/Runner.rc +++ b/windows/runner/Runner.rc @@ -69,7 +69,7 @@ IDI_APP_ICON ICON "resources\\icon.ico" #ifdef FLUTTER_BUILD_NAME #define VERSION_AS_STRING #FLUTTER_BUILD_NAME #else -#define VERSION_AS_STRING "1.0.0" +#define VERSION_AS_STRING "1.0.1" #endif VS_VERSION_INFO VERSIONINFO