News for hackers. Stuff that matters.
Re:What: A terminal tool to check what is taking up your ban... by lazyjones on Monday December 30, 2019 @04:56AM (#21912229)
Bad naming..

  WHAT(1)                   BSD General Commands Manual                  WHAT(1)
  NAME
       what -- show what versions of object modules were used to construct a file
(MacOS ...)
Re:What: A terminal tool to check what is taking up your ban... by anilgulecha on Monday December 30, 2019 @05:15AM (#21912325)
This is in the top class of utilities (htopm etc).

A good name could probably be bwtop, or tcptop or iftop.

Actually I searched for these, and turns out iftop exists! (https://linux.die.net/man/8/iftop)

Re:What: A terminal tool to check what is taking up your ban... by rotten on Monday December 30, 2019 @08:00AM (#21913052)
My complaint about the name is that it would be hard to "google" it. This means if I don't bookmark it or remember where I found it, then a couple of years from now when my laptop needs to be rebuilt, I'll have the darndest time finding it to install it again.
Re:What: A terminal tool to check what is taking up your ban... by aliveupstairs on Monday December 30, 2019 @09:05AM (#21913377)
This effectively made github my second search engine. We should have an AskHN on how to find software in general.
Re:What: A terminal tool to check what is taking up your ban... by lostlogin on Monday December 30, 2019 @02:26PM (#21915942)
I’m using multiple search engines more and more. Possibly this is due to me usually bypassing google to avoid the ad laden hits. A view with search results from a few sources comes to mind as a solution. Another back burner project.
Re:What: A terminal tool to check what is taking up your ban... by aliveupstairs on Monday December 30, 2019 @04:17PM (#21916793)
You can do this with browser search engines, but as a DuckDuckGo user, I can !bang search_term (`!gh`, `!github` to search in github.) Now, I think DuckDuckGo is very lacking in terms of Zero-click searching, but if I know where to get information I can !bang to it (e.g., `!hn what`) or if you're feeling luck `\hn what` will open the first search result. Much better than spending an afternoon setting up search engines.
Re:What: A terminal tool to check what is taking up your ban... by legends2k on Wednesday January 01, 2020 @03:51AM (#21927273)
3 year long user of DDG, never knew about the feeling lucky (\) option.
Re:What: A terminal tool to check what is taking up your ban... by wyclif on Monday December 30, 2019 @10:13PM (#21918672)
DDG has an Instant Answer API: https://duckduckgo.com/api
Re:What: A terminal tool to check what is taking up your ban... by cgarvis on Monday December 30, 2019 @03:53PM (#21916628)
Hackernews Search is a better google for cool things I've found on the internet.
Re:What: A terminal tool to check what is taking up your ban... by sdan on Monday December 30, 2019 @04:15PM (#21916784)
I just type in what I’m looking for and “news.ycombinator.com” at the end so that it links to a HN page. Sometimes I have to use site: to make sure it’s actually from HN, but works reasonably well.
Re:What: A terminal tool to check what is taking up your ban... by ric2b on Wednesday January 01, 2020 @10:48AM (#21928455)
with duck duck go you can just write !hn instead.
Re:What: A terminal tool to check what is taking up your ban... by overcast on Monday December 30, 2019 @10:33AM (#21913957)
Every browser has book marking syncing in some capacity these days. It's the equivalent of losing contacts with a new phone in 1999.
Re:What: A terminal tool to check what is taking up your ban... by tjoff on Monday December 30, 2019 @11:32AM (#21914480)
Not without creating an account, on Android.

Chrome has no other export functionality. And firefox copied that lack-of-feature without even realizing the motivations.

So now one have to copy them one by one.

Re:What: A terminal tool to check what is taking up your ban... by lostlogin on Monday December 30, 2019 @02:29PM (#21915965)
I must be misunderstanding something here, can you please explain the missing feature?

I load a set of bookmarks into Firefox on client machines regularly, but I suspect this isn’t what you are discussing.

Re:What: A terminal tool to check what is taking up your ban... by tjoff on Monday December 30, 2019 @04:06PM (#21916726)
I'm are talking firefox/chrome for android only. The only way to export bookmarks (and possibly import) is to register for an account and sync them.

There is no way to export them to an xml/whatever file (pretty sure you could at least in firefox before, but I guess it was too hard to maintain...).

Re:What: A terminal tool to check what is taking up your ban... by cortesoft on Monday December 30, 2019 @01:50PM (#21915697)
Or create an account?
Re:What: A terminal tool to check what is taking up your ban... by tjoff on Monday December 30, 2019 @04:09PM (#21916744)
Surf with chrome logged in? Will never happen. Hard no as long as my sanity remains.

Firefox, maybe, haven't looked into it and just the process of evaluating it isn't worth it. Mozilla doesn't have the track record that I want to blindly trust them with that either.

Re:What: A terminal tool to check what is taking up your ban... by ChikkaChiChi on Monday December 30, 2019 @11:02AM (#21914211)
I wouldn't recommend putting the onus on the end user to remember how to find your product. Too many assumptions.
Re:What: A terminal tool to check what is taking up your ban... by overcast on Monday December 30, 2019 @11:10AM (#21914274)
That was a response to them having an issue with losing bookmarks. Are bookmarks in general now a negative onus?
Re:What: A terminal tool to check what is taking up your ban... by macintux on Monday December 30, 2019 @11:15AM (#21914318)
As search engines have gotten better over the years, I find my use of bookmarks is usually write-once read-never.

Part of that is due to the fact that iOS is now my primary consumption platform, and finding bookmarks in a complex structure is much more awkward than it should be.

Part of it is just laziness: trying to manage a complex bookmark folder is more work than I care to do when search engines give me 99% of what I need.

Re:What: A terminal tool to check what is taking up your ban... by anais9 on Monday December 30, 2019 @12:51PM (#21915232)
For what it's worth I had the same problem with folder/hierarchically structured bookmarks, but tag-based bookmarking (like del.icio.us used to provide) meshed very well with me and my workflow so I wrote https://savecrate.com (still a WIP and rough around the edges but functional enough to work for me)
Re:What: A terminal tool to check what is taking up your ban... by ChikkaChiChi on Monday December 30, 2019 @07:24PM (#21917949)
I even pay for pinboard and barely use it.

It'd be great if every time I went back to a website, all the pages on the site that I already bookmarked would pop in a sidebar...

Re:What: A terminal tool to check what is taking up your ban... by lostlogin on Monday December 30, 2019 @02:33PM (#21915984)
> I find my use of bookmarks is usually write-once read-never

I found this with Instapaper. What was a bookmark and what was a read-later?

Re:What: A terminal tool to check what is taking up your ban... by dpwm on Monday December 30, 2019 @05:27AM (#21912372)
iftop is a remarkably useful utility. It's often one of the first things I install on new openwrt installations.
Re:What: A terminal tool to check what is taking up your ban... by acranox on Monday December 30, 2019 @07:22AM (#21912835)
Ever since I installed SQM on openwrt, I don’t really care what’s using the bandwidth anymore since it doesn’t impact any other users on the network. :) It’s true though that iftop is a very useful tool.
Re:What: A terminal tool to check what is taking up your ban... by joshspankit on Monday December 30, 2019 @08:59AM (#21913343)
Still nice in some cases to find applications/devices that are going wild due to a bug
Re:What: A terminal tool to check what is taking up your ban... by iso1631 on Monday December 30, 2019 @12:34PM (#21915086)
iftop (and ifstat) are part of my preseed file, along with tcpdump, (and htop/iostat/pidstat/mpstat)

For a router I'd also put ntopng on.

Re:What: A terminal tool to check what is taking up your ban... by blackhaz on Monday December 30, 2019 @08:59AM (#21913344)
Another option, since there are so many "tops," is something like psbw... Process bandwidth. Reminiscent of ps ax but ps bw.
Re:What: A terminal tool to check what is taking up your ban... by airstrike on Monday December 30, 2019 @08:17AM (#21913131)
whatif or whif would be great names
Re:What: A terminal tool to check what is taking up your ban... by em-bee on Monday December 30, 2019 @09:58PM (#21918627)
i really like whatif.

whif less so, that just doesn't seem to smell right.

Re:What: A terminal tool to check what is taking up your ban... by floatingatoll on Monday December 30, 2019 @05:24AM (#21912364)
‘whatop’
Re:What: A terminal tool to check what is taking up your ban... by inetknght on Tuesday December 31, 2019 @01:22AM (#21919338)
tbqh reading `iftop` is not easy at all
Re:What: A terminal tool to check what is taking up your ban... by Symbiote on Monday December 30, 2019 @05:12AM (#21912311)
'whence' would be more specific – it's archaic in English, it means 'from where' – although it's used within the ksh shell.
Re:What: A terminal tool to check what is taking up your ban... by kps on Monday December 30, 2019 @03:40PM (#21916510)
‘whence’ is POSIX-reserved even in shells that don't implement it¹. (‘what’ is also in POSIX². And ‘who’ is on first³.)

¹ https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V...

² https://pubs.opengroup.org/onlinepubs/9699919799/idx/utiliti...

³ https://youtu.be/kTcRRaXV-fg

Re:What: A terminal tool to check what is taking up your ban... by xorcist on Monday December 30, 2019 @05:43AM (#21912446)
zsh also implements whence
Re:What: A terminal tool to check what is taking up your ban... by drivers99 on Monday December 30, 2019 @09:44AM (#21913602)
ksh as well. Found someone’s reference to various “what” type commands[1]:

> The whence command is a Korn Shell feature that tells how a name would be interpreted by the shell: it detects commands and aliases, and searches your path.

[1] http://www.robelle.com/smugbook/whence.html

Re:What: A terminal tool to check what is taking up your ban... by bitlevel on Monday December 30, 2019 @06:00AM (#21912506)
Perhaps 'whip' for 'what internet protocol'?
Re:What: A terminal tool to check what is taking up your ban... by Waterluvian on Monday December 30, 2019 @09:11AM (#21913413)
Is there a website one can test names against? Of course you can locally but that doesn't easily cover the distros you might be thinking of targeting.
Re:What: A terminal tool to check what is taking up your ban... by abathur on Monday December 30, 2019 @11:13AM (#21914298)
I doubt any of these will help you if you pick the name of a shell builtin, but:

The closest (but not perfect) answer I know of is the open source project name checker (http://ivantomic.com/projects/ospnc/).

Repology (https://repology.org/projects/?search=what) can also help a bit, but it's less of a direct answer.

Re:What: A terminal tool to check what is taking up your ban... by ckuehl on Monday December 30, 2019 @04:59PM (#21917054)
Another thing that isn't perfect but could help is doing a search of package contents of a large distro, e.g. here's a search of Debian for packages that provide a file called "node": https://packages.debian.org/search?searchon=contents&keyword...
Re:What: A terminal tool to check what is taking up your ban... by wscott on Monday December 30, 2019 @05:49PM (#21917392)
The author has renamed this project to 'bandwhich'.
Re:What: A terminal tool to check what is taking up your ban... by blaser-waffle on Tuesday December 31, 2019 @11:58AM (#21922459)
Good. Not a beautiful name but distinct, and still captures some of the meaning of the tool.
Re:What: A terminal tool to check what is taking up your ban... by vhiremath4 on Monday December 30, 2019 @01:34PM (#21915557)
This is the main problem keeping me from using this right now. I don't like installing binaries that conflict with system package names because I'm tin foil about stability and the super small chance that some installation/config script for some other package I rely on references `what` and breaks.

@imsnif 2 questions:

1. Any chance you'd be willing to rename the package? I get it if not, but that would be so dope. 2. Would you consider putting this up as a cask on Brew? Brew is essentially the most popular package manager for Mac that I know of. This isn't as big of a deal for me honestly, but thought I'd ask.

Re:What: A terminal tool to check what is taking up your ban... by imsnif on Monday December 30, 2019 @06:08PM (#21917525)
1. Done. It's now known as "bandwhich" 2. This is in progress: https://github.com/imsnif/bandwhich/issues/9
Re:What: A terminal tool to check what is taking up your ban... by vhiremath4 on Thursday January 09, 2020 @10:25AM (#22001914)
Re:What: A terminal tool to check what is taking up your ban... by ComputerGuru on Tuesday December 31, 2019 @02:56AM (#21919609)
I love the name.
Re:What: A terminal tool to check what is taking up your ban... by Chris2048 on Monday December 30, 2019 @07:24AM (#21912849)
When the bb is slow, it might be because someone is "hogging" the bb - so maybe "whathog"?

or "wiccapig/wicpig" (whichhog) ;-)

Re:What: A terminal tool to check what is taking up your ban... by kazinator on Monday December 30, 2019 @02:39PM (#21916027)
A good name would be "nettop"; it's so good that several projects (on github alone) have already used it as the name of some network monitor. The shortened "ntop" is also taken. At least two projects have claimed "iptop".
Re:What: A terminal tool to check what is taking up your ban... by monkin on Monday December 30, 2019 @05:06PM (#21917100)
nettop already exists on macOS and does the same thing.

https://www.unix.com/man-page/osx/1/nettop/

Re:What: A terminal tool to check what is taking up your ban... by mobilemidget on Monday December 30, 2019 @05:03AM (#21912265)
cargo install what (fails)

  Package `trust-dns-proto v0.18.0` does not have these features: `tokio-compat`
(MacOS 10.15.2)
Re:What: A terminal tool to check what is taking up your ban... by djsumdog on Monday December 30, 2019 @07:09AM (#21912770)
This is one of the biggest problems I've had with any neat Rust thing posted up here. The language changes a lot. I have rust/cargo 1.37.0 installed (it's the latest marked stable in Gentoo) and adler32 v1.0.4 fails to compile with "`core::slice::<impl [T]>::len` is not yet stable as a const fn". I'm installing 1.40.0 from the unstable tree to see if that will build it.

I've had situations where I'm either not on the latest version of rust, or I'm on too current a version of rust, which deprecated/removed some feature needed for a dependency. I'm not sure if devs can define their min/max versions, but that kinda check should probably be done before cargo starts building packages.

Re:What: A terminal tool to check what is taking up your ban... by StavrosK on Monday December 30, 2019 @08:10AM (#21913096)
Agreed, and I had the same problem. It seems like an easy fix to add a requires_rust_version thing in Cargo.toml, and devs could at least set it to "the version I'm currently using" so we know it's guaranteed to build on that.
Re:What: A terminal tool to check what is taking up your ban... by steveklabnik on Monday December 30, 2019 @08:16AM (#21913125)
It’s not that easy; the real world has a lot of complexity. That said, we finally did accept a design for this in October; it’s not clear when it’s going to land though.
Re:What: A terminal tool to check what is taking up your ban... by StavrosK on Monday December 30, 2019 @08:18AM (#21913138)
Because of dependencies, you mean? Even an indication of "this builds fine for me at version X" would be good.
Re:What: A terminal tool to check what is taking up your ban... by steveklabnik on Monday December 30, 2019 @08:25AM (#21913171)
Tons of stuff. Various aspects of dependencies, for example, should this affect resolution? Is this a semver range? A minimum version? Is whatever we choose reasonably forward compatible for any extensions we might pick in the future? Can you write `cfg` attributes based on versions? Many of the same questions apply there. Etc etc etc.

It took about a year to get stuff figured out.

Re:What: A terminal tool to check what is taking up your ban... by codetrotter on Monday December 30, 2019 @11:28AM (#21914433)
I also suspect that if the plan is to add this as an attribute that developers put in Cargo.toml then there will be a lot of packages that will have the value set to a higher version than need be.

Speaking for myself, I don't know in which exact version of Rust the features that I use was first introduced, and I don't think anyone else knows that either if they use a lot of different Rust language features.

So if I were to add a minimum required version to Cargo.toml for the crates that I put out, I would for sure end up putting the current stable version that I am using myself.

In practice I think that is probably fine, but also a bit unfortunate in a way, that anyone using an older version of Rust, such as those using distro packaged Rust will see Cargo tell them they can't build and run my crate, because I set minimum version to say 1.40.0, and they are using 1.37.0, but actually I might happen to not be using any features beyond what was available in 1.35.0 or whatever in some random crate of mine, but I don't know that and I don't wish to test every change I make to my crates in a bunch of older versions of Rust also because that would slow me down considerably.

On the other hand, if the Rust Team had the resources for it, could the crates.io service be made to detect minimum version of Rust needed based on the features used? Probably a lot of work I would guess. Doubly so when considering different feature flags and other cfg switches.

Again, I don't know the plans you have for how to do it so maybe you are already planning to do it that way but, you guys sometimes run builds on basically all of the crates on crates.io, don't you? Would it be feasible that the crates.io service runs a background service that builds each crate with a few different versions of Rust and records the build results and possibly test results into the meta data for the crates on crates.io? I think that would probably require a lot of server time, and therefore likely cost too much to be possible but it would have been really cool if it was doable.

Re:What: A terminal tool to check what is taking up your ban... by steveklabnik on Monday December 30, 2019 @06:34PM (#21917665)
I’m imagining that’s too much resources, yeah. It’s the same issue with anything that’s created by people; I’m sure that it’ll be fine over time. If and when we do LTS releases that’ll make it easier too...
Re:What: A terminal tool to check what is taking up your ban... by mlindner on Monday December 30, 2019 @01:31PM (#21915541)
There's no such thing as a "too current a version of rust". All Rust compilers (since 1.0) compile all previous versions of code and will continue to do so.

In the rare case you might hit something that was removed/modified because of a security exploit, but those are very very rare.

Re:What: A terminal tool to check what is taking up your ban... by edflsafoiewq on Monday December 30, 2019 @02:39PM (#21916030)
This is not true in practice. Old code has failed to compile for various reasons; off the top of my head, new additions to the prelude, and denied lints that became more restrictive. It's not super rare.
Re:What: A terminal tool to check what is taking up your ban... by zlynx on Monday December 30, 2019 @01:07PM (#21915359)
Just a nitpick: Rust 1.40 seems to be the stable version for a couple of weeks now.
Re:What: A terminal tool to check what is taking up your ban... by bluejekyll on Monday December 30, 2019 @08:58PM (#21918390)
First, it’s really cool that their using trust-dns! Second, they probably want to upgrade to the 0.18 release. It’s interesting that the cargo.lock file didn’t restrict the package versions for this case.

Anyway, this tool should probably upgrade to the current 0.18 release now that it’s out, if possible.

Re:What: A terminal tool to check what is taking up your ban... by msla on Monday December 30, 2019 @08:20AM (#21913150)
More evidence that the best names are short, pronounceable, and meaningless, like Hadoop. Git almost qualifies, except for the fact it's a pejorative, so using a really obscure or off-the-wall word is almost as good.

Marketers were forced into this by trademarks, but it shouldn't take the threat of a trademark lawsuit to convince you that stepping too close to something else's toes is annoying for everyone.

(And don't be afraid to go with words that have negative meanings: Aside from git, MUMPS has been a successful medical records database environment for decades.)

Re:What: A terminal tool to check what is taking up your ban... by saganus on Monday December 30, 2019 @10:47AM (#21914078)
How is Git pejorative?

I haven't heard that word used like that, but I've only heard it to refer to the vcs.

Re:What: A terminal tool to check what is taking up your ban... by nneonneo on Monday December 30, 2019 @11:14AM (#21914308)
The word “git” as a pejorative (calling someone unpleasant, e.g. “Linus Torvalds is such a git”) long predates the VCS. Linus himself chose the name for the VCS partly due to the meaning, sarcastically remarking that he was naming another project after himself (first Linux, then Git). See the Wikipedia entry for more detail: https://en.m.wikipedia.org/wiki/Git#Naming
Re:What: A terminal tool to check what is taking up your ban... by saganus on Monday December 30, 2019 @12:53PM (#21915250)
Interesting, thanks!