GithubHelp home page GithubHelp logo

gskinnerteam / flokk Goto Github PK

View Code? Open in Web Editor NEW
1.4K 42.0 270.0 12.58 MB

A fresh and modern Google Contacts manager that integrates with GitHub and Twitter.

Home Page: https://flokk.app

License: BSD 2-Clause "Simplified" License

Dart 89.63% CMake 2.45% C 0.37% C++ 3.27% Swift 0.24% Ruby 0.22% HTML 3.70% JavaScript 0.12%

flokk's Introduction

Flokk

A fresh and modern Google Contacts manager that integrates with GitHub and Twitter.

Demo Builds

Contributing

You are invited to improve Flokk Contacts! Submitting pull requests, answering and asking questions in the Issues page, and updating documentation are all ways you can contribute to the app.

Please note that although we are monitoring GitHub issues, we aren't actively maintaining the codebase, so community involvement and contributions are really appreciated going forward. We're aiming to review pull requests on a weekly basis.

Getting Set Up

Demo Builds

To preview the app you can download from the app store on your device by visiting: https://flutter.gskinner.com/folio/#g-download

Installation

If you're new to Flutter the first thing you'll need is to follow the setup instructions.

Once Flutter is setup, you can use the latest stable channel:

  • Run flutter channel stable
  • Run flutter upgrade

Once you're on dev and desktop is enabled, you're ready to run the app:

  • flutter run -d windows
  • flutter run -d macos
  • flutter run -d linux
  • flutter run -d android
  • flutter run -d ios
  • flutter run -d web

If you re-start your IDE, you should also see a new launch option for your current desktop platform.

Client Keys

Google Sign In is required in order to run the app (unless running with cached data). The app uses the Google People API, and you will need to provide your own Google OAuth 2 client credentials in the /lib/api_keys.dart file.

Follow the instructions here to enable the People API and create credentials:

To optionally fetch social data for your contacts, add your own API keys for those as well:

Although the Twitter and GitHub keys are optional, they are recommended. Otherwise the app will not be able to fetch tweets and GitHub calls will be subject to a rate limit (https://developer.github.com/v3/#rate-limiting).

Web Builds

If you're building for web:

  • Edit /web/index.html to include your web credentials (web client Id) <meta name="google-signin-client_id" content="YOUR_GOOGLE_SIGN_IN_OAUTH_CLIENT_ID.apps.googleusercontent.com">.
  • This is needed for Google Sign In to work on web builds. For more details, see https://pub.dev/packages/google_sign_in_web

CORS Proxy

For Twitter support to work on web builds, it is necessary to use a CORS proxy. You can set up a proxy on your own domain, or else run a localhost instance with proxy/app.js.

If setting up on your domain, ensure you have enabled https (https://letsencrypt.org/). Once you have the security certificate, edit proxy/app.js and insert your cert and key. This is not necessary if running a localhost instance.

After the proxy is set up, edit services/twitter_rest_service.dart to point to your running proxy instance (e.g. "https://my-proxy.com", "http://localhost", etc.)

For more information, see https://github.com/Rob--W/cors-anywhere

Running With Cached Data

If you simply want to see the app running, it is possible to run the app using cached data:

  • Run the app at least once, to create your data folders
  • Extract the contents of /sample_data.zip to the newly created data folder on your machine:
    • Windows: \Users\[USER]\AppData\Roaming\flokk
    • Linux: $HOME/.local/share/flokk-contacts
    • macOS: /Users/[USER]/Library/Containers/app.flokk/Data/Library/Application Support/app.flokk
  • Overwrite any files that are there
  • Launch the app again, it should now sign in, and load with existing data.
  • If you sign out, your saved data will be wiped and you will need to repeat the process.

Note: This is meant as a 'read-only' mode so you can quickly explore all the widgets and features of the app. Updates, deletes, etc are not expected to work.

Test & Build

Debug Builds

  • Use flutter run -d DEVICE_ID to deploy a test build
  • To get a list of available DEVICE_ID, use flutter run
  • Typical values are: windows, linux, macos, chrome
  • Add --release to deploy an optimized build

Release Builds

  • Use flutter build PACKAGE_TYPE to build a release package
  • To get a list of available PACKAGE_TYPE, use flutter build
  • Typical values are windows, linux, apk, ios
  • In order to build the snap package one must first run lxd init on your system if you haven't already. ** Then execute snapcraft --use-lxd to create the snap from the flutter build

Force Log In

  • The app uses a kForceWebLogin flag to force release builds to skip the oauth screen.
  • Add --dart-define=flokk.forceWebLogin=true to your build command to enable
  • E.g. flutter build web --dart-define=flokk.forceWebLogin=true

Desktop Runners

The /linux and /windows folders contain modifications and should not be upgraded to upstream without first verifying that each plugin works correctly with the new upstream code and any modifications are made.

Since the desktop runners for this project may contain modifications, upgrades should not be made without first verifying that every plugin and embedder can be upgraded and that they remain compatible after an upgrade. Hopefully this will not be as much of an issue once Flutter's desktop support becomes more mature.

--

Happy Flokking!

flokk's People

Contributors

appflowy avatar benbb96 avatar cenomla avatar eddie-at-work avatar esdotdev avatar trevordunn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

flokk's Issues

Unable to copy text

Hey,
I'm trying to make a flutter desktop app for Linux and in a text field, I'm not able to use any keyboard shortcuts for eg, ctrl+c for copy or ctrl+a for all selection. Can you help me with this?

Fails to open up on macos Big Sur

“Flokk Contacts” can’t be opened because Apple cannot check it for malicious software.
This software needs to be updated. Contact the developer for more information.

This is the message which pops up 👆. I have tried changing my security preferences but still shows the same message.

Add support for adding ActivityPub profiles

ActivityPub is a federated and open alternative to Twitter, using a W3C-recommended protocol. Multiple implementations exist such as Mastodon, Pleroma, PeerTube, LearnAwesome.org etc. Supporting this will enable integration with many, many networks in just one go.

Additional Options for other Call integration

With Windows or Android it would be possible to use nativ call Apps.
This could be archived by using the tel uri scheme or CTI/TAPI.
I would prefere, if it had both options. Some call Apps work with the tel uri scheme some with CTI/TAPI.

Segmentation fault on Debian Testing

Installed using sudo snap install flokk-contacts and ran:

$ flokk-contacts
[ERROR:flutter/shell/platform/embedder/embedder_surface_gl.cc(108)] Could not create a resource context for async texture uploads. Expect degraded performance. Set a valid make_resource_current callback on FlutterOpenGLRendererConfig.
[ERROR:flutter/shell/platform/embedder/embedder_surface_gl.cc(108)] Could not create a resource context for async texture uploads. Expect degraded performance. Set a valid make_resource_current callback on FlutterOpenGLRendererConfig.
flutter: /##################################################
flutter: [BootstrapCommand]
flutter: DataDir is: /home/amituttam/snap/flokk-contacts/11/.local/share/flokk-contacts
flutter: ##################################################
flutter: FileSystemException: Cannot open file, path = '/home/amituttam/snap/flokk-contacts/11/.local/share/flokk-contacts/auth.dat' (OS Error: No such file or directory, errno = 2)
flutter: FileSystemException: Cannot open file, path = '/home/amituttam/snap/flokk-contacts/11/.local/share/flokk-contacts/twitter.dat' (OS Error: No such file or directory, errno = 2)
flutter: FileSystemException: Cannot open file, path = '/home/amituttam/snap/flokk-contacts/11/.local/share/flokk-contacts/github.dat' (OS Error: No such file or directory, errno = 2)
flutter: FileSystemException: Cannot open file, path = '/home/amituttam/snap/flokk-contacts/11/.local/share/flokk-contacts/contacts.dat' (OS Error: No such file or directory, errno = 2)
flutter: #########################
flutter: BootstrapCommand Complete
flutter: #########################
Segmentation fault

Note that the application seems to launch fine but when I press alt key it crashes:

$ dmesg
[ 2025.806582] flokk-contacts[11632]: segfault at f0 ip 00007f997b20b1f2 sp 00007fff63565768 error 4 in libgdk-3.so.0.2200.30[7f997b1c4000+eb000]

No support for Wayland

#8 was closed a while ago, when Flutter didn't support Wayland. It now does, but Flokk does not, still.

It may just need a rebuild to pull in the latest engine :)

Cannot resize on Gnome with scaling

I currently use 200% scaling in Gnome. When I launch Flokk, it is larger than my available screen and cannot be resized.

If I switch the scaling back to 100% and launch Flokk, it appears smaller than my screen and I am able to resize it.

win7 not work

need "api-ms-win-core-rtlsupport-l1-2-0.dll",but I can't fount it.do you konw?

Couldn't `flutter pub get`

Hello,
After flutter pub get I've got such error:

Because dartx >=0.2.0 depends on collection >=1.14.11 <1.15.0 and every version of flutter from sdk depends on collection 1.15.0-nullsafety, dartx >=0.2.0 is incompatible with flutter from sdk.
So, because flokk depends on both flutter any from sdk and dartx ^0.4.0, version solving failed.
pub get failed (1; So, because flokk depends on both flutter any from sdk and dartx ^0.4.0, version solving failed.)

I have

$ flutter --version
Flutter 1.20.0-8.0.pre.125 • channel master • https://github.com/flutter/flutter.git
Framework • revision 9c4a5ef1ed (9 hours ago) • 2020-07-15 21:41:27 +0100
Engine • revision 774ae0313d
Tools • Dart 2.9.0 (build 2.9.0-21.0.dev 89fe12b12a)

SampleData: Something when wrong with the authorization.....

I believe I've understood the instructions....

git clone -n https://github.com/flutter/flutter.git -b master
cd flutter
git checkout 9c3f0faa6d
cd flokk_src
(run once to create data dirs)
flutter run -d linux
unzip ../sample_data.zip -d ~/.local/share/flokk-contacts/
flutter run -d linux

Get:
Connection Error -
Something went wrong with authorization

Sorry, but I don't know how to fix, or what I did wrong
On my Ubuntu Mate 20.04 it's reproducible.
J

default country code for call integration

if my contact has a phone number: (510) 555-1211, when i click the link it uses the first 2 numbers as country code. +51 05551212

other times i get an error that the phone number is malformed.

it would be nice to have an option to default to a specific country code...

Question: Does static instance of context make a perf difference

I noticed that the AbstractCommand checks to see if the context passed into the constructor matches a previously passed in context.

AbstractCommand(BuildContext c) {
/// Get root context
/// If we're passed a context that is known to be root, skip the lookup, it will throw an error otherwise.
context = (c == _lastKnownRoot) ? c : Provider.of(c, listen: false);
_lastKnownRoot = context;
}

Wondering whether this done purely for perf gains, and if so how noticeable is the difference?

Running with cached data for web target

The README doesn't mention if this is supported or not. When I give it a try I am met with the following errors:

An Observatory debugger and profiler on Chrome is available at: http://127.0.0.1:59442/WqBomgPWUuI=
Flutter Web Bootstrap: Auto
[ERROR] Exception: app.settings not found
/##################################################
[BootstrapCommand]
##################################################
[ERROR] Exception: auth.dat not found
[ERROR] Exception: twitter.dat not found
[ERROR] Exception: github.dat not found
[ERROR] Exception: contacts.dat not found
[RefreshAuthTokensCommand] Refreshing with token:
1//06TVHZgXSuhqfCgYIARAAGAYSNwF-L9IrPuIVzs3JSYt1xzWSXnK8Vx5cUPgYrEN4FouCtOy1j01hosURDlWogymULquE-e1lXm0
Error: Exception: error-log.txt not found

Is it possible to extract sample_data.zip somewhere to be able to use cached data?

Resizing window stop working.

ElementaryOS Linux.

Steps to reproduce:

Start app. Wait for login and contacts list to be displayed.
Use double click/Window manager controls to maximize & minimize.
It works only one cycle of maximize/minimize then stop responding.

sqflite issues

Hi, wanna ask how do u guys implement solved the SQL problem in flokk on desktop version. AFAIK, there were no such plugin for sqflite for now in flutter.

Add support for nnbd

Create a new branch and begin migrating to non-null.

We can then create child-branches and land those as PR's against the main branch.

Editing Contact: Shift+Tab don't work

When editing a contact, I can move to next text edit form control with Tab but Shif+Tab does not move to previous widget.

OS: Linux, Elementaryos latest.

Default window size too large in Linux build

The file https://github.com/gskinnerTeam/flokk/blob/master/flokk_src/linux/window_configuration.cc sets the window size to 1366x768. About half of Ubuntu users, according to https://ubuntu.com/desktop/statistics , have a desktop resolution of 1366x768 or less. As the app opens in windowed mode (and taking window decorators and desktop docks into account), all of those users are going to find the window overflows the screen. There is no "maximise" button enabled to resize to the actual screen size.

In my case, the "Privacy Policy" link opens off-screen when the app starts up. That leaves a bad impression. The app should open in a smaller (resizable) window or should auto-detect resolution and adjust accordingly.

Where do i place the sample data?

I'm currently using vscode on windows to launch the web app.
As per the README to use cache data, I copy the contents of "sample_data.zip" to "C:\Users<USER>\AppData\Roaming\flokk"

However, i got some error and exception:

[ERROR] Exception: app.settings not found
...............
Error: Exception: error-log.txt not found
.............

Am i missing any steps?

Cannot build macos

Hi, I tried to run MacOS app with cache, but receive this error.

Building macOS application...
2023-05-16 16:52:15.818 Flokk Contacts[46296:6999285] Failed to find path for "flutter_assets"
2023-05-16 16:52:15.819 Flokk Contacts[46296:6999285] Failed to find path for "flutter_assets"
embedder.cc (1601): 'FlutterEngineInitialize' returned 'kInvalidArguments'. The assets path in the Flutter project arguments was missing.
2023-05-16 16:52:15.819 Flokk Contacts[46296:6999285] Failed to initialize Flutter engine: error 2

Unable to launch - opens a broken transparent window

OS - Ubuntu 20.04
Installed via: snap

Screenshot:

image

CLI output:

~ > flokk-contacts 
/bin/bash: warning: setlocale: LC_ALL: cannot change locale (en_GB.UTF-8)
libEGL warning: DRI2: failed to authenticate
[ERROR:flutter/shell/platform/embedder/embedder_surface_gl.cc(108)] Could not create a resource context for async texture uploads. Expect degraded performance. Set a valid make_resource_current callback on FlutterOpenGLRendererConfig.
[ERROR:flutter/shell/platform/embedder/embedder_surface_gl.cc(108)] Could not create a resource context for async texture uploads. Expect degraded performance. Set a valid make_resource_current callback on FlutterOpenGLRendererConfig.
flutter: /##################################################
flutter: [BootstrapCommand]
flutter: DataDir is: /home/tomw/snap/flokk-contacts/11/.local/share/flokk-contacts
flutter: ##################################################
flutter: FileSystemException: Cannot open file, path = '/home/tomw/snap/flokk-contacts/11/.local/share/flokk-contacts/auth.dat' (OS Error: No such file or directory, errno = 2)
flutter: FileSystemException: Cannot open file, path = '/home/tomw/snap/flokk-contacts/11/.local/share/flokk-contacts/twitter.dat' (OS Error: No such file or directory, errno = 2)
flutter: FileSystemException: Cannot open file, path = '/home/tomw/snap/flokk-contacts/11/.local/share/flokk-contacts/github.dat' (OS Error: No such file or directory, errno = 2)
flutter: FileSystemException: Cannot open file, path = '/home/tomw/snap/flokk-contacts/11/.local/share/flokk-contacts/contacts.dat' (OS Error: No such file or directory, errno = 2)
flutter: #########################
flutter: BootstrapCommand Complete
flutter: #########################

build fails with KeyEventResult type errors

(latest flutter on ubuntu)

> flutter run -d linux
Running "flutter pub get" in flokk_src...                          15.8s
Launching lib/main.dart on Linux in debug mode...
ERROR: lib/styled_components/styled_text_input.dart:149:20: Error: A value of type 'bool' can't be returned from a function with return type 'KeyEventResult'.
ERROR:  - 'KeyEventResult' is from 'package:flutter/src/widgets/focus_manager.dart' ('/home/dym/snap/flutter/common/flutter/packages/flutter/lib/src/widgets/focus_manager.dart').
ERROR:             return true;
ERROR:                    ^
ERROR: lib/styled_components/styled_text_input.dart:152:16: Error: A value of type 'bool' can't be returned from a function with return type 'KeyEventResult'.
ERROR:  - 'KeyEventResult' is from 'package:flutter/src/widgets/focus_manager.dart' ('/home/dym/snap/flutter/common/flutter/packages/flutter/lib/src/widgets/focus_manager.dart').
ERROR:         return false;
ERROR:                ^
ERROR: lib/views/search/search_bar_view.dart:46:14: Error: The argument type 'bool Function(FocusNode, RawKeyEvent)' can't be assigned to the parameter type 'KeyEventResult Function(FocusNode, RawKeyEvent)?'.
ERROR:  - 'FocusNode' is from 'package:flutter/src/widgets/focus_manager.dart' ('/home/dym/snap/flutter/common/flutter/packages/flutter/lib/src/widgets/focus_manager.dart').
ERROR:  - 'RawKeyEvent' is from 'package:flutter/src/services/raw_keyboard.dart' ('/home/dym/snap/flutter/common/flutter/packages/flutter/lib/src/services/raw_keyboard.dart').
ERROR:  - 'KeyEventResult' is from 'package:flutter/src/widgets/focus_manager.dart' ('/home/dym/snap/flutter/common/flutter/packages/flutter/lib/src/widgets/focus_manager.dart').
ERROR:       onKey: _handleKeyPress,
ERROR:              ^
Building Linux application...
Exception: Build process failed

Provide an AppImage

AppImage is a great packaging format for Linux, it allows creating a portable bundle that can be executed in almost every GNU/Linux distribution. It keeps the developer (you) in control of the libraries that are used by your app at runtime and it doesn't require anything to be installed previously in order to install your app.

I'm the developer of appimage-builder and would gladly help you making an AppImage recipe for flutter apps.

Theme Switcher

When switching themes, the Contact list tile background color changes instantly, but the rest of the app fades to the appropriate colors.

Empty window on Ubuntu 20.04

Just installed the snap version. After starting the app, I can only see an empty window. When I start the app from terminal I get this:

michal@michal-laptop:~$ flokk-contacts 

(flokk-contacts:3482): Gdk-WARNING **: 09:52:42.440: ../../../../../gdk/x11/gdkwindow-x11.c:5579 drawable is not a native X11 window

** (flokk-contacts:3482): WARNING **: 09:52:42.450: Failed to start Flutter engine: Failed to create EGL surface: Bad Native Window

Loading only 1000 out of 2566 contacts

I am only getting 1000 contacts. I think there is a error in "load more" mechanism. Logs:

Restarted application in 703ms.
flutter: /##################################################
flutter: [BootstrapCommand]
flutter: DataDir is: C:\Users\jrvid\AppData\Roaming\flokk
flutter: ##################################################
flutter: [RefreshAuthTokensCommand] Refreshing with token: <<>>
flutter: Response: 200 / {
"access_token": "<<>>",
"expires_in": 3599,
"scope": "https://www.googleapis.com/auth/userinfo.email https://www.googleapis.com/auth/contacts",
"token_type": "Bearer",
"id_token": "<<>>"
}
flutter: Refresh token success. authKey = <<>>, refreshToken = <<>>
flutter: [RefreshContactsCommand]
flutter: [RefreshAuthTokensCommand] Refreshing with token: <<>>
flutter: REQUEST: https://people.googleapis.com/v1/people/me/connections?access_token=<<>>&personFields=addresses,ageRanges,biographies,birthdays,braggingRights,coverPhotos,emailAddresses,events,genders,imClients,interests,locales,memberships,metadata,names,nicknames,occupations,organizations,phoneNumbers,photos,relations,relationshipInterests,relationshipStatuses,residences,sipAddresses,skills,taglines,urls,userDefined&sortOrder=FIRST_NAME_ASCENDING&pageSize=2000&requestSyncToken=true /// RESPONSE: 200
flutter: token: <<>> 1000 out of 2566
flutter: [RefreshContactGroupsCommand]
flutter: [RefreshAuthTokensCommand] Refreshing with token: <<>>
flutter: REQUEST: https://people.googleapis.com/v1/contactGroups?access_token=<<>>&pageSize=1000 /// RESPONSE: 200
flutter: Groups loaded = 13
flutter: Contacts loaded = 1000
flutter: #########################
flutter: BootstrapCommand Complete
flutter: #########################
flutter: [RefreshContactsCommand]
flutter: [RefreshAuthTokensCommand] Refreshing with token: <<>>
flutter: REQUEST: https://people.googleapis.com/v1/people/me/connections?access_token=<<>>&personFields=addresses,ageRanges,biographies,birthdays,braggingRights,coverPhotos,emailAddresses,events,genders,imClients,interests,locales,memberships,metadata,names,nicknames,occupations,organizations,phoneNumbers,photos,relations,relationshipInterests,relationshipStatuses,residences,sipAddresses,skills,taglines,urls,userDefined&sortOrder=FIRST_NAME_ASCENDING&pageSize=2000&requestSyncToken=true /// RESPONSE: 200
flutter: token: <<>> 1000 out of 2566

README gives incorrect Flutter hash

The recent changes to the repo appear to be using a recent master—it's using the latest FDE plugin versions, and a fairly recent version of the Windows runner—but the README still says to use Flutter 9c3f0faa6d, which is from June. That wouldn't compile.

The README should be updated to whatever version you updated against.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.