Giter Site home page Giter Site logo

Comments (13)

natsuk4ze avatar natsuk4ze commented on June 21, 2024 1

Thank you for your contribution @freshtechtips 🀝

Currently, I am reluctant to add Linux to the support of this plugin.
The reason is the lack of maintainers who are knowledgeable about Linux and capable of ongoing maintenance.

If we do support Linux, we will not add any code or dependencies on the Dart side. Instead, we believe that everything should be handled on the native side.

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

Thank you for your contribution @freshtechtips 🀝

Currently, I am reluctant to add Linux to the support of this plugin.
The reason is the lack of maintainers who are knowledgeable about Linux and capable of ongoing maintenance.

If we do support Linux, we will not add any code or dependencies on the Dart side. Instead, we believe that everything should be handled on the native side.

Thank you for the reply, I understand your concern, but the most efficient way to add support for linux is to use the command line as the dependencies on Linux in the command lind is already maintained for you for different distros

By the command line, I mean Linux dependencies like wget, which is a command or executable can be used in the command line in Linux and that is how things works in Linux this is why I did it this why, moving the logic to native side is not necessary as we will not use anything on the native side and it just make the process slower

If you mean I did add packages

The meta package most of it is already part of flutter, but I can remove it if you want

parh package I can remove it and create a solution from acratch

It's really unnecessary to make a call using a method channel and then use the command line in native code

I can test the code on different distros

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

Thank you for your contribution @freshtechtips 🀝

Currently, I am reluctant to add Linux to the support of this plugin.
The reason is the lack of maintainers who are knowledgeable about Linux and capable of ongoing maintenance.

If we do support Linux, we will not add any code or dependencies on the Dart side. Instead, we believe that everything should be handled on the native side.

If you want to test the code

You can use something like VirtualBox

Install any distro and test gal on it in any flutter project

You can also check the pull request code and tell me if there is anything spesefic to Linux that you don't know just in case so I explain it and why we did it this way

from gal.

natsuk4ze avatar natsuk4ze commented on June 21, 2024

I understand that you are not adding native code. @freshtechtips

  1. do not add new dependencies to pubspec.yaml.
  2. putting the Linux folder at the top level, like darwin and android.
  3. a detailed description of how you plan to design and implement it.

Are these three possible for you?

However, adding a new platform means semi-permanent support, and we believe that we should be very cautious, especially in a project like this plugin, which is small and has few contributors.

The main problem is that I have absolutely no knowledge of Linux πŸ˜…

Therefore, please understand that the review process can take quite some time and may result in rejection.

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

I understand that you are not adding native code. @freshtechtips

  1. do not add new dependencies to pubspec.yaml.
  2. putting the Linux folder at the top level, like darwin and android.
  3. a detailed description of how you plan to design and implement it.

Are these three possible for you?

However, adding a new platform means semi-permanent support, and we believe that we should be very cautious, especially in a project like this plugin, which is small and has few contributors.

The main problem is that I have absolutely no knowledge of Linux πŸ˜…

Therefore, please understand that the review process can take quite some time and may result in rejection.

The first and last are possible, the second, it's just implementation for linux but in dart since we are executing commands in the command line in dart code so it's impossible to move that to different place but don't worry the linux folder is just a name I can rename it or delete it and put the dart file directly

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

I understand that you are not adding native code. @freshtechtips

  1. do not add new dependencies to pubspec.yaml.
  2. putting the Linux folder at the top level, like darwin and android.
  3. a detailed description of how you plan to design and implement it.

Are these three possible for you?

However, adding a new platform means semi-permanent support, and we believe that we should be very cautious, especially in a project like this plugin, which is small and has few contributors.

The main problem is that I have absolutely no knowledge of Linux πŸ˜…

Therefore, please understand that the review process can take quite some time and may result in rejection.

platform

The details are simple, Linux doesn't have a specific framework to do things on the system since it has many distros and some of them work a little bit differently, unlike Darwin or Apple ecosystem

So we have to use the terminal and run commands in the dart code directly,
There is no album in Linux but there are Pictures and Videos in the home directory

So we create a new album in the pictures or videos if the developer wants to put the image or video in an album if he doesn't want that then we will use the temp directory instead, notice that we are always using Unix commands like cp, rm, wget to make sure 100% the code will work on any distros and has nothing to do with dart code

we are using the dart:io only in one case in putImageBytes we will get the new location and write the file easily, Linux we have access to the pictures and photos just like Linux but it is hard to say since there are sandbox-like flatpack that will make the security even better than macOS, unfortunately, we can't handle that case but don't worry as soon we trying to access the pictures or album it will request permission directly easily

The reason why the pull request in draft state since I'm planning on test the plugin on different Linux distros and I will today, I will also trying to support more features as much as I can, I will make sure to fix the bugs that if there are any and then I will make it ready to be merged or rejected

I think it's better if we move the conversation to the pull request but it doesn't make difference to me

from gal.

natsuk4ze avatar natsuk4ze commented on June 21, 2024

I think it's better if we move the conversation to the pull request

OK

from gal.

natsuk4ze avatar natsuk4ze commented on June 21, 2024

We might investigate whether we must always write native code.

https://docs.flutter.dev/packages-and-plugins/developing-packages#dart-only-platform-implementations

One thing for sure, we want to avoid as much as possible adding code just for a specific platform under the lib.

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

We might investigate whether we must always write native code.

https://docs.flutter.dev/packages-and-plugins/developing-packages#dart-only-platform-implementations

One thing for sure, we want to avoid as much as possible adding code just for a specific platform under the lib.

Good idea!! We just need to take the implementation from the previous PR and test it and that's all

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

We might investigate whether we must always write native code.

https://docs.flutter.dev/packages-and-plugins/developing-packages#dart-only-platform-implementations

One thing for sure, we want to avoid as much as possible adding code just for a specific platform under the lib.

The platform interface, I don't think we have a separate package for that

We need something like

gal_platform_interface

Before we can continue

from gal.

natsuk4ze avatar natsuk4ze commented on June 21, 2024

Since this is a small plugin, it would appear that splitting the package into separate packages for each platform would only make maintenance more difficult.

I am investigating how to organize the code for the Linux platform into a linux folder as well as the other platforms.

I understand that this is possible with native code, but if it could be done with Dart it would be ideal.

My concern is that Dart may not be able to handle the detailed Linux specifications.
For example, error handling, permissions, etc.

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

Since this is a small plugin, it would appear that splitting the package into separate packages for each platform would only make maintenance more difficult.

I am investigating how to organize the code for the Linux platform into a Linux folder as well as the other platforms.

I understand that this is possible with native code, but if it could be done with Dart it would be ideal.

My concern is that Dart may not be able to handle the detailed Linux specifications. For example, error handling, permissions, etc.

Don't worry, dart is not able to handle Linux Linux specifications but we can still use the command line which is more efficient, we just needs dart:io and that's all

from gal.

ellet0 avatar ellet0 commented on June 21, 2024

Since this is a small plugin, it would appear that splitting the package into separate packages for each platform would only make maintenance more difficult.

I am investigating how to organize the code for the Linux platform into a linux folder as well as the other platforms.

I understand that this is possible with native code, but if it could be done with Dart it would be ideal.

My concern is that Dart may not be able to handle the detailed Linux specifications. For example, error handling, permissions, etc.

Let's keep the comments in the PR so we can track things easily, or if you can, let's chat in private

from gal.

Related Issues (20)

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.