Skip to content

markdown_github render template change #707

Closed

Description

@wols

Description

The template from #640 is a very helpful feature.

Many repositories are structured this way:

.
├── docs
│   ├── cli command1.md
│   ├── cli command2.md
│   └── README.md
├── LICENSE
├── README.md
├── cli
└── src
    ├──

To distinguish it from ./README.md, I would like file docs/README.md to be renamed to docs/cli.md (the script name).

Activity

  1. changed the title [-]Change markdown_github render template[/-] [+]markdown_github render template change[/+] on May 23, 2026
  2. DannyBen commented on May 23, 2026

    @DannyBen
    Member

    These templates are provided for convenience. It is not bashly's primary objective to render documentation.

    There are now 3 documentation renderers, and they should cover most use cases.

    For other specific cases, the entire library is built in a way that you can customize it to your needs. You just run bashly add --list and then you can add any of these to your local bashly project, and customize the library files as you see fit.

    I noticed now that there is no bashly add for the github markdown, I will add this, but it does not change the general concept.

    The files for it are here:
    https://github.com/bashly-framework/bashly/tree/master/lib/bashly/libraries/render/markdown_github

    Does this help?

    If you are unsure how to edit those to fit your needs, I can help of course

  3. wols commented on May 24, 2026

    @wols
    Author

    Oh yes, that's very helpful. Thank you!

    I'll use the ManDoc renderer as a guide:

    mdfile = "#{target}/#{command.full_name.tr(' ', '-')}.md"

  4. DannyBen commented on May 24, 2026

    @DannyBen
    Member

    Excellent.

    I have added the library to the index in #708, but it should not matter to you now (it just means it can be used with bashly add in next release)

    I tested the change you mentioned. The simplest steps are:

    1. run bashly add render_markdown
    2. It will then add a folder with files, you can move the folder to wherever you want - location is not important
    3. Then you can either update the files in it, or already copy the ones from the github folder
    4. then the change you need to make is very small:
      - save "#{target}/README.md", gtx.parse(command)
      + save "#{target}/#{command.name}.md", gtx.parse(command)

    and now you can run bashly render templates/path out/path

    If you need further assistance, you know where to find me 😸

  5. added this to the 1.4.0 milestone on Jul 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions