Code Template

Hi there!

Since I have my special ways of writing code I made me a template. See attachment. I think everyone should be able to have his/her own code template (to be opened automatically when starting a new sketch).

What do you think?

Regards,

Gregor

template.txt (128 Bytes)

Does your special way always include misspellings and missing return types?

AWOL:
Does your special way always include misspellings and missing return types?

These are mistakes I never do :slight_smile:

Regards,

Gregor

Okay ... here you are ...

// Name des Sketches

//-------|---------|---------|---------|---------|---------|---------|---------|

void setup()
{
}

void loop()
{
}

gregorss:
I think everyone should be able to have his/her own code template (to be opened automatically when starting a new sketch).

The code that's added when you open a new sketch is from {Arduino IDE installation folder}/examples/01.Basics/BareMinimum. You can edit that file to whatever your preference is for new sketches. The Arduino IDE doesn't allow you to save example sketches so you'd need to do it using a regular text editor. The only problem is that, since the BareMinimum file is saved in the Arduino IDE installation folder, you need to redo this every time you update to a new version of the Arduino IDE. So you might want to save your template somewhere safe so it's quick and easy to copy it over to BareMinimum after updating the IDE.

you could create a library with examples only

pert:
The code that's added when you open a new sketch is from {Arduino IDE installation folder}/examples/01.Basics/BareMinimum. ...

Great! Thanks!

Gregor

You're welcome. I'm glad if I was able to be of assistance. Enjoy!
Per