bash: foo: No such file or directory

From Esolang
Jump to navigation Jump to search

bash: foo: No such file or directory or hsaB is a joke language made by User:Marina. It imitates a common bash error when the file or command in an instruction is not found.

Commands

There are no/infinite commands as any instruction is valid and it prints:

bash: [command]: No such file or directory

Interpreter

Python

print('\n'.join([f'bash: {i}: No such file or directory' for i in __import__('sys').stdin.read().split('\n')]))

C

The program implements a REPL, and uses the insecure function gets to read the program.

#include<stdio.h>
char _[1000000];int main(){while(!feof(stdin)){printf("$ ");gets(_);printf("bash: %s: No such file or directory\n",_);}}

Batch

@echo off
:bad
set /p x=$ 
echo Bash: %x%: No such file or directory
goto bad

See also