Skip to content

Commit 952ed82

Browse files
committed
Some package formatting (breaks the build script)
1 parent 33b5e6a commit 952ed82

2 files changed

Lines changed: 42 additions & 58 deletions

File tree

Tools/Modules/Lua/Shaderfuse/maintenance_functions.lua

Lines changed: 39 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -456,6 +456,11 @@ function create_package_fuses(repositorypath)
456456
local currentCategory=''
457457
local descriptionIndent=''
458458

459+
-- locla decribe = {}
460+
-- local deploy_all = {} -- on all platforms
461+
-- local deploy_mac = {} -- on macOS
462+
-- local deploy_win = {} -- on Windoes
463+
459464
for _, fuse in ipairs(fuses.list) do
460465

461466
util.clr_error()
@@ -486,13 +491,11 @@ function create_package_fuses(repositorypath)
486491
if fuse.Compatibility.macOS_Metal then
487492
OurPackageDescription=OurPackageDescription..descriptionIndent..' <li><strong style="color:#c0a050; ">'..fuse.Name..'</strong></li>\n'
488493
OurDeployments=OurDeployments
489-
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse",\n'
490-
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png",\n'
494+
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse", "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png",\n'
491495
else
492496
OurPackageDescription=OurPackageDescription..descriptionIndent..' <li><strong style="color:#c0a050; ">'..fuse.Name..'</strong> (Windows only)</li>\n'
493497
OurDeployments_windows=OurDeployments_windows
494-
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse",\n'
495-
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png",\n'
498+
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse", "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png",\n'
496499
patch_atom_for_platform=patch_atom_for_platform
497500
..'mv "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse" "Windows/Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse" \n'
498501
..'mv "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png" "Windows/Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png" \n'
@@ -501,8 +504,7 @@ function create_package_fuses(repositorypath)
501504
if fuse.Compatibility.macOS_Metal then
502505
OurPackageDescription=OurPackageDescription..descriptionIndent..' <li><strong style="color:#c0a050; ">'..fuse.Name..'</strong> (Mac only)</li>\n'
503506
OurDeployments_mac=OurDeployments_mac
504-
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse",\n'
505-
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png",\n'
507+
..' "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse", "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png",\n'
506508
patch_atom_for_platform=patch_atom_for_platform
507509
..'mv "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse" "Mac/Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.fuse" \n'
508510
..'mv "Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png" "Mac/Fuses/Shaderfuse_wsl/'..fuse.Shadertoy.ID..'.png" \n'
@@ -526,27 +528,25 @@ function create_package_fuses(repositorypath)
526528
return false
527529
end
528530

529-
handle:write([[
530-
Atom {
531+
handle:write([[Atom {
531532
Name = "]]..YourPackageName..[[",
532533
Category = "Shaders",
533534
Author = "]]..YourCompanyName..[[",
534535
Version = ]]..YourPackageVersion..[[,
535-
Date = ]]..YourPackageDate..[[,
536-
537-
Description = ]]
536+
Date = ]]..YourPackageDate..",\n\n"
538537
)
539538

540-
handle:write('[[\n<center>\n<br />')
539+
handle:write(' Description = [[<center><br />')
541540
handle:write(image.logo_html())
542541
handle:write('<br /><br />\n')
543542

544543
handle:write(
545-
[[The package <font color="white">]].. YourPackageName ..[[</font> adds some Fuses that utilize DCTL to implement various Shaders as found on <a href="https://www.shadertoy.com/">Shadertoy.com</a>.<br />
544+
[[At the moment <font color="#ff6060">THIS PACKAGE IS MAC AND WINDOWS ONLY</font>,<br />but if you have some dev skills you are very welcome to checkout the repo and test on Linux.<br />&nbsp;<br />
545+
The package <font color="white">]].. YourPackageName ..[[</font> adds some Fuses that utilize DCTL to implement various Shaders as found on <a href="https://www.shadertoy.com/">Shadertoy.com</a>.<br />
546546
See our repository on <a href="https://github.com/nmbr73/Shaderfuse">GitHub</a> for some insights and to maybe constribute to this project?!?<br />
547547
Find tons of example videos on what you can do with it on JiPi's <a href="https://www.youtube.com/c/JiPi_YT/videos">YouTube Channel</a>.<br />
548548
Please note that - unless stated otherwise - all these Fuses fall under Creative Commond 'CC BY-NC-SA 3.0 unported'.<br />
549-
For most shaders this regrettably means that in particular <font color="#ff6060">any commercial use is strictliy prohibited!</font>
549+
For most shaders this regrettably means that in particular <font color="#ff6060">ANY COMMERCIAL USE IS STRICTLIY PROHIBITED!</font>
550550
</center>]].."\n")
551551

552552
handle:write(OurPackageDescription)
@@ -568,35 +568,17 @@ See the following videos for some examples:
568568
Find these and even more videos on our <a href="https://www.youtube.com/playlist?list=PLqbIsaWc6bt1AuwEHF116QcFsNPKnLYHD">Shaderfuse</a> YouTube playlist.
569569
</p>]])
570570

571-
handle:write(']]')
571+
handle:write('\n]],\n\n') -- end endscription
572572

573-
if OurDeployments_windows ~= '' then
574-
if OurDeployments_mac == '' then
575-
OurDeployments_mac = ' "Fuses/Shaderfuse_wsl/README_MAC.md",\n'
576-
patch_atom_for_platform=patch_atom_for_platform
577-
..'echo "This is a dummy file to trick Reactor because there were some Windows only, but no Mac specific files." > "Mac/Fuses/Shaderfuse_wsl/README_MAC.md"\n'
578-
end
579-
else
580-
if OurDeployments_mac ~= '' then
581-
OurDeployments_windows = ' "Fuses/Shaderfuse_wsl/README_WINDOWS.md",\n'
582-
patch_atom_for_platform=patch_atom_for_platform
583-
..'echo "This is a dummy file to trick Reactor because there were some Mac only, but no Windows specific files." > "Windows/Fuses/Shaderfuse_wsl/README_WINDOWS.md"\n'
584-
end
585-
end
586573

587574

588-
local copy_browser_script = [[
589-
mkdir -p Scripts/Comp
590-
cp "../../Tools/Scripts/Comp/Shaderfuse/User Menu/Browser.lua" "Scripts/Comp/Shaderfuse Browser.lua"
591-
]]
592-
593575

594576
if patch_atom_for_platform ~= '' then
595577
patch_atom_for_platform =
596578
"mkdir -p Mac/Fuses/Shaderfuse_wsl/\n"
597579
.. "mkdir -p Windows/Fuses/Shaderfuse_wsl/\n"
580+
.. "mkdir -p Scripts/Comp\n"
598581
.. patch_atom_for_platform
599-
.. copy_browser_script
600582
..
601583
'zip -r "../'..PackageIdentifier..'.zip" Scripts Fuses Windows Mac "'..PackageIdentifier..'.atom"\n'
602584

@@ -610,32 +592,34 @@ cp "../../Tools/Scripts/Comp/Shaderfuse/User Menu/Browser.lua" "Scripts/Comp/Sha
610592
]]
611593
else
612594
patch_atom_for_platform =
613-
copy_browser_script ..
614595
'zip -r "../'..PackageIdentifier..'.zip" Scripts Fuses "'..PackageIdentifier..'.atom"\n'
615596
end
616597

617-
if OurDeployments_windows ~= '' then
618-
OurDeployments = OurDeployments
619-
.. "\n Windows = {\n"
620-
.. OurDeployments_windows
621-
.. " },\n"
622-
end
623-
624-
if OurDeployments_mac ~= '' then
625-
OurDeployments = OurDeployments
626-
.. "\n Mac = {\n"
627-
.. OurDeployments_mac
628-
.. " },\n"
629-
end
630598

631-
handle:write([[,
632-
633-
Deploy = {]]..'\n'..
634-
' "Scripts/Comp/Shaderfuse Browser.lua",\n'..
635-
OurDeployments ..[[
599+
handle:write([[
600+
Deploy = {
601+
]].. OurDeployments ..[[
602+
603+
Windows = {
604+
"Scripts/Comp/Shaderfuse Browser.lua",
605+
]] .. OurDeployments_windows .. [[
606+
},
607+
608+
Mac = {
609+
"Scripts/Comp/Shaderfuse Browser.lua",
610+
]] .. OurDeployments_mac .. [[
611+
},
612+
613+
-- Use the installers if you are brave enough to
614+
-- test the Fuses on Linux.
615+
-- Find a ZIP including all available installers on
616+
-- https://nmbr73.github.io/Shaderfuse/#installer
617+
--
618+
-- Linux = {
619+
-- "Scripts/Comp/Shaderfuse Browser.lua",
620+
-- },
636621
},
637-
638-
}]])
622+
}]])
639623

640624
handle:close()
641625

build.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,9 @@ function do_atom {
4747
cd ../..
4848

4949

50-
cd "atom/${ATOM_URI}"
51-
[ -f ../atomize.sh ] && sh ../atomize.sh
52-
cd ../..
50+
# cd "atom/${ATOM_URI}"
51+
# [ -f ../atomize.sh ] && sh ../atomize.sh
52+
# cd ../..
5353

5454
}
5555

0 commit comments

Comments
 (0)