All Projects → adonisjs → mrm-preset

adonisjs / mrm-preset

Licence: other
This repo is the preset used to AdonisJs team to manage and keep their config in sync.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to mrm-preset

opencart-project-template
OpenCart Project Template
Stars: ✭ 16 (+6.67%)
Mutual labels:  project-template
project-template
Yii2 Project Template
Stars: ✭ 53 (+253.33%)
Mutual labels:  project-template
AspNet-Core-REST-Service
VS2017/VS2019 project template for ASP.Net Core 3.1/5.0 to create fully functional production ready RESTful services
Stars: ✭ 57 (+280%)
Mutual labels:  project-template
qt-qml-project-template-with-ci
Template for a Qt/QML application with batteries included: GitHub C.I. for your QML app; automated gui testing with Xvfb; automatic code-format checks and more. Compiles for Desktop and Mobile (Linux, Mac, Windows, and Android).
Stars: ✭ 33 (+120%)
Mutual labels:  project-template
Kosm-Classic-FPS-Template-UE4
Classic Arena First-Person-Shooter Mechanics for Unreal Engine 4.
Stars: ✭ 38 (+153.33%)
Mutual labels:  dev-tools
sketchup-console-plus
A better Ruby Console and IDE for integrated development in SketchUp.
Stars: ✭ 31 (+106.67%)
Mutual labels:  dev-tools
sink
Development Toolbox for AdonisJS providers
Stars: ✭ 27 (+80%)
Mutual labels:  dev-tools
javacard-gradle-template
JavaCard project template for building CAP and running JCardSim with gradle + coverage
Stars: ✭ 27 (+80%)
Mutual labels:  project-template
tweego-setup
A blank Tweego project with all the trimmings. Uses node and gulp.
Stars: ✭ 40 (+166.67%)
Mutual labels:  project-template
project-template
📂 A template for open source projects.
Stars: ✭ 12 (-20%)
Mutual labels:  project-template
MonolithicArchitecture
This repository presents an approach on how to build an application using Monolithic architecture, ASP.NET Core, EntityFrameworkCore, Identity Server, CQRS, DDD
Stars: ✭ 18 (+20%)
Mutual labels:  project-template
flask-project-template
DO NOT FORK, CLICK "Use this template" - A github template to start a Flask Project - this uses github actions to generate your project based on the template.
Stars: ✭ 74 (+393.33%)
Mutual labels:  project-template
docker-django-boilerplate
Minimal boilerplate setup for a Django project with Docker.
Stars: ✭ 41 (+173.33%)
Mutual labels:  project-template
sparky
A Bootstrap 3 and 4 Sass Starter Project
Stars: ✭ 21 (+40%)
Mutual labels:  project-template
vanillajs-hello
Start a VanillaJS website using WebPack in just 30 seconds: HTML,CSS,Babel,SASS,Bootstrap,Prettier,Gitpod
Stars: ✭ 24 (+60%)
Mutual labels:  project-template
go-todo-backend
Go Todo Backend example using modular project layout for product microservice.
Stars: ✭ 177 (+1080%)
Mutual labels:  project-template
assembler
Set of commands to build and serve AdonisJS projects, along with `make:` commands
Stars: ✭ 25 (+66.67%)
Mutual labels:  dev-tools
webpack-multipage-cli
用webpack(已更新至4)构建的多页应用项目脚手架,具有自动打包,编译,部署等功能
Stars: ✭ 52 (+246.67%)
Mutual labels:  project-template
cmake-gtest-gbench-starter
A cross-platform C++11/14/17 starter project with google test and google benchmark support.
Stars: ✭ 27 (+80%)
Mutual labels:  project-template
cpp14-project-template
A simple, cross-platform, and continuously integrated C++14 project template
Stars: ✭ 64 (+326.67%)
Mutual labels:  project-template

AdonisJS preset for mrm to keep the project configuration files in-sync and consistent across various projects.

Table of contents

What is MRM?

You might be curious to know what the heck is MRM?

MRM is a command line tool to scaffold new projects. But instead of just creating the initial set of files, it has powerful utilities to update them as well.

For better explanation, I recommend reading this article by the project author.

What is MRM Preset?

This module is a custom preset of tasks for MRM and is used by AdonisJS and many other projects I author.

You can also create a preset for your own needs. However, just go through the tasks once to see if they fit your needs and that way you can avoid creating your own tasks.

Getting started

Let's quickly learn how to use this preset, before we dig into the specifics of tasks.

npm i --save-dev mrm @adonisjs/mrm-preset

Add script to package.json file

{
 "scripts": {
   "mrm": "mrm --preset=@adonisjs/mrm-preset"
 }
}

and then run it as follows

## Initiate by creating config file
npm run mrm init
## Execute all tasks (for new projects)
npm run mrm all

Tasks

Let's focus on all the tasks supported by AdonisJS preset.

Appveyor

Appveyor tasks creates a configuration file (appveyor.yml) in the root of your project. The tasks depends on the config file config.json and requires following key/value pairs.

{
  "services": ["appveyor"],
  "minNodeVersion": "12.0.0"
}

To remove support for appveyor from your project, just npm run mrm appveyor task by removing the appveyor keyword from the services array.

{
  "services": []
}
npm run mrm appveyor

Circle CI

Circle CI tasks creates a configuration file (.circleci/config.yml) in the root of your project. The tasks depends on the config file config.json and requires following key/value pairs.

{
  "services": ["circleci"],
  "minNodeVersion": "12.0.0"
}

To remove support for circleci from your project, just npm run mrm circleci task by removing the circleci keyword from the services array.

{
  "services": []
}
npm run mrm circleci

Contributing.md template

Creates .github/CONTRIBUTING.md file. This file is shown by Github to users creating new issues.

The content of the template is pre-defined and is not customizable. If you want custom template, then it's better to create the file by hand.

  1. Template for Typescript The typescript template is used when ts=true inside the config file.

    {
      "ts": true
    }
  2. Otherwise the default template will be used.

Editorconfig file

Creates a .editorconfig file inside the project root. The editor config file is a way to keep the editor settings consistent regardless of the the editor you open the files in.

You may need a plugin for your editor to make editorconfig work.

The file is generated with settings defined inside the task file and again is not customizable.

Eslint

Installs eslint and eslint-plugin-adonis. Also it will remove tslint and it's related dependencies from the project.

Github templates

Creates issues and PR template for Github. The contents of these templates will be pre-filled anytime someone wants to create a new issue or PR.

  1. Issues template content
  2. PR template

Github Actions

Github actions tasks creates a configuration file (.github/workflows/test.yml) in the root of your project. The tasks depends on the config file config.json and requires following key/value pairs.

{
  "services": ["github-actions"],
  "minNodeVersion": "14.15.4"
}

To remove support for github-actions from your project, just npm run mrm github-actions task by removing the github-actions keyword from the services array.

{
  "services": []
}
npm run mrm github-actions

Gitignore template

Creates .gitignore file in the root of your project. Following files and folders are ignored by default. However, you can add more to the template.

node_modules
coverage
test/__app
.DS_STORE
.nyc_output
.idea
.vscode/
*.sublime-project
*.sublime-workspace
*.log
build
docs
dist
shrinkwrap.yaml

License template

Creates LICENSE.md file in the root of your project.

You can choose from one of the available licenses when running npm run init command or define it by hand inside config.json file.

{
  "license": "MIT"
}

If not defined, will fallback to package.json file or MIT.

Np release management

np is a sick (👌) tool to publish your npm packages by ensuring that your package is in healthy state for release.

We recommend reading their README too https://github.com/sindresorhus/np.

Package file generation

This tasks does lots of work to install handful of packages and update package.json file.

The list of operations is based on my personal learnings while maintaining open source projects.

Testing

The japa test runner is installed along side with japaFile.js.

Typescript setup

We create a tsconfig.json file and install following dependencies.

  1. @types/node
  2. typescript
  3. @adonisjs/require-ts

Scripts

The following scripts are defined inside the package.json file.

  1. clean to clean the build folder before starting the build. We also install del-cli npm package for this script to work
  2. compile to compile the TypeScript code to JavaScript
  3. build runs compile
  4. prePublishOnly to compile before publishing to npm.

Prettier

Installs prettier and eslint-plugin-prettier and eslint-config-prettier to setup prettier along side with eslint. Also the task will check, if .eslintrc.json file exists and then only performs the eslint specific setup

Probot applications

Configures certain probot application templates inside the .github directory. Currently, following apps are supported.

Readme file

Generates a Readme file using a pre-defined template. Feel free to change the contents of the file, since it's just a starting point.

Readme file TOC

Generates table of contents for the readme file. This tasks registers a git hook to automatically generate the TOC before every commit.

Under the hood npm package doctoc is used for generating the TOC, so make sure to read their readme file as well.

Validate commit

Configures a git hook to validate the commit messages. This is great, if you want to ensure that contributors to your project must form commit messages as per a given standard.

The default standard used is conventional-changelog and rules are defined inside this template, which is copied over to your project .github folder for readers reference.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].