Skip to content

Commit

Permalink
🚧🍃 More testing
Browse files Browse the repository at this point in the history
  • Loading branch information
MulverineX committed Sep 8, 2023
1 parent e1f1d2c commit 6a4d941
Show file tree
Hide file tree
Showing 10 changed files with 32 additions and 23 deletions.
4 changes: 2 additions & 2 deletions packages/client-flutter/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"

android {
namespace "org.refracturemedia.refracture_music"
namespace "media.refracture.refracture_music"
compileSdkVersion flutter.compileSdkVersion
ndkVersion flutter.ndkVersion

Expand All @@ -45,7 +45,7 @@ android {

defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "org.refracturemedia.refracture_music"
applicationId "media.refracture.refracture_music"
// You can update the following values to match your application needs.
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
minSdkVersion 21
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.refracturemedia.refracture_music
package media.refracture.refracture_music

import io.flutter.embedding.android.FlutterActivity

Expand Down
12 changes: 6 additions & 6 deletions packages/client-flutter/ios/Runner.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
SWIFT_VERSION = 5.0;
Expand All @@ -383,7 +383,7 @@
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic.RunnerTests;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic.RunnerTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
Expand All @@ -401,7 +401,7 @@
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic.RunnerTests;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic.RunnerTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner";
Expand All @@ -417,7 +417,7 @@
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic.RunnerTests;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic.RunnerTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Runner.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Runner";
Expand Down Expand Up @@ -544,7 +544,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
Expand All @@ -566,7 +566,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_OBJC_BRIDGING_HEADER = "Runner/Runner-Bridging-Header.h";
SWIFT_VERSION = 5.0;
Expand Down
15 changes: 13 additions & 2 deletions packages/client-flutter/lib/app/load_core.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import 'dart:async';
import 'dart:convert';
import 'dart:io';

import 'package:flutter_js/extensions/fetch.dart';
import 'package:sqflite_common_ffi/sqflite_ffi.dart';
import 'package:path/path.dart';
import 'package:path_provider/path_provider.dart';
Expand Down Expand Up @@ -51,7 +52,9 @@ Future<void> load() async {

final core = getJavascriptRuntime();

await core.evaluateAsync(bundle);
await core.enableFetch();

await core.enableHandlePromises();

initDatabase() async {

Expand All @@ -73,5 +76,13 @@ Future<void> load() async {
return db.query(query);
});

print(core);
core.onMessage('test', (message) {
print(message);
});

await core.evaluateAsync("""
var connection_data = ${json.encode({"address": "http://localhost:4829"})};
""");

await core.evaluateAsync(bundle);
}
2 changes: 1 addition & 1 deletion packages/client-flutter/linux/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ project(runner LANGUAGES CXX)
set(BINARY_NAME "refracture_music")
# The unique GTK application identifier for this application. See:
# https://wiki.gnome.org/HowDoI/ChooseApplicationID
set(APPLICATION_ID "org.refracturemedia.refracture_music")
set(APPLICATION_ID "media.refracture.refracture_music")

# Explicitly opt in to modern CMake behaviors to avoid warnings with recent
# versions of CMake.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic.RunnerTests;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic.RunnerTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/refracture_music.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/refracture_music";
Expand All @@ -398,7 +398,7 @@
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic.RunnerTests;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic.RunnerTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/refracture_music.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/refracture_music";
Expand All @@ -412,7 +412,7 @@
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic.RunnerTests;
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic.RunnerTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 5.0;
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/refracture_music.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/refracture_music";
Expand Down
4 changes: 2 additions & 2 deletions packages/client-flutter/macos/Runner/Configs/AppInfo.xcconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
PRODUCT_NAME = refracture_music

// The application's bundle identifier
PRODUCT_BUNDLE_IDENTIFIER = org.refracturemedia.refractureMusic
PRODUCT_BUNDLE_IDENTIFIER = media.refracture.refractureMusic

// The copyright displayed in application information
PRODUCT_COPYRIGHT = Copyright © 2023 org.refracturemedia. All rights reserved.
PRODUCT_COPYRIGHT = Copyright © 2023 media.refracture. All rights reserved.
4 changes: 2 additions & 2 deletions packages/client-flutter/windows/runner/Runner.rc
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,11 @@ BEGIN
BEGIN
BLOCK "040904e4"
BEGIN
VALUE "CompanyName", "org.refracturemedia" "\0"
VALUE "CompanyName", "media.refracture" "\0"
VALUE "FileDescription", "refracture_music" "\0"
VALUE "FileVersion", VERSION_AS_STRING "\0"
VALUE "InternalName", "refracture_music" "\0"
VALUE "LegalCopyright", "Copyright (C) 2023 org.refracturemedia. All rights reserved." "\0"
VALUE "LegalCopyright", "Copyright (C) 2023 media.refracture. All rights reserved." "\0"
VALUE "OriginalFilename", "refracture_music.exe" "\0"
VALUE "ProductName", "refracture_music" "\0"
VALUE "ProductVersion", VERSION_AS_STRING "\0"
Expand Down
4 changes: 1 addition & 3 deletions packages/core/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export class MusicCore {
playlists: ItemManager;

async startup () {
await this.session.startup();
// await this.session.startup();
}

constructor() {
Expand All @@ -41,8 +41,6 @@ export class MusicCore {

export const Music = new MusicCore();

console.log('[Music Core] Hello world!!!!!!!!');

declare function sendMessage(channel_name: string, message: any): any;

sendMessage('test', '[Music Core] Hello? *tap tap* Is this thing on?');
Expand Down
2 changes: 1 addition & 1 deletion scripts/common.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export type Releases = { pkg: string, assets: Record<string, string>, version: s
if (files.includes('webpack.config.js')) {
const CI = webpackCI(pkg_dir, release, releases, dist, pkg)

if (CI) changelog += CI
if (CI) changelog += await CI
}
}

Expand Down

0 comments on commit 6a4d941

Please sign in to comment.