59
submitted 1 day ago* (last edited 1 day ago) by christos@lemmy.world to c/linux@lemmy.ml

cross-posted from: https://lemmy.world/post/20670854

https://gitlab.com/christosangel/c-squares

c-squares written in the C language will render random coloured rectangulars in the terminal, while the font, speed, density, color, ratio and number of the shapes drawn are fully costumizable.

Every time a rectangular is complete, a new one starts to take shape.

https://gitlab.com/christosangel/c-squares/-/raw/main/screenshots/1.png

https://gitlab.com/christosangel/c-squares/-/raw/main/screenshots/2.png

https://gitlab.com/christosangel/c-squares/-/raw/main/screenshots/3.png


Feel free to explore the endless variations.

top 17 comments
sorted by: hot top controversial new old
[-] tetris11@lemmy.ml 2 points 17 hours ago* (last edited 17 hours ago)

Well, first of all, through a framebuffer, all graphics inside a virtual terminal are possible, so jot that down

mac_its_always_sunny.gif

Most of these are not squares. They're rectangles.

Also, c-squared would have been an amazing name based on a math pun. Lol

Also, this looks awesome and I love it.

[-] GustavoM@lemmy.world 6 points 1 day ago
[-] flashgnash@lemm.ee 13 points 1 day ago

Perfect! Now I can deploy it to my kubernetes cluster and make it scalable!

[-] GustavoM@lemmy.world 3 points 1 day ago

Nice! Hope you have fun with it.

[-] Black616Angel@discuss.tchncs.de -2 points 19 hours ago

What does this have to do with Linux?

[-] christos@lemmy.world 5 points 18 hours ago

I am a linux user, this is a FOSS project that I created.

This is a project that makes my linux experience more pleasant.

Is this a project that might interest other linux users, or might make their experience better?

Judging from the 49 upvotes so far, yes.

Do you share the same opinion? I don't know.

If not, feel free to downvote, and/or move on.

[-] christos@lemmy.world 4 points 1 day ago
[-] 0x0@programming.dev 2 points 1 day ago* (last edited 1 day ago)

This script written in the C language

C is not a scripting language.

[-] embed_me@programming.dev 3 points 1 day ago

I do not get your point?

A script is more about the program rather than the language. You can write a script in assembly or C++ or whatever

[-] tetris11@lemmy.ml 1 points 17 hours ago

Is it? I thought a script is a portable and instantly grokkable piece of code that can be easily modified by others, since it uses very little actual code in itself (e.g. by being reliant on larger imported frameworks), and thus not being a full-fledged application.

The above code is pretty much self-contained, and though it is impressively minimal, it is not instantly grokkable, and I would have a hard time modifying it.

[-] embed_me@programming.dev 2 points 16 hours ago

Fair enough. For me, scripts are small reusable programs performing a very specific (sometimes trivial or common) task. Eg: making a wav file from PCM data, modifying byte sequences or formatted text in a particular way, etc. I mostly program in C so I have written most scripts in C. Need not necessarily be grokkable as long as its application and scope is clear

[-] tetris11@lemmy.ml 1 points 16 hours ago

Need not necessarily be grokkable as long as its application and scope is clear

Well that's a fair point.

[-] magikmw@lemm.ee 11 points 1 day ago

Every language is a scripting language if you're brave enough.

[-] GustavoM@lemmy.world 7 points 1 day ago* (last edited 1 day ago)

Oh yeah? Then redo the classic doom code in pure bash.

[-] flashgnash@lemm.ee 11 points 1 day ago* (last edited 1 day ago)
!#/usr/env bash
~/doom-game/bin/doom
[-] christos@lemmy.world 1 points 1 day ago

I stand corrected.

this post was submitted on 09 Oct 2024
59 points (94.0% liked)

Linux

47661 readers
476 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS