Giter Club home page Giter Club logo

readme-md-generator's Introduction

Welcome to readme-md-generator 👋

downloads License: MIT gitmoji-changelog Twitter: FranckAbgrall

CLI that generates beautiful README.md files.
readme-md-generator will suggest you default answers by reading your package.json and git configuration.

✨ Demo

readme-md-generator is able to read your environment (package.json, git config...) to suggest you default answers during the README.md creation process:

demo

Generated README.md:

cli output

Example of package.json with good meta data:

// The package.json is not required to run README-MD-GENERATOR
{
  "name": "readme-md-generator",
  "version": "0.1.3",
  "description": "CLI that generates beautiful README.md files.",
  "author": "Franck Abgrall",
  "license": "MIT",
  "homepage": "https://github.com/kefranabg/readme-md-generator#readme",
  "repository": {
    "type": "git",
    "url": "git+https://github.com/kefranabg/readme-md-generator.git"
  },
  "bugs": {
    "url": "https://github.com/kefranabg/readme-md-generator/issues"
  },
  "engines": {
    "npm": ">=5.5.0",
    "node": ">=9.3.0"
  }
}

🚀 Usage

Make sure you have npx installed (npx is shipped by default since npm 5.2.0)

Just run the following command at the root of your project and answer questions:

npx readme-md-generator

Or use default values for all questions (-y):

npx readme-md-generator -y

Use your own ejs README template (-p):

npx readme-md-generator -p path/to/my/own/template.md

You can find ejs README template examples here.

Code Contributors

This project exists thanks to all the people who contribute. [Contribute].

Financial Contributors

Become a financial contributor and help us sustain our community. [Contribute]

Individuals

Organizations

Support this project with your organization. Your logo will show up here with a link to your website. [Contribute]

🤝 Contributing

Contributions, issues and feature requests are welcome.
Feel free to check issues page if you want to contribute.
Check the contributing guide.

Author

👤 Franck Abgrall

Show your support

Please ⭐️ this repository if this project helped you!

📝 License

Copyright © 2019 Franck Abgrall.
This project is MIT licensed.


This README was generated with ❤️ by readme-md-generator

readme-md-generator's People

Contributors

allcontributors[bot] avatar anku255 avatar apatrascu avatar bdougie avatar david-dasilva avatar dependabot[bot] avatar detectivequack avatar errorname avatar greenkeeper[bot] avatar hgb123 avatar hgwood avatar kefranabg avatar kushagra-ag avatar lucasprocopio avatar nikxda avatar rdil avatar samit4me avatar slashgear avatar swapnikkatkoori avatar tbetous avatar yannbertrand avatar yexan avatar zenigata avatar zizizi17 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

readme-md-generator's Issues

README says no need for package.json, but gives error

README says package.json is not needed, also, in the USAGE section, only run the command readme. However it gives this error

⠋ Gathering project infosreadme [template]

Generate README.md from a template

Positionals:
  template  The name of template you want to use            [default: "default"]

Options:
  --version  Show version number                                       [boolean]
  --help     Show help                                                 [boolean]

{ Error: ENOENT: no such file or directory, open 'package.json'
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: 'package.json' }

Provide initializer package

You should publish a thin wrapper package named create-markdown-md with a small bin script. Due to the create-* convention it would qualify as a proper "initializer package".
This would allow usage via npm init readme-md or yarn create readme-md without prior installation.

I'd even go further and name it create-readme.md for a totally awesome yarn create readme.md :)

Error on "readme" command : TypeError [ERR_INVALID_ARG_TYPE]

When I try to use the "readme" command it returns this error that I may have found in several Issue on other repo but none of the solutions are useful here :

⠋ Gathering project infosreadme [template]

Generate README.md from a template

Positionals:
  template  The name of template you want to use             [défaut: "default"]

Options:
  --version  Affiche le numéro de version                              [booléen]
  --help     Affiche de l'aide                                         [booléen]

TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received type undefined
    at validateString (internal/validators.js:107:11)
    at Object.basename (path.js:1149:5)
    at module.exports (/usr/local/lib/node_modules/readme-md-generator/node_modules/project-name/index.js:8:47)
    at Object.getProjectInfos (/usr/local/lib/node_modules/readme-md-generator/src/project-infos.js:106:16)
    at async mainProcess (/usr/local/lib/node_modules/readme-md-generator/src/cli.js:46:31)

Thank you !

Idea: Modify existing README

hi,

It would be cool to be able to pre-fill the different fields when a README.md already exists. We would be able to modify the readme without making a new one from scratch.

Keep up the great work.

npm WARN

npm installl

output is :

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

audited 866857 packages in 14.515s
found 0 vulnerabilities

Create a template without HTML tags

The problem:

Some platforms (like bitbucket) does not support HTML tags in markdown. See #60

Solution:
The solution would be to create a second template named no-html that generates the same README content as the default one, but without HTML tags.

When you start the command npx readme-md-generator, it would display the list of available template, and you would be able to choose the one you want (use inquirer list for this feature) :

Example :

npx readme-md-generator
? Choose a template
> default.md (the default readme-md-generator template)
  default-no-html (the default readme-md-generator template without html tags)

Idea: Add contributors

Hi,

First of all, thank you for your awesome work 👍

There is a section about author. This would be cool to have a section about contributors too. all-contributors is a specification about recognizing contributors. They also have a tool that edit README.md to add contributors.

Idea: Add an EditorConfig file

For formatting code there is EditorConfig (https://editorconfig.org/) which is supported in all major IDE's (including the ones from JetBrains) and Visual Studio Code through the means of a plugin (ext install EditorConfig.EditorConfig).

The format of the file is straightforward, and can cover all files that are used/will be used. For example, something similar with the following can be used on your code:

[*]
charset=utf-8
end_of_line=lf
insert_final_newline=true
indent_style=space
indent_size=2

If you think it's a good idea, I can create a PR with this feature.

install errror

npx readme-md-generator

output is:
npx: installed 114 in 41.99s
Unexpected token (

Available Scripts

What do you think about a session Available Scripts?
Getting all your scrpts commands on package.json file. Like generated apps with create-react-app.

If is ok I can try to do this.

Idea: Add note running the generator via `npx`

A project like this seems like a good candidate for use via npx.

It might be worthwhile to note in the "Installation" section of the README that this project can be run with npx readme-md-generator. (I've tested this, and it already seems to work)

Thanks for your work on this, it's a great template for making READMEs. 😄👍

Command list "&" become "&amp"

Looks like a utf bug, when you setup a new readme, in the "Install command" line, setting something with "&" will result in "&amp" in the final readme.

Weird on bitbucket

It's all messed up until the description after the tags :/

 <h1><p><h1 align="center">Welcome to XXX 👋</h1> <p> <a href="https://twitter.com/XXX"> <img alt="Twitter: XXX" src="https://img.shields.io/twitter/follow/XXX.svg?style=social" target="_blank" /> </a> </p>```

Doesn't seem to work on macOs

Tried out your project on my MacBook Pro (Mojave macOs 10.14.5). After successfully installing using your notes, I attempted to run and get the following error:

usr/local/lib/node_modules/readme-md-generator/src/cli.js:14
const askQuestions = async projectInfos => {
                           ^^^^^^^^^^^^
SyntaxError: Unexpected identifier
    at Object.exports.runInThisContext (vm.js:76:16)
    at Module._compile (module.js:528:28)
    at Object.Module._extensions..js (module.js:565:10)
    at Module.load (module.js:473:32)
    at tryModuleLoad (module.js:432:12)
    at Function.Module._load (module.js:424:3)
    at Module.require (module.js:483:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/usr/local/lib/node_modules/readme-md-generator/src/index.js:5:25)
    at Module._compile (module.js:556:32)

Which is interesting as I can clearly see the require statement

const projectInfos = require('./project-infos')

And project-infos.js appears to be fine.
Not knowledgable enough in node to debug it further myself.

Different behavior on GitLab vs GitHub

Hello, I've tested on GitLab and I saw that they are using a different flavor of Markdown and other rules for embedding HTML.

The default generated HTML looks like this right now on GitLab:
Selection_001

But if the Markdown is written as:

<div align="center">

# Test
</div>
<p>
  <img src="https://img.shields.io/badge/version-2.0-blue.svg?cacheSeconds=2592000" />
</p>

it looks correct:
Selection_003

Idea: use npm version badge if package exists

You could use view command to test if a package exists on npm:

npm view [package]

If it exists you can use npm version badge instead of generic one. An another improvement would be to let user add a tag to point on a specific version channel. For example 2.0.0-alpha.1

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.