Raw C Shell: interact with your operating system using raw C code, because why not?

Related tags

Command-line rcsh
Overview

rcsh

Raw C Shell is a minimalist shell with no built in commands. You write entirely in C code and use return; to execute your code.

Unlike that silly csh where certain features and functions are added to make it more appropriate as a shell, this literally just pipes what you type into it into gcc.

image image image

Have fun!

principles of rcsh

  • Everything you type is placed into a buffer. Upon typing return; into the shell, the buffer is placed into an int main() function, executed, and then cleared, allowing you to write a new block of code.
  • The buffer is updated every time you hit enter. You cannot modify previously entered lines. When your code is executed and cleared, you cannot edit it, you must type it out again.
  • exit(_); closes the shell. Your program must compile successfully for the function to have any effect.
  • In the resulting code given to gcc, every C89 header is imported before that main function.
  • If you type your own #include directives into the shell, they are handled specially and placed above the main function. When your code is cleared on return;, the #include directives remain.
  • Ctrl-L clears the current screen and also whatever program you were typing.
You might also like...
Mafa is a command-line tool that helps people interact with online websites in a terminal(tty).
Mafa is a command-line tool that helps people interact with online websites in a terminal(tty).

A Small Demo Installation Prerequisite Option 1: Cargo install (recommended) Option 2: Build from source Option 3: Prebuilt binaries Mafa is for me? W

A rust library to interact with the Vyper compiler!

vyper-rs A rust library to interact with the Vyper compiler! Dependencies Please ensure that the Vyper compiler is installed and added to PATH! To ins

Slack chat bot written in Rust that allows the user to interact with a large language model.
Slack chat bot written in Rust that allows the user to interact with a large language model.

A Slack chat bot written in Rust that allows the user to interact with a large language model. Creating an App on Slack, first steps Go to https://api

Learning Rust through Advent of Code 2021 - probably not very clean!

AoC 2021 ======== I'm using AoC2021 as an excuse to learn Rust (and maybe some other languages). Please do *not* use this repository as a good source

Use your computer as a cosmic ray detector! One of the memory errors Rust does not protect against.

Your computer can double up as a cosmic ray detector. Yes, really! Cosmic rays hit your computer all the time. If they hit the RAM, this can sometimes

Shell scripting that will knock your socks off
Shell scripting that will knock your socks off

atom Shell scripting that will knock your socks off. NOTE: Click the image above for a video demonstration.

Explore from the safety of your shell
Explore from the safety of your shell

turtlescan Explore from the safety of your shell Installation: cargo install turtlescan tui Starts a little tui which connects to your JSON-RPC server

McFly - fly through your shell history
McFly - fly through your shell history

McFly - fly through your shell history McFly replaces your default ctrl-r shell history search with an intelligent search engine that takes into accou

Animated app icons in your Dock that can run an arbitrary shell script when clicked.
Animated app icons in your Dock that can run an arbitrary shell script when clicked.

Live App Icon for Mac Animated app icons in your Dock that can run an arbitrary shell script when clicked. Requirements macOS 13 (Ventura) or higher X

Releases(v1.0.0)
Owner
null
💻 Interact with Hop in your terminal

Hop CLI The Hop CLI allows you to interface with Hop services through your command line. It can be used as a replacement for the Console. Installation

Hop 56 Dec 15, 2022
Ask ChatGPT for a shell script, code, or anything, directly from your terminal 🤖🧠👨‍💻

ShellGPT Ask ChatGPT for a shell script, code, or anything, directly from your terminal ?? ?? ??‍?? Demo Install The binary is named gpt when installe

null 4 May 15, 2023
🐢 Atuin replaces your existing shell history with a SQLite database, and records additional context for your commands

Atuin replaces your existing shell history with a SQLite database, and records additional context for your commands. Additionally, it provides optional and fully encrypted synchronisation of your history between machines, via an Atuin server.

Ellie Huxtable 4.6k Jan 1, 2023
An experimental real-time operating system (RTOS) written in Rust

An experimental real-time operating system (RTOS) written in Rust

null 0 Nov 14, 2022
Work-in-progress software for managing the Azeron keypad on any operating system.

azeron-cli A small, unfinished CLI application intended to manage the Azeron Cyborg. The code is still in a very messy state and doesn't look very rus

cozyGalvinism 5 Nov 24, 2022
An operating system written in Rust (for fun and educational purposes)

Prestige Prestige is an operating system written for fun and educational purposes in Rust. It targets the x86-64 architecture and can run on common em

binds 3 Nov 14, 2022
Self-contained template system with Handlebars and inline shell scripts

Handlematters Self-contained template system with Handlebars and inline shell scripts Introduction Handlematters is a template system that combines Ha

Keita Urashima 3 Sep 9, 2022
Shell Escape for Typst typesetting system. Linux Only.

Shell Escape for Typst This is a simple shell escape for Typst. It allows you to run shell commands directly from Typst compiler. That said, it does n

Nikolay Stepanov 4 Jun 7, 2023
This is a simple command-line interface tool that allows you to interact with ChatGPT from OpenAI or Azure.

HeyGPT This is a simple command-line interface tool that allows you to interact with ChatGPT from OpenAI or Azure. You can use it to: Chat with ChatGP

Philip 5 Mar 28, 2023
Mafa is a command-line tool that helps people interact with online websites in a terminal(tty).

Table of Contents A Small Demo Installation Prerequisite Option 1: Cargo install (recommended) Option 2: Build from source Option 3: Prebuilt binaries

Michael Lee 6 Jul 10, 2023