Giter VIP home page Giter VIP logo

guanlecoja's Introduction

Buildbot

The Continuous Integration Framework

Buildbot is based on original work from Brian Warner, and currently maintained by the Botherders.

Visit us on http://buildbot.net !

travis-badge codecov-badge readthedocs-badge

Buildbot consists of several components:

  • master
  • worker
  • www/base
  • www/console_view
  • www/waterfall_view

and so on

See the README in each subdirectory for more information

Related repositories:

guanlecoja's People

Contributors

lekensteyn avatar p12tic avatar rutsky avatar tardyp avatar tothandras avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

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

guanlecoja's Issues

How to import/export coffeescript Classes between files?

Pardon me for the vague question-issue here. I'm not quite sure what part of the guanlecoja stack this is related to.

I have a buildbot plugin which was working but it has one rather large source file that I'm trying to break up into several smaller source files. For example i have coffeescript a class called ConsoleUIHelpers which I broke into a separate file. Now I'm getting ReferenceError: ConsoleUIHelpers is not defined

Searching the scripts.js that some part of the guanlecoja framework is outputting I do find my class in the outputted code:

(function() {
  var ConsoleUIHelpers, consoleUIHelpers,
    bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };

  ConsoleUIHelpers = (function() {
  ...
}).call(this);

which appears before the code which is failing with the ReferenceError

It's not clear to me where/why the code is getting surrounded by the (function() { ... }).call(this) , but that seems to be what is preventing the subsequent code from having ConsoleUIHelpers as an identifier that it can access.

When I pass my class through a regular-old coffeescript-to-js conversion it does not surround it with (function() { ... }).call(this), so I'm guessing that it is coming from some other part of the guanlecoja framework, but i have no idea which piece of technology does this.

from reading https://stackoverflow.com/questions/2421911/what-is-the-purpose-of-wrapping-whole-javascript-files-in-anonymous-functions-li, I'm assuming that surrounding the code with (function() { ... }).call(this) is some kind of namespacing mechanism, though the examples in that stack overflow do something like var myPlugin = (function() { ... }).call(this) which then gives an identifier with which to access the contents of the namespace.

Apologies for my ignorance, I don't even know what to research in this case since reading about "coffeescript exports", "coffeescript modules" etc. turned up nothing that seemed relevant. I'm familiar with require.js but it doesn't appear to be being used anywhere in buildbot's front-end code, and can't find any examples of any sort of require/import statement to go off.

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.