Recommended Elive Programming Practices

Official (created by Thanatermesis)

  • See this website: HowtoGoodProgrammingTechniques – Elive Development
  • Practices in this post:
    • functions should be called with arguments, so variables must be passed in that way instead of using global variables, unless a global variable has its own purpose
    • variables must be set as local (as much as possible) in order to make the code more reliable
    • an important thing is to make the code more readable, this means using better naming convention, in short, an english sentence sorted in the inverse way just like an object parent to the object children, for example using something like "eltrans_translation_file_get" instead of "get_file_translation_eltrans" (just what wordpress and many things do in an horrible way)
    • using elive-tools functions instead of own functions made (if they are available), you can see them by typing el_<TAB> in the terminal (they are bash commands, so you'll need to run them as a shell command)

Unofficial

  • Try to write programs in Bash/Zsh using zenity or yad (best) or C with EFLs if you need something more powerful. Use Python, Perl, or Ruby if you need to. Thanatermesis doesn't know other languages very well, so only use them if you must.

If you have better Programming Practices to use, add them here! :1up:

Pinned due to this being important to read.