Compare commits
6
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5043d9cdff | ||
|
|
7e36244478 | ||
|
|
157fc8d95b | ||
|
|
4d2f92b144 | ||
|
|
8e805316fb | ||
|
|
77051e5206 |
@@ -41,9 +41,7 @@ jobs:
|
|||||||
printf 'y\n' | "$ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager" --licenses > /dev/null
|
printf 'y\n' | "$ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager" --licenses > /dev/null
|
||||||
"$ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager" \
|
"$ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager" \
|
||||||
"platform-tools" \
|
"platform-tools" \
|
||||||
"platforms;android-35" \
|
|
||||||
"platforms;android-36" \
|
"platforms;android-36" \
|
||||||
"build-tools;35.0.0" \
|
|
||||||
"build-tools;36.0.0" \
|
"build-tools;36.0.0" \
|
||||||
"ndk;27.1.12297006"
|
"ndk;27.1.12297006"
|
||||||
mkdir -p carry-your-live/android/app
|
mkdir -p carry-your-live/android/app
|
||||||
|
|||||||
@@ -1,36 +0,0 @@
|
|||||||
name: Build Desktop (deb)
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches: [main]
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Set up Node
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: 22
|
|
||||||
|
|
||||||
- name: Install JS dependencies
|
|
||||||
working-directory: carry-your-live
|
|
||||||
run: npm ci
|
|
||||||
|
|
||||||
- name: Export web bundle
|
|
||||||
working-directory: carry-your-live
|
|
||||||
run: npx expo export --platform web
|
|
||||||
|
|
||||||
- name: Build deb package
|
|
||||||
working-directory: carry-your-live
|
|
||||||
run: npx electron-builder --linux deb --config electron-builder.config.js
|
|
||||||
|
|
||||||
- name: Upload deb
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: carry-your-live-desktop-deb
|
|
||||||
path: carry-your-live/desktop-build/*.deb
|
|
||||||
@@ -10,6 +10,7 @@ permissions:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
release:
|
release:
|
||||||
|
needs: build
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
@@ -17,6 +18,12 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Download APK artifact
|
||||||
|
uses: actions/download-artifact@v4
|
||||||
|
with:
|
||||||
|
name: carry-your-live-release
|
||||||
|
path: .
|
||||||
|
|
||||||
- name: Compute next version
|
- name: Compute next version
|
||||||
id: version
|
id: version
|
||||||
run: |
|
run: |
|
||||||
@@ -53,4 +60,5 @@ jobs:
|
|||||||
tag_name: ${{ steps.version.outputs.next }}
|
tag_name: ${{ steps.version.outputs.next }}
|
||||||
name: ${{ steps.version.outputs.next }}
|
name: ${{ steps.version.outputs.next }}
|
||||||
body: ${{ steps.changelog.outputs.body }}
|
body: ${{ steps.changelog.outputs.body }}
|
||||||
|
files: ./app-release.apk
|
||||||
generate_release_notes: false
|
generate_release_notes: false
|
||||||
@@ -63,7 +63,6 @@ screenOptions={{
|
|||||||
key={route.name}
|
key={route.name}
|
||||||
style={[
|
style={[
|
||||||
styles.tabItem,
|
styles.tabItem,
|
||||||
focused && styles.tabItemActive,
|
|
||||||
{ backgroundColor: focused ? theme.accentSoft : 'transparent' },
|
{ backgroundColor: focused ? theme.accentSoft : 'transparent' },
|
||||||
]}
|
]}
|
||||||
onPress={() => props.navigation.navigate(route.name as never)}
|
onPress={() => props.navigation.navigate(route.name as never)}
|
||||||
@@ -122,9 +121,6 @@ const styles = StyleSheet.create({
|
|||||||
borderRadius: 8,
|
borderRadius: 8,
|
||||||
minWidth: 70,
|
minWidth: 70,
|
||||||
},
|
},
|
||||||
tabItemActive: {
|
|
||||||
backgroundColor: theme.accentSoft,
|
|
||||||
},
|
|
||||||
rippleContainer: {
|
rippleContainer: {
|
||||||
width: 44,
|
width: 44,
|
||||||
height: 44,
|
height: 44,
|
||||||
|
|||||||
@@ -10,7 +10,6 @@ import { useEffect } from 'react';
|
|||||||
import { requestQuickAddFocus } from '@/utils/quickAddFocus';
|
import { requestQuickAddFocus } from '@/utils/quickAddFocus';
|
||||||
import { registerForPushNotificationsAsync, setupNotificationChannels, addNotificationResponseReceivedListener, removeNotificationSubscription } from '@/services/pushNotifications';
|
import { registerForPushNotificationsAsync, setupNotificationChannels, addNotificationResponseReceivedListener, removeNotificationSubscription } from '@/services/pushNotifications';
|
||||||
import * as Notifications from 'expo-notifications';
|
import * as Notifications from 'expo-notifications';
|
||||||
import { Platform } from 'react-native';
|
|
||||||
|
|
||||||
Notifications.setNotificationHandler({
|
Notifications.setNotificationHandler({
|
||||||
handleNotification: async () => ({
|
handleNotification: async () => ({
|
||||||
@@ -57,31 +56,18 @@ function RootNavigator() {
|
|||||||
Linking.getInitialURL().then(handleUrl).catch(() => {});
|
Linking.getInitialURL().then(handleUrl).catch(() => {});
|
||||||
const subscription = Linking.addEventListener('url', ({ url }) => handleUrl(url));
|
const subscription = Linking.addEventListener('url', ({ url }) => handleUrl(url));
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
const handleKeyDown = (event: KeyboardEvent) => {
|
const handleKeyDown = (event: KeyboardEvent) => {
|
||||||
if (event.key === 'Escape') {
|
if (event.key === 'Escape') {
|
||||||
const router = useRouter();
|
|
||||||
router.back();
|
router.back();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
window.addEventListener('keydown', handleKeyDown);
|
window.addEventListener('keydown', handleKeyDown);
|
||||||
return () => window.removeEventListener('keydown', handleKeyDown);
|
|
||||||
}, []);
|
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
const unsubscribe = Linking.addEventListener('url', ({ url }) => {
|
|
||||||
if (!url || !url.includes('://quick-add')) return;
|
|
||||||
router.replace('/(tabs)');
|
|
||||||
requestQuickAddFocus();
|
|
||||||
});
|
|
||||||
|
|
||||||
return () => unsubscribe();
|
|
||||||
}, []);
|
|
||||||
|
|
||||||
return () => {
|
return () => {
|
||||||
subscription.remove();
|
subscription.remove();
|
||||||
removeNotificationSubscription(responseListener);
|
removeNotificationSubscription(responseListener);
|
||||||
|
window.removeEventListener('keydown', handleKeyDown);
|
||||||
};
|
};
|
||||||
}, [router]);
|
}, [router]);
|
||||||
|
|
||||||
|
|||||||
@@ -220,5 +220,9 @@ export const migrations = schemaMigrations({
|
|||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
toVersion: 21,
|
||||||
|
steps: [],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -11,7 +11,6 @@ import RepeatProfile from '@/models/RepeatProfile';
|
|||||||
import Friendship from '@/models/Friendship';
|
import Friendship from '@/models/Friendship';
|
||||||
import { TombstoneEntity } from '@/models/Tombstone';
|
import { TombstoneEntity } from '@/models/Tombstone';
|
||||||
import { fetchPendingTombstones, removeTombstonesInBatch } from './tombstones';
|
import { fetchPendingTombstones, removeTombstonesInBatch } from './tombstones';
|
||||||
import { useOnline } from '@/hooks/useOnline';
|
|
||||||
|
|
||||||
const LAST_PULLED_AT_KEY = 'sync:lastPulledAt';
|
const LAST_PULLED_AT_KEY = 'sync:lastPulledAt';
|
||||||
const LAST_PUSHED_AT_KEY = 'sync:lastPushedAt';
|
const LAST_PUSHED_AT_KEY = 'sync:lastPushedAt';
|
||||||
@@ -96,7 +95,7 @@ export async function runSync(): Promise<SyncResult> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// If offline, mark timestamps and return early - changes will sync on next foreground launch
|
// If offline, mark timestamps and return early - changes will sync on next foreground launch
|
||||||
const isCurrentlyOnline = await useOnline();
|
const isCurrentlyOnline = navigator.onLine;
|
||||||
if (!isCurrentlyOnline) {
|
if (!isCurrentlyOnline) {
|
||||||
const now = Date.now();
|
const now = Date.now();
|
||||||
await setLastPulledAt(now);
|
await setLastPulledAt(now);
|
||||||
|
|||||||
Reference in New Issue
Block a user