Code Monkey home page Code Monkey logo

libgit2dart's People

Contributors

dnys1 avatar skinnymind 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

Watchers

 avatar  avatar  avatar

libgit2dart's Issues

How can I output real-time progress when I'm pushing? Instead of printing all the progress at once after the push

ReceivePort receivePort = ReceivePort();
sendPort.send(receivePort.sendPort);
receivePort.listen((params) {
  ...
  try{
  	...
    var keypair = Keypair(username: username,pubKey: sshKey.publicKeyPath ,privateKey: sshKey.privateKeyPath,passPhrase: sshKey.passPhrasePath);
    var callbacks = Callbacks(credentials: keypair,
        sidebandProgress: (progress){
          sendPort.send(progress);
          print(progress);
        }
    );
    remote.push(refspecs: ['refs/heads/master'],callbacks: callbacks);
    print('push to ${remote.url} success !');
    remote.free();
    sendPort.send('success');
  }catch(e){
    print('push error:$e');
    ...
  }
});

Getting the diff to a reference (HEAD)

Hello again! I am trying to get a diff to the HEAD reference.
However, repo.diff(...) only accepts trees as arguments.
Is this possible with libgit2dart? Thanks!

PS.: It would be very cool to get be able to contact you over gitter for example - or other platforms for small things like this, maybe you could create a room for libgit2dart?

dylib name error: should be libgit2.1.5.dylib

s.vendored_libraries = 'libgit2-1.5.0.dylib'

dylib name should be libgit2.1.5.dylib or it will be fail to find the lib when running

otool -L ./fgit show

@rpath/libgit2.1.5.dylib (compatibility version 1.5.0, current version 1.5.0)

➜ fgit fvm flutter doctor -v

[!] Flutter (Channel stable, 3.7.4, on macOS 12.6.3 21G419 darwin-x64, locale zh-Hans-CN)
    • Flutter version 3.7.4 on channel stable at /Users/liugang/fvm/versions/3.7.4
    ! Warning: `dart` on your path resolves to /usr/local/Cellar/dart/2.19.2/libexec/bin/dart, which is not inside your current Flutter SDK checkout at /Users/liugang/fvm/versions/3.7.4. Consider adding /Users/liugang/fvm/versions/3.7.4/bin to the front of your path.
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision b4bce91dd0 (4 days ago), 2023-02-21 09:50:50 +0800
    • Engine revision 248290d6d5
    • Dart version 2.19.2
    • DevTools version 2.20.1
    • Pub download mirror https://pub.flutter-io.cn
    • Flutter download mirror https://storage.flutter-io.cn
    • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0-rc2)
    • Android SDK at /Users/liugang/Dev/android-sdk-macosx
    • Platform android-31, build-tools 33.0.0-rc2
    • Java binary at: /Library/Java/JavaVirtualMachines/jdk1.8.0_131.jdk/Contents/Home/bin/java
    • Java version Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
    • All Android licenses accepted.

[!] Xcode - develop for iOS and macOS (Xcode 14.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 14C18
    ! CocoaPods 1.10.1 out of date (1.11.0 is recommended).
        CocoaPods is used to retrieve the iOS and macOS platform side's plugin code that responds to your plugin usage on the Dart side.
        Without CocoaPods, plugins will not work on iOS or macOS.
        For more info, see https://flutter.dev/platform-plugins
      To upgrade see https://guides.cocoapods.org/using/getting-started.html#installation for instructions.

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[!] Android Studio (version 2022.1)
    • Android Studio at /Users/liugang/Library/Application Support/JetBrains/Toolbox/apps/AndroidStudio/ch-0/221.6008.13.2211.9514443/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    ✗ Unable to find bundled Java version.
    • Try updating or re-installing Android Studio.

[✓] IntelliJ IDEA Ultimate Edition (version 2022.3.2)
    • IntelliJ at /Users/liugang/Applications/JetBrains Toolbox/IntelliJ IDEA Ultimate.app
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart

[✓] IntelliJ IDEA Ultimate Edition (version 2022.3.2)
    • IntelliJ at /Users/liugang/Library/Application Support/JetBrains/Toolbox/apps/IDEA-U/ch-0/223.8617.56/IntelliJ IDEA.app
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart

[✓] VS Code (version 1.75.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.58.0

[✓] Proxy Configuration
    • HTTP_PROXY is set
    • NO_PROXY is localhost,127.0.0.1,::1
    • NO_PROXY contains localhost
    • NO_PROXY contains 127.0.0.1
    • NO_PROXY contains ::1

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-x64     • macOS 12.6.3 21G419 darwin-x64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 110.0.5481.177

[✓] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 3 categories.

Failed to load dynamic library

When I try to check that Libgit2 is installed (with print(Libgit2.version)), i get an error:

Failed to open the library. Make sure that libgit2 library is bundled with the application.

════════ Exception caught by gesture ═══════════════════════════════════════════
The following ArgumentError was thrown while handling a gesture:
Invalid argument(s): Failed to load dynamic library 'flutter_app_repo_path\.dart_tool\libgit2\windows\libgit2-1.5.0.dll': error code 126

This is a Flutter Windows project.
I tried dart run libgit2dart:setup but it did not help.

OS: Windows 11 22621.819
Flutter: 3.3.8
Dart: 2.18.4

Usage in Dart app without flutter

Hello,
I'm new to Dart, maybe there is something that I'm missing.
I have pure Dart app and wanted to require your package. The readme says that this package should work in dart but because of

environment:
  sdk: ">=2.17.0 <3.0.0"
  flutter: ">=3.0.0"

I'm not able to update dependencies because my app is not a flutter app.

Is there a way that I can add this package to app that is not a flutter app?

Documentation on how to install this library?

Hello, thanks for providing this library!
I am considering to use it for my project!
However, I am pretty new to Dart and Flutter, so I am a bit lost about how to install it.
It is not listed in the official repositories (pub.dev), so I guess I'd have to install it 'by hand' - do you have some hint on how to do that?
Thanks!

Does ssh work on windows platform?

I had some problems with SSH tests on the Windows platform.
Could you clarify for me, is it my fault or the restriction of the library?

Add support for arm64 for macos

Thanks for making this plugin!

I'm on an ARM mac and had build errors about needing an arm64 binary when I tried to use the plugin.

I checked and running file macos/libgit2-1.5.0.dylib gives:

macos/libgit2-1.5.0.dylib: Mach-O 64-bit dynamically linked shared library x86_64

I built a universal binary with libgit2 and replaced the libgit2dart/macos/libgit2-1.5.0.dylib but then the build wasn’t finding the dylib until I put a (slightly differently named) dylib in a folder the app was checking in but then was still getting a different error that said:

“Failed to open the library. Make sure that libgit2 library is bundled with the application.”

I did get a dylib that I built to work by putting it straight in an empty project (ie. no plugin) so I guess I must have messed up the libgit2dart project config somehow. I've given up for now but happy to have another go if it's helpful.

Thanks!

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.