Coder Social home page Coder Social logo

iniquitybbs / iniquity Goto Github PK

View Code? Open in Web Editor NEW
52.0 11.0 5.0 4.62 MB

A re-imagining of the iconic BBS software.

Home Page: http://iniquitybbs.com

License: MIT License

Dockerfile 3.85% TypeScript 90.41% AGS Script 0.88% JavaScript 4.86%
bbs telnet web ansi ascii community messaging file-sharing games framework

iniquity's Introduction

Iniquity

This is the re-imagining of the iconic Iniquity Bulletin Board Software.

Alt text

Release Quality Gate Status lerna Discord GitHub license Docker Pulls Docker Image Size (latest by date)

Synopsis

npm install -g @iniquitybbs/iniquity

You will find a iniquity and iq command in your path. Both commands do the same thing. Use whichever you prefer.

iq --version

Initialize the current directory as an Iniquity BBS.

iq init

Once the current directory has been initialized you quickly start the BBS with the start command.

iq server start

While you are developing, you can use the --watch flag to automatically restart the server when you make changes.

iq server --watch

Using SyncTerm, you can connect to your BBS at localhost. Or web browsers can connect to http://localhost.

Getting started guide

In its most simple form, Iniquity can provide you with some shortcuts to working with a terminal...

import { say, pause, wait, ask } from "@iniquitybbs/core"

say("Hey there visitor?".color("blue")).pause()

ask("Hey can I know your name", (name) => {
    say(`Hey ${name}, nice to meet you!`)
})

Alright, that's kinda neat, but now let's make it a bit more useful, because Iniquity can handle some more common use cases.

import iq from "@iniquitybbs/core"

iq.artwork({ filename: Assets.sm_iniq2 }).render({ clearScreenBefore: true, speed: 100 })

iq.say(
    `You just connected to an iniquity bbs. The artwork you are seeing above is called ${welcomeArt.filename} It's still pretty new. Likely has bugs. Real talk, it's not even finished. But maybe you'll still think it's cool.`
        .newlines(2)
        .color("background red")
        .center()
).pause({ colorReset: true, newlines: 2, center: true })

How about we make a menu that users could use to help them navigate around a bit.

import iq from "@iniquitybbs/core"

const menu = iq.menu({
    name: "Iniquity answer menu.",
    description: "Really I just get to rattle off more non-sense.",
    commands: {
        L: (description = "Sit cillum consequat qui quis dolore Lorem.") => {
            iq.say("Hey, don't touch that!")
        },
        O: () => {
            iq.say("Nothing to see here, move along...")
        },
        H: () => {
            if (ask("Are you sure you want to hangup?")) {
                iq.disconnect()
            }
        },
        default: () => {
            iq.say("That command key doesn't do anything, try again.".gotoxy(1, 1))
        }
    }
})

menu.render(
    (res: IQMenuLoopMessageResponse, cmdkey: Function) => {
        iq.artwork().render({
            clearScreenBefore: true,
            filename: IQCoreAssets.sm_iniq2
        })

        menu.prompt({ x: 20, y: 30, text: "Feed me: " }).command(cmdkey)
    },
    {
        maxInterval: 1000000
    }
)

Thinking you need something a bit more advanced? Try the class based approach.

import { IQ, IQModule, IQModuleRuntime, IQModuleACLS, IQCoreAssets, IQCoreModules } from "@iniquitybbs/core"

@IQModule({ basepath: "/iniquity/core/src/assets/", access: IQModuleACLS.low })
export class Login extends IQ {
    @IQModuleRuntime({ debug: true })
    start() {
        const art = this.artwork({ basepath: this.basepath })

        art.render({ filename: IQCoreAssets.iq3_login }).cursor(40, 25)

        const login = this.ask("Enter your handle, or type 'new' to apply".color("green"))

        /** More login logic to come **/
    }
}

Familiar with making event-driven, single page applications like with Vue, React or Angular? You can build fully reactive applications with iniquity 3 also.

import { IQCoreAssets, IQFrameColorOptions, IQMenuLoopMessageResponse, IQModule, IQModuleRuntime, IQReactor, IQ } from "@iniquitybbs/core"

@IQModule({
    basepath: "/iniquity/core/src/assets",
    data: IQReactor({
        message: "Umm, yeah this needs to change",
        number: 1,
        time: time(),
        system: system.stats
    })
})
export class Answer extends IQ {
    @IQModuleRuntime({
        debug: true
    })
    start() {
        this.data.observe("message", () => {
            this.artwork({ filename: IQCoreAssets.iq3_apply }).render({ speed: 1, clearScreenBefore: true }).colorReset()
            this.say(this.data.model.message).wait(1000)
            this.pause()
        })
        this.data.observe("number", () => {
            this.say(this.data.model.number).wait(1000)
        })

        while (this.terminfo.x < 132 || this.terminfo.y < 37) {
            const menu = this.menu({
                name: "Unsupported",
                description: "A simple menu for letting the user know their terminal settings are not supported.",
                commands: {
                    /**
                     * Unsupported.R
                     * @param description
                     * @returns
                     */
                    R: (description = "Sit cillum consequat qui quis dolore Lorem.") => {
                        return {
                            description
                        }
                    },
                    G: () => {
                        this.data.model.number + 1
                    },
                    H: () => {
                        this.data.model.message = this.ask("What should I change the message to?")
                    },
                    default: () => {
                        // this.say("please try again.".gotoxy(1, 1))
                    }
                }
            })

            menu.render(
                (res: IQMenuLoopMessageResponse, cmdkey: Function) => {
                    this.artwork({ filename: IQCoreAssets.sm_iniq2 }).render({
                        clearScreenBefore: true,
                        speed: 1,
                        data: this.data.model
                    })
                    menu.prompt({ text: "Enter your command: ".color("bright cyan"), x: 20, y: 20 }).command(cmdkey)
                },
                {
                    maxInterval: 3000,
                    data: this.data.model
                }
            )

            this.wait(100)
        }

        alert(this.data.model.message)

        alert(this.basepath)

        this.data.model.message = this.ask("So what's the new message?")

        this.artwork({ filename: IQCoreAssets.iq3_welcome })
            .render({
                speed: 100,
                data: this.data,
                mode: "@-codes"
            })
            .pause()

        const frame = this.frame({
            x: 10,
            y: 10,
            width: 30,
            height: 15,
            color: IQFrameColorOptions.blue
        })

        const menu = this.menu({
            name: "Iniquity answer menu.",
            description: "Really I just get to rattle off more non-sense.",
            commands: {
                L: (help = "Sit cillum consequat qui quis dolore Lorem.") => {
                    this.gotoxy(23, 63)
                    this.data.model.message = this.ask("Oh so you wanna change it?")
                    this.data.model.number++
                },
                O: () => {
                    frame.open()

                    while (true) {
                        frame.say(JSON.stringify(this.data.model))
                        frame.cycle()

                        this.data.model.number++

                        if (this.data.model.number > 20) break

                        this.wait(10)
                    }

                    frame.close()
                },
                H: () => {
                    this.cursor().down().left(22)
                    this.data.model.number++
                },
                default: () => {
                    this.say("please try again.".gotoxy(1, 1))
                }
            },
            data: this.data.model
        })

        menu.render(
            (res: IQMenuLoopMessageResponse, cmdkey: Function, data?: any) => {
                this.artwork().render({
                    clearScreenBefore: true,
                    filename: IQCoreAssets.sm_iniq2,
                    data: this.data.model
                })

                this.data.model.number++

                menu.prompt({ x: 20, y: 30, text: "Feed me: " }).command(cmdkey)
            },
            {
                maxInterval: 1000000
            }
        )
    }
}

Want to learn more? Read the docs!

More details about iniquity 3

Your development environment should contain something like this, or similar

  • macOS / Windows / Linux required
    • These modern operating systems are currently supported.
  • Docker Desktop for macOS / Windows or Docker Machine required
    • The Iniquity BBS runtime is executed inside of a Docker container for portability.
  • Node.js & NPM required
    • The Node community tools are used for TypeScript transpiling and Iniquity package management.
  • Visual Studio Code recommended
    • This repository is specifically tuned to take full advantage of this IDE.
  • Moebius recommended
    • The ideal choice for working with ANSI/ASCII/PETSCII/AMIGA artwork.

Some guiding thoughts surrounding the idea of iniquity 3

I want this to be something a typical sysop can use, yes, I also want it to be something a modder/programmer will love. But also, someone should be able to create an entirely new terminal style application with it if they wanted. To only use iniquity 3 for the development of a legacy style bbs would be a real waste of its potential. @ispyhumanfly

  • A BBS software framework that is geared towards developers and modders .
  • Make it easy for sysops to develop and deploy BBS applications.
  • Easily network files, messages and other forms of communication between other BBS applications.
  • What you see in Terminal.app, xterm, NetRunner, SyncTerm, EtherTerm or qodem is what you see in a web browser.
    • Though the ability to do interesting things specific to web/terminal should exist.

About iniquity's runtime

Alpha... — Today at 11:29 AM @ispyhumanfly curious about that last commit, "Now with Synchronet under the hood" 🙂

Many cross-platform applications today are executed on a runtime environment known as Node.js. Node.js makes it possible for these applications to be written in JavaScript. Well, iniquity aims also to be a cross-platform software, and is largely executing inside of a custom runtime environment that is a fusion of Node.js, Synchronet JavaScript and Ubuntu all wrapped into a Docker container. Anytime you run iniquity on your computer or on some cloud computing environment somewhere, this containerized runtime is quietly running in the background, making iniquity’s magic possible.

Alpha... — Today at 12:28 PM so, that allows iniquity to leverage existing javascript-based modules, like parts of Synchronet, without having to re-invent the wheel?

ispyhumanfly — Today at 1:39 PM

That's basically the primary reason for using it. In addition to the wealth of command line utilities centered around the subject of bbs/ansi/terminal/etc made possible by the people behind Synchronet. Also, there are many utilities available within the Ubuntu ecosystem. DOSemu being one of them, which is integrated into this runtime container as well. Iniquity itself is written in TypeScript and requires Node.js and Docker on your computer to make this all work.

Alpha... — 03/16/2022 The more I read about IQ3, the more I dig that this isn't just a BBS platform, it's a tool that can be used to create/script just about any kind of terminal application... Seems to share that piece of DNA with x84, yeah?

//rubs hands in maniacal anticipation//

ispyhumanfly — 03/17/2022 Yup, that's basically it @Alpha... . When in a more finished state, the @iniquitybbs/templates package is going to have a few different kinds of examples, and BBS setups for people to get started with. But they exist as examples. Iniquity 3 itself is an SDK and platform for creating terminal applications that can be accessed from terminal/web/maybe mobile. Absolutely x84 is the genesis of the idea here. I liked what those guys had done, but, wanted to hopefully be able to take it a bit further. So with that in mind, I originally started this project as a ruby project, and started working on the CLI portion... after sometime decided to switch to the TypeScript/JS version that exists now, with the runtime as I've explained previously.

grymmjack — 04/08/2022 wow @ispyhumanfly iq is node?

ispyhumanfly — 04/11/2022 Hey @grymmjack , I’d say it like this… Iniquity 3 itself is written in TypeScript. And, for anyone wanting to develop an iniquity bbs or application or whatever, you would also be writing this in TypeScript. Iniquity has a few elements to its runtime; NodeJS, SynchronetJS, Browser JS and Ubuntu Linux with all the system tools a sysop may need. All of this is contained within the “Iniquity Runtime”, which is basically everything I just mentioned wrapped tightly in a Docker container. As someone wanting to use Iniquity it’s as simple as installing it from NPM, making sure Docker is running, and the rest is handled in the background for you.

grymmjack — 04/12/2022 that is rad @ispyhumanfly

Development of this project

This is a monorepo project. It uses lerna for management of its packages.

First, clone this repository somewhere on your system

git clone https://github.com/iniquitybbs/iniquity.git

Inside of the iniquity directory, install the project dependencies

Will install all dependencies and bootstrap and build all packages.

npm install

Start iniquity

Inside of the VS Code Integrated Terminal, fire up the development server.

npm start

Docker

You could just pull the latest version of the runtime directly from docker.

docker pull iniquitybbs/iniquity

Or even just run it directly

docker run -d -P --name iniquity -it iniquitybbs/iniquity

Discord

Join us on Discord.

Issues

Share your ideas, feedback and bug reports.

Documentation

Read the Iniquity documentation.

iniquity's People

Contributors

dependabot[bot] avatar github-actions[bot] avatar ispyhumanfly avatar shlomif avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

iniquity's Issues

Create the User API

Synopsis

The Iniquity interface to User records and other related data services.

Theme Support

Overview

Themes/Menu Sets/Skins for BBS development has always been cumbersome for artists, typically not programmers, to create and distribute for general sysop use. Sysops should feel if a theme is distributed they can install it with appropriate license/permission to do so; Artists should feel a theme will be displayed unaltered (no art modifications, stripping of artist name).

Proposal

Container format for themes for IQ3. Simple compressed file (.zip), Manifest of contained artwork, artist name, group name, version, theme name, theme description (possibly as .json or .yaml). Optional file_id.diz can be included for thumbnail reference when released in a repo.

IQ3 should perform validation on theme pack to ensure required art is included prior to install/use by sysop.

The things we loved about Iniquity 2.x and 1.x

Synopsis

There are a number of cool ideas and features that existed in the early and mid 90s releases by Fricker, Pike and later Jack Phlash, Spec and Darkwing.

Though some of these ideas may not make sense for the modern age, or perhaps just don't fit well with some of the design goals we've accumulated over the last 2 years of brainstorm and proof of concept work, they should be considered or perhaps new ways of approaching a similar feature should be considered.

Goals

I'd like to reach out to everyone and anyone interested in this project and ask them to input ideas here in this ticket. No promises will be made but from this dialog here we can begin creating tickets for those specific features we all know, love, and think we should still have.

Error

Get this error when I telent into the board
!ERROR compiling /sbbs/exec/login.js
The sysop has been notified

Create the iniquity runtime environment (Docker).

What is this?

It's hard to explain at this point. But it's a container running Ubuntu with Synchronet installed and running, coupled with a TypeScript compiled and NodeJS environment. It will allow for the creation of the new IPL (Iniquity Programming Language), or some variation, perhaps IQF? (Framework).

This part is't clear but what is clear is that leveraging the strengths of the hardworking developers and modders over at Synchronet BBS team and community would be a mistake to me. So much integration done, so much testing on both telnet and web, and the fact that we could use front-end languages like TypeScript to actually author your BBS in seems a more modern approach to BBS development.

Or maybe, all of this is to better learn what is needed to create a different kind of runtime. For now, this is the direction.

Theme Support

Discussed in #23

Originally posted by christianvozar October 11, 2018

Overview

Themes/Menu Sets/Skins for BBS development has always been cumbersome for artists, typically not programmers, to create and distribute for general sysop use. Sysops should feel if a theme is distributed they can install it with appropriate license/permission to do so; Artists should feel a theme will be displayed unaltered (no art modifications, stripping of artist name).

Proposal

Container format for themes for IQ3. Simple compressed file (.zip), Manifest of contained artwork, artist name, group name, version, theme name, theme description (possibly as .json or .yaml). Optional file_id.diz can be included for thumbnail reference when released in a repo.

IQ3 should perform validation on theme pack to ensure required art is included prior to install/use by sysop.

Stuck at "Rest service started", and BBS never loads over Telnet

So I've tried installing this reimagined version of Iniquity on two different Macs, one running macOS Mojave, and the other macOS Catalina, and every time I get to the end of the installation process and run "iniquity", I get "Rest service started".

iniq

Eventually I get "iniquity - Periodic timed event example..."

Then if I try to connect via Telnet, I get "iniquity - Someone connected to the system.."

But the software never loads:

Screen Shot 2020-04-02 at 6 09 05 PM

Clearly define the boundary between Synchronet and Iniquity's role.

Synopsis

Properly define the line in the sand between the Node.js layer, the Synchronet and Ubuntu layers.

Notes

From @ProceduralRealms:

i guess i'm not sure what the vision is in terms of how much of synchronet will be used, from what i can tell it's basically the ansi handling so far?

Docker

I'd install this in a flash it you could without Docker!
I really don't like how you have to edit files from outside the board and docker image.

OMG ... that reminds me.....

sorry for posting here... i had this running so many years ago... the original... in times nobody heard of "internet", amazing ! ;-)

i have to ask (maybe) a stupid question: what is this project about ? can you give me some use-cases here ??

THX!

Making the bbs list better with networking

Per @ispyhumanfly, the networking of Iniquity boards is one of the initial design concepts for iq3.

One idea - amongst many - for how we could take advantage of that networking is the traditional bbs list. How often have you tried connecting to boards from a list, only to find they’ve been taken offline? How can we make this better?

Imagine a bbs list that is kept up-to-date automatically across all boards that use it and where:

  • New boards appear automatically
  • Dead boards fall off automatically (i.e. didn't submit info within a certain definable time period)
  • The current bbs software version used is listed
  • The current hardware used is listed
  • The current system OS used is listed
  • How many days each bbs has been up is listed and kept up-to-date automatically
  • User ratings and rankings are received from all networked boards, and kept in sync everywhere, so the #1 board is the #1 board everywhere.

Each board participating could send its info via the networking each day.

Ideally, eventually other bbs softwares would be able to hook into this so it's not just iq3 boards.

More details to be fleshed out later when this is added to a milestone.

If this gives you ideas for how we can leverage iq3's forward-thinking networking, raise a ticket with your ideas or run it by everyone at the discord server (https://discord.gg/FknwhC).

Create the deploy command for iniquity.

The deploy command will allow a sysop to easily deploy their bbs to a cloud provider. The idea out of the box is to support AWS and Azure. The result will look something like this iq server deploy --provider aws. Internally we could likely just use Terraform to handle the management of the deployed bbs state, etc.

Iniquity won't start

Hello BBS'ers

I wrote an Email but dont get an Answer .. so i try it again this way ...

I Install Iniquity like the Install Doc on different Systems ( PI, Odroid, BananaPI, Tinkerboard and PC ) and i try it with different Distributions .. i have all time the same Problem..

The Problem is .. if i type iniquity the server starts and give no Errors .. if i login in via Telnet i get the Message on my server ,, Someone connected to the system .. and on the client i call i get the Loading Screen .. thats all ... i really hope samone can help me ..

The Installation of Enigma-BBS on all Systems runs Perfect ..

I dont know if it important .. but i think the iqpkg not working .. the Install doc tell i have to call iqpkg install eternity .. but i only get the Iniquity ASCII and iqpkg - The Iniquity BBS Package Manager.
Its every time the same message i can type iqpkg install bullshit .. its the same ..

Please help me ..

Greets IRoN

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.