Cup o' Go


★ Support this podcast on Patreon ★

Creators & Guests

Host
Jonathan Hall
Freelance Gopher, Continuous Delivery consultant, and host of the Boldly Go YouTube channel.
Host
Shay Nehmad
Engineering Enablement Architect @ Orca
Editor
Filippo Valvassori Bolgè
Sound Designer / Audio Editor based in Milan

What is Cup o' Go?

Stay up to date with the Go community in about 15 minutes per week

Jonathan Hall:

This show is sponsored by you. Stick around till after the news to hear more about that.

Shay Nehmad:

This is

Jonathan Hall:

Cup of Go for March 22, 2024. Keep up to date with the important happenings in the Go community in about 15 minutes per week. I'm Jonathan Hall.

Shay Nehmad:

And I'm Shayne Ahmad.

Shay Nehmad:

Quick, what's today's date?

Jonathan Hall:

Declined.

Shay Nehmad:

Alright. We have a themed episode for y'all today, where we are going to mostly focus on declined proposals. Shout out to Tom from Orca. Oh, that's funny. The previous, listener from my workplace was also Tom.

Shay Nehmad:

It's a different Tom. Oh, a new Tom. Tom from Orca Shift left, who said he liked the decline proposals. So we decided to do a themed episode just for you.

Jonathan Hall:

Yep. There we go. But we have

Shay Nehmad:

a few items to get through first.

Jonathan Hall:

Yeah. So on the topic of declines, call for papers is open now for Colab 2024. That's so optimistic.

Shay Nehmad:

On the topic of working hard submitting a a call for papers and getting it declined with no review, the call for papers is over.

Jonathan Hall:

Some of you may remember Golab, happened in Florence, Italy this last, year. It's happening again. If you if you want to be like me and have your CFP declined, be sure to submit it before the deadline, which is May 1st. So

Shay Nehmad:

like always, we encourage you to work on a talk on a call for papers and hand it in. It doesn't take a lot of work, but it's really like, if you get into a conference or or a meetup, usually pans out good for everyone, because there's more Go content out there for everybody to learn, and for you personally it's good like for your career and whatever. On that topic, I did a meet up talk week and a half ago and it should be up on YouTube, like this weekend. So if

Jonathan Hall:

it Okay.

Shay Nehmad:

Comes out before the episode comes out, we might put it in the show notes. But it's Hebrew only, so sorry.

Jonathan Hall:

So if you don't say Hebrew, declined.

Shay Nehmad:

Yeah. Declined. Kuvia says no.

Jonathan Hall:

Speaking of people who say no, Brian Mills has recently announced that he's leaving or has left the Go team. So I guess he I guess he declined to go. I don't know how we wanna frame that. But anyway, thanks, Brian, for all your help, with Go over the years. It's, not not that we, like, are spying on the Go team, but, you know, this is a Go news podcast, so it's relevant to announce when one of them team members leaves.

Jonathan Hall:

I don't know who, if anybody, will will be replacing him, or if we would even know that information because it's not like Yeah.

Shay Nehmad:

The Go team is still act like Google. But thanks, you know, so much for all your work over the years. What do you wanna say is the highlight of, like, Brian's contributions, other than, you know, being a part of the team and sort of maintaining the language?

Jonathan Hall:

I I mostly know Brian through, his thoughtful comments on issues that I I track or when I'm preparing for the show. B BC Mills, I think, is his GitHub handle. So, you know, he he pipes in a lot with with, useful comments, as does the entire Go team to my knowledge. You know? I've never met any one of them who, I don't think are being helpful or constructive in the way they provide feedback.

Shay Nehmad:

So So thanks a lot, Brian, for, helping decline so many issues on that topic.

Jonathan Hall:

Would you tell us how it feels to be declined?

Shay Nehmad:

My proposal got declined yet again. Long time listeners know that, whenever a discussion, picks up on the channel where people are like, oh, I don't like this, I don't like that, and we're all, like, sort of complaining about a thing. If I agree with it, I like opening up a ticket, opening up a proposal. I did it once for YAML, where I wanted the YAML files to be part of the standard library, same as JSON. That got declined on the basis that YAML is not doesn't really have a spec, so putting it in the Go stdlib is kinda bad.

Shay Nehmad:

And also, there's a third party library that does it really well, and people really like, which is yamil.v3. So no real reason to put in the STDlib with a really thoughtful comment from, Russ, in the same vein of comments that you talked about. So in our one of our latest episodes, we talked about a new time format that someone suggested. Can you say it out out loud without opening the notes? No.

Shay Nehmad:

Nobody can, because it's 151, whatever, like a bunch of random numbers that actually mean the Unix timestamp. And that sort of speaks to how we do time formatting in the Go standard library. For those who aren't familiar, you have a time dot parse function that gets a string, that's the thing you wanna parse as the second argument. But the first argument is a layout. Now what's different about that layout than other languages that you would normally use?

Jonathan Hall:

It uses a reference date of January 2, 2006. I don't remember the exact specification, but it's it's a reference date until you basically just write that date in the format you want, and then it magically interprets that to be the format. Rather than doing like m m d d y y y, whatever.

Shay Nehmad:

Yeah. And, you know, the usual I guess the I don't wanna say standard, because there isn't really a standard, but I did a comparison to other languages, because suddenly when I thought about it, I was surprised. We put that proposal on the, we talked about that proposal on the show, right? Of adding Unix time, which looked really funny. And everybody on the channel chimed in and were like, this would make me dislike Ghost time parse even more.

Shay Nehmad:

And a whole bunch of people piled on because it's fun to complain about that function. Because it is kind of weird. Yeah. So I opened a proposal. I compared to Python, where you have datetime, I could put the JavaScript, where you have Luxon, and from format to explain.

Shay Nehmad:

I compare it to Java, like datetime format that runs on every enterprise machine in the world, probably can be wrong. And even a new ish language like Rust's, s t r f time, in their chrono format crate. And I wrote what we should do in Go. I tried to find, like, previous work and give some context as well. Just got declined as a duplicate because closed issues this was discussed in the past.

Shay Nehmad:

Closed in the past, and basically the Go team, decided that they're not gonna relitigate an issue without significant new information. And there isn't really significant new information. Like a bunch of devs rediscovering the time dot parse is kinda funny looking, is not really new information. At first I was kinda disappointed. Felt like I put in some work into it and I was like, why not?

Shay Nehmad:

But then, you know, with the explanation that Go has a single way to do things and it doesn't wanna support 2 ways to do the same thing, I was really pleased about it. Like after 30 minutes I cooled down, and, I think it was the correct ish decision. Even though we don't have like a standard ish library like yamil, dotv3. How do you think the, you know, the closing of the issue went? Like, do you agree with it or are you kinda

Jonathan Hall:

Ultimately, I I I do agree with the closing of the issue. I also disagree with the original design. But I don't think it's I don't think the original design is bad enough to warrant making things more confusing.

Shay Nehmad:

Yeah. I wish I were in the room where it happened when they decided so

Shay Nehmad:

I could, like, stop them.

Jonathan Hall:

If I could change one small thing about it, I would make it to use, like, ISO 30 was it 3339 date instead of a US standard date? Because that makes sense to everybody, but that's really a minor thing.

Shay Nehmad:

So my proposal get declined, yet again. I don't know if that's really news. It's like a dog bit a person. It's the expected way

Shay Nehmad:

of the world, I guess.

Shay Nehmad:

But there are some other, declined, proposals.

Jonathan Hall:

Yeah. We have a few others. So this is an interesting one. Things like this have come up a few times. This one got some new attention.

Jonathan Hall:

It was proposed in December 20th and, so it's fairly recent. The proposal was to add support for explicit conversion from Boolean to integer types. So if you write int paren and then a bool value is true or false, close paren, it would convert it to either a 0 or a 1. That was the proposal. And it has a lot of sort of supporting evidence that this is something needed.

Jonathan Hall:

A lot of people have commented that they wish the language did this. I have wished for this sometimes. Of course, it is possible to do the conversion, but it's like 4 lines of code to do that right now. Right? You have to create var I int if the boolean value then I equals 1 and then close parens.

Jonathan Hall:

That's that's 4 lines of code to get what could be turned into just a simple type conversion, in theory. Ultimately, it was declined.

Shay Nehmad:

Yeah. It was declined. This is, another, like, restart of an issue. This was something, that was proposed for Go 1.5, but Alan Donovan, who suggested this, you know, he brings the evidence when he talks about issues. We're gonna talk about another one of his proposals in just a few minutes, but one thing I really like is that he writes analyzers that look up specific cases, you know, that he, that he proposes.

Shay Nehmad:

So it's not just like, oh, I think it's gonna look cool. It's also like, look at all these places in the language where people solved it differently. We would use my proposals for this, you know, for this issue in various, you know, packages in the Go mod mirror. So that's really cool. Like bringing in the evidence both from, Go mod and also from the standard library, I think makes the discussion a lot more interesting, because you can see the real life examples, and you can see, you know, in the standard library, when you do time format, if we're already talking about it, there's a place where you do int of u equals equals 0, and you put it in a variable called n.

Shay Nehmad:

Like whatever that means, it would have been replaced by just like u. Right? Mhmm. So u equals equals 0. Yeah.

Shay Nehmad:

So it's an interesting thought at least, but it's not super difficult to to implement. Like it replaces basically a var and an if. So it is in the realm of syntactic sugar, at least for me. Mhmm. Yep.

Shay Nehmad:

So it got declined after a lot of discussions, and I think people aren't happy with the decline because the decline has, like, 11 down votes and some sad faces.

Jonathan Hall:

Yeah. So I think this is an example where the Go team is kind of in a tough spot because you get a popular request like this. But they they wanna decline it because it's it's not solving a really serious problem. It's it's solving a slight annoyance. So it's something a really serious problem.

Jonathan Hall:

So is it really worth the effort of of introducing another way to do something and go, you know, ensuring that it doesn't break any code. I don't I don't know how it would, but maybe it could. You know, but you you need to be very careful when you're doing this sort of stuff. So I I understand why the Go team sort of biases toward not changing even in a popular thing like this, but it it puts them in a tough spot because now they have to make the unpopular decision to not do something that is popular. And it's judgment call that, you know, I don't know how I would do it better.

Shay Nehmad:

And people, by the way, said that where they're surprised by the, you know, change in consensus. And I think people don't realize that consensus doesn't mean a consensus in the GitHub issues, like up votes and what do people say. I think it's consensus in the review board, where people actually sit and talk about the issues, sort of an architectural overview board that has all the context, has all the history, and ultimately holds the decisions. But, you know, there is one very interesting comment, if we're already talking about the client proposals, from NDG that says basically, given that, you know, every change becomes more difficult and the bar gets raised every version. Right?

Shay Nehmad:

Because you have to worry about more things. The language is getting more and more complicated as time goes on and as we're adding things to it. Overall, like there were changes that simplified language. But overall, I think as a trend, we're adding more and more stuff to the language. Right?

Shay Nehmad:

Now you add into bullying, you gotta make sure, I don't know, the performance tracer that we talked about 2 weeks ago still works when you do the release. Like you have more things to worry about. So Andy says that he would love a way to weigh in in prioritizing changes, instead of, like, more than just commenting on GitHub and saying, like, plus or minus. I'm wondering how much that resonates with you. Because users usually don't know what they want, you know.

Shay Nehmad:

We've been developing software long enough to know that. But I I don't know, maybe language community members affecting the 33% of the priority in like popular votes or something like that. I have something similar at work where I have a developer survey and that, you know, directly impacts what I do because I do engineering effectiveness. Like I asked the developers, would you rather I work on ease of release or would you rather I work on documentation quality? And even if I think that X is better, if you know, all of them vote y, then I'm gonna work on y because you have to make people, also use the solution you're developing, not just use the but not just develop the best solution you can.

Jonathan Hall:

Yeah. I definitely think that there's room for more influence from from the public and and and maybe even just, like, more attention. Like like, I I think it's easy for issues. I have a proposal that I think is perfectly acceptable. I don't see any objections to it, and it's just sitting there.

Jonathan Hall:

It hasn't really I mean, it got attention when I first published it. It just sits there. I I wish that these things would get our attention. If you're gonna decline it, fine, but at least decline it. I didn't do I don't even get that respect.

Jonathan Hall:

You got yours declined. Mhmm. Why is it sitting there rotting? So, you know and and I understand that they're busy. I'm not trying to to pick on anybody here, but I I do I I think I've said this before, if not on this show in another venue, I wish that there was more of a, like a community liaison or something on the Go team who would help.

Jonathan Hall:

If they can't improve the way they're doing this, at least to communicate why. You know, let let us understand, and, you know, just be that liaison for us and help us understand what what you expect from the community as the Go team and how we can interact effectively.

Shay Nehmad:

Although, I do think, just to be fair and round the doubt, that this balance is okay. I mean, it can be better, but it's good. It could be

Jonathan Hall:

a lot worse too.

Shay Nehmad:

Yeah. The main priorities are not making the community happy. The main priorities are making sure the language is stable, a new version comes out every 6 months, making sure it's secure. You don't hear anybody complaining about, oh, the patches are coming out too slow for security updates, because they're super on top of that. So, you know, I do think they have their priorities straight.

Shay Nehmad:

I guess wishing for more capacity in the Go team in case, Sundar is listening to this podcast, you know, maybe throw 2 extra $1,000,000,000 a year towards the Go team. I don't know. I don't think Gemini is doing that well. Maybe you can divert some funds.

Jonathan Hall:

So before I finish at this topic, I wanna mention one, comment that Rescox made that I I I like. It's not really relevant to the topic, he said but it's an interesting comment. He says, I am sure approximately nothing uses complex types. If Go didn't have them today, I think we would decline adding them pretty quickly. It's fun to hear that from somebody who I know as part of his day job investigates public uses of Go features.

Jonathan Hall:

And if he's the one telling us that approximately nothing uses complex, that inspires me to not add complex support to any tools I'm ever creating for Go. Totally.

Shay Nehmad:

Wait. What what does he mean when he say complex types?

Jonathan Hall:

Complex 64 and complex 128. Oh, yeah. Numbers.

Shay Nehmad:

Yeah. Well, if you got

Shay Nehmad:

to that point, you're on your own. So another proposal we wanna discuss, it's currently active so you can influence its future, but I do think it might get declined based on, Russ' comments, just because it doesn't seem worthwhile. But it is interesting. It's simple enough to actually say the code out in, audio form, which is rare for us. So it's a new function.

Shay Nehmad:

Right? So func. The function is called is, I s, and it gets one parameter, x of type any. Right? So it's a generic function.

Shay Nehmad:

You can pass any type of parameter. Returns true or false, returns true if, the type assertion would succeed, and false if it doesn't. So you basically can use it, you know, if you want to make sure a thing is of a type y. Right? So you call is square brackets, I know, int, then you pass in a string, it would say false.

Shay Nehmad:

You pass in an int, it would say true.

Jonathan Hall:

Right.

Shay Nehmad:

So it's sorta about generics indirectly. There are a lot of examples in other languages. This proposal is by, Allen Donovan, who we already mentioned. So like he usually does, he put the analyzer here with all the examples where this is relevant, and 2.5% of modules on Gomod define a function that is basically is. So you know, you have to rewrite it for almost everything.

Shay Nehmad:

Which is, you know, I think it's a very compelling argument. Right? Many of them are related to errors. You check if something is of type specific error, and then you handle that specific error differently than, you know, just a generic let's panic or something.

Jonathan Hall:

To to be clear, if anybody's not obvious to everybody, you can do this right now but it's more verbose and cumbersome. So if you do underscore comma okay colon, then your variable dot and a type assertion, that that okay that's returned is true or false. That's the same value we're looking for. Just a a more concise way to do it that It doesn't require 2 lines of code that you could, like, put 3 of them together in an if statement without being awkward and that sort of thing.

Shay Nehmad:

Yeah. You the problem right now is that you can't use it in, like, you know, expressions in the middle of an expression. Because you have to if you wanna do if something and end x is of type y, there's no way to write that out in a single line. Which, you know, saying it out loud sounds kinda funny. There's no way to do x is of type y, like, is x of type y?

Shay Nehmad:

There's no way to do that. Yeah. So if you have a lot of code that uses, like, some types or you you have some code that analyzes Go code and you wanna do assertions on types, if you develop a linter that like checks for specific types or whatever, you're probably gonna wanna chime in because this proposal I think is on its way out. I like it. It's simple, I wouldn't think twice if I saw it in code.

Shay Nehmad:

I would just read it and I was like, I understand completely what this does, which for me clears the bar enough to do it. But I wouldn't add a third party library for that support, right? If I needed to implement it, I would implement it myself, like 2.5% of the packages, in GoMUN Mirror. But I think the Go team's attitude towards this proposal is, while it's true, x, okay, you know, doing like the okay type assertion just gives you the value you need to use, and that's okay. Because that's usually the case you wanna do.

Shay Nehmad:

You don't wanna just do the type assertion, you also wanna use the thing as the new type. So that's sort of where they are. Is wouldn't give you the new type. It would just give you the true and false part.

Jonathan Hall:

So I have 2 issues, maybe 3 issues with this proposal. I agree that the that it's trying to solve a problem that I want to have solved. I don't know if I agree with the way to solve it. So first, I I think this problem is broader than type assertions. We have the same construct where you where you do underscore comma okaycolon equals when doing certain map lookups, when reading from a channel, and so on.

Jonathan Hall:

I would I would like to see a solution that solves all of those in the same way. You know, if I if all I want to see is did I get a revert a value from this channel, I is wouldn't work for that, but I feel like it's solving the same problem. So I'd like to see a solution that works on all 3 of those cases. Maybe there's others too. I'm not sure.

Jonathan Hall:

And then the other is, one of the comments I thought was interesting. When we're doing built in functions, we aren't strictly tied to the function signatures that we are in other cases. We have, like, make and new are great examples. They're built in functions and they take types as arguments, like type names, which you can't do at regular functions. Why not do the same thing here?

Jonathan Hall:

If we're gonna have an is function, just make it take 2 arguments. The first is the name of the type and the second is the variable or vice versa. So is x int? Why not do that rather than making it a syntactically generic function? So those are 2 but those are my two complaints mainly about this.

Jonathan Hall:

They aren't really compatible with each other. Mhmm. But, I would love to see a solution. I don't know what the solution is, but I feel like it should be, like, I don't know, an alternative to the blank identifier that makes it that turns it 2, return an expression that returns 2 values into one that only returns 1, like, completely ignore the first value or something like that. I don't

Shay Nehmad:

I definitely wrote this function, like, twice in my life already. Mhmm. I wasn't like I wrote it in a single file where I used it. It wasn't like, oh, in my normal utilities that's always what I put in, in the same way that Yeah. Okay, new Go project, need to go Langsy Island, find the golden config file, set up the Earth file, you know, you go through that rigmarole the first 15 minutes where you set up the thing.

Shay Nehmad:

Wait, what's the GitHub address? Is it GitHub.com? Is it HTTPS, GitHub.com? How do you set that up, etcetera, etcetera. It's not part of that.

Shay Nehmad:

Like, it's not part of the boiler plate of every new project. It's kind of a localized feature. So if the bar is indeed high as we're learning on this episode, it's okay that this will get rejected, but if you have a lot of use for is, then it would be a good place to chime in. I can imagine in code generators, by the way, this is a would be a huge deal. Right?

Shay Nehmad:

Because you wanna generate code, but you don't really care about the underlying value. If this is int, then I wanna generate, like, a go function that gets int or something like that. I don't know.

Jonathan Hall:

I'm I'm working on a project exactly like that and I'm I'm running into that. It's essentially the same problem. Yes.

Shay Nehmad:

So maybe you can go comment that in upvote. But if you don't like that API, so maybe don't. Well, yeah.

Jonathan Hall:

I think it's like I said, I think it's a problem that should be solved. I don't know if I like that particular solution.

Shay Nehmad:

Let's talk about one more declined proposal. This one, an easy one that I'm I'm I'm very happy that it got declined.

Jonathan Hall:

So we're all excited about the new Range Rover Funk that's coming through, or maybe some of us aren't. We've talked about that on the show before too, but it's coming probably in Go 1.23. It's already available as an experiment. If you enable Go experiment equals range funk, you can already play with it. So somebody observed that you can range over a nil slice or a nil map or a nil channel without a problem, and it just treats them as empty.

Jonathan Hall:

But as soon as you try to range over a nil func, you get a panic. So the proposal was to make a nil func with this new range over func act as though it were an empty set to iterate over. That was the proposal, and it ultimately got declined. And you think it that's a good thing. Why?

Shay Nehmad:

Because it says the word for when you do, 4 range over an iterator, but it's just syntactic sugar over a function. And calling a nil function panics. It's more consistent. Like, laying it out like that is unfair. You're really like, 4 range slice doesn't panic.

Shay Nehmad:

4 range iter does panic. Doesn't that seem weird? But a slice is not a function. It's a it's a pointer to a container type. Right?

Shay Nehmad:

Like that has 0 or more elements. And very predictably, you iterate over the the four body 0 or more time. It's super consistent to everything you know, and it's also very natural. Trying to call a nil function, you should definitely check that the function is not nil before you call it. Right?

Shay Nehmad:

Mhmm. The way you get this, iterator, right, the way you fill it in, is very different from the way you fill in the slice. You know what I mean? You you would need to have someone give you an ill iterator to get that. And that's going to be kinda rare because because you wouldn't be able to pass it in.

Shay Nehmad:

Like it would fail upper higher up the stack. It's gonna be a very rare case of like converting types from any without any, like, type safety checking to get to that situation, I think. You know

Jonathan Hall:

I agree with you.

Shay Nehmad:

Nil iterators are just a mistake. I would assume that someone can find a way to write a linter that even detects that, right? Where you if you get a In some cases, yeah. An iterator, and it's not a 100% certain from the types that it's not gonna be nil, then it's gonna, like, flint you. Like, I think this is something we can do even in GoVet.

Shay Nehmad:

So I'm happy that it's gonna panic. Like, write your test, it's gonna panic, and then you're gonna figure it out and be like, oh, I made a big mistake here. I shouldn't iterate over this nil value.

Jonathan Hall:

And honestly, from a debugging standpoint, I would rather it panic than behave as though it were empty because I'm more likely to detect my bug that way.

Shay Nehmad:

Yeah. You would put, like, a breakpoint in the iterator, and you would be like, oh, no. Why am I not iterating? Am I not producing the messages into that, function or whatever? I think it's more consistent.

Shay Nehmad:

But it's still a worthwhile proposal. It's it's an interesting discussion, just with a clear cut, you know, conclusion. So thanks Tamayaka from Japan, from, opening this, issue. And thank you Go team for declining it.

Jonathan Hall:

Let's talk about one final thing that's not declined and that is our upcoming interview. Woo hoo.

Shay Nehmad:

If you're into terminals, like me, and you like playing around with your, terminal and terminal configuration, you're gonna love this. We're talking about Elvish, the 100% go and, terminal and also, like, shell scripting language.

Jonathan Hall:

The one shells rule them all.

Shay Nehmad:

Yeah. Speak, go, and enter. They they should have put that

Qi Xiao (xiaq):

on there.

Jonathan Hall:

There it is. There it is.

Shay Nehmad:

That's coming up right after this break. Stick around. This show is supported by you. Thanks a lot to all our new and existing Patreon members. We wanna shout out the new members, that joined this week, Rob Prentice and Charlie TC.

Shay Nehmad:

We're just paying for like equipment and mostly editing fees and stuff like that. Shout out to our amazing editor. Where can you reach us? You can reach us at capago.dev, you can reach us at the go for slack, hashtag capago with dashes, so like kebab case. You can email us at news at capago.dev.

Shay Nehmad:

That is news@capago.dev.

Qi Xiao (xiaq):

You

Shay Nehmad:

can also buy Swag at store.capacode.dev. Basically, find all the links on capacode.dev, including all past episodes. Before we jump into, you know, the rest of the, break, I wanna tell you about this week's sponsor, boldly go. Tech. So if you're listening to the show, you're probably running some Go code in production.

Shay Nehmad:

And if you haven't heard all about BoldlyGo. Tech, you might be already running their code in production. What? Yeah. That's kind of a bold clue.

Jonathan Hall:

How is that possible?

Shay Nehmad:

Well, they've contributed to many popular open source projects, including Loggres, the Go language itself, Echo, Sentry, CouchDB, and others. Wow. This is Jonathan. Jonathan's looking at me. This is me.

Shay Nehmad:

Like, looking for when I'm gonna tell the people that. So yeah, Jonathan's available for consultation. He can help you build your projects for you with implementation. He can help you debug broken behavior that's just got you stumped. He can do code review and auditing and even architectural reviews and guidance.

Shay Nehmad:

You know, his code has been trusted by companies that you know, Canonical, Unity, Deliveroo, Booking dot com. You can do a lot worse. So, you can reach out to, Jonathan at baldi go.tech/subscription. Link is in the show notes. Thank you for your sponsorship.

Jonathan Hall:

Hey. No problem. And thanks for the the kind plug.

Shay Nehmad:

For sure. So other than, our patrons and the sponsor, we wanna nerd out about 2 things. One, we wanna ask you to leave a review on Spotify, Apple Podcasts, or wherever you listen to your podcast and sort of share the show. We've been getting really, really, good responses on the show lately, a lot of interesting discussions, people reaching out to me in meet ups and being like, hey. I know you from the podcast, which was which is new, at least for me.

Shay Nehmad:

And we wanna nerd out about analytics a a little bit. We we tend not to do this too often, but we recently crossed a really exciting milestone. So we recently crossed 50,000 downloads on our episodes, which is a really big milestone. It's more than the population of the Northern Mariana Islands, but slightly less than the Faroe Islands that belong to Denmark. But like you go to the list of countries in the world and you have like Vatican City, right?

Shay Nehmad:

Where there are like 500 people. We're way above that in the list of countries, which is amazing. It's just mind blowing to me, and we really appreciate all your support. Especially considering that we've talked about this in the past, but like download numbers are not really reflective of listening numbers. So I think it might be even more people that actually we reached out and maybe even helped, you know, and educated a little bit.

Shay Nehmad:

So that's been great. We've really appreciated all your support over the last, whatever, I don't know, year and a few months.

Jonathan Hall:

Yeah. And I think I also deserves a shout out. February was our record breaking month. We had 5,503 downloads in February. Woo hoo.

Jonathan Hall:

Which which beat our previous record by about 10%. So we're on an upward trend, I guess.

Shay Nehmad:

Yeah. Yeah. Really cool. And I know people like to nerd out about that as well in the top countries. So US is still firmly on top, but second place is Germany.

Shay Nehmad:

And they, outrun the UK, which used to be our second, second top most listening country. And Israel's up there as well, like, place, 8 or 9.

Jonathan Hall:

Netherlands is just barely beating on Israel by, 2 tenths of a percent.

Shay Nehmad:

Yeah. And also a lot of listeners from India. So shout out to our 2% of listeners from India. Yeah. And and that we just wanted to say thank you for all the support and and share, you know, share our enthusiasm, with you.

Shay Nehmad:

So thanks a lot.

Jonathan Hall:

I think that's it. Stick around for Elvish.

Shay Nehmad:

So, John, did you check out my new tattoo? I love it. Yeah. Do you know where it's from?

Jonathan Hall:

I don't.

Shay Nehmad:

What does it look like?

Jonathan Hall:

It kinda looks like something from Lord of the Rings, maybe.

Shay Nehmad:

So I wish, there was someone here who spoke Elvis who could help you with it. Oh, hi, Chi.

Qi Xiao (xiaq):

Hi. I know How you doing? Although it's maybe it may not be the the Elvis that you're looking for though.

Shay Nehmad:

At this point, Jonathan will take anything you can get. So how about you tell the listeners a little bit about yourself?

Qi Xiao (xiaq):

My name is Chi. I'm a software engineer, and I I use Go. And among other things, I developed a shell and a programming language. It's the it's one thing, not two things. It's called Avish, and that's what I'm here to talk about today.

Qi Xiao (xiaq):

I'm really glad to be here.

Shay Nehmad:

We're glad to have you, man. So, you know, all of us developed our own shell and programming languages every Monday Thursday. So so nothing special there, but what's special about Elvish?

Qi Xiao (xiaq):

What is special about Elvish is that I think it has, well, there's nothing, like, super new about Elvish. I tried to stick to, like, Rust's kind of old mantra that it only uses things that are actually well researched. That's where the name Rust comes from, but I actually try to stick to it. So but what I'm trying to do is I'm trying to, build kind of a modern scripting language and, build it with a very super nice, interactive features, and also make a shell programming language, which I think it it is a combination that is not that is not very common. At least, not very common when I when I started Elvish.

Qi Xiao (xiaq):

I started Elvish, I think, 10 years ago. And, at that time, like, when you use Shell, people just think, like, Bash or maybe this Chinese shell z e s h from 1991. So Mhmm. Or some people use fish. But, at that time, I felt like not all of them have very modern scripting language.

Qi Xiao (xiaq):

It's a little bit different today, but that's when I started. It was kind of like that. It was kind of a unique combination of a good interactive shell and a model scripting language.

Shay Nehmad:

Cool. Did it come, like, out of, obviously, not everybody is developing their own languages, every all the time. It's something very unique to do.

Qi Xiao (xiaq):

That's surprising.

Shay Nehmad:

Yeah. Maybe because it's hard. But, you know, did it come out of

Shay Nehmad:

a need where you're, like, frustrated with the Z Shell

Qi Xiao (xiaq):

and Fish? So let me tell you a bit of my backstory there. So I think it was the last day of my uni. So I became kind of kind of a command line enthusiast, I think. So I was in a computer science adjacent, major.

Qi Xiao (xiaq):

So I did all my assignments on the Linux command line, even those that I probably shouldn't have done, like, CAD stuff. And, I was also doing some, system admin work, for the local open source software Mirasite. The the things you get, like, think things like you get your APT, package on, like, if you use Debian or RPM package if you use So I used shell quite heavily, both kind of interactively in my workflow, but also, using scripting because of those system administration work. You need to, like, periodically synchronize your mirror side from your upstream, like, for instance. For Debian, you will go to the actual official Debian download side and synchronize all the APT packages from it.

Qi Xiao (xiaq):

So there were kind of 2 things among others that kind of made me want to write in my own shell. The first thing was I was using Anzesh at that time, and I tried to implement an interactive directory history in Zesh. And I thought, oh, this shouldn't be hard because this language is, like, super powerful. You would do all sorts of stuff with it, like, having Tetris, including Tetris in the terminal with Zesh. So I tried I tried to do that, and I made a mistake of opening up Zesh's, user menu.

Qi Xiao (xiaq):

And, I saw all this very like, it has, like, 20 different operators for the different string operations. All with, like, either symbols or, like, a single letter names. That was really I felt really overwhelmed at that point. And I and I closed it in a panic.

Shay Nehmad:

That's funny. I've I've opened, like, I'm I'm using Zesh. That's my daily driver. Jonathan, what's yours? Probably bash.

Shay Nehmad:

Right?

Jonathan Hall:

I usually use bash. Yeah.

Shay Nehmad:

I never opened the user manual. Like, I never went Yeah. That way. Oh, it looks Yeah.

Qi Xiao (xiaq):

I think now old. I think nowadays, there probably isn't such a need because with things like, oh, my gosh. Like, if you want to do something more interesting in there, probably somebody has already gone to the trouble of reading the user manual and written a plug in for it. But, that time, I was trying to implement kind of my own fancy interactive features. Right.

Qi Xiao (xiaq):

And and another thing was, back to the open source mirror side. So I was debugging. So we had we hacked up some shell scripts to kind of periodically synchronize all the, like, packages. And, before it was just really hard to do anything slightly more complex with it. And I thought it was it must have been just that.

Qi Xiao (xiaq):

I really sucked at this language. Oh, and somebody came along, and they they told me, oh, I found this, very well written, very well maintained script from, and it's called FTP sync. And he showed me, oh, you must use this. It's very it's very nice. And I opened up, and I I realized it was not my fault.

Qi Xiao (xiaq):

It was it was the shell's fault. Like, you you just can't write very clean, script with the the traditional shell features. So those were kind of 2 things among other experience. Like, I think those are the 2 typical most typical experience I can still recall. And, I just I felt that, Shell is really kind of underpowered.

Qi Xiao (xiaq):

And, at that at the same time, I was also quite interested in things like programming languages. And, so I picked up a copy of, APUE, advanced programming in the UNIX environment. And at the same time, there's a new language, from some of the original developers of UNIX, that came out. You will be surprised to know what it is. It's called Mhmm.

Qi Xiao (xiaq):

It's called Go. So Go just came out last summer. I think when I first started developing Elvish, I was using Go 1.1. So not exactly the day Go was released, but, like, a few months after that.

Shay Nehmad:

It's interesting that, you know, the new language came out and almost inevitably, like, there was a shell in it. There was a, like, everybody just reimplemented the things that they care about in that new language. But other than the fact that it's, you know, formally Unix guys, which is, like, for your specific application is very relevant. But other than that, why, why go? I mean, most shells are written in c.

Shay Nehmad:

Right?

Qi Xiao (xiaq):

Most shells were written in c. I actually started trying to implement Elvish in c, and I kind of just gave up after a few days. I thought I need a more modern language. Like, things like it's very hard, to actually properly modulize your c code. You have to have all those like, you have to do manual name spacing.

Qi Xiao (xiaq):

You have to come up with a unique prefix for all your functions and stick to it all the time. That was quite painful. Also, like, cross compiling c was also quite painful. So that was why Go really appealed to me when it first came out. And I found more reasons, to actually use Go along the way.

Qi Xiao (xiaq):

We can talk about that now.

Shay Nehmad:

Sure. Go ahead. What features are are, like, the main ones in Elvish? Because it's not an HTTP back end server for so for, like, 80% of the listeners, this is totally new ground.

Qi Xiao (xiaq):

Yeah. It's not an HTTP back end server. It is a shell. And, Go is actually quite relevant because several reasons. 1st, Go is actually reasonably fast.

Qi Xiao (xiaq):

It wasn't actually super fast when it first came up, but it was already kind of fast enough for my, purposes. It had much, a much quicker startup speed than Java. And, it's, in general, its performance is much better than things like Python, Ruby. And, if you think about 10 years ago, there wasn't a lot of players in that niche, really. Nowadays, you have things like Rust, Zig, and all those kind of new coming like newcomer languages that aim to place c and c plus plus But really 10 years ago, if you ask somebody, what's the better version of much better version of c?

Qi Xiao (xiaq):

Like, Go was a pretty reasonable answer. And, there's some more reasons to use Go. So for instance, Go code turned out to be quite readable. And, I knew this I kind of knew this at the beginning because I I kind of trusted the taste, of the people who were involved in the original Unix. And, I've I've I'm vaguely familiar with some of their work, like plan 9.

Qi Xiao (xiaq):

And I think before Go, Rob Pike also worked on several programming languages. I think one of them is called it's not called Limbo, but it's there's an operating system called Limbo, and it has a corresponding programming language. And, I think they're I kind of like their taste. So I think this is probably a language that I will also like. And, also, eventually, I discovered Go has Go had great tooling.

Qi Xiao (xiaq):

Like Go FMT, when it first came out, it was actually quite new. Like, there were things like, the format just was not new. Right? But, like, saying that the language has one format that everybody uses, it was quite new. So I I didn't have to worry about how to, which style might which, like, indentation style, which great style, my my my program should use.

Qi Xiao (xiaq):

So it was pretty nice. And, also, nowadays, you have Go PLS. And but before that, there was another program called Go Code that makes very easy to get, like, ID like experience in editors like Vim. So that was pretty nice.

Shay Nehmad:

Oh, you use Vim as an edit?

Qi Xiao (xiaq):

Yeah. I used Vim as

Shay Nehmad:

an editor. You'd write your own.

Qi Xiao (xiaq):

No. I have I have not yet.

Shay Nehmad:

Yes. I just can imagine, like, 2 listeners right now dropping their phone and running to Slack and be like, dude, let's write the next meme and go.

Qi Xiao (xiaq):

I I think the well, but on a more serious note, I think the, market of editors is is quite saturated these days. And I use Versus Code most of the time.

Shay Nehmad:

Me too. Me too. No shame. You you turn on a VIMA mode and you're just as hardcore as people who spend, 45 minutes configuring their, like, neo VIM configuration files every day, but you just get more stuff done. I just convinced one of my team members, you know, we're sitting there.

Shay Nehmad:

He's fighting against his neo VIM config. Like, dude, just open VSCode. Let's get to work. Anyway, editor fights aside. It's not it's not, the that show.

Shay Nehmad:

He he backs all the way. I can't believe.

Jonathan Hall:

Okay. I wanna talk about elder some more instead of editors. I'm curious as a scripting language, how does it compare? How is it better? How is it maybe more limited than let's just use Bash or POSIX since that's what everybody is familiar with.

Qi Xiao (xiaq):

So I think when it comes to scripting, I think there are essentially two aspects that I think that makes it better than more traditional shells. The first aspect is that it's actually quite clean. So if you you actually kind of need a degree to write and correct shell scripts, right? You need to remember to always quote, your variables with double quotes. Otherwise, like, white spaces and, and the wildcards in the variables will do weird things when you run when you run it.

Qi Xiao (xiaq):

And you need to know how to do error handling properly. There are a lot of articles you can find on the some telling you that you should always use set dash e. And for bash, there's also, I think, something called pipe status, something like that. And but none of them actually kind of work 100% of the time. So you have to be very careful to handle errors correctly.

Qi Xiao (xiaq):

And kind of doesn't have those problems. So for instance, every variable in Elvish would just expand to a single, value. You wouldn't do all those shenanigans behind your back. And error handling, which takes this kind of succeed or die approach to error handling. A lot of things just become exceptions.

Qi Xiao (xiaq):

Like, if you call an external command and it says with non zero, that's an exception. If you don't catch the exception, it just crashes your entire script, which I think is actually desirable behavior for a lot of usage, scenarios that you would use shell in. Because when you write a shell script, we kind of expect it to, like, to follow a predefined script, right, because it's called a script. And if anything goes wrong, the correct behavior is to stop and not proceed. So this is one aspect where I think it's just a much cleaner language.

Qi Xiao (xiaq):

Another aspect is that I I made Elvish basically on par with, like, modern scripting languages. So things it has for instance, some things it has is, like, nest nested data structures. In bash or zesh, you can have strings. You can have arrays of strings. You can have maps of strings, and that's it.

Qi Xiao (xiaq):

You you can't have an array of array of strings, and you can't have a map of where the value is a is the list of strings, so things like that. Elvish doesn't have those restrictions. It just, like, takes kind of, like, a a common sense approach if you are designing a new dynamic programming language. It also has, 1st class functions, which is more useful than you might think because one my favorite example is we are customizing your prompt in bash. What you do is that you learn this all those escape codes escape codes, with percentage or something.

Qi Xiao (xiaq):

Like, for instance, percent h is host, percent u is user. I think, like, there are many reasons why it works this way, but I think the fundamental reason is that batch doesn't have first class functions. Because in the Elvish, the way you customize your code is you redefine a function, and that becomes your prompt. And you assign this function to a variable called edit colon prompt, and that's a prompt. And the way you do install completion scripts in Elvish is that there is a map from the command name to a function.

Qi Xiao (xiaq):

And so, for instance, if you're writing a new completion script for git, what you do is that you would assign the git element of this map to a function that takes your existing command line and outputs what you want to complete. Whereas, if you look at, for instance, the command completion API of bash and zesh, There's a lot of, like, it involves multiple commands. It has a lot of flags. Like, I don't think all of this is to make up for the fact that we don't have things like first class functions. And nested data structure because completers can get quite complicated.

Shay Nehmad:

I wanna shout out a specific, feature, exceptions. And the reason I wanna shout it out is not it's not especially like, it doesn't stand out especially in the documentation, but it stands out to to me personally. I'm gonna put myself out here. I had a really shitty bug with a bash script last week where RCICD pipeline is in, bash, like, mostly bash scripts in GitHub actions. And there was a command, like, run the tests and then error code equals the error code of the tests.

Shay Nehmad:

Right? Which is how you carry over errors like and then do some error handling and then pipe the error out in normal shell scripting. In Elvish, if I understand correctly, it would have been an exception. Right? And I had to do, like, try catch if I wanted to explicitly do stuff.

Qi Xiao (xiaq):

Exactly.

Shay Nehmad:

That would have been great to news to me last week, because, this week I just used shell, and then I accidentally shoved another command in between the tests and the error code, capture. And then suddenly all our pipelines were super green and everybody was happy. And for, like, 24 hours, we didn't actually run the test. Like, we ran the it's even worse. We ran the test, we spent the time, and then we GitHub was always green.

Shay Nehmad:

So there are a ton of great features here in the scripting

Qi Xiao (xiaq):

I should advertise this more loudly, I think, especially for people writing the ICD scripts. Also, that's that's actually very relevant because just a few weeks ago, I converted the majority of, the shell scripts used in Elvish's own SaaS CD pipeline to use Elvish itself, and it was a very nice experience. And, in my old shell script, I had a lot of had a lot of caveat saying that, oh, I didn't bother making this JavaScript, like, white space correct. So make sure you don't have any white spaces in your file names. And also, this arrow should probably be handled correctly.

Qi Xiao (xiaq):

I have I have a bunch of comments that are around my shell script like that. And with Elvish, the the shape of the script is mostly the same. It didn't use a lot of fancy features but just all the caveats just went away.

Shay Nehmad:

That leads me immediately to my next question. I think one of the reasons shell script is so I guess the word I'm looking for is ubiquitous. It's just like everywhere. Right? Is that you can assume that s h is installed on the machine you're running on.

Shay Nehmad:

Yeah. Whether it's someone else's machine in your company, whether it's open source, you know, someone what just want to install something, then you can just do, like, curl, run the script. Right? And especially in CICD pipelines where, you know, they change runners, they change containers, the underlying image might get updated whatever whatever. But you can always rely on sh to be there.

Shay Nehmad:

How hard Yeah. It is in your experience to come to a a group like r and d group or a company or something like that? Cause what I'm imagining is a lot of our listeners right now are like, wow. This is cool. I wish I could use Elvish in my company but obviously I can't because integrating it is gonna be kind of difficult.

Shay Nehmad:

Like, you need to learn a whole new language and you need to install a lot of stuff. So I'm interested to hear, you know, about the human aspect of, like, how does integrating Elvish into an existing code base or an existing company, how does that shape out?

Qi Xiao (xiaq):

So I haven't have I haven't, like, talked to a lot of peoples who are trying to do, like, integrating them into their own existing pipeline. I know there are I've seen in Elvish user group that some people have managed actually managed to to to integrate them into, like, their research projects, like data pipelines. But I I to be honest, I don't have I haven't talked to a lot of people who are trying to do that, but I can tell you kind of my experience and also some of the objective facts. So I think what I would say is that it's much easier than you might think. And this is where I think a big advantage of Go comes in because, cross compilation is just trivial.

Qi Xiao (xiaq):

We are using Go. If you go to Elvish's website, it's the first time I plug his URL. It's just elv.sh.

Shay Nehmad:

That's a good URL, man. It's a good domain.

Qi Xiao (xiaq):

It's a domain hack I'm really proud of. And if you go to the get section, the top nav bar has a get section. It generates a script for you. And, it's really just a few lines of code, and you can just paste this script anywhere. And you can just start running Elvish.

Qi Xiao (xiaq):

And, I also made a GitHub action. It's called what is it called? It's called GitHub actions action, I guess Mhmm. That you can use to just use Elvish inside your GitHub action. I'm saying action too many times here.

Qi Xiao (xiaq):

And it is really it is super it is super easy because because of this the fact that, Go you can't compile things to just a single static linked binary in Go. And, I use Elvish on my servers as well. What I literally do is that is just I just SCP my local Elvish binary to my SSH host and then /user/local/thing, and then I can start using Elvish. So it is a little bit of barrier to overcome, and, I I would say that some people would may just not bother. But for me to just not, like, give up and admit defeat, I think what I'm what I'm trying to do is to make Elvish as, like, compelling enough that people will overcome kind of this small barrier to actually start using it.

Jonathan Hall:

Is there I can imagine that the answer to this is no. But I wanna just be I wanna ask it so we can get it out there. Does Elvis try in any way to be POSIX compatible or or similar enough that it feels like the same sort of thing when you're writing it? Or is it did you just sort of start from scratch and and is it a completely different experience?

Qi Xiao (xiaq):

That's such a very good question. And the answer is actually not a complete no. I think I mean, on a surface level, the answer is no. Like, I wish it is a non POSIX program language because I want to, like, shed all the baggage that comes with the, like, POSIX shells. Right?

Qi Xiao (xiaq):

But, on the other hand, I'm kind of I'm trying to keep very familiar to somebody who uses POSIX shells. So one example I would point out is that I think there has been a lot of kind of new shell languages, this years. And, one thing Elvish does is that anything you type on the command directly is always going to be a command. I think a lot of newer shells will do things like, if you type a number, it just becomes a number. It's not a command.

Qi Xiao (xiaq):

If you type like, if you quote your string, it becomes a string, and it's not a command. I always tries very hard to keep that kind of traditional shell feeling, if that makes any sense. And, I try to not, like, as as much as as it is a non POSIX language, I also try very hard to not use a lot of new kind of symbols, a lot of new keywords. It has to be some keywords. But I think the overall feeling, if you compare it to many other, like, modern shell languages, it's it feels more like POSIX shell.

Qi Xiao (xiaq):

And also that so that's that's one part of my answer. Another part of my answer is that I actually worked quite kind of briefly on a POSIX compliant like, not POSIX compliant, but kind of POSIX compatible shell. It is in my it is on my GitHub. It's, on my GitHub. GitHub slash xiaq slash POSIX SH.

Qi Xiao (xiaq):

And my plan was well, my plan is still is maybe I can integrate this into Eldridge someday, because some people have these small snippets of, vaguely POSIX shell lying around. Like, maybe they got they copy something from the Internet. Maybe they just have some old config that I they don't want to bother porting to a new language. I think that is still a that is still a possibility in the future, although it's, it's not done yet, but it's possible.

Shay Nehmad:

And another question for, that I I'm pretty sure the answer is no, but it is but I also wanna put out there in a completely different direction. Elvish has a lot of work behind it. Like, I look at the site, this by the way, the new site looks awesome. You know, there are release notes. There's documentation.

Shay Nehmad:

You have, awesome Elvish group, you have a Telegram group, like, it looks very serious, but I don't see the enterprise pricing button anywhere. What's up with that?

Qi Xiao (xiaq):

So right now, I think, I've thinking about, things like, building kind of a business out of this. But I think at this stage, at least probably for a few more months, I'm kind of still focusing on the technical aspects of it. And I think one distinct advantage that building a shell can have is that you can kind of get people to start using it kind of step by step. You can kind of get people to use it first as their interactive shell. Maybe they're just using this on their workstation.

Qi Xiao (xiaq):

They're not using this in the production environment. And then they become familiar, with the experience. They really like the experience. They really like the language, and they can probably gradually expand from there. So I'm not doing enterprising enterprise y things at the moment because I want to make the language work really well.

Qi Xiao (xiaq):

I want to make people, like, very comfortable with it using as their daily driver first. And I think after that point after that point, it's kind of more is finished. Maybe we can think about how to get this into, like, more serious enterprise grade business stuff.

Shay Nehmad:

Cool. Well, it it's pretty amazing to see, you know, the pretty consistent releases, the site getting updated, the huge, like, module list, and even themes, and it's still just a passion project. You you got a lot of passion for, for terminals. They'll give you that. And if you don't mind sharing, I don't know if this is too personal.

Shay Nehmad:

What's, what theme do you use? Like, power Paradigm, Chain, Starship.

Qi Xiao (xiaq):

I use Alwy's default name because it's kind of optimized for myself.

Shay Nehmad:

Actually, that makes a lot of sense.

Jonathan Hall:

Yeah. Sean, I'm curious. Have you tried Elvis yet?

Shay Nehmad:

I played around with it a bit, and I read the learn part. I started reading it, but I'm mostly interested in trying to, like, use it in my in my, company. We're doing a lot of CICD pipelines, stuff like that. I recently had that bug that I just told about. Like, I'm looking for a place where it would make a lot of impact because I'm super used to my, terminal and all the, like, I already have my dot files that I've been lugging around for, like, 7 years now and and patching and improving.

Shay Nehmad:

So I need a a a pretty convincing, reason to leave my terminal. Like, I imagine maybe Chi you beat me to it, but that with all my frustrations of the terminal, I might be better off building my my own than trying another one. Right? Because, Elvish is probably the most economic for chi, but I don't know if it's gonna be the most economic for me. Even though it's written in Go, so that's a big bonus.

Qi Xiao (xiaq):

Well, I would say I I mean, I was kind of half joking when I said it was kind of optimized for my taste because I think I have pretty simple taste. So which default prompts is actually quite minimal. It just shows your working directory. And, it also has a write prompt, kind of stole the idea is stolen from from Zesh.

Shay Nehmad:

It

Qi Xiao (xiaq):

just shows your username and your host. And that's kind of all I need. And, it's actually it's it's also very simple. It's kind of we we just said it's probably easier to build your own shell. Well, I have a shell to you where it's actually kind of programmable because because, for for instance, the thing I mentioned earlier, like, for instance, the property in Elwish is just a it's just a function.

Qi Xiao (xiaq):

So you can pretty much do anything you want. You can use a lot of existing, for instance, external prompts with Elvish. But if you just have an idea of why don't I add this information to the prompt? As long as you know the command to it, you can just write your own prompt. A lot of people do that instead of using the various, like, external prompt, like, programs.

Qi Xiao (xiaq):

It's super easy to kind of it's I would say it's like, right now, it could be more programmable, but a lot of pieces are already quite programmable. If I'm thinking about, like, kind of your daily experience, how to look and feel of the shell.

Shay Nehmad:

My experience at least was, that installing it is super easy, and it had a, a few features that I expect from my z shell that I had to, like, install plugins for and learn stuff for. The main one being a command history. I really like clicking, control r and seeing the command history, like, looking pretty. Because the usual Yep. I I don't know if you use, you know, vanilla sh or vanilla bash or even vanilla zsesh.

Shay Nehmad:

When you type, control r you get, like, it says, backwards search r or something like that. Yeah. Yeah. Start typing and you don't what you're looking for. But the command history in Elvish works a lot like, you know, the FZF plugins, stuff like that, which I really like.

Qi Xiao (xiaq):

Because this is an audio program

Jonathan Hall:

for people

Qi Xiao (xiaq):

who are not who don't have Elvish on their hand yet. What what's the kind of it's the same key for searching history. Right? But what does is that it just shows a list of, it just shows you a list of your history. Like, you can start typing.

Qi Xiao (xiaq):

I mean, the list just narrows down to what entries match your type. And you can navigate using your hierarchies and just press enter to accept something like that.

Shay Nehmad:

And and there was one thing that surprised me and wasn't just like, you know, I turn on air vision, it does something I already like. That's great. There was something that really surprised me and I need to see how I do it in Z Shell as well. Or maybe it will be enough to to convince me to move to Elvish, which is directory navigation. It's like nerd tree plug in in VM.

Shay Nehmad:

It was really cool.

Qi Xiao (xiaq):

You mean the

Shay Nehmad:

controller n?

Qi Xiao (xiaq):

That you can trigger with control n. Right. Yeah.

Shay Nehmad:

So you just press control n and you're in, like, some I think in, Emacs, it's called, like, file mode, you know, nerd tree where it opens the directory and you can navigate, on your own. It's great. Instead of LSCD, LSCD, LSCD, it's a lot more ergonomic. Yep.

Qi Xiao (xiaq):

Yeah. Exactly. Like, I spend much less time typing LS and CD after I start using Elvish as my own kind of daily driver because Yeah.

Shay Nehmad:

You just you just spent, 10 years developing your time back anytime now.

Jonathan Hall:

Yeah. Well, I I really like the the interactive, features. It's it's it's sexy. It remain I'll have to try it for a while and see if it's enough to productivity improves. It probably will.

Jonathan Hall:

Bash has never been a very productive tool for me. It's just the one I know. So I'm gonna give it a try.

Shay Nehmad:

Can you imagine, John, going into, you know, one of your consultation projects? They, like, bring you from outside. You bring your own shell and people are happy to see that. I'm just imagining people at work hearing like, yeah. Not not only I'm ragging on your Python and I'm telling you you should use Go, you should use this new terminal language as well.

Shay Nehmad:

Like, I'm really trying to understand how to how to do the pitch, the elevator pitch.

Jonathan Hall:

Honestly, I have to say for me, I'm I'm it sounds like you, Shy, are interested in trying to use this for CI, and I could see the benefits. But I'm more interested in trying to use it locally for personal productivity. So, like, I I probably wouldn't want to install this in the CI pipeline for one of my clients where I'm, you know, a freelancer for a few months and I leave. As then someone's gonna come along and not understand it and not take the time to read the the 15 minute FAQ and like, screw this. And they're gonna either not maintain the script because they don't feel like learning it or they're gonna rip it out and replace it with something worse.

Jonathan Hall:

You know, in Bash or or something like that. So but but for personal productivity, I'm interested in trying it.

Shay Nehmad:

So installing a newer machine?

Qi Xiao (xiaq):

I think the perspective from both of you is such a great, kind of it's a great way to see, like, the kind of the 2 main use cases, for Elvish these days. And, and I would say it's like, what I'm trying to do is try to balance kind of the the development priority kind of on both fronts. But, personally, I use it from on both fronts. So you can Mhmm. You can count on that.

Qi Xiao (xiaq):

It will it will both see, like, a better interactive features, but it will also be a better even be an even better language to put in your CICD pipeline.

Jonathan Hall:

Well, we're we're about at the end of our time here. Let's one more time give everybody a link. It's elv.sh. Is there anywhere else to go? Or is that is that the place to go for everything Elvish?

Qi Xiao (xiaq):

That is the place to go.

Jonathan Hall:

Okay.

Shay Nehmad:

I do wanna quickly mention Yeah. That it's really cool it's a really cool domain, but I chi, I don't know if you know this. It's actually a country code.

Qi Xiao (xiaq):

Yeah. It's Saint Helena.

Shay Nehmad:

Right? Yeah. I think, I I remember something like 35% of their GDP is domain registration. Yeah. It's like this tiny island with, 2 crabs, 3, like, bungalows, and, a few domain servers.

Shay Nehmad:

And they make a lot of money. I'm I'm very happy for them. Both, s h and t v. I think it's, like, Tuvalor or something. Yeah.

Shay Nehmad:

Same story. And f m.

Qi Xiao (xiaq):

Dot I o is the, Indian Ocean Territory.

Shay Nehmad:

No way. Really?

Qi Xiao (xiaq):

Yeah. Of United Kingdom, I think. Also, Saint Helena is also United United Kingdom's overseas territory. So

Shay Nehmad:

Well, they do have a lot of these. Yeah. Yeah. Yeah. As a former citizen of 1, you know, here in Israel as well.

Shay Nehmad:

So elv.sh, or you can fly over to Saint Helena and try to drink the bits directly from the coconut.

Jonathan Hall:

If people are interested in following you personally, do you have, social media presence where people can follow you? No is a perfectly reasonable answer.

Qi Xiao (xiaq):

Yeah. I I have a Twitter, but I'm mostly tweeting Chinese.

Jonathan Hall:

Okay.

Qi Xiao (xiaq):

I think it's kind of long overdue for me to actually make a separate account in English. But if you want to follow my Chinese Twitter right now, it's Alright. The username is xiaq. That's my normal username. Mhmm.

Qi Xiao (xiaq):

But then you spell it backwards again, q a I x, because Twitter didn't like my short username. And, when if I have a English account, I will be sure to put that, like, on my current Chinese account profiles.

Jonathan Hall:

Well, I'm sure we have Chinese speakers listening anyway. So, they can follow you there. Great. Well, we we like to round out every interview with, a question. If you can remember far back to when you were learning Go, when you first got introduced to language, was there anything surprising or challenging about the language for you that, yeah, that surprised you when you were learning this new language?

Qi Xiao (xiaq):

Yeah. So Jonathan actually asked me this before our interview starts, and I spent a very long time to come up with something that surprised me. I actually pulled out the gold language spec, and digging through things, that I like. And I and I was just going through the entire space. Oh, this is not surprising.

Qi Xiao (xiaq):

This is not surprising. This makes sense. That makes sense. So I think, in a sense, like, the major the, like, 99% of Go is not very surprising. And that's a that's a very that that itself was kind of a surprising thing because when you learn a new language, you do expect to learn, like, some new way to think.

Qi Xiao (xiaq):

Right? Yeah. Like, Go is not really in the business of making you learn a new way to think. It kind of tries to tries to build on your past knowledge of how to think, and then use that, like, to build a very, like, pretty straightforward language. However, after reading the spec for a while, I realized there was one thing that did surprise me, was the fact that Go had pointers at all.

Qi Xiao (xiaq):

Mhmm. Because Go is a garbage collected language. And normally, you wouldn't expect our pointers, in the garbage collected language, but but it did. So that was kind of surprising. And, also, when you use pointers in receivers versus more using pointers in receivers, the semantics are a little bit confusing because it's some it depends.

Qi Xiao (xiaq):

So for instance, if you just declare a variable that's a struct and, and then you can call it. You can call it pointer receiver methods even though the struct itself is not a pointer. Mhmm. This is because if you define a local variable, it's considered addressable. And addressable variables can just become pointers when you call a method.

Qi Xiao (xiaq):

So there's there's some, like, the concept of addressability doesn't actually appear, like, in a lot of other places in the language spec, but it is required to understand how, like, point receivers work. So that was a little bit surprising, a little bit confusing.

Shay Nehmad:

Yeah. I think it was I came from, like, c plus plus, originally, and coming into Go, it felt simpler. But now if you, like, I had to give a lesson on how these operators work, I probably have to brush up on it. It's just not something I usually think about when I when I program Go languages. I think in much higher level.

Shay Nehmad:

Even though it that it it does behoove me to, like, put the ampersand in the correct place and put the the the asterisk in the correct place.

Qi Xiao (xiaq):

Though I think in retrospect, I think Go's approach to Pointer is actually quite sensible because, like, in languages like Java, that just doesn't give you any control whether value goes onto the stack or goes onto a heap. Like, they actually did a lot of work to make sure that, like, the ideal to make sure that the compiler, the JVM, places the value on the heap on the stack correctly. Whereas in Go, you do this gives you some control, but not total control for when to put values on the stack.

Shay Nehmad:

I think it makes a lot of sense. I but I agree with you that it at least initially and even right now, I'm I I'm not sure I can explain it, without reading the docs first and making sure I'm correct.

Qi Xiao (xiaq):

Yeah. Yeah.

Shay Nehmad:

Yeah. Well, thanks a lot, Chi.

Jonathan Hall:

Yeah. Thank you. This has been educational and inspiring. I'm I'm gonna try a new shell.

Qi Xiao (xiaq):

Well, and, Shay, I would really recommend to try it in those CICD pipeline.

Jonathan Hall:

I will. I will.

Shay Nehmad:

For sure. I just need to the the only hurdle is convincing my, new team member to learn a new terminal. If I if, Elvish documentation is good enough, then they will. And from the site, I think there's no question. It's really documented well.

Shay Nehmad:

It's not even close to the user manual you mentioned before that I opened and immediately tabbed out.

Jonathan Hall:

And we'd love to hear from our other listeners who try out Elvish or maybe already have tried Elvish. Come out to our come over to our Slack channel. Let us know what you think, what your impressions are.

Shay Nehmad:

Yeah. Send some send some screenshots of themes. Oh, there we go.

Qi Xiao (xiaq):

Yeah. I look forward to hearing from existing users and new users.

Shay Nehmad:

Awesome. Thanks, Chi.

Jonathan Hall:

Thank you.

Qi Xiao (xiaq):

Thank you. I'm really really happy to be on your show.