save scripts with new name and keep the old

Moderator: leecollings

Post Reply
terjekr
Posts: 1
Joined: Thursday 04 April 2019 12:07
Target OS: Windows
Domoticz version: 4.11597
Location: Oslo
Contact:

save scripts with new name and keep the old

Post by terjekr »

After updating to version: 4.10548 it is not possible to save a blockly script in different versions with different names. When I give a script a new name, the old name is just overwritten. How do I keep different versions of a script for testing?
SweetPants

Re: save scripts with new name and keep the old

Post by SweetPants »

Use import/export
uschuga
Posts: 19
Joined: Friday 26 October 2018 17:04
Target OS: Raspberry Pi / ODroid
Domoticz version: 2023.2
Location: Germany
Contact:

Re: save scripts with new name and keep the old

Post by uschuga »

How to import & export? Via clipboard? It does not work as the clipboard remains empty and a "blocking" sign pops up.
Used Z-Wave devices: EUR_SPIRITZ, FGBS001, FGR223, FGS223, FGBS222, ZMNHYD1 Smart Plug 16A, ZWA009 AërQ Sensor, NAS-WR01Z Power plug 12A, ZME_WALLC-S, FGD212, ST812 Flood Detector, PAN04-1 Double Relay Switch, ZMNHND1 Flush 1D relay, ZME_UZB1 USB Stick
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: save scripts with new name and keep the old

Post by waaren »

uschuga wrote: Saturday 20 July 2019 9:31 How to import & export? Via clipboard? It does not work as the clipboard remains empty and a "blocking" sign pops up.
on event editor screen
----------------------------
choose old script
press export
Click outside the block
[ctrl] a
[ctrl] c


notepad or other editor of your choice
-----------------------------------------------
[ctrl] v
select all text between xml tags (beginning with <xml and ending with </xml>)
[ctrl] c


on event editor screen
----------------------------
press +
press Blockly and type new name into the name field
press import and paste clipboard into popup
press save
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
uschuga
Posts: 19
Joined: Friday 26 October 2018 17:04
Target OS: Raspberry Pi / ODroid
Domoticz version: 2023.2
Location: Germany
Contact:

Re: save scripts with new name and keep the old

Post by uschuga »

Perfect, thank you! I knew I was only a click away...
Used Z-Wave devices: EUR_SPIRITZ, FGBS001, FGR223, FGS223, FGBS222, ZMNHYD1 Smart Plug 16A, ZWA009 AërQ Sensor, NAS-WR01Z Power plug 12A, ZME_WALLC-S, FGD212, ST812 Flood Detector, PAN04-1 Double Relay Switch, ZMNHND1 Flush 1D relay, ZME_UZB1 USB Stick
Stonez
Posts: 1
Joined: Wednesday 16 October 2019 9:41
Target OS: Windows
Domoticz version:
Contact:

Re: save scripts with new name and keep the old

Post by Stonez »

May I take the liberty to suggest a faster (lazier) way?

on event editor screen
----------------------------
choose old script
Just press export and DON'T Click anywhere else!
[ctrl] a
[ctrl] c
esc

on event editor screen
----------------------------
press +
press Blockly and type new name into the name field
press import
[ctrl] v
press save
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: save scripts with new name and keep the old

Post by waaren »

Stonez wrote: Wednesday 16 October 2019 9:51 May I take the liberty to suggest a faster (lazier) way?
👍 Thanks !
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest