Schematic Tools Module

Post any examples or modules that you want to share here
Post Reply
User avatar
trogluddite
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Schematic Tools Module

Post by trogluddite »

I've long wished that FlowStone had a "Save as a Copy..." menu item, so that I could save a quick backup but carry on using the current file as my main working version. Being able to avoid all the WIndows file dialogues would be even better! And how about all those project sub-folders of presets that I made and snippets of Ruby code?!

A full on source-code manager like Git seems like overkill - but FlowStone and Ruby have (nearly) all the tools to do exactly what I need. So I made a little module that can sit at the top of my schematics to take the donkey work out of managing backups. The module can...

- Back up the current schematic plus any resource files that belong to the project to a unique sub-folder within a nominated backups folder. If the schematic folder itself is nested within parent project folders, no problem - the source folder can also be nominated so that the whole lot is backed up.

- Folder paths can be absolute or relative to the schematic's folder, and may include automatic substitutions for the schematic name, date and/or time. Date and time stamps are formatted so that they sort into time order. If that still doesn't make each backup's folder name unique, an auto-incrementing index is automatically added.

- Any files and/or folders may be excluded from backing up by giving a list of filters, which may use the usual Windows file path wild-cards for matching. For example *.txt would prevent text files from being backed up.

- The option to pop-up a confirmation dialogue before saving anything. A list of the files which would be saved are available at a module output so that you can check that everything's set up OK before committing.

- An area to scribble notes which will be included as a text file within the backup folder.

- Buttons to open the schematic folder or the backups folder in Windows explorer.

- Buttons to copy the schematic's full path, the schematic's folder path, or the backups folder path to the Windows clipboard.

The only thing I haven't worked out yet is how to make it press CTRL-S first so that I definitely get the current edits into the backup - so I can't completely exclude my ailing memory from mucking things up just yet!! :lol:

schematic_tools.fsm
(7.11 KiB) Downloaded 1185 times
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
adamszabo
Posts: 667
Joined: Sun Jul 11, 2010 7:21 am

Re: Schematic Tools Module

Post by adamszabo »

Very cool indeed!
tulamide
Posts: 2714
Joined: Sat Jun 21, 2014 2:48 pm
Location: Germany

Re: Schematic Tools Module

Post by tulamide »

trogluddite wrote:- Back up the current schematic plus any resource files that belong to the project to a unique sub-folder within a nominated backups folder.

I guess you're talking about the last saved version of the schematic, not the current schematic, right?
"There lies the dog buried" (German saying translated literally)
User avatar
trogluddite
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Re: Schematic Tools Module

Post by trogluddite »

tulamide wrote:I guess you're talking about the last saved version of the schematic, not the current schematic, right?

Exactly. That's the limitation I was on about at the end of the first post - if you haven't pressed CTRL-S first, you might be missing some recent edits. It's a nice little labour saver; but without direct access to FlowStone's file menu, I can't automate it any further.

It should be possible via Win32API to read the unsaved-file marker in the FlowStone window's title bar and then send it simulated shortcut keys - the module already accesses the Windows clipboard that way, and I've done very similar things using AutoHotkey in the past. However, I need a break from the Windows API docs for a bit before I do any more! :lol:
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
Spogg
Posts: 3368
Joined: Thu Nov 20, 2014 4:24 pm
Location: Birmingham, England
Contact:

Re: Schematic Tools Module

Post by Spogg »

This is a very impressive demonstration of file management using Ruby, trog. Amazing! :ugeek:

Cheers

Spogg
tulamide
Posts: 2714
Joined: Sat Jun 21, 2014 2:48 pm
Location: Germany

Re: Schematic Tools Module

Post by tulamide »

Spogg wrote:This is a very impressive demonstration of file management using Ruby, trog. Amazing! :ugeek:

Cheers

Spogg

Now here comes a very selfish reply of being upset: You say that as if nobody before had shared file management. Like nobody before had created an automatic file loader with selectable extension and setting the root folder + plus reading from all subfolders, that you use in pretty much every sample based synth you offer.
"There lies the dog buried" (German saying translated literally)
User avatar
Spogg
Posts: 3368
Joined: Thu Nov 20, 2014 4:24 pm
Location: Birmingham, England
Contact:

Re: Schematic Tools Module

Post by Spogg »

Ahh but I didn’t say it was the only file management system I’d ever seen! :lol:

Cheers

Spogg
jesterstudios
Posts: 7
Joined: Thu Sep 05, 2019 12:00 pm
Contact:

Re: Schematic Tools Module

Post by jesterstudios »

adamszabo wrote:Very cool indeed!

Sure is cool. I catch myself sitting and staring at the program not knowing what to do sometimes.
Industrial music isn't dead.
Post Reply