Code Monkey home page Code Monkey logo

ewbscp's Introduction

ewbscp

CLI Usage

First, make sure you have make installed on your system. Then:

$ make help

Commands:
  make build - Mix project build
  make zip <cmd> <args> - Runs commands based on this:
   >> directory_size <path> -- [<flags>]
      |> --allow-empty - Includes empty directories
   >> fetch_wikipedia_page <uri>
  make help - Display this message

Architecture

architecture diagram

Concepts & Responsibilities

concepts and responsibilities diagram

Folder structure

.
├── /entrypoints/
│   └── /cli/
│       └── cli_input.ex
├── /port/
│   └── /workflow/
│       └── /articles/
│           ├── /external/
│           │   └── cli_to_article.ex
│           ├── /internal/
│           │   └── title_to_article.ex
│           └── /models/
│               └── article_input.ex
├── /domain/
│   ├── /workflow/
│   │   └── /articles/
│   │       ├── orchestrator.ex
│   │       ├── fetch_main_page.ex
│   │       └── fetch_references.ex
│   └── /entities/
│       └── /article/
│           ├── article.ex
│           └── reference.ex
└── /clients/
    └── /article/
        └── article_client.ex

Example call flow from CLI

user
  ↓
cli_input.ex         | handles the action inputted
  ↓
cli_to_article.ex    | handles the transformation between external and internal
  ↓
orchestrator.ex      | handles external calls to return a domain entity
  ↓
title_to_article.ex  | handles how to fetch an external content and return to domain as an entity
  ↓
article_client.ex    | handles http calls
  |
  ↑
user (response)

This representations assumes that the user receives the result from cli_input.ex (entrypoint), but assuming that is a black box. Then, cli_input.ex depends on the cli_to_article.ex response, and so on.

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.