GithubHelp home page GithubHelp logo

jillmnolan / node.cobol Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ionicabizau/node.cobol

0.0 1.0 0.0 22 KB

:pager: Node.js bridge for COBOL which allows you to run Node.js code from COBOL.

License: MIT License

JavaScript 21.54% COBOL 78.46%

node.cobol's Introduction

node.cobol

node.cobol

Support me on Patreon Buy me a book PayPal Ask me anything Version Downloads Get help on Codementor

Buy Me A Coffee

Node.js bridge for COBOL which allows you to run Node.js code from COBOL.

node.cobol

You have to install Node.js on your machine. In case you do not have a COBOL compiler, you can install it by running:

# Ubuntu
sudo apt-get install open-cobol

# OS X
brew install gnu-cobol

📋 Example

      * Compile this file together with the node.cobol
      * modules:
      *
      *  $ cobc -x example/main.cbl lib/node-exec*.cbl
      *
      * Then execute the binary file:
      *
      *  $ ./main
       IDENTIFICATION DIVISION.
       PROGRAM-ID. MAIN.

       DATA DIVISION.
          WORKING-STORAGE SECTION.
          01 NODEJS-CODE PIC X(100) value "console.log('Hello World!')".

       PROCEDURE DIVISION.
      * Execute a short Node.js snippet
           CALL 'EXEC_NODEJS' USING NODEJS-CODE

           DISPLAY "Starting an HTTP server on port 8000".

      * Convert an image into ASCII/ANSI art
           CALL 'EXEC_NODEJS_FILE' USING "example/grace-hopper.js"

           DISPLAY "Starting an HTTP server on port 8000".

      * Starting an HTTP server in Node.js
           CALL 'EXEC_NODEJS_FILE' USING "example/server.js".
       STOP RUN.

To compile the program, use:

cobc -x example/main.cbl lib/node-exec*.cbl

❓ Get Help

There are few ways to get help:

  1. Please post questions on Stack Overflow. You can open issues with questions, as long you add a link to your Stack Overflow question.

  2. For bug reports and feature requests, open issues. 🐛

  3. For direct and quick help, you can use Codementor. 🚀

📝 Documentation

The COBOL modules from the lib/ directory export the following subroutines:

EXEC_NODEJS(code)

  • code: The Node.js snippet to execute.

EXEC_NODEJS_FILE(file)

  • file: The Node.js file path.

😋 How to contribute

Have an idea? Found a bug? See how to contribute.

💖 Support my projects

I open-source almost everything I can, and I try to reply to everyone needing help using these projects. Obviously, this takes time. You can integrate and use these projects in your applications for free! You can even change the source code and redistribute (even resell it).

However, if you get some profit from this or just want to encourage me to continue creating stuff, there are few ways you can do it:

  • Starring and sharing the projects you like 🚀

  • Buy me a book—I love books! I will remember you after years if you buy me one. 😁 📖

  • PayPal—You can make one-time donations via PayPal. I'll probably buy a coffee tea. 🍵

  • Support me on Patreon—Set up a recurring monthly donation and you will get interesting news about what I'm doing (things that I don't share with everyone).

  • Bitcoin—You can send me bitcoins at this address (or scanning the code below): 1P9BRsmazNQcuyTxEqveUsnf5CERdq35V6

Thanks! ❤️

✨ Related

  • cobol—COBOL bridge for NodeJS which allows you to run COBOL code from NodeJS.
  • fortran—Fortran bridge for Node.js which allows you to run Fortran code from Node.js.
  • node.fortran—Execute Node.js in your Fortran programs.

📜 License

MIT © Ionică Bizău

node.cobol's People

Contributors

ionicabizau avatar

Watchers

James Cloos avatar

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.