Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add programming languages and frameworks #112

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,10 @@ node_modules
main.py

# trash
.DS_Store
.DS_Store

# Website uses yarn; ignore npm package-lock.json
website/package-lock.json

# Ignore .swp files
.swp
16 changes: 15 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Contribution Guide

You shouldn't edit the node class files (all files under `diagram` directory) by
You shouldn't edit the node class files (all files under `diagrams/` directory) by
yourself.

## Resources
Expand Down Expand Up @@ -55,3 +55,17 @@ Then just run the `./autogen.sh` to generate the added or updated aliases.
```shell
python -m unittest tests/*.py -v
```

## Testing changes to the website

The [Docusaurus](https://docusaurus.io/)-based documentation website can be run by installing dependencies, then simply running `npm run start`.

```bash
cd website/
npm i
npm run start
```

The website will be available on [http://localhost:3000](http://localhost:3000).

Edit files in `website/` and `docs/` respectively to edit documentation.
4 changes: 3 additions & 1 deletion autogen.sh
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
#!/bin/bash
set -e

app_root_dir="diagrams"

# NOTE: azure icon set is not latest version
providers=("onprem" "aws" "azure" "gcp" "k8s" "alibabacloud" "oci")
providers=("onprem" "aws" "azure" "gcp" "k8s" "alibabacloud" "oci" "programming")

if ! [ -x "$(command -v round)" ]; then
echo 'round is not installed'
Expand Down
3 changes: 2 additions & 1 deletion config.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
DIR_RESOURCE = "resources"
DIR_TEMPLATE = "templates"

PROVIDERS = ("base", "onprem", "aws", "azure", "gcp", "k8s", "alibabacloud", "oci")
PROVIDERS = ("base", "onprem", "aws", "azure", "gcp", "k8s", "alibabacloud", "oci", "programming")

#########################
# Resource Processing #
Expand All @@ -32,6 +32,7 @@
"k8s": (),
"alibabacloud": (),
"oci": ("OCI-",),
"programming": (),
}

#########################
Expand Down
12 changes: 12 additions & 0 deletions diagrams/programming/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
"""
Programming provides a set of programming languages and frameworks.
"""

from diagrams import Node


class _Programming(Node):
_provider = "programming"
_icon_dir = "resources/programming"

fontcolor = "#ffffff"
55 changes: 55 additions & 0 deletions diagrams/programming/framework.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# This module is automatically generated by autogen.sh. DO NOT EDIT.

from . import _Programming


class _Framework(_Programming):
_type = "language"
_icon_dir = "resources/programming/framework"


class Angular(_Framework):
_icon = "angular.png"


class Backbone(_Framework):
_icon = "backbone.png"


class Django(_Framework):
_icon = "django.png"


class Ember(_Framework):
_icon = "ember.png"


class Flask(_Framework):
_icon = "flask.png"


class Flutter(_Framework):
_icon = "flutter.png"


class Laravel(_Framework):
_icon = "laravel.png"


class Rails(_Framework):
_icon = "rails.png"


class React(_Framework):
_icon = "react.png"


class Spring(_Framework):
_icon = "spring.png"


class Vue(_Framework):
_icon = "vue.png"


# Aliases
79 changes: 79 additions & 0 deletions diagrams/programming/language.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
# This module is automatically generated by autogen.sh. DO NOT EDIT.

from . import _Programming


class _Language(_Programming):
_type = "language"
_icon_dir = "resources/programming/language"


class Bash(_Language):
_icon = "bash.png"


class C(_Language):
_icon = "c.png"


class Csharp(_Language):
_icon = "csharp.png"


class Cpp(_Language):
_icon = "cpp.png"


class Dart(_Language):
_icon = "dart.png"


class Go(_Language):
_icon = "go.png"


class Java(_Language):
_icon = "java.png"


class Javascript(_Language):
_icon = "javascript.png"


class Kotlin(_Language):
_icon = "kotlin.png"


class Matlab(_Language):
_icon = "matlab.png"


class Nodejs(_Language):
_icon = "nodejs.png"


class PHP(_Language):
_icon = "php.png"


class Python(_Language):
_icon = "python.png"


class R(_Language):
_icon = "r.png"


class Ruby(_Language):
_icon = "ruby.png"


class Swift(_Language):
_icon = "swift.png"


class Typescript(_Language):
_icon = "typescript.png"


# Aliases
40 changes: 40 additions & 0 deletions docs/nodes/programming.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
---
id: programming
title: Programming
---

Node classes list of programming languages, runtimes and frameworks

## programming.language

- **diagrams.programming.language.Bash**
- **diagrams.programming.language.C**
- **diagrams.programming.language.Csharp**
- **diagrams.programming.language.Cpp**
- **diagrams.programming.language.Dart**
- **diagrams.programming.language.Go**
- **diagrams.programming.language.Java**
- **diagrams.programming.language.Javascript**
- **diagrams.programming.language.Kotlin**
- **diagrams.programming.language.Matlab**
- **diagrams.programming.language.Nodejs**
- **diagrams.programming.language.PHP**
- **diagrams.programming.language.Python**
- **diagrams.programming.language.R**
- **diagrams.programming.language.Ruby**
- **diagrams.programming.language.Swift**
- **diagrams.programming.language.Typescript**

## programming.framework

- **diagrams.programming.framework.Angular**
- **diagrams.programming.framework.Backbone**
- **diagrams.programming.framework.Django**
- **diagrams.programming.framework.Ember**
- **diagrams.programming.framework.Flask**
- **diagrams.programming.framework.Flutter**
- **diagrams.programming.framework.Laravel**
- **diagrams.programming.framework.Rails**
- **diagrams.programming.framework.React**
- **diagrams.programming.framework.Spring**
- **diagrams.programming.framework.Vue**
Binary file added resources/programming/framework/angular.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/backbone.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/django.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/ember.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/flask.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/flutter.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/laravel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/rails.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/react.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/spring.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/framework/vue.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/bash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/c.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/cpp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/csharp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/dart.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/go.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/java.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/javascript.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/kotlin.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/matlab.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/nodejs.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/php.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/python.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/r.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/programming/language/ruby.png
Binary file added resources/programming/language/swift.png
Binary file added resources/programming/language/typescript.png
2 changes: 1 addition & 1 deletion scripts/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import config as cfg
from . import app_root_dir, doc_root_dir, resource_dir, template_dir

_usage = "Usage: generate.py <onprem|aws|gcp|azure|k8s|alibabacloud|oci>"
_usage = "Usage: generate.py <onprem|aws|gcp|azure|k8s|alibabacloud|oci|programming>"


def load_tmpl(tmpl: str) -> Template:
Expand Down
3 changes: 3 additions & 0 deletions website/i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@
},
"nodes/onprem": {
"title": "OnPrem"
},
"nodes/programming": {
"title": "Programming"
}
},
"links": {
Expand Down
2 changes: 1 addition & 1 deletion website/pages/en/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ class Index extends React.Component {
`Diagram as Code` allows you to **track** the architecture diagram changes in any **version control** system.
</MarkdownBlock>
<MarkdownBlock>
Diagrams currently supports six major providers: `AWS`, `Azure`, `GCP`, `Kubernetes`, `Alibaba Cloud` and `Oracle Cloud`. It now also supports `On-Premise` nodes.
Diagrams currently supports six major providers: `AWS`, `Azure`, `GCP`, `Kubernetes`, `Alibaba Cloud` and `Oracle Cloud`. It now also supports `On-Premise` nodes as well as `Programming Languages` and `Frameworks`.
</MarkdownBlock>
</div>
);
Expand Down
3 changes: 2 additions & 1 deletion website/sidebars.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
"nodes/gcp",
"nodes/k8s",
"nodes/alibabacloud",
"nodes/oci"
"nodes/oci",
"nodes/programming"
]
}
}