V2.05 Sketchbook path

Previously using V1.xx, my libraries were in the default Arduino/libraries location, but my project sketches were on another drive in a folder tree of my liking.

After upgrading to V2.0.5 it appears that the library and sketchbook can only be in the same path.

Is it possible to have the libraries in the default location and my ino sketches on another drive or another machine?

Please provide a detailed description of what gave you that impression.

Sure.

Arduino IDE does have some features that do only work for sketches stored in the sketchbook folder:

  • Sketches can be opened from the File > Sketchbook menu
  • Sketches can be opened from the "SKETCHBOOK" view in the side panel

However, these are only convenience features; not essential functionality. Even though the sketchbook folder is a convenient place to store sketches, you are welcome to store sketches in any location you like. You can then open the sketches via the Arduino IDE's File > Open menu, or by opening the sketch directly (file association).

In Arduino 2.0.5 File, Preferences I see "Sketchbook location:" but I don't see "Library directory location:".

If I change Sketchbook Location: to where my sketch directory is on d:\projects\here\there, and load a sketch from there, then compiles fail (includes) suggesting it can't find the libraries. If I copy the libraries directory tree to d:\projects\here\there (just for testing) then the compile works fine.

That's how I got the impression that the libraries path and sketchbook root path needed to be the same, or were the same.

The Sketchbook location (after install in my computer) is c:\Users\Tom\Documents\Arduino, and that's where the Libraries live. My sketchbook is empty.

From a new sketch (File, New Sketch), if I select File, Open it starts at c:\Users\Tom\Documents\Arduino. I can certainly point it to anywhere else and load a sketch.

If I load a sketch from d:\this\that\myfavorite.ino, and then select File, Save As it starts at c:\Users\Tom\Documents\Arduino. I can then point it to anywhere I want and save the sketch.

If I open a .ino file by association (double click on file in explorer) Arduino 2.0.5 opens the file, but when I File, Save as it starts at the c:\Users\Tom\Documents\Arduino path.

While being used to Arduino 1.x.x I expected 2.0.5 to perhaps defer to File, Save As back in the directory I loaded the sketch from. Many applications (like editors) change the source file working path to the path the file was loaded from, as Arduino 1.x.x does. Or they provide an option to change the working path to the file load path.

Arduino 2.0.5 seems to have an affinity to the sketchbook path for .ino file loads and saves. Is this just something I should to get used to, or am I missing something? I hope that's all not too much detail.

Thanks, Jim

It's a load of detail. As you have found out, the libraries need to be in the directory pointed to by the sketchbook location.
So path\to\there and path\to\there\libraries.

The affinity to save to the sketchbook location might be there; not behind a PC to check. But if it is, it's a minor issue for me. All my active projects are in subdirectories in the sketchbook location so it woukd be a matter of navigating one or two directories down. But that is the way I work.

Hi sterretje,

Thanks for your reply. Are you on the Arduino team?

My projects (sketches) need to be on a shared or network drive, as they are accessed from multiple machines.

I believe it is bad form in Windows to share root-ish paths in a machine's C drive, which is where the Documents folder is. In any case, it wouldn't be allowed here.

If it's a single user in a closed environment it less of an issue. The concept and structure of a Sketchbook is fine, although I would debate the trend of making computers look less like computers...

So, Arduino 2.0.5 having the habit of steering a file-save or file-save-as to the local sketchbook directory is less than desirable. The person saving the file can and should to remember to select the proper path to use to save the file. Depending on "should" is... risky.

If the sketchbook location could be specified in setup, separate from the Library location, that would be good. Or, if Arduino had the option to change the sketch working path to where the file was opened from, that would be good. I believe Arduino 1.x.x did that, or that's what it appeared to do. Or, I might not understand what I see.

By the way, Arduino 2.0.5 is Nice! A big change from 1.x.x in a good direction. Kudos to the team for what was clearly a lot of work.

Thanks, Jim

Also... In Arduino 2.0.5, Ctrl-F or Ctrl-E doesn't access the file or edit menus. I only have one installation and haven't tested in depth, but I rebooted.

But at least the File-Edit-Tools menu bar is still there! Please don't follow the trend to Mac-ize software so we are always guessing which icon does what. Hovering the mouse and waiting for an explanation to pop up is torture! Hey, we're writing code, we can operate a menu bar, even without the mouse.

I imagine there is a UN World Order Working Group to Standardize Clickable Icons (or UNWOWGSCI) that will eventually outlaw real menu bars and mandate globally accepted soft-cornered blue-blocked non-offensive clickable icons. Insert something about my cold, dead hands here... {End Rant}

Thanks, Jim

In my previous posts here I referred to Arduino 2.0.5, but I just noticed it is 2.0.4.

Also, is there a more appropriate place to report or inquire about operational issues?

Where would I find release notes for 2.x.x?

Thanks, Jim

Formal bug reports can be submitted according to the procedure documented here:

https://github.com/arduino/arduino-ide/blob/main/docs/contributor-guide/issues.md#issue-report-guide

But as for less formal reports, requests for assistance, or general discussion. The "Arduino IDE 2.0" category here on the forum is the best place.

The changelogs are here:

There is a more verbose user-targeted release announcement here:

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.