diff --git a/.gitignore b/.gitignore index 1786a45..4ffaa66 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ node_modules/ npm-debug.log -.DS_Store \ No newline at end of file +.DS_Store +yarn.lock \ No newline at end of file diff --git a/README.md b/README.md index 84c9e40..e0226ce 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ This first version installs and configures the tool chain and helps you to kicks - Vice - Crunchers - and more - - Automatic Sublime Installation and Configuration + - Automatic Sublime 2 or 3 Installation and Configuration - 6502 and BASIC syntax highlighting - Instangt Build & Run Options for ASM and BASIC projects - Auto-Start in Vice via BASIC loader diff --git a/lib/dust_text b/lib/dust_text index 11fa816..57a0dda 100644 --- a/lib/dust_text +++ b/lib/dust_text @@ -4,13 +4,20 @@ var dust = require('../bin/dust'); exports.dustLogo = function dustLogo(){ dust.color.bold(); + dust.color.red() console.log(""); console.log("________ __ __ "); + dust.color.red() console.log("\\______ \\ __ __ _______/ |_| | _____ ___.__. ___________ "); + dust.color.hex('#ff9900') console.log(" | | \\| | \\/ ___/\\ __\\ | \\__ \\< | |/ __ \\_ __ \\"); + dust.color.yellow() console.log(" | ` \\ | /\\___ \\ | | | |__/ __ \\\\___ \\ ___/| | \\/"); + dust.color.green() console.log("/_______ /____//____ > |__| |____(____ / ____|\\___ >__| "); + dust.color.blue() console.log(" \\/ \\/ \\/\\/ \\/ "); + console.log(""); dust.color.reset(); } diff --git a/mods/c64/config/mod.json b/mods/c64/config/mod.json index 0bd4b0c..c91e787 100644 --- a/mods/c64/config/mod.json +++ b/mods/c64/config/mod.json @@ -46,6 +46,15 @@ "postinstaller": "postInstallSublimeText", "directory": "configurationSublime" }, + "sublime3": { + "name": "Sublime Text 3 v3.2.1 ( > macOS 10.7)", + "downloads": ["https://download.sublimetext.com/Sublime%20Text%20Build%203207.dmg", + "https://download.sublimetext.com/Sublime%20Text%20Build%203207.dmg"], + "filename": "Sublime Text 3207.dmg", + "installer": "installSublimeText3", + "postinstaller": "postInstallSublimeText3", + "directory": "configurationSublime" + }, "vice": { "name": "Vice v2.4 (C64 Emulator)", "downloads": ["http://sourceforge.net/projects/vice-emu/files/releases/binaries/macosx/vice-macosx-cocoa-i386+x86_64-10.6-gcc42-2.4.dmg/download", @@ -57,7 +66,20 @@ }, "installOptions": { "all": { - "description" : "Install everything", + "description" : "Install everything with Sublime Text 3", + "list": { + "acme": true, + "buildscripts": true, + "exomizer": true, + "pucrunch": true, + "sidreloc": true, + "sublime": false, + "sublime3": true, + "vice": true + } + }, + "legacy": { + "description" : "Install everything with Sublime Text 2", "list": { "acme": true, "buildscripts": true, @@ -65,11 +87,12 @@ "pucrunch": true, "sidreloc": true, "sublime": true, + "sublime3": false, "vice": true } }, "skip_sublime": { - "description" : "Install everything but Sublime Text 2", + "description" : "Install everything but Sublime Text", "list": { "acme": true, "buildscripts": true, @@ -77,6 +100,7 @@ "pucrunch": true, "sidreloc": true, "sublime": false, + "sublime3": false, "vice": true } } diff --git a/mods/c64/lib/dust_setup b/mods/c64/lib/dust_setup index 60b290f..49b4678 100644 --- a/mods/c64/lib/dust_setup +++ b/mods/c64/lib/dust_setup @@ -205,6 +205,35 @@ function postInstallSublimeText(workdir,bundledir){ } } +function installSublimeText3(filename){ + process.stdout.write('installing Sublime Text 3 '); + dust.shell.cd(dust.shell.env['HOME'] + "/temp_dust_compile/", {silent:dust.silent}); + dust.externals.download('mac', dust.config.mod.setup.mac.externals.sublime.downloads[0], filename,true); + process.stdout.write('installing '); + + dust.shell.exec('hdiutil attach "$HOME/temp_dust_compile/' + filename +'"', {silent:dust.silent}); + dust.shell.exec('cp -R -v "/Volumes/Sublime Text/Sublime Text.app" "/Volumes/Sublime Text/Applications"', {silent:dust.silent}); + dust.shell.exec('hdiutil detach "/Volumes/Sublime Text"', {silent:dust.silent}); + dust.setup.installStatus(true); +} + +function postInstallSublimeText3(workdir,bundledir){ + process.stdout.write("Copying Sublime Text 3 Configuration "); + if (dust.shell.test("-d", "/Applications/Sublime Text.app")){ + dust.shell.cd(dust.shell.env['HOME'] + "/temp_dust_compile/" + bundledir, {silent:dust.silent}); + dust.shell.cd(workdir); + dust.shell.exec('sudo mv -v "Sublime Text/sublime" "/usr/local/bin"', {silent:dust.silent}); + dust.shell.exec('mkdir -p "$HOME/Library/Application Support/Sublime Text/Packages"', {silent:dust.silent}); + dust.shell.exec('cp -R -v "Sublime Text/" "$HOME/Library/Application Support/Sublime Text/Packages"', {silent:dust.silent}); + dust.setup.installStatus(true); + } + else { + dust.color.yellow(); + console.log("sublime not available - no build systems were configured"); + dust.color.reset(); + } +} + function installVice(filename){ process.stdout.write('installing Vice '); dust.shell.cd(dust.shell.env['HOME'] + "/temp_dust_compile/", {silent:dust.silent}); @@ -221,7 +250,6 @@ function installVice(filename){ dust.setup.installStatus(true); } - function cloneMac(){ console.log (""); console.log("Cloning Repository - this may take a while.");