Newcomers, change the IDE default BareMinimum.ino file.

To newcomers.

Save programming time when you start new Arduino projects.
Modify your BareMinimum.ino file which is a template for new programs.
When you use File/New in your IDE, this is the template that is presented.

Attached below is the template I use. BareMinimum.ino
(EDIT: I have included SwitchManagerWithFilter.h too, see below.)

When you have decided on a style you like, save it to the directory as see above.

BareMinimum.ino (10.5 KB)

SwitchManagerWithFilter.h (4.18 KB)

You are full of amazing tips and tricks :)

My wife sometimes says I am full of . . .

Here's mine:

//ref
//date

void setup() 
{
  Serial.begin(9600);
  Serial.println(".... description ....");
  Serial.print("Created: ");
  Serial.print(__TIME__);
  Serial.print(", ");
  Serial.println(__DATE__);
  
  //turn off L13
  pinMode(LED_BUILTIN, OUTPUT);
  digitalWrite(LED_BUILTIN, LOW);

} //setup

void loop() 
{
  
} //loop

There is one problem: Windows won’t let you edit any file in that folder (or any other folder in C:\Program Files (x86)). You have to move the file to - for example - C:\Temp, edit it and then move it back! And don’t try to start the IDE or create a new project in the mean time, the IDE will crash.

You can edit the file if you run under administrator privileges.

Nope. I could not save it, in spite of being logged in as administrator. (Windows 7/64)

Windows 10/64 here, works as mentioned.

Erik_Baas:
Nope. I could not save it, in spite of being logged in as administrator. (Windows 7/64)

I just got it done like this:

Windows assumed

Create new file. It’ll be named sketch
Modify as desired and save it in the user folder and close
Navigate to the user folder and to the folder containing the newly created .ino file
Copy the .ino file.
Navigate to the bare minimum folder as illustrated above
Paste your new custom file to the folder
Rename the existing bareMinimum, I used ‘BareMinimum orig’
Rename the new file to BareMinimum
Done

Thanks, larryd!

On the Mac / Java / examples / 01.Basics / BareMinimum See post #6 and 8

https://forum.arduino.cc/index.php?topic=611876.msg4148957#msg4148957

larryd: On the Mac / Java / examples / 01.Basics / BareMinimum See post #6 and 8

https://forum.arduino.cc/index.php?topic=611876.msg4148957#msg4148957

It's probably worth adding that on Mac the file is replaced every time you upgrade the IDE so if the changes are non-trivial it might be worth keeping a backup copy somewhere outside the Arduino.app package.