mirror of
https://github.com/KRTirtho/spotube.git
synced 2025-09-13 07:55:18 +00:00
Merge branch 'master' into dev
This commit is contained in:
commit
36396b7583
3
.env.example
Normal file
3
.env.example
Normal file
@ -0,0 +1,3 @@
|
||||
POCKETBASE_URL=
|
||||
USERNAME=
|
||||
PASSWORD=
|
@ -1,10 +1,3 @@
|
||||
|
||||
# 🚨 DO NOT INSTALL Spotube FROM `PLAY STORE`
|
||||
## There's an unofficial + `illegal` clone/copycat of Spotube available on `Play Store` that is full of malware, ads and trackers. To help take down this illegal copycat/clone, please FOLLOW THIS GUIDE : [wiki/Report-Spotube-Copycat-on-PlayStore](https://github.com/KRTirtho/spotube/wiki/Report-Spotube-Copycat-on-Playstore)
|
||||
|
||||
Follow this issue thread to get updates on the progress of the legal action against the illegal copycat/clone: https://github.com/KRTirtho/spotube/issues/448
|
||||
|
||||
|
||||
<p align="center"><img width="700" src="assets/spotube_banner.png" alt="Spotube Logo"></p>
|
||||
|
||||
<p align="center">
|
||||
|
@ -17,7 +17,6 @@ import 'package:spotube/pages/lyrics/lyrics.dart';
|
||||
import 'package:spotube/pages/player/player.dart';
|
||||
import 'package:spotube/pages/playlist/playlist.dart';
|
||||
import 'package:spotube/pages/root/root_app.dart';
|
||||
// import 'package:spotube/pages/search/search.dart';
|
||||
import 'package:spotube/pages/settings/settings.dart';
|
||||
import 'package:spotube/pages/mobile_login/mobile_login.dart';
|
||||
|
||||
|
@ -77,18 +77,18 @@ final localTracksProvider = FutureProvider<List<LocalTrack>>((ref) async {
|
||||
}).map(
|
||||
(f) async {
|
||||
try {
|
||||
final metadata = await MetadataGod.getMetadata(f.path);
|
||||
final metadata = await MetadataGod.readMetadata(file: f.path);
|
||||
|
||||
final imageFile = File(join(
|
||||
(await getTemporaryDirectory()).path,
|
||||
"spotube",
|
||||
basenameWithoutExtension(f.path) +
|
||||
imgMimeToExt[metadata?.picture?.mimeType ?? "image/jpeg"]!,
|
||||
imgMimeToExt[metadata.picture?.mimeType ?? "image/jpeg"]!,
|
||||
));
|
||||
if (!await imageFile.exists() && metadata?.picture != null) {
|
||||
if (!await imageFile.exists() && metadata.picture != null) {
|
||||
await imageFile.create(recursive: true);
|
||||
await imageFile.writeAsBytes(
|
||||
metadata?.picture?.data ?? [],
|
||||
metadata.picture?.data ?? [],
|
||||
mode: FileMode.writeOnly,
|
||||
);
|
||||
}
|
||||
|
@ -10,6 +10,7 @@ import 'package:flutter/services.dart';
|
||||
import 'package:flutter_hooks/flutter_hooks.dart';
|
||||
import 'package:hive_flutter/hive_flutter.dart';
|
||||
import 'package:hooks_riverpod/hooks_riverpod.dart';
|
||||
import 'package:metadata_god/metadata_god.dart';
|
||||
import 'package:package_info_plus/package_info_plus.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
import 'package:spotube/collections/cache_keys.dart';
|
||||
@ -69,6 +70,7 @@ void main(List<String> rawArgs) async {
|
||||
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
await SystemTheme.accentColor.load();
|
||||
MetadataGod.initialize();
|
||||
await QueryClient.initialize(cachePrefix: "oss.krtirtho.spotube");
|
||||
Hive.registerAdapter(CacheTrackAdapter());
|
||||
Hive.registerAdapter(CacheTrackEngagementAdapter());
|
||||
|
@ -108,8 +108,8 @@ class Downloader with ChangeNotifier {
|
||||
final response = await get(Uri.parse(imageUri));
|
||||
|
||||
await MetadataGod.writeMetadata(
|
||||
file.path,
|
||||
Metadata(
|
||||
file: file.path,
|
||||
metadata: Metadata(
|
||||
title: track.name,
|
||||
artist: track.artists?.map((a) => a.name).join(", "),
|
||||
album: track.album?.name,
|
||||
@ -123,7 +123,7 @@ class Downloader with ChangeNotifier {
|
||||
fileSize: file.lengthSync(),
|
||||
trackTotal: track.album?.tracks?.length,
|
||||
picture: response.headers['content-type'] != null
|
||||
? Image(
|
||||
? Picture(
|
||||
data: response.bodyBytes,
|
||||
mimeType: response.headers['content-type']!,
|
||||
)
|
||||
|
@ -8,7 +8,6 @@
|
||||
|
||||
#include <audioplayers_linux/audioplayers_linux_plugin.h>
|
||||
#include <catcher/catcher_plugin.h>
|
||||
#include <metadata_god/metadata_god_plugin.h>
|
||||
#include <screen_retriever/screen_retriever_plugin.h>
|
||||
#include <system_theme/system_theme_plugin.h>
|
||||
#include <url_launcher_linux/url_launcher_plugin.h>
|
||||
@ -22,9 +21,6 @@ void fl_register_plugins(FlPluginRegistry* registry) {
|
||||
g_autoptr(FlPluginRegistrar) catcher_registrar =
|
||||
fl_plugin_registry_get_registrar_for_plugin(registry, "CatcherPlugin");
|
||||
catcher_plugin_register_with_registrar(catcher_registrar);
|
||||
g_autoptr(FlPluginRegistrar) metadata_god_registrar =
|
||||
fl_plugin_registry_get_registrar_for_plugin(registry, "MetadataGodPlugin");
|
||||
metadata_god_plugin_register_with_registrar(metadata_god_registrar);
|
||||
g_autoptr(FlPluginRegistrar) screen_retriever_registrar =
|
||||
fl_plugin_registry_get_registrar_for_plugin(registry, "ScreenRetrieverPlugin");
|
||||
screen_retriever_plugin_register_with_registrar(screen_retriever_registrar);
|
||||
|
@ -5,7 +5,6 @@
|
||||
list(APPEND FLUTTER_PLUGIN_LIST
|
||||
audioplayers_linux
|
||||
catcher
|
||||
metadata_god
|
||||
screen_retriever
|
||||
system_theme
|
||||
url_launcher_linux
|
||||
@ -14,6 +13,7 @@ list(APPEND FLUTTER_PLUGIN_LIST
|
||||
)
|
||||
|
||||
list(APPEND FLUTTER_FFI_PLUGIN_LIST
|
||||
metadata_god
|
||||
)
|
||||
|
||||
set(PLUGIN_BUNDLED_LIBRARIES)
|
||||
|
@ -10,7 +10,6 @@ import audio_session
|
||||
import audioplayers_darwin
|
||||
import catcher
|
||||
import device_info_plus
|
||||
import metadata_god
|
||||
import package_info_plus
|
||||
import path_provider_foundation
|
||||
import screen_retriever
|
||||
@ -27,7 +26,6 @@ func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
|
||||
AudioplayersDarwinPlugin.register(with: registry.registrar(forPlugin: "AudioplayersDarwinPlugin"))
|
||||
CatcherPlugin.register(with: registry.registrar(forPlugin: "CatcherPlugin"))
|
||||
DeviceInfoPlusMacosPlugin.register(with: registry.registrar(forPlugin: "DeviceInfoPlusMacosPlugin"))
|
||||
MetadataGodPlugin.register(with: registry.registrar(forPlugin: "MetadataGodPlugin"))
|
||||
FLTPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FLTPackageInfoPlusPlugin"))
|
||||
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
|
||||
ScreenRetrieverPlugin.register(with: registry.registrar(forPlugin: "ScreenRetrieverPlugin"))
|
||||
|
12
pubspec.lock
12
pubspec.lock
@ -699,10 +699,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: flutter_rust_bridge
|
||||
sha256: aedbf045f72c7ed778d1cfc8bff0ceae28519d258e3f477abd70ce375ae8cdda
|
||||
sha256: "34f5becca2df35955b2ec5e875349028ea609a826de7aade4de80534cf876b27"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.62.1"
|
||||
version: "1.72.1"
|
||||
flutter_svg:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -965,10 +965,10 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: metadata_god
|
||||
sha256: a2a54285d363f15baa261abc16eb5f1b95397c7838a29c9c98d2a684e6fe052c
|
||||
sha256: "02de939fc2dcfdc959ed34768eecc97038b6e95ebaa3415f9f7582d71a2ad047"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.3.2"
|
||||
version: "0.4.1"
|
||||
mime:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -1777,5 +1777,5 @@ packages:
|
||||
source: hosted
|
||||
version: "1.12.3"
|
||||
sdks:
|
||||
dart: ">=2.19.0 <3.0.0"
|
||||
flutter: ">=3.3.0"
|
||||
dart: ">=2.19.2 <3.0.0"
|
||||
flutter: ">=3.7.0"
|
||||
|
@ -49,7 +49,7 @@ dependencies:
|
||||
json_annotation: ^4.8.0
|
||||
json_serializable: ^6.6.0
|
||||
logger: ^1.1.0
|
||||
metadata_god: ^0.3.2
|
||||
metadata_god: ^0.4.1
|
||||
mime: ^1.0.2
|
||||
package_info_plus: ^3.0.2
|
||||
palette_generator: ^0.3.3
|
||||
|
@ -8,7 +8,6 @@
|
||||
|
||||
#include <audioplayers_windows/audioplayers_windows_plugin.h>
|
||||
#include <catcher/catcher_plugin.h>
|
||||
#include <metadata_god/metadata_god_plugin_c_api.h>
|
||||
#include <permission_handler_windows/permission_handler_windows_plugin.h>
|
||||
#include <screen_retriever/screen_retriever_plugin.h>
|
||||
#include <system_theme/system_theme_plugin.h>
|
||||
@ -21,8 +20,6 @@ void RegisterPlugins(flutter::PluginRegistry* registry) {
|
||||
registry->GetRegistrarForPlugin("AudioplayersWindowsPlugin"));
|
||||
CatcherPluginRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("CatcherPlugin"));
|
||||
MetadataGodPluginCApiRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("MetadataGodPluginCApi"));
|
||||
PermissionHandlerWindowsPluginRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("PermissionHandlerWindowsPlugin"));
|
||||
ScreenRetrieverPluginRegisterWithRegistrar(
|
||||
|
@ -5,7 +5,6 @@
|
||||
list(APPEND FLUTTER_PLUGIN_LIST
|
||||
audioplayers_windows
|
||||
catcher
|
||||
metadata_god
|
||||
permission_handler_windows
|
||||
screen_retriever
|
||||
system_theme
|
||||
@ -15,6 +14,7 @@ list(APPEND FLUTTER_PLUGIN_LIST
|
||||
)
|
||||
|
||||
list(APPEND FLUTTER_FFI_PLUGIN_LIST
|
||||
metadata_god
|
||||
)
|
||||
|
||||
set(PLUGIN_BUNDLED_LIBRARIES)
|
||||
|
Loading…
Reference in New Issue
Block a user