Skip to content

eficode/beyond-readme

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Beyond README

Welcome to your journey beyond a traditional README file.


This project contains example operations that you can run:

  • list_docs: lists all files in the docs folder
  • read_file: reads contents of any file in this repository
  • foo: prints bar

A README like this is often out of date, especially if the project contains many complicated operations. In this case, operation foo does not exist. Generally, there are 2 approaches to solve README inconsistency:

  1. Generating a README or docs in general
  2. Making a really short README and executable scripts with autocomplete and help

These options are not mutually exclusive.

This example implements executable operations with _autocomplete.sh.


Note: this example only works on zsh which is the bestest of shells. So if it doesn't work for you please install zsh and become awesome now.

Running operations

source _autocomplete.sh
operations  # Press tab for autofill (or enter for help)

autofill

operations list_docs

list_docs

Tips

  • Your operations should by default expect to be executed from the root of the repo
  • Your CI pipeline should also use the same operations. It ensures that you execute operations in the exactly same way in your CI that you do locally. In addition to that, it makes your CI jobs oneliners which is beautiful and works well also in yaml based pipeline definitions.

About

Demonstrate what to do instead of a long README file

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages