---
title: "Introducing Bun Shell: Running Cross-Platform Shell Scripts in JavaScript"
url: https://daily.dev/posts/introducing-bun-shell-running-cross-platform-shell-scripts-in-javascript-sz728mqhs
source_url: https://daily.dev/posts/introducing-bun-shell-running-cross-platform-shell-scripts-in-javascript-sz728mqhs
type: collection
source: "Collections"
published: 2024-01-20T05:55:46.086Z
updated: 2024-01-21T14:40:55.060Z
tags: ["javascript", "typescript"]
reading_time: 1
upvotes: 11
comments: 3
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Introducing Bun Shell: Running Cross-Platform Shell Scripts in JavaScript

**[Collections](https://daily.dev/sources/collections)** · 1 min read · 11 upvotes · 3 comments

## Summary

Bun v1.0.25 is a significant update for the fast JavaScript runtime, bundler, transpiler, and package manager. It includes bug fixes for crashes and loose equals in the transpiler, as well as new features such as vm.createScript and the Bun Shell.

## Content

Bun is a fast JavaScript runtime, bundler, transpiler, and package manager. In the latest release of Bun, version 1.0.25, several bugs have been fixed and new features have been added.

One of the bug fixes addresses crashes in fs.readFile, Bun.file().text(), and IPC. These crashes have now been resolved, resulting in a more stable and reliable runtime.

Another important fix in this release is a bug involving loose equals in the transpiler. This bug has been fixed, ensuring accurate and consistent transpilation results.

Additionally, the new version of Bun brings the introduction of vm.createScript, which allows for the creation of executable scripts.

Furthermore, the Bun Shell has been introduced in this release. The Bun Shell is an embedded language and interpreter that enables the running of cross-platform shell scripts in JavaScript and TypeScript. This addition addresses the challenges of running shell scripts in JavaScript, providing a seamless and efficient solution.

Overall, Bun v1.0.25 is a significant update that improves the functionality and stability of the JavaScript runtime, while introducing new features such as vm.createScript and the Bun Shell.

## Community discussion

Top comments from developers on daily.dev.

**@tdlm** · 1 upvotes

> Looks awesome. Reminds me of Google's zx, but it's bun! However, I just tried it on v1.0.25 and it doesn't work:
>
> ```
> $ bun -v
> 1.0.25
> ```
>
> The file (:
>
> ```
> // test.bun.sh
> import { $ } from "bun";
>
> // to stdout:
> await $`ls *.js`;
>
> // to string:
> const text = await $`ls *.js`.text();
> ```
>
> Running attempt:
>
> ```
> $ bun test.bun.sh
> error: Failed to run test.bun.sh due to error Unexpected `(`, subshells are currently not supported right now. Escape the `(` or open a GitHub issue.
> ```
>
> What am I doing wrong?
>
> NOTE: I am running macOS 14.2.1 on an Apple M1.

## Similar posts on daily.dev

- [Don’t just attend KubeCon \+ CloudNativeCon, Merge Forward your experience\!](https://daily.dev/posts/don-t-just-attend-kubecon-cloudnativecon-merge-forward-your-experience--l0rpp73x8) · CNCF · 0 upvotes · 0 comments
- [Announcing H2 2026 KCDs](https://daily.dev/posts/announcing-h2-2026-kcds-m96goajm1) · CNCF · 1 upvotes · 0 comments
- [Two months of Open Community Groups](https://daily.dev/posts/two-months-of-open-community-groups-asf52zhbs) · CNCF · 0 upvotes · 0 comments
- [CNCF Unveils Schedule for KubeCon \+ CloudNativeCon Europe 2026](https://daily.dev/posts/cncf-unveils-schedule-for-kubecon-cloudnativecon-europe-2026-ikhcoa5cb) · CNCF · 2 upvotes · 0 comments
- [CNCF Debuts KubeCon \+ CloudNativeCon Japan 2026 Schedule](https://daily.dev/posts/cncf-debuts-kubecon-cloudnativecon-japan-2026-schedule-xp5pyudub) · CNCF · 1 upvotes · 0 comments

---

Tags: [#javascript](https://daily.dev/tags/javascript), [#typescript](https://daily.dev/tags/typescript)

[View this post on daily.dev](https://daily.dev/posts/introducing-bun-shell-running-cross-platform-shell-scripts-in-javascript-sz728mqhs)
