Giter VIP home page Giter VIP logo

Comments (10)

Freaky avatar Freaky commented on May 24, 2024

I made filesize as a cross-platform way of getting the size of objects on disk.

Termion looks to be getting there.

from diskonaut.

imsnif avatar imsnif commented on May 24, 2024

Hey @Freaky, I saw your PR and will take a look at it shortly regarding filesize. Thanks for this!

Since diskonaut uses tui-rs, I think we can definitely switch the backend to crossterm or something that supports windows with a conditional compilation flag. So even if it takes a while for that Termion issue to be merged, I think we can still go forward with this.

from diskonaut.

imsnif avatar imsnif commented on May 24, 2024

So to update this issue: thanks to @Freaky, 1 has been taken care of. We are left with 2.

from diskonaut.

pm100 avatar pm100 commented on May 24, 2024

what the state here. I have a rough version working with crossterm on windows. Is this interesting or are you waiting for termion to get a working windows version.

Could either switch 100% to crossterm, or make the backend choice a feature. I dont know enough to be able to say whats best, easiest is 100% switch

from diskonaut.

imsnif avatar imsnif commented on May 24, 2024

Very interesting! I'd be happy to move 100% to crossterm (we've recently done something similar with bandwhich) if it gives us windows support. Only thing is I'd like to manually test it on linux/mac first to make sure it's okay, because our tests mock the tui backend.

from diskonaut.

pm100 avatar pm100 commented on May 24, 2024

ok, this is 100% switch to crossterm, runs on my windows 10 dev box and on my rasp pi.

The tests dont even compile so I have not sent you a pull request. But you can check it out here https://github.com/pm100/diskonaut

Let me know if you find anything broken

from diskonaut.

pm100 avatar pm100 commented on May 24, 2024

BTW - I found this project via 'this week in rust' projects looking for help.

Total rust noob.

from diskonaut.

pm100 avatar pm100 commented on May 24, 2024

tests now compile. they all fail, I dont know how they work so not sure how to fix. You seem to be testing to see what draw commands are issued, hers the failure on the first test i drilled into

thread 'tests::cases::ui::two_large_files_one_small_file' panicked at 'assertion failed: `(left == right)`
  left: `[Clear, HideCursor, Draw, HideCursor, Flush, Draw, HideCursor, Flush, Clear, ShowCursor]`,
 right: `[Clear, HideCursor, Draw, Flush, Draw, Flush, Clear, ShowCursor]`', src\tests\cases\ui.rs:106:5

I wonder if this is just a difference of how tui drives the backend, not sure.

from diskonaut.

imsnif avatar imsnif commented on May 24, 2024

Hey @pm100, I took a brief look at the repo and it looks like a great start! I haven't yet tested this locally though, and if you'd like to move forward with this I'll definitely take a closer look.

About the tests: it definitely might be. I wouldn't worry too much about these (you can even comment them out for now) and would more try to concentrate on the snapshots. These are snapshots taken of the UI in each draw event (as a delta of what was on the screen in the previous draw event). They should not be very different and should make it easier to understand what changed.

Do feel free to open a PR though, even with failing tests. I think it will make it easier for us to discuss.

Also - I'm happy you found this project and want to work on this. No worries about experience levels, I think you're doing great. :)

from diskonaut.

imsnif avatar imsnif commented on May 24, 2024

Released in 0.11.0, thanks @pm100 !!

from diskonaut.

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.