Experiment: Start integrating supabase

This commit is contained in:
Vishesh Handa
2021-08-16 12:44:29 +02:00
parent c7fb3b792e
commit f631b99aa5
6 changed files with 108 additions and 4 deletions

View File

@ -78,12 +78,20 @@ limitations under the License.
android:name=".UriReceiverActivity"
android:parentActivityName=".MainActivity">
<intent-filter>
<!-- Used for "Automatic Git Setup" -->
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="gitjournal" android:host="login.oauth2" />
<!-- Triggering URI would be gitjournal://login.oauth2 -->
</intent-filter>
<intent-filter>
<!-- Used for logging into the App -->
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="gitjournal-identity" android:host="login-callback" />
</intent-filter>
</activity>
<meta-data android:name="flutterEmbedding" android:value="2" />

View File

@ -46,6 +46,7 @@
<key>CFBundleURLSchemes</key>
<array>
<string>gitjournal</string>
<string>gitjournal-identity</string>
</array>
</dict>
<dict>

View File

@ -12,6 +12,7 @@ import 'package:stack_trace/stack_trace.dart';
import 'package:gitjournal/app.dart';
import 'package:gitjournal/error_reporting.dart';
import 'package:gitjournal/settings/app_settings.dart';
import 'package:supabase_flutter/supabase_flutter.dart';
void main() async {
WidgetsFlutterBinding.ensureInitialized();
@ -21,6 +22,14 @@ void main() async {
LevelMessages.warning,
];
// FIXME: Does this need to be done over here?
await Supabase.initialize(
url: 'https://tefpmcttotopcptdivsj.supabase.co',
anonKey:
'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJyb2xlIjoiYW5vbiIsImlhdCI6MTYyODA2NDAyNiwiZXhwIjoxOTQzNjQwMDI2fQ.xAN-giE3m1MPjoRkkdcg_0NJueLH0_L-Wu-V0TSnpwU',
authCallbackUrlHostname: 'login-callback',
);
var pref = await SharedPreferences.getInstance();
AppSettings.instance.load(pref);

View File

@ -26,6 +26,7 @@
<key>CFBundleURLSchemes</key>
<array>
<string>gitjournal</string>
<string>gitjournal-identity</string>
</array>
</dict>
</array>

View File

@ -605,6 +605,13 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0"
gotrue:
dependency: transitive
description:
name: gotrue
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.0"
graphs:
dependency: transitive
description:
@ -626,6 +633,20 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "0.7.0"
hive:
dependency: transitive
description:
name: hive
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.4"
hive_flutter:
dependency: transitive
description:
name: hive_flutter
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0"
http:
dependency: "direct main"
description:
@ -740,6 +761,13 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "4.0.1"
jwt_decode:
dependency: transitive
description:
name: jwt_decode
url: "https://pub.dartlang.org"
source: hosted
version: "0.3.1"
launch_review:
dependency: "direct main"
description:
@ -923,7 +951,7 @@ packages:
name: path_provider
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.1"
version: "2.0.2"
path_provider_linux:
dependency: transitive
description:
@ -1015,6 +1043,13 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "1.5.0"
postgrest:
dependency: transitive
description:
name: postgrest
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.5"
process:
dependency: transitive
description:
@ -1071,6 +1106,13 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "3.0.1"
realtime_client:
dependency: transitive
description:
name: realtime_client
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.8"
recase:
dependency: "direct main"
description:
@ -1286,6 +1328,13 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "1.10.0"
storage_client:
dependency: transitive
description:
name: storage_client
url: "https://pub.dartlang.org"
source: hosted
version: "0.0.4"
stream_channel:
dependency: transitive
description:
@ -1307,6 +1356,20 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0"
supabase:
dependency: transitive
description:
name: supabase
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.0"
supabase_flutter:
dependency: "direct main"
description:
name: supabase_flutter
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.0"
synchronized:
dependency: "direct main"
description:
@ -1384,6 +1447,27 @@ packages:
url: "https://pub.dartlang.org"
source: hosted
version: "1.3.0"
uni_links:
dependency: transitive
description:
name: uni_links
url: "https://pub.dartlang.org"
source: hosted
version: "0.5.1"
uni_links_platform_interface:
dependency: transitive
description:
name: uni_links_platform_interface
url: "https://pub.dartlang.org"
source: hosted
version: "1.0.0"
uni_links_web:
dependency: transitive
description:
name: uni_links_web
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.0"
universal_io:
dependency: "direct main"
description:
@ -1397,7 +1481,7 @@ packages:
name: url_launcher
url: "https://pub.dartlang.org"
source: hosted
version: "6.0.3"
version: "6.0.9"
url_launcher_linux:
dependency: transitive
description:
@ -1418,7 +1502,7 @@ packages:
name: url_launcher_platform_interface
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.2"
version: "2.0.4"
url_launcher_web:
dependency: transitive
description:
@ -1467,7 +1551,7 @@ packages:
name: web_socket_channel
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.0"
version: "2.1.0"
webkit_inspection_protocol:
dependency: transitive
description:

View File

@ -83,6 +83,7 @@ dependencies:
universal_io: ^2.0.4
sprintf: ^6.0.0
recase: ^4.0.0
supabase_flutter: ^0.1.0
dev_dependencies:
#flutter_driver: