Compare commits

...

23 Commits

Author SHA1 Message Date
Prateek Sunal
ae77a38846 fix: don't include build number for version 2024-09-29 16:05:02 +05:30
Prateek Sunal
d7946fbfc5 fix(linux): update version in appdata 2024-09-29 14:41:01 +05:30
Prateek Sunal
594843f48b fix(linux): metainfo package name 2024-09-29 04:08:16 +05:30
Prateek Sunal
4c5942016f fix: make release path generic 2024-09-28 22:15:53 +05:30
Prateek Sunal
39765dd802 fix: path for release 2024-09-28 22:13:25 +05:30
Prateek Sunal
bd9bcf607c Merge remote-tracking branch 'origin/main' into auth-linux-fixes 2024-09-28 21:42:51 +05:30
Prateek Sunal
30e26a815f chore: bump version to 4.0.3 2024-09-28 21:39:42 +05:30
Prateek Sunal
d873921422 chore: remove clip_ggml again 2024-09-28 21:37:31 +05:30
Prateek Sunal
c160afc6de [auth] fix x64 installer on arm64 Windows (#3502)
Portable x64 Ente Auth works on arm64 Windows, but the installer version
fails due to not supporting arm64. As per Inno Setup's documentation the
'x64' option will only allow installing on x64 Windows, changing to
'x64compatible' allows the x64 installer to work on arm64 as well.
2024-09-28 21:33:40 +05:30
Manav Rathi
f971b968af [desktop] Start next release cycle (#3515) 2024-09-28 19:35:58 +05:30
Manav Rathi
c8468efd20 [desktop] Start next release cycle 2024-09-28 19:21:49 +05:30
omove
6d969ab72a [auth] fix x64 install on arm64 Windows
Inno Setup's 'x64' option only allows install on x64 Windows, changing to 'x64compatible' allows x64 installation on arm64 and x64 Windows.
2024-09-28 00:05:59 -04:00
Prateek Sunal
528f503444 Merge remote-tracking branch 'origin/auth-linux-fixes' into auth-linux-fixes 2024-09-27 00:25:31 +05:30
Prateek Sunal
fa9d171287 Merge remote-tracking branch 'origin/main' into auth-linux-fixes 2024-09-27 00:25:15 +05:30
Prateek Sunal
43ba2ee2da Merge remote-tracking branch 'origin' into auth-linux-fixes 2024-09-27 00:24:12 +05:30
Prateek Sunal
3292655ff7 fix(deb): don't include build number in desktop file 'Version' 2024-09-27 00:23:14 +05:30
Prateek Sunal
484b05bdb2 fix: update receipe for linux and windows 2024-09-25 00:16:59 +05:30
Prateek Sunal
cdbcc93571 chore: lint fixes 2024-09-20 01:06:36 +05:30
Prateek Sunal
00415cb6fe chore: lint fixes 2024-09-19 01:04:47 +05:30
Prateek Sunal
6af1604026 fix(auth): add migrate naming changes for linux 2024-09-19 01:04:40 +05:30
Prateek Sunal
2e01a96477 fix: add xdg directories for linux 2024-09-18 20:25:27 +05:30
Prateek Sunal
fa8a8dd639 fix(auth[linux]): update binary name 2024-09-18 20:24:20 +05:30
Prateek Sunal
4a03388cf1 fix: update binary name 2024-09-18 19:50:59 +05:30
17 changed files with 185 additions and 85 deletions

View File

@@ -96,7 +96,8 @@ jobs:
- name: Build desktop app
run: |
flutter config --enable-linux-desktop
dart pub global activate flutter_distributor
# dart pub global activate flutter_distributor
dart pub global activate --source git https://github.com/prateekmedia/flutter_distributor --git-ref develop --git-path packages/flutter_distributor
flutter_distributor package --platform=linux --targets=deb --skip-clean
mv dist/**/*-*-linux.deb artifacts/ente-${{ github.ref_name }}-x86_64.deb
env:
@@ -104,7 +105,7 @@ jobs:
- name: Generate checksums and push to artifacts
run: |
sha256sum artifacts/ente-* > artifacts/sha256sum-apk-deb
sha256sum artifacts/ente-* > artifacts/sha256sum-apk-deb
- name: Create a draft GitHub release
uses: ncipollo/release-action@v1
@@ -125,65 +126,65 @@ jobs:
track: internal
build-fedora-etc:
runs-on: ubuntu-latest
runs-on: ubuntu-latest
defaults:
run:
working-directory: auth
defaults:
run:
working-directory: auth
steps:
- name: Checkout code and submodules
uses: actions/checkout@v4
with:
submodules: recursive
steps:
- name: Checkout code and submodules
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install Flutter ${{ env.FLUTTER_VERSION }}
uses: subosito/flutter-action@v2
with:
channel: "stable"
flutter-version: ${{ env.FLUTTER_VERSION }}
cache: true
- name: Install Flutter ${{ env.FLUTTER_VERSION }}
uses: subosito/flutter-action@v2
with:
channel: "stable"
flutter-version: ${{ env.FLUTTER_VERSION }}
cache: true
- name: Create artifacts directory
run: mkdir artifacts
- name: Create artifacts directory
run: mkdir artifacts
- name: Install dependencies for desktop build
run: |
sudo apt-get update -y
sudo apt-get install -y libsecret-1-dev libsodium-dev libwebkit2gtk-4.0-dev libfuse2 ninja-build libgtk-3-dev dpkg-dev pkg-config rpm patchelf libsqlite3-dev locate libayatana-appindicator3-dev libffi-dev libtiff5 xz-utils libarchive-tools
sudo updatedb --localpaths='/usr/lib/x86_64-linux-gnu'
- name: Install dependencies for desktop build
run: |
sudo apt-get update -y
sudo apt-get install -y libsecret-1-dev libsodium-dev libwebkit2gtk-4.0-dev libfuse2 ninja-build libgtk-3-dev dpkg-dev pkg-config rpm patchelf libsqlite3-dev locate libayatana-appindicator3-dev libffi-dev libtiff5 xz-utils libarchive-tools
sudo updatedb --localpaths='/usr/lib/x86_64-linux-gnu'
- name: Install appimagetool
run: |
wget -O appimagetool "https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage"
chmod +x appimagetool
mv appimagetool /usr/local/bin/
- name: Install appimagetool
run: |
wget -O appimagetool "https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage"
chmod +x appimagetool
mv appimagetool /usr/local/bin/
- name: Build desktop app
run: |
flutter config --enable-linux-desktop
# dart pub global activate flutter_distributor
dart pub global activate --source git https://github.com/prateekmedia/flutter_distributor --git-ref pacman --git-path packages/flutter_distributor
# Run below command if it is a beta or nightly
if [[ ${{ github.ref }} =~ beta|nightly ]]; then
flutter_distributor package --platform=linux --targets=pacman --skip-clean
mv dist/**/*-*-linux.pacman artifacts/ente-${{ github.ref_name }}-x86_64.pacman
fi
flutter_distributor package --platform=linux --targets=rpm --skip-clean
mv dist/**/*-*-linux.rpm artifacts/ente-${{ github.ref_name }}-x86_64.rpm
flutter_distributor package --platform=linux --targets=appimage --skip-clean
mv dist/**/*-*-linux.AppImage artifacts/ente-${{ github.ref_name }}-x86_64.AppImage
- name: Build desktop app
run: |
flutter config --enable-linux-desktop
# dart pub global activate flutter_distributor
dart pub global activate --source git https://github.com/prateekmedia/flutter_distributor --git-ref develop --git-path packages/flutter_distributor
# Run below command if it is a beta or nightly
if [[ ${{ github.ref }} =~ beta|nightly ]]; then
flutter_distributor package --platform=linux --targets=pacman --skip-clean
mv dist/**/*-*-linux.pacman artifacts/ente-${{ github.ref_name }}-x86_64.pacman
fi
flutter_distributor package --platform=linux --targets=rpm --skip-clean
mv dist/**/*-*-linux.rpm artifacts/ente-${{ github.ref_name }}-x86_64.rpm
flutter_distributor package --platform=linux --targets=appimage --skip-clean
mv dist/**/*-*-linux.AppImage artifacts/ente-${{ github.ref_name }}-x86_64.AppImage
- name: Generate checksums
run: sha256sum artifacts/ente-* >> artifacts/sha256sum-rpm-appimage
- name: Generate checksums
run: sha256sum artifacts/ente-* >> artifacts/sha256sum-rpm-appimage
- name: Create a draft GitHub release
uses: ncipollo/release-action@v1
with:
artifacts: "auth/artifacts/*"
draft: true
allowUpdates: true
updateOnlyUnreleased: true
- name: Create a draft GitHub release
uses: ncipollo/release-action@v1
with:
artifacts: "auth/artifacts/*"
draft: true
allowUpdates: true
updateOnlyUnreleased: true
build-windows:
runs-on: windows-latest
@@ -211,10 +212,11 @@ jobs:
- name: Build Windows installer
run: |
flutter config --enable-windows-desktop
dart pub global activate flutter_distributor
# dart pub global activate flutter_distributor
dart pub global activate --source git https://github.com/prateekmedia/flutter_distributor --git-ref develop --git-path packages/flutter_distributor
make innoinstall
flutter_distributor package --platform=windows --targets=exe --skip-clean
mv dist/**/ente_auth-*-windows-setup.exe artifacts/ente-${{ github.ref_name }}-installer.exe
mv dist/**/*-windows-setup.exe artifacts/ente-${{ github.ref_name }}-installer.exe
- name: Retain Windows EXE and DLLs
run: cp -r build/windows/x64/runner/Release ente-${{ github.ref_name }}-windows
@@ -307,7 +309,7 @@ jobs:
flutter config --enable-macos-desktop
dart pub global activate flutter_distributor
flutter_distributor package --platform=macos --targets=dmg --skip-clean
mv dist/**/ente_auth-*-macos.dmg artifacts/ente-${{ github.ref_name }}.dmg
mv dist/**/*-macos.dmg artifacts/ente-${{ github.ref_name }}.dmg
- name: Code sign DMG
run: |

View File

@@ -13,11 +13,11 @@ import 'package:ente_auth/models/key_attributes.dart';
import 'package:ente_auth/models/key_gen_result.dart';
import 'package:ente_auth/models/private_key_attributes.dart';
import 'package:ente_auth/store/authenticator_db.dart';
import 'package:ente_auth/utils/directory_utils.dart';
import 'package:ente_auth/utils/lock_screen_settings.dart';
import 'package:ente_crypto_dart/ente_crypto_dart.dart';
import 'package:flutter_secure_storage/flutter_secure_storage.dart';
import 'package:logging/logging.dart';
import 'package:path_provider/path_provider.dart';
import 'package:shared_preferences/shared_preferences.dart';
import 'package:sqflite_common_ffi/sqflite_ffi.dart';
import 'package:tuple/tuple.dart';
@@ -56,7 +56,6 @@ class Configuration {
static final _logger = Logger("Configuration");
String? _cachedToken;
late String _documentsDirectory;
late SharedPreferences _preferences;
String? _key;
String? _secretKey;
@@ -75,8 +74,7 @@ class Configuration {
_preferences = await SharedPreferences.getInstance();
sqfliteFfiInit();
_secureStorage = const FlutterSecureStorage();
_documentsDirectory = (await getApplicationDocumentsDirectory()).path;
_tempDirectory = "$_documentsDirectory/temp/";
_tempDirectory = (await DirectoryUtils.getDirectoryForInit()).path;
final tempDirectory = io.Directory(_tempDirectory);
try {
final currentTime = DateTime.now().microsecondsSinceEpoch;

View File

@@ -23,6 +23,7 @@ import 'package:ente_auth/store/code_store.dart';
import 'package:ente_auth/ui/tools/app_lock.dart';
import 'package:ente_auth/ui/tools/lock_screen.dart';
import 'package:ente_auth/ui/utils/icon_utils.dart';
import 'package:ente_auth/utils/directory_utils.dart';
import 'package:ente_auth/utils/lock_screen_settings.dart';
import 'package:ente_auth/utils/platform_util.dart';
import 'package:ente_auth/utils/window_protocol_handler.dart';
@@ -69,6 +70,10 @@ void main() async {
HttpOverrides.global = WindowsHttpOverrides();
}
if (Platform.isLinux) {
await DirectoryUtils.migrateNamingChanges();
}
if (PlatformUtil.isDesktop()) {
await windowManager.ensureInitialized();
await WindowListenerService.instance.init();

View File

@@ -1,12 +1,95 @@
import 'dart:io';
import 'package:logging/logging.dart';
import 'package:path/path.dart' as p;
import 'package:path_provider/path_provider.dart';
import 'package:xdg_directories/xdg_directories.dart';
class DirectoryUtils {
static Future<String> getDatabasePath(String databaseName) async => p.joinAll(
[
(await getApplicationDocumentsDirectory()).path,
"ente",
".$databaseName",
],
static final logger = Logger('DirectoryUtils');
static Future<String> getDatabasePath(String databaseName) async {
String? directoryPath;
if (Platform.isLinux) {
try {
directoryPath = dataHome.path;
} catch (e) {
logger.warning("Failed to get dataHome: $e");
}
}
directoryPath ??= (await getApplicationDocumentsDirectory()).path;
return p.joinAll(
[
directoryPath,
"enteauth",
".$databaseName",
],
);
}
static Future<Directory> getDirectoryForInit() async {
Directory? directory;
if (Platform.isLinux) {
try {
return cacheHome;
} catch (e) {
logger.warning("Failed to get cacheHome: $e");
}
}
directory ??= await getApplicationDocumentsDirectory();
return Directory(p.join(directory.path, "enteauthinit"));
}
static Future<Directory> getTempsDir() async {
return await getTemporaryDirectory();
}
static migrateNamingChanges() async {
final databaseFile = File(
p.join(
(await getApplicationDocumentsDirectory()).path,
"ente",
".ente.authenticator.db",
),
);
final offlineDatabaseFile = File(
p.join(
(await getApplicationDocumentsDirectory()).path,
"ente",
".ente.offline_authenticator.db",
),
);
final oldDataDir = Directory(
p.join(dataHome.path, "ente_auth"),
);
final newDir = Directory(
p.join(dataHome.path, "enteauth"),
);
await newDir.create(recursive: true);
if (await databaseFile.exists()) {
await databaseFile.rename(
p.join(newDir.path, ".ente.authenticator.db"),
);
}
if (await offlineDatabaseFile.exists()) {
await offlineDatabaseFile.rename(
p.join(newDir.path, ".ente.offline_authenticator.db"),
);
}
if (await oldDataDir.exists()) {
await oldDataDir.list().forEach((file) async {
await file.rename(p.join(newDir.path, p.basename(file.path)));
});
await oldDataDir.delete(recursive: true);
}
}
}

View File

@@ -10,6 +10,7 @@ import 'package:ente_auth/ui/components/dialog_widget.dart';
import 'package:ente_auth/ui/components/models/button_type.dart';
import 'package:ente_auth/ui/tools/debug/log_file_viewer.dart';
import 'package:ente_auth/utils/dialog_util.dart';
import 'package:ente_auth/utils/directory_utils.dart';
import 'package:ente_auth/utils/platform_util.dart';
import 'package:ente_auth/utils/share_utils.dart';
import 'package:ente_auth/utils/toast_util.dart';
@@ -146,7 +147,7 @@ Future<String> getZippedLogsFile(BuildContext context) async {
await dialog.show();
final logsPath = (await getApplicationSupportDirectory()).path;
final logsDirectory = Directory("$logsPath/logs");
final tempPath = (await getTemporaryDirectory()).path;
final tempPath = (await DirectoryUtils.getTempsDir()).path;
final zipFilePath =
"$tempPath/logs-${Configuration.instance.getUserID() ?? 0}.zip";
final encoder = ZipFileEncoder();

View File

@@ -4,7 +4,7 @@ project(runner LANGUAGES CXX)
# The name of the executable created for the application. Change this to change
# the on-disk name of your application.
set(BINARY_NAME "ente_auth")
set(BINARY_NAME "enteauth")
# The unique GTK application identifier for this application. See:
# https://wiki.gnome.org/HowDoI/ChooseApplicationID
set(APPLICATION_ID "io.ente.auth")

View File

@@ -1,4 +1,5 @@
display_name: Auth
display_name: Ente Auth
package_name: enteauth
license: GPLv3
metainfo: linux/packaging/ente_auth.appdata.xml
@@ -26,9 +27,9 @@ startup_notify: false
# include:
# - libcurl.so.4
include:
- libffi.so.8
- libtiff.so.5
- libjpeg.so.8
- libffi.so.8
- libtiff.so.5
- libjpeg.so.8
supported_mime_type:
- x-scheme-handler/enteauth
- x-scheme-handler/enteauth

View File

@@ -1,5 +1,7 @@
display_name: Auth
package_name: auth
display_name: Ente Auth
package_name: enteauth
include_build_number: false
maintainer:
name: Ente.io Developers
email: auth@ente.io

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop-application">
<id>ente_auth</id>
<id>enteauth</id>
<metadata_license>CC0-1.0</metadata_license>
<project_license>AGPL-3.0</project_license>
<name>Ente Auth</name>
@@ -10,7 +10,7 @@
<p>Auth has an app for every platform. Mobile, desktop and web. Your codes sync across all your devices, end-to-end encrypted.</p>
<p>Auth also comes with Offline mode, tags, icons, pins, import/export and more</p>
</description>
<launchable type="desktop-id">ente_auth.desktop</launchable>
<launchable type="desktop-id">enteauth.desktop</launchable>
<url type="homepage">https://ente.io/auth</url>
<screenshots>
<screenshot type="default">
@@ -18,10 +18,10 @@
</screenshot>
</screenshots>
<releases>
<release version="3.0.12" date="2024-06-17"/>
<release version="4.0.3" date="2024-09-29" />
</releases>
<provides>
<id>ente_auth.desktop</id>
<id>enteauth.desktop</id>
</provides>
<content_rating type="oars-1.0" />
<developer id="io.github.ente-io.ente">

View File

@@ -1,5 +1,5 @@
display_name: Auth
package_name: auth
display_name: Ente Auth
package_name: enteauth
maintainer:
name: Ente.io Developers
email: auth@ente.io

View File

@@ -6,6 +6,8 @@ packager: Ente.io Developers
packagerEmail: auth@ente.io
license: GPLv3
url: https://github.com/ente-io/ente
package_name: enteauth
include_build_number: false
display_name: Auth

View File

@@ -1792,7 +1792,7 @@ packages:
source: hosted
version: "0.4.2"
xdg_directories:
dependency: transitive
dependency: "direct main"
description:
name: xdg_directories
sha256: faea9dee56b520b55a566385b84f2e8de55e7496104adada9962e0bd11bcff1d

View File

@@ -1,6 +1,6 @@
name: ente_auth
description: ente two-factor authenticator
version: 4.0.2+402
version: 4.0.3+403
publish_to: none
environment:
@@ -105,6 +105,7 @@ dependencies:
uuid: ^4.2.2
win32: ^5.1.1
window_manager: ^0.4.2
xdg_directories: ^1.0.4
dependency_overrides:
flutter_secure_storage_linux:

View File

@@ -16,8 +16,8 @@ SetupIconFile={{SETUP_ICON_FILE}}
WizardStyle=modern
;PrivilegesRequired={{PRIVILEGES_REQUIRED}}
PrivilegesRequiredOverridesAllowed=dialog
ArchitecturesAllowed=x64
ArchitecturesInstallIn64BitMode=x64
ArchitecturesAllowed=x64compatible
ArchitecturesInstallIn64BitMode=x64compatible
UninstallDisplayIcon={app}\auth.exe
[Languages]

View File

@@ -1,4 +1,5 @@
app_id: 9E5F0C93-96A3-4DA9-AE52-1AA6339851FC
package_name: enteauth
publisher: ente.io
publisher_url: https://github.com/ente-io/ente
display_name: Ente Auth

View File

@@ -1,5 +1,9 @@
# CHANGELOG
## v1.7.6 (Unreleased)
- .
## v1.7.5
- Face grouping (beta).

View File

@@ -1,6 +1,6 @@
{
"name": "ente",
"version": "1.7.5",
"version": "1.7.6-beta",
"private": true,
"description": "Desktop client for Ente Photos",
"repository": "github:ente-io/photos-desktop",