TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Batsh – A language that compiles to Bash and Windows Batch

2 pointsby susi22about 11 years ago

1 comment

gkyaabout 11 years ago
What&#x27;s the use of this project? A shell language bears the main purpose of enabling user to interact with the system including it, and thus the shell is platform specific at it&#x27;s nature. A language may well be compiled to both Windows and POSIX shell languages, but what will happen when a feature or a program endemic to one of these systems is invoked within a shell script? Is there a complement in Windows land for, say, sed(1), awk(1), ls(1), cp(1)? If so, are these programs synonymous. What will happen when I invoke ls in my program, will it get translated to dir for windows?<p>Shell languages&#x27; primary purpose is invoking programs. Most important programs for shells are endemic to one platform or another, and thus translating only the shell language does not mean anything.