feat: bootstrap radar and config files if they are not present
This commit is contained in:
committed by
Mathias Schopmans
parent
d5668e1d95
commit
6dbcd45a52
26
README.md
26
README.md
@@ -21,6 +21,13 @@ new `config.json` based on the documentation below. You can find a reference imp
|
||||
our [repo](https://github.com/AOEpeople/techradar). The old version is still available in the `v3`
|
||||
branch.
|
||||
|
||||
Version 4.0.0 also removes the .html extension from the URLs. If you want to support the old URLs,
|
||||
we recommend to add a redirect rule. For nginx, you can use the following rule:
|
||||
|
||||
```nginx
|
||||
rewrite ^/techradar/(.+)\.html$ /techradar/$1/ permanent;
|
||||
```
|
||||
|
||||
## Create your own radar
|
||||
|
||||
The generator is free to use under Open Source License - in fact there are already some other Radars
|
||||
@@ -47,16 +54,18 @@ file like the following and adapt to your needs:
|
||||
}
|
||||
```
|
||||
|
||||
Run `npm install` to install the dependencies
|
||||
Run `npm install` to install the dependencies and run `npm run build` to create the initial radar.
|
||||
This will also create a basic bootstrap of all required files, including the `config.json` and
|
||||
the `about.md` if they do not exist yet.
|
||||
|
||||
### Step 2: Change logo and the favicon
|
||||
|
||||
Create a folder named `public` and put your `logo.svg` and `favicon.ico` in it.
|
||||
Place your `logo.svg` and `favicon.ico` in the `public` folder next to the `package.json`.
|
||||
The ideal logo is 150px x 60px. For reference have a look at [public/logo.svg](./public/logo.svg).
|
||||
|
||||
### Step 3: Configure the radar
|
||||
|
||||
Copy the [`config.json`](./data/config.json) next to the `package.json` and adapt it to your needs.
|
||||
Open the `config.json` file and configure the radar to your needs.
|
||||
|
||||
| Attribute | Description |
|
||||
| --------- | ------------------------------------------------------------------------------------------------------------------------------ |
|
||||
@@ -110,13 +119,14 @@ Copy the [`config.json`](./data/config.json) next to the `package.json` and adap
|
||||
|
||||
### Step 4: Add a help page with explanations
|
||||
|
||||
Create a file `about.md` next to the `package.json` file. This file will be shown on
|
||||
Edit the `about.md` file next to the `package.json` file. The contents will be shown on
|
||||
the `/help-and-about-tech-radar` page. Optionally you can change the title of the menu by
|
||||
setting `labels.pageAbout` in your `config.json`.
|
||||
|
||||
### Step 5: Create the radar items
|
||||
|
||||
For a new Technology Radar release, create a folder of the release date (YYYY-MM-DD)
|
||||
Remove or edit existing items in the `radar` folder.
|
||||
For a new release, create a folder of the release date (YYYY-MM-DD)
|
||||
under `./radar`. e.g. `./radar/2024-03-01`.
|
||||
|
||||
The items are written in Markdown format (.md)
|
||||
@@ -178,12 +188,10 @@ Your final file and folder structure should look like this:
|
||||
└── demo-item-3.md
|
||||
```
|
||||
|
||||
Run `npm run build` to build the radar and
|
||||
upload the files of the `./build` folder to your server.
|
||||
Run `npm run build` to build the radar and upload the files of the `./build` folder to your server.
|
||||
|
||||
You can view a development version of the radar by running `npm run serve` and open the radar in
|
||||
your
|
||||
browser at `http://localhost:3000`.
|
||||
your browser at `http://localhost:3000`.
|
||||
|
||||
## Development
|
||||
|
||||
|
||||
@@ -16,11 +16,59 @@ function info(message) {
|
||||
console.log(`\x1b[32m${message}\x1b[0m`);
|
||||
}
|
||||
|
||||
function warn(message) {
|
||||
console.warn(`Warning: ${message}`);
|
||||
}
|
||||
|
||||
function error(message) {
|
||||
console.error(`Error: ${message}`);
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
function bootstrap() {
|
||||
if (!fs.existsSync(path.join(CWD, "radar"))) {
|
||||
warn(
|
||||
"Could not find radar directory. Created a bootstrap radar directory in your current working directory. Feel free to customize it.",
|
||||
);
|
||||
fs.cpSync(
|
||||
path.join(BUILDER_DIR, "data", "radar"),
|
||||
path.join(CWD, "radar"),
|
||||
{
|
||||
recursive: true,
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
if (!fs.existsSync(path.join(CWD, "public"))) {
|
||||
warn(
|
||||
"Could not find public directory. Created a public radar directory in your current working directory.",
|
||||
);
|
||||
fs.cpSync(path.join(BUILDER_DIR, "public"), path.join(CWD, "public"), {
|
||||
recursive: true,
|
||||
});
|
||||
}
|
||||
|
||||
if (!fs.existsSync(path.join(CWD, "config.json"))) {
|
||||
warn(
|
||||
"Could not find a config.json. Created a bootstrap config.json in your current working directory. Customize it to your needs.",
|
||||
);
|
||||
fs.copyFileSync(
|
||||
path.join(BUILDER_DIR, "data", "config.json"),
|
||||
path.join(CWD, "config.json"),
|
||||
);
|
||||
}
|
||||
|
||||
if (!fs.existsSync(path.join(CWD, "about.md"))) {
|
||||
warn(
|
||||
"Could not find a about.md. Created a bootstrap about.md in your current working directory. Customize it to your needs.",
|
||||
);
|
||||
fs.copyFileSync(
|
||||
path.join(BUILDER_DIR, "data", "about.md"),
|
||||
path.join(CWD, "about.md"),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// Calculate current hash of package.json
|
||||
function calculateHash(file) {
|
||||
const fileBuffer = fs.readFileSync(file);
|
||||
@@ -59,16 +107,16 @@ if (RECREATE_DIR) {
|
||||
process.chdir(BUILDER_DIR);
|
||||
info("Installing npm packages");
|
||||
execSync("npm install", { stdio: "inherit" });
|
||||
bootstrap();
|
||||
} catch (e) {
|
||||
error("Could not install npm packages");
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
if (fs.existsSync(path.join(BUILDER_DIR, "data", "radar"))) {
|
||||
fs.rmSync(path.join(BUILDER_DIR, "data", "radar"), { recursive: true });
|
||||
}
|
||||
|
||||
try {
|
||||
fs.cpSync(path.join(CWD, "radar"), path.join(BUILDER_DIR, "data", "radar"), {
|
||||
recursive: true,
|
||||
});
|
||||
|
||||
@@ -1,77 +1,9 @@
|
||||
# How to use the AOE Technology Radar
|
||||
# How to use the Technology Radar
|
||||
|
||||
### Introduction
|
||||
|
||||
Technology is advancing rapidly, with new technologies and innovations constantly emerging.
|
||||
|
||||
It is essential for a development and technology company like AOE to continually improve and keep
|
||||
track of the latest valuable innovations. It is important to actively seek out innovations and new
|
||||
technologies and periodically question established technologies and methods.
|
||||
|
||||
But, it is also important to wisely choose which technologies to use in our daily work and in the
|
||||
different projects we are carrying out. As we all know: There is no silver bullet.
|
||||
|
||||
### What is the AOE Technology Radar?
|
||||
|
||||
The Tech Radar provides an overview of different technologies, including languages, frameworks,
|
||||
tools, and patterns, as well as platforms, that we consider 'new or noteworthy.' The radar does not
|
||||
cover all established technologies; instead, it focuses on items that have recently gained
|
||||
significance or undergone changes. Items previously featured in the radar are not listed on the
|
||||
homepage but remain available in the complete overview and search.
|
||||
|
||||
### How it is created
|
||||
|
||||
The items in the technology radar are suggested by different teams, many of which are related to the
|
||||
work and challenges faced by the teams in various projects. In fact, we do not include anything on
|
||||
the radar that we haven't personally tested at least once.
|
||||
|
||||
Numerous valuable discussions have taken place in various expert groups regarding the classification
|
||||
and details of each technology and innovation. The culmination of these discussions is reflected in
|
||||
the latest technology radar.
|
||||
|
||||
### How should it be used
|
||||
|
||||
The radar serves as an overview of technologies that we believe everyone in the teams should be
|
||||
aware of at present.
|
||||
|
||||
Its goal is to guide and inspire daily work within the teams. Additionally, it aims to provide
|
||||
valuable information and a high-level perspective to enable decisions to be made with a deeper
|
||||
understanding of the subject matter, resulting in more informed and coordinated choices.
|
||||
|
||||
We also hope that developers outside of AOE will find the information in our technology overview
|
||||
inspiring.
|
||||
|
||||
We categorize the items into four quadrants, and sometimes, when it's not entirely clear where an
|
||||
item belongs, we choose the best fit.
|
||||
|
||||
#### The quadrants are:
|
||||
|
||||
- **Languages & Frameworks:** In this category, we include development languages like Scala or
|
||||
Golang, as well as low-level development frameworks such as Play or Symfony. These are valuable
|
||||
for implementing various types of custom software.
|
||||
- **Tools:** This section is dedicated to a wide range of software tools, from small utilities to
|
||||
more extensive software projects.
|
||||
- **Methods & Patterns:** Patterns hold enduring significance, with many of them standing the test
|
||||
of time compared to some tools or frameworks. This category is where we provide information on
|
||||
methods and patterns related to development, continuous integration, testing, organization,
|
||||
architecture, and more.
|
||||
- **Platforms & Operations:** In this quadrant, we group technologies related to the operation of
|
||||
software, infrastructure, and platform-related tools and services.
|
||||
|
||||
#### Each of the items is classified in one of these rings:
|
||||
|
||||
- **Adopt:** We wholeheartedly recommend this technology. It has been extensively used in many teams
|
||||
for an extended period, proving its stability and utility.
|
||||
- **Trial:** We have successfully implemented this technology and suggest taking a closer look at it
|
||||
in this category. The aim here is to scrutinize these items more closely with the intention of
|
||||
elevating them to the 'Adopt' level.
|
||||
- **Assess:** We have experimented with this technology and find it promising. We recommend
|
||||
exploring these items when you encounter a specific need for the technology in your project.
|
||||
- **Hold:** This category is somewhat unique. Unlike the others, it advises discontinuing or
|
||||
refraining from using certain technologies. This does not necessarily imply that they are
|
||||
inherently bad; it often may be acceptable to use them in existing projects. However, we move
|
||||
items here when we believe they should no longer be employed, as we have identified better options
|
||||
or alternatives.
|
||||
Edit this file to your needs to provide an introduction to the technology radar. Explain the purpose
|
||||
of the radar and how it is created. This is a good place to explain the quadrants and rings, too.
|
||||
|
||||
### Contributing to the AOE Technology Radar
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
{
|
||||
"id": "adopt",
|
||||
"title": "Adopt",
|
||||
"description": "We can clearly recommend this technology. We have used it for longer period of time in many teams and it has proven to be stable and useful.",
|
||||
"description": "",
|
||||
"color": "#588157",
|
||||
"radius": 0.5,
|
||||
"strokeWidth": 5
|
||||
@@ -49,7 +49,7 @@
|
||||
{
|
||||
"id": "trial",
|
||||
"title": "Trial",
|
||||
"description": "We have used it with success and recommend to have a closer look at the technology in this ring. The goal of items here is to look at them more closely, with the goal to bring them to the adopt level.",
|
||||
"description": "",
|
||||
"color": "#457b9d",
|
||||
"radius": 0.69,
|
||||
"strokeWidth": 3
|
||||
@@ -57,7 +57,7 @@
|
||||
{
|
||||
"id": "assess",
|
||||
"title": "Assess",
|
||||
"description": "We have tried it out and we find it promising. We recommend having a look at these items when you face a specific need for the technology in your project.",
|
||||
"description": "",
|
||||
"color": "#bc6c25",
|
||||
"radius": 0.85,
|
||||
"strokeWidth": 2
|
||||
@@ -65,7 +65,7 @@
|
||||
{
|
||||
"id": "hold",
|
||||
"title": "Hold",
|
||||
"description": "This category is a bit special. Unlike the others, we recommend to stop doing or using something. That does not mean that they are bad and it often might be ok to use them in existing projects. But we move things here if we think we shouldn't do them anymore - because we see better options or alternatives now.",
|
||||
"description": "",
|
||||
"color": "#d62828",
|
||||
"radius": 1,
|
||||
"strokeWidth": 0.75
|
||||
@@ -93,10 +93,6 @@
|
||||
"blipSize": 12
|
||||
},
|
||||
"social": [
|
||||
{
|
||||
"href": "https://www.facebook.com/aoepeople",
|
||||
"icon": "facebook"
|
||||
},
|
||||
{
|
||||
"href": "https://twitter.com/aoepeople",
|
||||
"icon": "x"
|
||||
@@ -109,14 +105,6 @@
|
||||
"href": "https://www.xing.com/company/aoe",
|
||||
"icon": "xing"
|
||||
},
|
||||
{
|
||||
"href": "https://www.instagram.com/aoepeople",
|
||||
"icon": "instagram"
|
||||
},
|
||||
{
|
||||
"href": "https://www.youtube.com/user/aoepeople",
|
||||
"icon": "youtube"
|
||||
},
|
||||
{
|
||||
"href": "https://github.com/aoepeople",
|
||||
"icon": "github"
|
||||
@@ -130,7 +118,7 @@
|
||||
"quadrantOverview": "Quadrant Overview",
|
||||
"zoomIn": "Zoom in",
|
||||
"filterByTag": "Filter by Tag",
|
||||
"footer": "AOE is a leading global provider of services for digital transformation and digital business models. AOE relies exclusively on established Enterprise Open Source technologies. This leads to innovative solutions, digital products and portals in agile software projects, and helps build long-lasting, strategic partnerships with our customers.",
|
||||
"footer": "The technology radar is a project by AOE GmbH. Feel free to build your own radar based on the open source project.",
|
||||
"notUpdated": "This item was not updated in last three versions of the Radar. Should it have appeared in one of the more recent editions, there is a good chance it remains pertinent. However, if the item dates back further, its relevance may have diminished and our current evaluation could vary. Regrettably, our capacity to consistently revisit items from past Radar editions is limited.",
|
||||
"notFound": "404 - Page not found",
|
||||
"pageAbout": "How to use AOE Technology Radar?",
|
||||
|
||||
1366
package-lock.json
generated
1366
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "aoe_technology_radar",
|
||||
"version": "4.0.0-alpha.8",
|
||||
"version": "4.0.0-alpha.9",
|
||||
"private": true,
|
||||
"bin": {
|
||||
"techradar": "./bin/techradar.js"
|
||||
|
||||
Reference in New Issue
Block a user