Giter VIP home page Giter VIP logo

build-tools's Introduction

Gitter Build Status

SproutCore 2: For Native-Caliber Web Apps

Sproutcore 2 no longer support the Abbot Buildtools which has been replaced by the new Node.js Build Tools.

SproutCore is a JS-MVC framework for building blazing-fast, native-caliber web applications. SproutCore's full-stack approach to single-page application development gives you the tools you need to build rich, powerful applications... which happen to run in the browser.

Getting Started

The easiest way to get started with SproutCore is to install the Ruby gem. You can find instructions here. Once you've got SproutCore installed, checkout the Getting Started tutorial.

Next Steps

Once you're through the Getting Started tutorial:

Support

Resources for SproutCore developers include the docs for API documentation, and the Guides for a series of topical walk-throughs.

For additional SproutCore user support, join the mailing list, or stop by the #sproutcore IRC channel. For those interested in contributing to the framework itself, please join [email protected].

Acknowledgements

SproutCore includes code from a number of different open source projects including:

build-tools's People

Contributors

cclauss avatar dependabot[bot] avatar mauritslamers avatar nicolasbadia avatar topherfangio avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

build-tools's Issues

Errors when running BT after nodejs update

When running the BT after a major NodeJS update, dependencies which contain binary libraries (node-sass, node-canvas) will cause the BT to crash.
The workaround is to run npm update [package-name] in the BT root, but this could be automated.

BT do not work under Linux...

because of the lack of an included compiled canvas module.

TODO: either add a precompiled library, or make the sproutcore installation under linux run the compilation of node-canvas.

Directory rename doesn't lead to adjusting path of files within

When a directory inside the project changes names, the BT currently does not check for any files which where in the original folder.
As the BT detects the name change as a file name change, it should detect whether the changed file is a directory, and either remove the files and reload in the new location, or adjust the paths of the files affected.

Showcase not working

I have the test project ( git://github.com/mauritslamers/garcon-testproject ) setup and running. Only one piece of the showcase app appears to be working for me. I can click on Using SC.Color and manipulate the controls. However, when I click on SC.ButtonView, etc. nothing appears.

Design error: handling of sc_static and static_url is done too early

I reached this conclusion after finding out that in a relative build the urls for the legacy theme were wrong.

The problem essentially is that the url generated for sc_static and static_url are now generated in the very beginning of the build process, and the generated url is based on the relative path between the file containing the sc_static or static_url "call" and the referred file.

However, in the process of combining files the generated url should be reconsidered as the combined file is different from the original file. In order to get a correctly generated url, the sc_static or static_url parsing should be performed by the "final" file, being a file about to be saved or served, or perhaps even by a process outside the file itself.
Thoughts?

command line version bump

When running the build from external tools would be handy to have a version number bump that would allow us to verify that our client were on the current live version.

Ideally would bump the minor version number 1.2.x

What to insert exactly when sc_static refers to an unknown file?

When performing sc_static replacement of the tests application, it turns out it is referring to a picture which doesn't exist in the app.

For now, the BT will display a message to stdout (terminal), and replace sc_static with an empty string, but should perhaps also a developer warning be inserted as well?

Attempting to install a framework (via git) without a frameworks directory fails.

Received the following error when attempting to install a framework via git. It was fixed by simply creating a frameworks directory.

8 May 14:23:22 - about to run code: SC.run(function () { BT.startInstall('git://github.com/profoundry-us/FireCore.git', { }); });
Checking out git://github.com/profoundry-us/FireCore.git into $TMPDIR/sproutcoreBT_1399577002158/FireCore
Checkout complete...
Copying into /Users/topher/Documents/Development/profoundry/collaborate/frameworks/FireCore

/Users/topher/Documents/Development/profoundry/build-tools/lib/installer.js:199
      if (er.code !== "EEXIST") throw er; // only throw if other error than th
                                      ^
Error: ENOENT, no such file or directory '/Users/topher/Documents/Development/profoundry/collaborate/frameworks/FireCore'
    at Object.fs.mkdirSync (fs.js:642:18)
    at BT.Installer.SC.Object.extend.installFramework (/Users/topher/Documents/Development/profoundry/build-tools/lib/installer.js:196:13)
    at BT.Installer.SC.Object.extend.gitCheckOutDidFinish (/Users/topher/Documents/Development/profoundry/build-tools/lib/installer.js:152:12)
    at /Users/topher/Documents/Development/profoundry/build-tools/lib/installer.js:128:33
    at ChildProcess.exithandler (child_process.js:635:7)
    at ChildProcess.EventEmitter.emit (events.js:98:17)
    at maybeClose (child_process.js:743:16)
    at Socket.<anonymous> (child_process.js:956:11)
    at Socket.EventEmitter.emit (events.js:95:17)
    at Pipe.close (net.js:465:12)

BT crashes with big combined css files with out-of-memory error

Because of the amount of memory the cssmin package takes when minifying a css file, it can happen that the BT crashes with an out of memory error during a build.

This problem came to light when bringing in code which automatically includes sass partials (css files beginning with an underscore, such as _theme.css). In the current setup, the BT will always parse every css file in a standalone way, which makes it necessary to include all partials in the single css file.
When combining multiple css files, this leads to duplication of all the partials. The more files there are to combine, the more duplicates of the partials there will be.

The current solution is to mark these partials with comments and filtering the combined file to only include every partial once. While this solves the problems for the moment, it is important to mark this as a potential weakness, and as a reminder that when large apps are processed with much css, it can happen that the minification by cssmin will break a build.

This issue is created for documentation purposes and will be closed for now, as there is a fix in place. If anyone runs into this problem again, please reopen!

config file syntax proposal

Currently, there are two separate syntax models used in the config files:

BT.addFramework(BT.Framework.extend({
  path: "path/to/framework"
})

and

var myApp = BT.AppBuilder.create({
  name: "myApp",
  frameworks: ['myAppFw']
});

I think it would be nice to have a single syntax model, which would not exclude the options mentioned above but add to them:

BT.addFramework({
  ref: 'myframework'
  path: 'frameworks/myframework'
});
BT.addTheme({
  ref: 'mytheme',
  path: 'themes/mytheme'
});
BT.addApp({
  name: 'myApp',
  path: 'apps/my_app',
  theme: 'mytheme'
});

Thoughts?

New BT having strange error (endless loop)?

The BT slowly get in a state that it is actually possible to run apps in the dev environment. (Installation instructions can be found at https://gist.github.com/mauritslamers/9998580)

I get a pretty weird error, which seems to be an endless loop, and I am not sure what to make from it...

SC.Set.SC.mixin.add combined.js:8221
SC.Observable._notifyPropertyObservers combined.js:2683
SC.Observable.propertyDidChange combined.js:2041
invoke_superclass_method combined.js:8722
SC.View.reopen.propertyDidChange combined.js:11153
SC.Observable.set combined.js:1876
(anonymous function) combined.js:15069
(anonymous function) combined.js:8902
SC.Pane.reopen._notifyDidAttach combined.js:15238
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722
SC.Pane.reopen._notifyDidAttach combined.js:15254
invoke_superclass_method combined.js:8722

Anonymous function calls are :

(combined.js line 15069 is this.set line)

 recomputeDependentProperties: function (original) {
    this.set('currentWindowSize', this.rootResponder.computeWindowSize());
    original();
  }.enhance()

(combined.js line 8902 is return enhancement)

SC._enhance = function (originalFunction, enhancement) {
  return function () {
    var args = Array.prototype.slice.call(arguments, 0),
        self = this;

    args.unshift(function () { return originalFunction.apply(self, arguments); });
    return enhancement.apply(this, args);
  };
};

Files don't always update correctly: files can exist twice in a single framework

Using the BT I ran into an issue already reported earlier by Topher Fangio, which is that sometimes certain files don't seem to get updated when a file on disk changes.
Investigating this problem, I found out that it is possible somehow that a file gets created twice in the same framework.
The fsevents process (on Mac) will update a different file object than the server will return, resulting in the impression that a file doesn't get updated, where it effectively does, but the wrong file object is returned by the server. It is possible that this is triggered in a delete / create (rename) process where a new file is added to the system where an existing file already has that path, or the original file didn't get destroyed.

Framework hash in the URL to enable aggressive caching

Abbot currently includes an MD5 (I assume) hash of a frameworks' contents in the framework's directory structure, in order to support aggressive caching.

If a built file changes, then its hash will change, meaning that its URI will change, causing previously-cached versions to be dropped from use automatically. Since we're confident that new versions are at new URIs, we can reliably cache files "forever", improving application load performance substantially.

It's very slick, and losing this feature would be a major regression for production performance, and probably open up a ton of caching headaches that we just don't have to worry about in abbot. This is a must-have feature.

I would think that all text files in the built folder would be hashed, so that the hash would change if any JS or CSS changed. I'm less worried about images, though that may be naive.

Idea for a speed improvement in css file handling

After implementing the file manager, I was partly surprised that the speed improvement was rather limited. After doing some profiling, it seems that part of the issue that in my project the BT takes 33 seconds to start is because it takes around 26 seconds to do the css file parsing.
The profiling data shows that the parseContent function is executed twice, the one without the x2 option takes 12 seconds, the one with 14.
My impression is that it should be possible to cache a few things which are not influenced by the x2 option.The current implementation does the entire transform from raw content till product twice, but is this actually really necessary?

Build tools need to handle build modes

In abbot, if you wrap code in:

//@if(debug)
...
//@endif

then it will be removed if not in debug mode.

It would be nice to build this as part of a more comprehensive build mode system, with possible developer access. Having a "qa" build mode would be nice, and not having to hard-code all the build modes would also be nice. =)

Support for coverage check of localization strings

It would be a very useful feature if the buildtools would be able to check for the coverage of the localization strings used in an application. It should be able to indicate used strings that do not exist in the selected language, as well as finding strings that are present in the selected language, but which are not used in the app.

Differences in sorting with Abbot

In the pursuit of a possible cause for issue #7, I noticed that the sorting technique in the new BT has a few differences with the sorting as done by Abbot.
In https://gist.github.com/mauritslamers/11040893 there are two index.html files, one generated by the new BT, the other by abbot, where in both the combining has been turned off to see the load order.

Few things to notice in the comparison:

  • Why are the debug and testing frameworks included in a normal app?
  • Why is the debug part of the runtime framework before everything else, and as a side question: why is it included at all in a normal app?
  • CoreFoundation:
    • system/browser.js comes fourth in BT, but second in Abbot
    • why are the files in child_view_layouts included in sequence in Abbot? In BT vertical comes much later than horizontal
    • panes/main.js comes much earlier in BT and last in Abbot: is this a side effect from main.js always being last for apps?
    • utils/rect.js is before utils.js in BT and the other way around in Abbot
  • Foundation
    • In BT tasks/task.js and system/module.js are second and third, and in Abbot much later, task.js just before system/app_cache.js and module.js just before system/task_queue.js
  • Desktop
    • render_delegates/toolbar.js is second in BT, much later in Abbot (just before render_delegates/well.js)
    • system/drag.js and debug/drag.js are second and third in Abbot, much later in BT. system/drag.js in BT just before protocols/drag_data_source.js, debug/drag.js in BT just before render_delegates/well.js

In DataStore the order is almost entirely different, a few small changes in statechart. The order inside an application is also different. Are there additional rules not observed yet?

Installation relies on $TMP environment variable on Ubuntu

The $TMP environment variable is not available by default in Ubuntu and as such the installation fails with the following error message:

Installing sproutcore as global dependency, this can take a while...
error when checking out: { [Error: Command failed: fatal: could not create leading directories of '/sproutcoreBT_1400760994332/sproutcore': Permission denied
] killed: false, code: 128, signal: null }
[email protected] node_modules/sproutcore
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected] ([email protected], [email protected], [email protected], [email protected])
├── [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
├── [email protected]
└── [email protected]

<app>.save() is broken

While this successfully generate the proper HTML with links to the css and js the latter files are not built and saved to disk.

npm install fails on Windows 7

Install in on windows 7 x64 with npm 3.10.10 and node 6.9.4. In my environment I have to run npm with strict-ssl=false.

Exception is thrown in pre_install.js
Here is the log output.

verbose stack Error: [email protected] preinstall: `node pre_install.js`
verbose stack Exit status 1
verbose stack     at EventEmitter.<anonymous> (C:\Development\nodejs\node_modules\npm\lib\utils\lifecycle.js:255:16)
verbose stack     at emitTwo (events.js:106:13)
verbose stack     at EventEmitter.emit (events.js:191:7)
verbose stack     at ChildProcess.<anonymous> (C:\Development\nodejs\node_modules\npm\lib\utils\spawn.js:40:14)
verbose stack     at emitTwo (events.js:106:13)
verbose stack     at ChildProcess.emit (events.js:191:7)
verbose stack     at maybeClose (internal/child_process.js:877:16)
verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
verbose pkgid [email protected]
verbose cwd C:\Users\<user folder>
error Windows_NT 6.1.7601
error argv "C:\\Development\\nodejs\\node.exe" "C:\\Development\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "sproutcore" "--verbose"
error node v6.9.4
error npm  v3.10.10
error code ELIFECYCLE
error [email protected] preinstall: `node pre_install.js`
error Exit status 1
error Failed at the [email protected] preinstall script 'node pre_install.js'.
error Make sure you have the latest version of node.js and npm installed.
error If you do, this is most likely a problem with the sproutcore package,
error not with npm itself.
error Tell the author that this fails on your system:
error     node pre_install.js
error You can get information on how to open an issue for this project with:
error     npm bugs sproutcore
error Or if that isn't available, you can get their info via:
error     npm owner ls sproutcore
error There is likely additional logging output above.
verbose exit [ 1, true ]

Build Tool not working with SC.TemplateView

https://github.com/ericgorr/myproject.git

Here is the output from the JS Console:

Resource interpreted as Script but transferred with MIME type text/html: "http://localhost:8000/printing_template/printing_template/templates/print_template.handlebars". printing_template:32

Uncaught SyntaxError: Unexpected token < print_template.handlebars:1

print action ready_state.js:12

Uncaught TypeError: undefined is not a function printController.js:22
    PrintingTemplate.printController.SC.Object.create.renderTemplate printController.js:22
    (anonymous function) printController.js:49
    PrintingTemplate.printController.SC.Object.create.print printController.js:48
    PrintingTemplate.printController.SC.Object.create.printContent printController.js:69
    PrintingTemplate.ReadyState.SC.State.extend.actionPrint ready_state.js:14
    SC.State.SC.Object.extend.tryToHandleEvent statechart.js:1740
    SC.StatechartManager.sendEvent statechart.js:3333
    SC.RootResponder.SC.Object.extend.sendAction core_foundation.js:13501
    SC.ButtonView.SC.View.extend._runAction desktop.js:2935
    SC.ButtonView.SC.View.extend._action desktop.js:2917
    SC.ButtonView.SC.View.extend.mouseUp desktop.js:2803
    SC.Object.tryToPerform runtime.js:7719
    SC.Pane.SC.View.extend.sendEvent core_foundation.js:10635
    (anonymous function) core_foundation.js:13644
    SC.run runtime.js:13318
    SC.RootResponder.SC.Object.extend.sendEvent core_foundation.js:13638
    SC.RootResponder.SC.Object.extend.mouseup core_foundation.js:14875
    SC.mixin.handle core_foundation.js:4288
    listener core_foundation.js:4445

GET http://localhost:8000/printing_template/printing_template/print_css 404 (Not Found) printController.js:46
    PrintingTemplate.printController.SC.Object.create.print printController.js:46
    PrintingTemplate.printController.SC.Object.create.printContent printController.js:69
    PrintingTemplate.ReadyState.SC.State.extend.actionPrint ready_state.js:14
    SC.State.SC.Object.extend.tryToHandleEvent statechart.js:1740
    SC.StatechartManager.sendEvent statechart.js:3333
    SC.RootResponder.SC.Object.extend.sendAction core_foundation.js:13501
    SC.ButtonView.SC.View.extend._runAction desktop.js:2935
    SC.ButtonView.SC.View.extend._action desktop.js:2917
    SC.ButtonView.SC.View.extend.mouseUp desktop.js:2803
    SC.Object.tryToPerform runtime.js:7719
    SC.Pane.SC.View.extend.sendEvent core_foundation.js:10635
    (anonymous function) core_foundation.js:13644
    SC.run runtime.js:13318
    SC.RootResponder.SC.Object.extend.sendEvent core_foundation.js:13638
    SC.RootResponder.SC.Object.extend.mouseup core_foundation.js:14875
    SC.mixin.handle core_foundation.js:4288
    listener core_foundation.js:4445

Here is the output from the terminal:

ericgorr@Glamdring ~/d/s/myproject> node myproject_node.js
3 Jun 18:54:24 - Building app: printing_template
Server started on http://localhost:8000
3 Jun 18:54:26 - dirname for file frameworks/sproutcore/frameworks/desktop/resources/menu_item_view.css: printing_template/sproutcore/desktop
3 Jun 18:54:26 - isSaving? undefined
WARNING: printing_template/sproutcore/desktop/foundation:blank.gif referenced in frameworks/sproutcore/frameworks/desktop/resources/menu_item_view.css but was not found.
3 Jun 18:54:26 - returning rewritten staticurl: url('printing_template/sproutcore/desktop/foundation:blank.gif')
3 Jun 18:54:26 - dirname for file frameworks/sproutcore/frameworks/desktop/resources/menu_item_view.css: printing_template/sproutcore/desktop
3 Jun 18:54:26 - isSaving? undefined
WARNING: printing_template/sproutcore/desktop/foundation:blank.gif referenced in frameworks/sproutcore/frameworks/desktop/resources/menu_item_view.css but was not found.
3 Jun 18:54:26 - returning rewritten staticurl: url('printing_template/sproutcore/desktop/foundation:blank.gif')
3 Jun 18:54:27 - dirname for file frameworks/sproutcore/themes/ace/resources/progress/ace/progress.css: printing_template/sproutcore/themes/ace
3 Jun 18:54:27 - isSaving? undefined
WARNING: printing_template/sproutcore/themes/ace/progress_view_indeterminate_content.png referenced in frameworks/sproutcore/themes/ace/resources/progress/ace/progress.css but was not found.
3 Jun 18:54:27 - returning rewritten staticurl: url('printing_template/sproutcore/themes/ace/progress_view_indeterminate_content.png')
3 Jun 18:54:27 - dirname for file frameworks/sproutcore/frameworks/foundation.js: printing_template/sproutcore/foundation
3 Jun 18:54:27 - isSaving? undefined
3 Jun 18:54:27 - returning rewritten staticurl: 'printing_template/sproutcore/foundation/blank.gif'
3 Jun 18:54:28 - dirname for file apps/printing_template/controllers/printController.js: printing_template/printing_template
3 Jun 18:54:28 - isSaving? undefined
WARNING: printing_template/printing_template/print_css referenced in apps/printing_template/controllers/printController.js but was not found.
3 Jun 18:54:28 - returning rewritten staticurl: 'printing_template/printing_template/print_css'
Proxying /favicon.ico
3 Jun 18:54:28 - done reading data from request, calling onEnd
3 Jun 18:54:28 - sending proxy request...
ERROR: "connect ECONNREFUSED" for proxy request on localhost:5984
Proxying /printing_template/printing_template/print_css
3 Jun 18:54:31 - done reading data from request, calling onEnd
3 Jun 18:54:31 - sending proxy request...
ERROR: "connect ECONNREFUSED" for proxy request on localhost:5984
Proxying /favicon.ico
3 Jun 18:54:31 - done reading data from request, calling onEnd
3 Jun 18:54:31 - sending proxy request...
ERROR: "connect ECONNREFUSED" for proxy request on localhost:5984

New BT and compass

Perhaps this issue can be best put at the sproutcore repo, but there is a (already known) existing problem with NodeJS and non-ruby compass support, in the sense that there isn't any.

In the sass_slicing branch (https://github.com/sproutcore/build-tools/tree/sass_slicing) I have moved in the sass and slicing support originally written for garçon. This branch however crashes because sass doesn't understand the compass extensions.
In garcon I worked around it by just filtering everything out sass couldn't understand, and just inserting all the compass extensions written in sass/scss. However, this is not a full replacement, because compass also extends the ruby part of sass/scss which cannot be replicated directly into nodejs.

My question here is: What parts of compass do we actually use in sproutcore and in what way do they rely on the ruby extension of compass? How easy would it be to do a kind of workaround to have the same effects without actually using compass?

Redesign of the config file parsing

In order to add generators to the new BT, I researched the way Abbot does the generators. While the way Abbot decides what the project root should be seems to me a bit like pulling a white rabbit out of a hat, I found that the way Abbot parses the Buildfiles is rather elegant.

The Buildfiles consists of code, and are executed as code, but unlike the BT, Abbot executes the contents of these files in a sandbox. In this sandbox, a set of functions forming a domain specific language are exposed in order to set the config.

The upside of implementing a similar strategy for the BT is that a change in the config files doesn't require restarting the BT. The downside might be that overriding certain behavior of the BT becomes a bit more difficult.
I would like to hear your thoughts!

Crash when checking out another branch

I experienced a crash when checking out another git branch. Here is the error:

crypto.js:209
  this._binding.update(data, encoding);
                ^
TypeError: Not a string or buffer
    at Hash.update (crypto.js:209:17)
    at BT.ImageFile.BT.File.extend.contentHash (/.../build-tools/lib/file_types/image.js:9:38)
    at SC.Observable.get (/.../build-tools/node_modules/sproutnode/frameworks/runtime/mixins/observable.js:214:103)

When a framework is configured, but not on disk, the BT continue with theme errors

Whenever a framework is missing on disk, but is configured, the BT will give a warning, but continue. It will then generate a series of warnings that the configured theme cannot be found, and then start the server.

Whenever a framework is missing, the app builder should simply abort building the app, and if no apps remain, stop the server.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.