Skip to content

Styleguide

DC* edited this page Dec 29, 2016 · 1 revision

General style guide

  • Always use spaces
  • 2 spaces for indentation
  • Keep line length below 80 characters

Conventions

  • Underscore for variable names ($this_is_a_variable)
  • Dash for function names (this-is-a-function)
  • Prefix '-' for "private" functions
  • Always use if / then / else for conditionals

Running shellcheck

Shellcheck is run on TravisCI, but you can run it manually this way:

shellcheck bin/antigen.zsh --shell=ksh