Skip to content

Commit

Permalink
Converting dos spaces and CRLFs to unix spaces & LFs
Browse files Browse the repository at this point in the history
  • Loading branch information
bcochran committed Nov 6, 2012
1 parent 0404035 commit bd4858f
Show file tree
Hide file tree
Showing 30 changed files with 1,323 additions and 1,322 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ src/build.log
src/out src/out
node_modules node_modules
api-js/ api-js/
/*.project
48 changes: 24 additions & 24 deletions build/test/test-debug.js
Original file line number Original file line Diff line number Diff line change
@@ -1,29 +1,29 @@
YUI.add('test', function (Y, NAME) { YUI.add('test', function (Y, NAME) {






/** /**
* YUI Test Framework * YUI Test Framework
* @module test * @module test
* @main test * @main test
*/ */


/* /*
* The root namespace for YUI Test. * The root namespace for YUI Test.
*/ */


//So we only ever have one YUITest object that's shared //So we only ever have one YUITest object that's shared
if (YUI.YUITest) { if (YUI.YUITest) {
Y.Test = YUI.YUITest; Y.Test = YUI.YUITest;
} else { //Ends after the YUITest definitions } else { //Ends after the YUITest definitions


//Make this global for back compat //Make this global for back compat
YUITest = { YUITest = {
version: "@VERSION@", version: "@VERSION@",
guid: function(pre) { guid: function(pre) {
return Y.guid(pre); return Y.guid(pre);
} }
}; };


Y.namespace('Test'); Y.namespace('Test');


Expand Down
48 changes: 24 additions & 24 deletions build/test/test.js
Original file line number Original file line Diff line number Diff line change
@@ -1,29 +1,29 @@
YUI.add('test', function (Y, NAME) { YUI.add('test', function (Y, NAME) {






/** /**
* YUI Test Framework * YUI Test Framework
* @module test * @module test
* @main test * @main test
*/ */


/* /*
* The root namespace for YUI Test. * The root namespace for YUI Test.
*/ */


//So we only ever have one YUITest object that's shared //So we only ever have one YUITest object that's shared
if (YUI.YUITest) { if (YUI.YUITest) {
Y.Test = YUI.YUITest; Y.Test = YUI.YUITest;
} else { //Ends after the YUITest definitions } else { //Ends after the YUITest definitions


//Make this global for back compat //Make this global for back compat
YUITest = { YUITest = {
version: "@VERSION@", version: "@VERSION@",
guid: function(pre) { guid: function(pre) {
return Y.guid(pre); return Y.guid(pre);
} }
}; };


Y.namespace('Test'); Y.namespace('Test');


Expand Down
Original file line number Original file line Diff line number Diff line change
@@ -1,5 +1,5 @@
Contributor = Y.Base.create('contributor', User, [], {}, { Contributor = Y.Base.create('contributor', User, [], {}, {
ATTRS: { ATTRS: {
contributions: {value: 0} contributions: {value: 0}
} }
}); });
Original file line number Original file line Diff line number Diff line change
@@ -1,35 +1,35 @@
ContributorListView = Y.Base.create('contributorListView', Y.View, [], { ContributorListView = Y.Base.create('contributorListView', Y.View, [], {
// Compiles the ContributorList Template into a reusable Handlebars template. // Compiles the ContributorList Template into a reusable Handlebars template.
template: Y.Handlebars.compile(Y.one('#t-contributor-list').getHTML()), template: Y.Handlebars.compile(Y.one('#t-contributor-list').getHTML()),
render: function () { render: function () {
var contributors = this.get('modelList'), var contributors = this.get('modelList'),
contributorsData, content; contributorsData, content;
// Iterates over all `Contributor` models in the list and retrieves a // Iterates over all `Contributor` models in the list and retrieves a
// sub-set of each model instance's data as a simple JSON structs and // sub-set of each model instance's data as a simple JSON structs and
// collects it in an array. // collects it in an array.
contributorsData = contributors.map(function (contributor) { contributorsData = contributors.map(function (contributor) {
// Only a few of the `Contributor` data attributes are needed. // Only a few of the `Contributor` data attributes are needed.
var data = contributor.getAttrs(['login', 'avatar_url', 'contributions']); var data = contributor.getAttrs(['login', 'avatar_url', 'contributions']);
// Add proper pluralized labels for numerical data fields. // Add proper pluralized labels for numerical data fields.
addLabel(data, 'contributions', 'Contribution'); addLabel(data, 'contributions', 'Contribution');
return data; return data;
}); });
// Applies the `ContributorList` data to the ContributorList Template // Applies the `ContributorList` data to the ContributorList Template
// along with the total number of contributors for the repo. // along with the total number of contributors for the repo.
content = this.template({ content = this.template({
num : contributors.size(), num : contributors.size(),
contributors: contributorsData contributors: contributorsData
}); });
// Sets the resulting HTML from apply the data to the template as the // Sets the resulting HTML from apply the data to the template as the
// contents of this view's container. // contents of this view's container.
this.get('container').setHTML(content); this.get('container').setHTML(content);
return this; return this;
} }
}); });
Original file line number Original file line Diff line number Diff line change
@@ -1,27 +1,27 @@
ContributorList = Y.Base.create('contributorList', Y.ModelList, [GithubSync], { ContributorList = Y.Base.create('contributorList', Y.ModelList, [GithubSync], {
model : Contributor, model : Contributor,
githubURL: '/repos/{user}/{repo}/contributors', githubURL: '/repos/{user}/{repo}/contributors',
buildURL: function () { buildURL: function () {
// This list's `repo` is used to build the API URL. // This list's `repo` is used to build the API URL.
var repo = this.get('repo'); var repo = this.get('repo');
return Y.Lang.sub(this.githubURL, { return Y.Lang.sub(this.githubURL, {
user: repo.getAsURL('owner.login'), user: repo.getAsURL('owner.login'),
repo: repo.getAsURL('name') repo: repo.getAsURL('name')
}); });
}, },
// Override the default `comparator()` so items are sorted by most number of // Override the default `comparator()` so items are sorted by most number of
// contributors to least number of contributors. // contributors to least number of contributors.
comparator: function (contributor) { comparator: function (contributor) {
// Note the minus sign. // Note the minus sign.
return -contributor.get('contributions'); return -contributor.get('contributions');
} }
}, { }, {
ATTRS: { ATTRS: {
// A `ContributorList` has a `Repo` associated with it, this allows for // A `ContributorList` has a `Repo` associated with it, this allows for
// a loose-coupling between a repo and set of contributors. // a loose-coupling between a repo and set of contributors.
repo: {value: null} repo: {value: null}
} }
}); });
Loading

0 comments on commit bd4858f

Please sign in to comment.