Live data from Hacker News

Bttf is a command line datetime Swiss army knife

github.com

81–90 of 104 posts

Re: Bttf is a command line datetime Swiss army knife

#82

I'm the author of Bttf. I just wanted to share a really cool example of something that Bttf can do that I _think_ is kinda hard to do otherwise. (And also, I want to make an assertion about it and I hope this will lead to me being wrong and learning something new.) The use case is: "I want to see a list of all files in a repository, sorted in ascending order of when it was most recently changed according to source co…

> “If you run this on a big repository, it will take quite a lot of time because `git log -n1` takes a long time. I think this is the fastest way to get the most recent commit time on a single file? (That's the assertion that I hope someone can correct me on!) In any case, `bttf tag exec` is using parallelism under the hood to make this even faster.” Instead of running `git log -n1` on every file, I think you can wal…

Oh interesting! That is indeed quite a bit faster.

I'll have to noodle on this one. `bttf tag exec` works with arbitrary commands that can print any kind of date. But your approach require a different access pattern. I can either specialize the use case in bttf (blech) or I can figure out how to generalize your approach.

I think the key issue here is probably that it isn't line oriented. bttf composes well, but only when you have a one-to-one relationship between date and data. (Or a many-to-one is also supported, but it's many dates to one datum, not one date to many datums.) So maybe that relational model is worth figuring out how to streamline. Then I think this use case would work better.

Also, thank you! This is exactly the kind of reply I was hoping for! :D

Re: Bttf is a command line datetime Swiss army knife

#83

I'm the author of Bttf. I just wanted to share a really cool example of something that Bttf can do that I _think_ is kinda hard to do otherwise. (And also, I want to make an assertion about it and I hope this will lead to me being wrong and learning something new.) The use case is: "I want to see a list of all files in a repository, sorted in ascending order of when it was most recently changed according to source co…

> I think [`git log -n1 -- `] is the fastest way to get the most recent commit time on a single file? In terms of machine time? I'd guess so, but I'd also guess calling it for each of `git ls-files` is not the fastest way to get the most recent commit of all the files in a typical scenario (large repo, recent time of interest, most files not changed that recently). And especially if you're okay assuming the most rece…

Yeah totally right. I just don't know enough about git to figure it out. But a sibling commenter helped a lot.

And yeah perf probably doesn't matter much. But, like, running my approach on the Rust compile repo takes at least minute on my beefly (if a little dated) machine. But lukasgelbmann's approach only takes about 11 seconds. That's a big improvement.

Yeah though, perf here may not matter much. It's just an example use of bttf that is less than instant. (And it's not really bttf. It's my examples access pattern of git.)

Re: Bttf is a command line datetime Swiss army knife

#84

I'm the author of Bttf. I just wanted to share a really cool example of something that Bttf can do that I _think_ is kinda hard to do otherwise. (And also, I want to make an assertion about it and I hope this will lead to me being wrong and learning something new.) The use case is: "I want to see a list of all files in a repository, sorted in ascending order of when it was most recently changed according to source co…

Pretty recent Git versions have git-last-modified(1) which can list all files along with the last modified commit.

Oh neat! TIL about `git last-modified`. That looks like a fun one to explore. Thank you.

Re: Bttf is a command line datetime Swiss army knife

#87

I feel like this kind of tool has been completely obsoleted by LLMs (even local models). I've used similar tools such as tiny for Emacs, which is a DSL for generating text based on numeric ranges. Now, it's simply more efficient to ask AI.

Quite plausible. I built most of it in May 2025 (1 year ago) before I even looked at LLMs for coding, and announced it in Oct 2025[1]. I started it principally as a mechanism to dog-food Jiff[2]. Jiff has not been obsoleted by LLMs and is exactly the sort of thing an LLM would add as a dependency to a Rust project. This ended up being an extremely useful exercise because it did lead to some Jiff improvements.

Fun fact: ripgrep started as something to dog-food the regex crate (with a focus on performance). I didn't originally build it to release to end users funnily enough. To be clear, I'm not implying bttf will follow the same path. I honestly probably agree with you at this point. I wouldn't have 1 year ago though.

[1]: https://news.ycombinator.com/item?id=45608547

[2]: https://github.com/BurntSushi/jiff

Re: Bttf is a command line datetime Swiss army knife

#88

I feel like this kind of tool has been completely obsoleted by LLMs (even local models). I've used similar tools such as tiny for Emacs, which is a DSL for generating text based on numeric ranges. Now, it's simply more efficient to ask AI.

I believe AI-for-everything will become unsustainable financially for many and I’m genuinely curious to see how people deal with it. When to use it? When is it wasteful?

My big hypothesis is that tokens are going to get much more expensive. Either that or OpenAI/anthropic are going bankrupt. I’m almost excited to find out, I have to admit.

Your remark just reminded me of this, I went a bit off topic, I admit.

Re: Bttf is a command line datetime Swiss army knife

#90

I feel like this kind of tool has been completely obsoleted by LLMs (even local models). I've used similar tools such as tiny for Emacs, which is a DSL for generating text based on numeric ranges. Now, it's simply more efficient to ask AI.

I believe AI-for-everything will become unsustainable financially for many and I’m genuinely curious to see how people deal with it. When to use it? When is it wasteful? My big hypothesis is that tokens are going to get much more expensive. Either that or OpenAI/anthropic are going bankrupt. I’m almost excited to find out, I have to admit. Your remark just reminded me of this, I went a bit off topic, I admit.

Have you tried DeepSeek V4 Flash? It's very competent and extremely cheap.

I think Gemma 4 is also a good example of a capable small model.

I mention these not only because they're cheap but because they can run on consumer devices. The "every year bigger and more capable SOTA model" trend is mirrored by "the every year smaller and more capable open source model" trend.

Post reply on HN