-
-
Notifications
You must be signed in to change notification settings - Fork 298
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replace termion with Windows compatible crossterm #179
Conversation
Hey @remgodow, I'm very happy to see this! This looks great, and I imagine it was quite an undertaking. This is a bit of a risky change, since it is completely untested (the TUI backend is exactly the part we're mocking in our tests - as you might have seen already). So I'd want this tested thoroughly manually. While I'm sure you've tested this extensively, I hope you will not mind some more eyes on it. :) I'm going to run some manual tests on my machine (linux) tomorrow, and maybe workout a quick check-list of stuff to check. Then I want to find someone willing to go through that check list on a mac with this branch, to see that all is well there too. Do you happen to have access to one? If not, I'll try and find someone who does. I'm looking forward to making this happen and will try to devote as much of my attention as possible to it. :) |
Alright. I went over all the changes in this PR and they look good. I also tested this manually on my local machine and it works great. Bundle size hasn't changed either. I asked a friend to test this manually on a mac, I hope that happens today/tomorrow and then we're good to merge this. |
@imsnif Nice, just in case, I should be able to ask a friend for mac tests as well, if for any reason your friend will not be able to. As for what remains, well besides the other draft, there is an issue with building on Windows - libpnet requires WinPcap SDK, I guess we would need to automate downloading and extracting it in build.rs. I also would like to create chocolatey package, it should not be that hard, as it will be single executable, but it would make the tool much more approachable (cargo install requires rust, visual c++, winpcap which would limit target audience to rust programmers). |
About winpcap - is this standard that tools automate its downloading+building? Can't we say "requires winpcap: About the chocolatey package: that would be really great. About testing, for convenience I made a quick check list of how to manually check this for others wanting to help us. If your friend is available to check this, that would be awesome :)
git checkout -b remgodow-crossterm main
|
Well, we should as for the runtime, the user needs a WinPcap/NpCap driver installed.
This relates to WinPcap SDK - C Library for communicating with the driver. It is required for building libpnet on Windows.
So to support CI/CD we would need to automate that, unfortunately on Windows you need to do such tasks by hand instead of good old apt-get. |
Aha, I see. I was hoping to do this incrementally somehow. Alright then, thanks for the explanation. |
@imsnif Is there a way to get mac binary from travis? My friend is not familiar with Rust, so the binary would be the best option. |
Not trivially (that I know of). Once can get it to publish binaries to github releases (which I've been meaning to get to for a while), but I don't think for pull requests. Other than that it could be something along the lines of "get the build script to send the binary as an email somewhere", but I think it would be easier to wait for my friend. :) |
So, unfortunately my friend will only get to this much later today. If your friend wants to check, the list above is rather detailed and doesn't assume rust knowledge. You can add a 0 phase to it to install rust+cargo: Otherwise, we'll wait and I'll try to find more people. Sadly around me seems to be moving to linux/windows these days :) |
I've tested this on mac with a help of my friend, and a TeamViewer :). Looks good, tab, pause, q, ctrl-c works. |
Awesome. Thanks for doing this! |
Hi,
first of all thanks for creating bandwhich, I really like how easy it is to have an overview of the networking.
As much as I like Linux, I'm still a Windows guy due to gaming and work. I also wanted to try out Rust for some time, so I thought why not try adding Windows support to this awesome tool.
I have a POC working at my fork
It took some refactoring here and there, so I decided to split my work into few stages.
This is the first - using crossterm for terminal backend, as it is compatible with Windows OS.
Looking forward to make #15 into master :)