conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "human", "value": "Add helper script for extracting list of options and languages\n" }, { "from": "gpt", "value": "jsonStringify = require('json-stable-stringify')\nLanguages = require('../src/languages')\nlanguages = new Languages().languages\n# console.log(languages.length)\n_ = requ...
coffeescript
chosen
[ { "from": "system", "value": "Add class on main section.\n" }, { "from": "human", "value": "`import Em from \"vendor/ember\"`\n\nComponent = Em.Component.extend\n type: Em.computed \"content.type\", -> \"oxisection-\" + @get \"content.type\"\n actions:\n buttonClick: (button) ->\n ...
coffeescript
chosen
[ { "from": "human", "value": "Update to imageButton for android\n" }, { "from": "gpt", "value": "root.ImageButton_Framework_Android = class ImageButton_Framework_Android extends root.ImageButton_Framework\n constructor:(options = {}) ->\n options = root._.extend {}, options\n super options...
coffeescript
chosen
[ { "from": "human", "value": "Add the test cases for OrderItemBuilder.coffee\n" }, { "from": "gpt", "value": "#= require jquery\n#= require jasmine-jquery\n#= require comable/admin/order_item_builder\n\ndescribe 'OrderItemBuilder', ->\n described_class = null\n subject = null\n\n beforeEach ->...
coffeescript
chosen
[ { "from": "system", "value": "Add a request to get all recurring events\n" }, { "from": "human", "value": "cozydb = require 'cozydb'\n\ntagsView =\n map: (doc) ->\n doc.tags?.forEach? (tag, index) ->\n type = if index is 0 then 'calendar' else 'tag'\n emit [type, ...
coffeescript
chosen
[ { "from": "system", "value": "Enable multi language filter in projects_path\n\nTo filter more than two language projects_path, use Cmd or Ctrl key\nwhen selecting language.\nThis behavior is well known in many OS, so people will be want to use\nthis when filtering multi languages.\n" }, { "from": "h...
coffeescript
chosen
[ { "from": "human", "value": "Add integration test for states (create, update, delete)\n" }, { "from": "gpt", "value": "_ = require 'underscore'\nQ = require 'q'\nSphereClient = require '../../lib/client'\nConfig = require('../../config').config\n\nuniqueId = (prefix) ->\n _.uniqueId \"#{prefix}...
coffeescript
chosen
[ { "from": "human", "value": "Add example purely for output demonstration\n" }, { "from": "gpt", "value": "Quest = require '../../src/quest'\n\nmodule.exports =\nclass OutputExampleQuest extends Quest\n adventure: ->\n\n console.log \"So, what's a person like?\".bold\n\n @sql \"\"\"\n ...
coffeescript
chosen
[ { "from": "human", "value": "Disable code folding in Atom\n" }, { "from": "gpt", "value": "# Your init script\n#\n# Atom will evaluate this file each time a new window is opened. It is run\n# after packages are loaded/activated and after the previous editor state\n# has been restored.\n#\n# An e...
coffeescript
chosen
[ { "from": "human", "value": "Test cases for handling default function\n" }, { "from": "gpt", "value": "describe 'Overloadad functions', ->\n overloadableFunction = null\n spiedFunction = jasmine.createSpy()\n\n describe 'Default function', ->\n it 'should throw error when default...
coffeescript
chosen
[ { "from": "human", "value": "Add grunt task to download release assets.\n" }, { "from": "gpt", "value": "fs = require 'fs'\npath = require 'path'\nos = require 'os'\nminimatch = require 'minimatch'\nGitHub = require '../lib/github'\n\nmodule.exports = (grunt) ->\n taskName...
coffeescript
chosen
[ { "from": "human", "value": "Add some unit tests for preprocessor" }, { "from": "gpt", "value": "#==============================================================================\n# lib/preprocessor.js module\n#==============================================================================\ndescrib...
coffeescript
chosen
[ { "from": "system", "value": "Remove page actions buttons on overview section\n" }, { "from": "human", "value": "Augury.Views.Home.Index = Backbone.View.extend(\n initialize: ->\n\n render: ->\n @env = _(Augury.connections).findWhere(id: Augury.env.id)\n\n @$el.html JST[\"admin/templates...
coffeescript
chosen
[ { "from": "system", "value": "BUGFIX: Apply button does not jump to \"Apply\"\n" }, { "from": "human", "value": "_ = require 'underscore'\nBackbone = require 'backbone'\nView = require './view.coffee'\nJump = require '../../../components/jump/view.coffee'\n\nmodule.exports = class PartnershipsRo...
coffeescript
chosen
[ { "from": "system", "value": "Remove uncapitalize from artist route\n" }, { "from": "human", "value": "#\n# The artist page found at /artist/:id.\n#\n\nexpress = require 'express'\nroutes = require './routes'\nsections = require './sections'\ntimeout = require 'connect-timeout'\nuncapitalize = r...
coffeescript
chosen
[ { "from": "human", "value": "Allow Hubot to fetch app performance stats from New Relic\n" }, { "from": "gpt", "value": "# Display current app performance stats from New Relic\n#\n# You need to set the following variables:\n# HUBOT_NEWRELIC_ACCOUNT_ID = \"<Account ID>\"\n# HUBOT_NEWRELIC_APP_...
coffeescript
chosen
[ { "from": "human", "value": "Add joke me from /r/jokes\n" }, { "from": "gpt", "value": "# joke me - Pull a random joke from /r/jokes\n\nmodule.exports = (robot) ->\n\n robot.respond /joke me/i, (msg) ->\n msg.http('http://www.reddit.com/r/jokes.json')\n .get() (err, res, body) ->\n ...
coffeescript
chosen
[ { "from": "human", "value": "Teams: Create base class for common context menu on credential and stack list.\n" }, { "from": "gpt", "value": "kd = require 'kd'\nJView = require 'app/jview'\nKDButtonViewWithMenu = kd.ButtonViewWithMenu\nActivityItemMenuItem = r...
coffeescript
chosen
[ { "from": "system", "value": "Use parameter instead of ivar\n" }, { "from": "human", "value": "DeferredAtomPackage = require 'deferred-atom-package'\nLoadPathsTask = require './src/load-paths-task'\n\nmodule.exports =\nclass FuzzyFinder extends DeferredAtomPackage\n loadEvents: [\n 'fuzzy-fi...
coffeescript
chosen
[ { "from": "human", "value": "Add bootstrap slider react component\n" }, { "from": "gpt", "value": "Slider = React.createClass(\n getDefaultProps: ->\n {\n min: 0\n max: 100\n step: 1\n value: 50\n toolTip: false\n onSlide: ->\n }\n\n handleSlide: (event) ->\...
coffeescript
chosen
[ { "from": "human", "value": "Add publisher script for Nu.nl\n\nThis can be compiled locally using coffee -c <filename>. No need to compile this in Grunt, since the script will only be installed locally into Chrome.\n" }, { "from": "gpt", "value": "###\n// ==UserScript==\n// @name Factlink Publ...
coffeescript
chosen
[ { "from": "human", "value": "Add a lightweight JSON-RPC implementation\n" }, { "from": "gpt", "value": "kopi.module(\"kopi.jsonrpc\")\n .require(\"kopi.exceptions\")\n .request(\"kopi.utils\")\n .define (exports, exceptions, utils) ->\n\n ###\n A lightweight JSON-RPC message wrapper\n ...
coffeescript
chosen
[ { "from": "human", "value": "Fix scroll on spacebar press\n" }, { "from": "gpt", "value": "# Taken from https://gist.github.com/leshniak/f3b163b23bbfac5dad313b628f3c09ac\n# Fixes scrolling on space key in atom-text-editor.mini\nfixScrollOnSpace = () =>\n editorSelector = 'atom-text-editor[min...
coffeescript
chosen
[ { "from": "human", "value": "Add unit tests for /login and /logout\n" }, { "from": "gpt", "value": "\"use strict\"\n\nassert = require 'assert'\nserver = require '../coffee/server.coffee'\n\nexports.cookie = cookie = null\n\ndescribe '/login', ->\n it 'should server a login page', (done) ->\n ...
coffeescript
chosen
[ { "from": "system", "value": "Return the router object when initializing filter\n" }, { "from": "human", "value": "Backbone = require 'backbone'\nArtworkFilterRouter = require './router.coffee'\n\nmodule.exports.init = (options = {}) ->\n new ArtworkFilterRouter options\n require './analytics....
coffeescript
chosen
[ { "from": "system", "value": "Use temp dir in specs\n" }, { "from": "human", "value": "fs = require 'fs'\npath = require 'path'\n\ngrunt = require 'grunt'\ntemp = require 'temp'\n\ndescribe 'create-windows-installer task', ->\n it 'creates a nuget package', ->\n outputDirectory = __dirname\n...
coffeescript
chosen
[ { "from": "human", "value": "Tests: Add Rewinder test. Works on Node 0.10, fails on Node 0.12\n\nNon-pump outputs are failing on Node 0.12 and iojs, apparently because their\nwritable streams don't try calling read again when a `readable` is emitted.\n" }, { "from": "gpt", "value": "RewindBuffer...
coffeescript
chosen
[ { "from": "system", "value": "Create view helper for getShortTaskIDMiddleEllipsis utils method" }, { "from": "human", "value": "Handlebars.registerHelper 'ifEqual', (v1, v2, options) -> if v1 is v2 then options.fn @ else options.inverse @\nHandlebars.registerHelper 'ifLT', (v1, v2, options) -> i...
coffeescript
chosen
[ { "from": "human", "value": "Add a redux like store as the successor\n" }, { "from": "gpt", "value": "# TODO-2 try to load the state from local storage.\n# BUT if there's no cookie, then act like local storage isn't there.\n# Also, state changes should update the data in local storage as well.\n...
coffeescript
chosen
[ { "from": "system", "value": "Mark Notification public and add docs\n" }, { "from": "human", "value": "{Emitter} = require 'event-kit'\n\n# Experimental: This will likely change, do not use.\nmodule.exports =\nclass Notification\n constructor: (@type, @message, @options={}) ->\n @emitter = n...
coffeescript
chosen
[ { "from": "human", "value": "Create radio button coffee script\n" }, { "from": "gpt", "value": "root = exports ? this\n\nRadioButtonsModule =\n\n bindToRadioButtons: ->\n $('input[type=radio]').on 'change', ->\n $(\"[name='\" + $(this).attr('name') + \"']\").parent().removeClass(\"selec...
coffeescript
chosen
[ { "from": "human", "value": "Change git next/prev diff keys\n" }, { "from": "gpt", "value": "'.atom-text-editor':\n 'alt-g down': 'unset!'\n 'alt-g j': 'git-diff:move-to-next-diff'\n 'alt-g up': 'unset!'\n 'alt-g k': 'git-diff:move-to-previous-diff'\n" } ]
coffeescript
chosen
[ { "from": "human", "value": "Add a suite of helper functions in CoffeeScript\n" }, { "from": "gpt", "value": "{toString} = Object.prototype\n\n\n# Uppercase the first letter of a string\nucFirst = (value) ->\n\tvalue.replace /\\b(\\w)(.*$)/g, (match, firstLetter, remainder) ->\n\t\tfirstLetter.t...
coffeescript
chosen
[ { "from": "system", "value": "Add version to expected .nupkg path\n" }, { "from": "human", "value": "fs = require 'fs'\npath = require 'path'\n\ngrunt = require 'grunt'\ntemp = require 'temp'\n\ndescribe 'create-windows-installer task', ->\n it 'creates a nuget package', ->\n outputDirectory...
coffeescript
chosen
[ { "from": "human", "value": "Add BobCat JS file for BobCat files.\n" }, { "from": "gpt", "value": "# Require 'nyulibraries' \n# = require nyulibraries\n$ ->\n # BobCat Tabs Tips\n new window.popover.Popover(\".nav-tabs li a\").init()\n new window.popover.PartialHoverPopover(\"#account h2 a\")...
coffeescript
chosen
[ { "from": "human", "value": "spec: Add a simple test case for desktopCapturer\n" }, { "from": "gpt", "value": "assert = require 'assert'\n{desktopCapturer} = require 'electron'\n\ndescribe 'desktopCapturer', ->\n it 'should returns something', (done) ->\n desktopCapturer.getSources {types: [...
coffeescript
chosen
[ { "from": "human", "value": "Add basic request handling node server\n" }, { "from": "gpt", "value": "sys = require 'sys'\nhttp = require 'http'\n\nhttp.createServer((request, response) ->\n sys.puts 'I got kicked'\n response.writeHeader 200, {\"Content-Type\": \"text/plain\"}\n response.write...
coffeescript
chosen
[ { "from": "human", "value": "Add Chat js handling logic\n" }, { "from": "gpt", "value": "window.InteractionWebTools ||= {}\nwindow.InteractionWebTools.chat = new Chat\n\n$ ->\n InteractionWebTools.chat.receiveMessages()\n\n$(document).on 'submit', 'form.chat-message-form', (e) ->\n e.preventDe...
coffeescript
chosen
[ { "from": "human", "value": "Add spec for required ports\n" }, { "from": "gpt", "value": "if typeof process isnt 'undefined' and process.execPath and process.execPath.indexOf('node') isnt -1\n chai = require 'chai' unless chai\n component = require '../src/lib/Component.coffee'\n port = requi...
coffeescript
chosen
[ { "from": "human", "value": "Add spec for token iterator regression\n" }, { "from": "gpt", "value": "TextBuffer = require 'text-buffer'\nTokenizedBuffer = require '../src/tokenized-buffer'\n\ndescribe \"TokenIterator\", ->\n it \"correctly terminates scopes at the beginning of the line (regress...
coffeescript
chosen
[ { "from": "system", "value": "Fix a silly error from changing approach midway.\n" }, { "from": "human", "value": "# Description:\n# Report the status of a Minecraft server\n# Uses http://api.syfaro.net/\n#\n# Dependencies:\n# None\n#\n# Configuration:\n# server_url and server_port, below...
coffeescript
chosen
[ { "from": "human", "value": "Add test script using Dialog\n" }, { "from": "gpt", "value": "Path = require \"path\"\nDialog = require Path.join __dirname, \"..\", \"src\", \"dialog\"\n\nmodule.exports = (robot) ->\n\n # robot.hear /.*/i, (msg) ->\n # dialog = Dialog.getDialog msg.envelope.use...
coffeescript
chosen
[ { "from": "system", "value": "Include ImageSizes for featured links\n" }, { "from": "human", "value": "_ = require 'underscore'\nBackbone = require 'backbone'\nItems = require '../collections/items.coffee'\nLayoutSyle = require './mixins/layout_style.coffee'\n{ Image, Markdown } = require 'artsy...
coffeescript
chosen
[ { "from": "human", "value": ":new: Add some basic linter-behavior specs\n" }, { "from": "gpt", "value": "describe 'Linter Behavior', ->\n linter = null\n linterState = null\n bottomContainer = null\n trigger = (el, name) ->\n event = document.createEvent('HTMLEvents');\n event.initEven...
coffeescript
chosen
[ { "from": "system", "value": "Reset data for each test\n" }, { "from": "human", "value": "DB = require '../lib/db'\n\ndescribe \"DB\", ->\n db = null\n\n test1 = off\n test2 = off\n\n data =\n testproject1:\n title: \"Test project 1\"\n group: \"Test\"\n paths: [\n \...
coffeescript
chosen
[ { "from": "system", "value": "Remove the explicit for_sale filter and instead sort works by -decayed_merch on mobile web\n" }, { "from": "human", "value": "_ = require 'underscore'\nBackbone = require 'backbone'\nqs = require 'qs'\nFilterArtworks = require '../../collections/filter_artworks.coff...
coffeescript
chosen
[ { "from": "human", "value": "Add Programmer class (for updating firmware)\n" }, { "from": "gpt", "value": "\"use strict\"\n# Pre dependencies\n# (none)\n\n###*\n@class Programmer\n Firmware updater class\n###\nmodule.exports = class Programmer\n null\n\n #-------------------------------------...
coffeescript
chosen
[ { "from": "human", "value": "Add tests for changing node properties\n\n[#99423710]" }, { "from": "gpt", "value": "global.window = { location: '' }\n\nchai = require('chai')\nchai.config.includeStack = true\n\nexpect = chai.expect\nshould = chai.should()\nSinon = require(...
coffeescript
chosen
[ { "from": "human", "value": "Add test for simple cors over spdy\n" }, { "from": "gpt", "value": "class SimpleCorsSpdyTest\n constructor: ($http) ->\n @result = \"pending\"\n @display_name = \"Simple CORS over SPDY\"\n @$http = $http\n\n run: ->\n a = Math.floor((Math.random() * 100...
coffeescript
chosen
[ { "from": "human", "value": "Add tests for layout mixins." }, { "from": "gpt", "value": "jest.autoMockOff()\n\nfs = require 'fs'\npath = require 'path'\nsass = require 'node-sass'\ncss = require 'css'\n\nrenderSass = (sass_source) ->\n output = sass.renderSync\n ...
coffeescript
chosen
[ { "from": "human", "value": "Add rad json matcher with legit output on failure" }, { "from": "gpt", "value": "_ = require 'underscore'\n\nbeforeEach ->\n @addMatchers\n toEqualJson: (expected) ->\n failures = {}\n\n class Failure\n constructor: (@path, @actual, @expected) ->...
coffeescript
chosen
[ { "from": "human", "value": "Add test for cmEditor directive\n" }, { "from": "gpt", "value": "define ['ide/editor/directives/cmEditor'], () ->\n describe 'cmEditor', () ->\n beforeEach(module('SharelatexApp'))\n\n beforeEach () ->\n @richTextInit = sinon.stub()\n window.Frontend...
coffeescript
chosen
[ { "from": "human", "value": "Add script to convert the data to multiple yaml files\n" }, { "from": "gpt", "value": "#!/usr/bin/env coffee\n#\n# Copyright (C) 2015 by EatOutBerlin\n#\n\nfs = require 'fs'\nyaml = require 'js-yaml'\ncolors = require 'colors/safe'\npath = require 'path'\ndiff = requ...
coffeescript
chosen
[ { "from": "human", "value": "Add a basic build success/failure notifier endpoint\n" }, { "from": "gpt", "value": "# Description\n# Notifies based on the results of xcode builds and controls xcode builds\n#\n# Dependencies\n# None\n#\n# Configuration\n# None\n#\n# Commands:\n# hubot build...
coffeescript
chosen
[ { "from": "human", "value": "Add menu item for package\n" }, { "from": "gpt", "value": "'menu': [\n {\n 'label': 'Packages'\n 'submenu': [\n 'label': 'Autosave Onchange'\n 'submenu': [\n {\n 'label': 'Toggle'\n 'command': 'autosave-delay:toggle'\n ...
coffeescript
chosen
[ { "from": "system", "value": "Abort task when view is created\n" }, { "from": "human", "value": "_ = require 'underscore'\n\nmodule.exports =\n projectPaths: null\n fuzzyFinderView: null\n loadPathsTask: null\n\n activate: (state) ->\n rootView.command 'fuzzy-finder:toggle-file-finder', =...
coffeescript
chosen
[ { "from": "human", "value": "Create an internationalization module which uses associative array and manage language from url\n" }, { "from": "gpt", "value": "module.exports = (env, callback) ->\n lang_FR = [\n 'LAB_KEYWORDS' : 'Mots clés',\n 'LAB_DEMOS' : 'Démos & Projets...
coffeescript
chosen
[ { "from": "human", "value": "Extend _ with utility functions for type checking\n" }, { "from": "gpt", "value": "\n_.mixin\n\n # Tests if the instance of an object is a subtype of a given class. (Note that this only works for coffeescript classes)\n # @param [Object] An instance of an object\n ...
coffeescript
chosen
[ { "from": "human", "value": "Create a new KodingListController instance for InvitationsListController\n" }, { "from": "gpt", "value": "kd = require 'kd'\nremote = require('app/remote').getInstance()\nInvitedItemView = require './inviteditemview'\nKDNotific...
coffeescript
chosen
[ { "from": "human", "value": "Add migration to enable trackChanges for all users\n" }, { "from": "gpt", "value": "Settings = require \"settings-sharelatex\"\nfs = require(\"fs\")\nmongojs = require(\"mongojs\")\nObjectId = mongojs.ObjectId\ndb = mongojs(Settings.mongo.url, ['users'])\n_ = require...
coffeescript
chosen
[ { "from": "human", "value": "Add some view specs for set password flow\n\nAlso improved some coverage for the forgot flow by default.\n" }, { "from": "gpt", "value": "jade = require 'jade'\npath = require 'path'\nfs = require 'fs'\ncheerio = require 'cheerio'\n\nrender = (templateName) ->\n fil...
coffeescript
chosen
[ { "from": "human", "value": "Add spec for download image route\n" }, { "from": "gpt", "value": "_ = require 'underscore'\nQ = require 'bluebird-q'\nsinon = require 'sinon'\nBackbone = require 'backbone'\nrequest = require 'superagent'\n{ fabricate } = require 'antigravity'\nroutes = require '../...
coffeescript
chosen
[ { "from": "human", "value": "Add Packages > Open On GitHub menu\n" }, { "from": "gpt", "value": "'menu': [\n {\n 'label': 'Packages'\n 'submenu': [\n 'label': 'Open On GitHub'\n 'submenu': [\n { 'label': 'Blame', 'command': 'open-on-github:blame' }\n { 'label': 'Co...
coffeescript
chosen
[ { "from": "system", "value": "Use guest user name if already registered\n" }, { "from": "human", "value": "Meteor.methods\n\tsendMessageLivechat: (message) ->\n\t\tif s.trim(message.msg) isnt ''\n\n\t\t\tif isNaN(TimeSync.serverOffset())\n\t\t\t\tmessage.ts = new Date()\n\t\t\telse\n\t\t\t\tmess...
coffeescript
chosen
[ { "from": "system", "value": "Firewall: Update rule item view when rule is updated.\n" }, { "from": "human", "value": "class EnvironmentRuleItem extends EnvironmentItem\n\n constructor: (options = {}, data) ->\n\n options.cssClass = 'rule'\n options.joints = ['right'...
coffeescript
chosen
[ { "from": "system", "value": "Add keybindings for win32 and linux\n" }, { "from": "human", "value": "# Keybindings require three things to be fully defined: A selector that is\n# matched against the focused element, the keystroke and the command to\n# execute.\n#\n# Below is a basic keybinding w...
coffeescript
chosen
[ { "from": "system", "value": "Update settings, add Command testing\n" }, { "from": "human", "value": "_ = require \"underscore\"\n\nmodule.exports = (target, source) ->\n _.extend {}, target, _.pick(source, [\n \"commandId\"\n \"stepId\"\n \"userId\"\n \"avatarId\"\n ])" }, { ...
coffeescript
chosen
[ { "from": "system", "value": "Use app package.json file in spec\n" }, { "from": "human", "value": "fs = require 'fs'\npath = require 'path'\n\ngrunt = require 'grunt'\ntemp = require 'temp'\n\ndescribe 'create-windows-installer task', ->\n it 'creates a nuget package', ->\n outputDirectory =...
coffeescript
chosen
[ { "from": "system", "value": "Test also that error is passed to onError handler\n" }, { "from": "human", "value": "# build-dependencies: bus\ndescribe \"EventStream.doError\", ->\n it \"calls function before sending error to listeners\", ->\n called = []\n bus = new Bacon.Bus()\n s = b...
coffeescript
chosen
[ { "from": "human", "value": "Create a model factory fot angular js\n" }, { "from": "gpt", "value": "'use strict'\n\ndescribe 'ngDatabase model', ->\n $model = null\n\n beforeEach ->\n module 'ngDatabase'\n return\n\n beforeEach ->\n inject ($injector) ->\n ...
coffeescript
chosen
[ { "from": "human", "value": "Add wrapper class for analytics.\n\n[#51845303]\n" }, { "from": "gpt", "value": "###\n This class's function parameters are inspired by Segment.io. It's a light wrapper for it in case I decide to\n switch analytics providers.\n###\nclass @SpendflowStats\n\nanalytic...
coffeescript
chosen
[ { "from": "human", "value": "Add an action that implies '.txt' at the end of a URL.\n" }, { "from": "gpt", "value": "staticHandler= require('../static_handler')\nmimeWrapper= require('../mime_wrapper')\nhasAnExtension = require('../utilities').hasAnExtension\n\nextensions= ['.txt']\n\n# if addin...
coffeescript
chosen
[ { "from": "human", "value": "Add JavaScript for Courses Listing Scroll\n\nAdd JavaScript code to handle setting the width of the Courses listing\nso that if there are more courses than fit on the page, the container\nscrolls.\n" }, { "from": "gpt", "value": "$ ->\n # handle updating the width f...
coffeescript
chosen
[ { "from": "human", "value": "Add menu item to jump to matching bracket\n" }, { "from": "gpt", "value": "'menu': [\n {\n 'label': 'Packages'\n 'submenu': [\n 'label': 'Bracket Matcher'\n 'submenu': [\n { 'label': 'Go To Matching Bracket', 'command': 'bracket-matcher:go-to-...
coffeescript
chosen
[ { "from": "human", "value": "Add pluggable performance measurement logger\n" }, { "from": "gpt", "value": "load_moments = []\nlast_sorted = 0\n\nadd_timing_event = (name) ->\n add_existing_timing_event name, new Date().getTime()\n\nadd_existing_timing_event = (name, time) ->\n load_moments.pus...
coffeescript
chosen
[ { "from": "system", "value": "Set useragent on api requests to github\n" }, { "from": "human", "value": "NotificationPlugin = require \"../../notification-plugin\"\n\nclass GithubIssue extends NotificationPlugin\n BASE_URL = \"https://api.github.com\"\n\n stacktraceLines = (stacktrace) ->\n ...
coffeescript
chosen
[ { "from": "human", "value": "Expand things like merlin: and merlin-lax: to message the correct people.\n" }, { "from": "gpt", "value": "# Expands a message to a named group of people into their individual names\n#\n# merlin: <your message>\n\nmerlin_remote_members = [\n \"Cliff Dickerson\",\n ...
coffeescript
chosen
[ { "from": "human", "value": "Add unit tests for metadata functions\n" }, { "from": "gpt", "value": "should = require \"should\"\nmetadata = require \"../../lib/api/metadata\"\n\ndescribe \"Metadata Functions\", ->\n\n describe \".removeProperties\", ->\n\n it \"should return an object with _...
coffeescript
chosen
[ { "from": "human", "value": "Add initial 'who's turn' script\n" }, { "from": "gpt", "value": "# Who's turn to do something ?\n#\n# who <does something> : <someone>, <someone>, <someone> ? - Returns who does !\n# \nmodule.exports = (robot) ->\n robot.respond /(who|qui) (.+) ...
coffeescript
chosen
[ { "from": "human", "value": "Add JS specs for Array extensions\n" }, { "from": "gpt", "value": "#= require extensions/array\n\ndescribe 'Array extensions', ->\n describe 'first', ->\n it 'returns the first item', ->\n arr = [0, 1, 2, 3, 4, 5]\n expect(arr.first()).toBe(0)\n\n desc...
coffeescript
chosen
[ { "from": "human", "value": "Move language information deducing functionality to workspace utils\n" }, { "from": "gpt", "value": "{Point} = require('atom')\npath = require('path')\n\nlanguageRegistry = require('./language-registry').getInstance()\n\n# -----------------------...
coffeescript
chosen
[ { "from": "human", "value": "Add a test for display of attribution_class on desktop\n" }, { "from": "gpt", "value": "_ = require 'underscore'\njade = require 'jade'\ncheerio = require 'cheerio'\npath = require 'path'\nfs = require 'fs'\n{ fabricate } = require 'antigravity'\nsinon = require 'sin...
coffeescript
chosen
[ { "from": "system", "value": "Upgrade indicator selector to diorama 0.2.0\n" }, { "from": "human", "value": "window.Backbone ||= {}\nwindow.Backbone.Views ||= {}\n\nclass Backbone.Views.IndicatorSelectorView extends Backbone.Diorama.NestingView\n template: Handlebars.templates['indicator_select...
coffeescript
chosen
[ { "from": "human", "value": "Tests: Add failing test getting non-existant attribute in continue tree\n" }, { "from": "gpt", "value": "chai = require 'chai' unless chai\nChoice = require '../lib/Choice'\nRoot = require '../lib/Root'\n\ndescribe 'Subtrees', ->\n\n describe 'non-existent attribute...
coffeescript
chosen
[ { "from": "system", "value": "Use working directory instead of project path\n\nProject path might be a sub directory of the repository\n" }, { "from": "human", "value": "path = require 'path'\nfs = require 'fs-plus'\nFuzzyFinderView = require './fuzzy-finder-view'\n\nmodule.exports =\nclass GitS...
coffeescript
chosen
[ { "from": "system", "value": "Use presenter for rendering overlay decorations\n\nWe’re still doing some sync DOM reads and computation in the view that\nshould eventually be made async and moved into the presenter, but I’m\ngoing to leave it alone for now.\n" }, { "from": "human", "value": "modu...
coffeescript
chosen
[ { "from": "system", "value": "Add comment about filter permission\n" }, { "from": "human", "value": "checkToken = require('../lib/token').checkToken\nerrors = require '../middlewares/errors'\n\nmodule.exports.checkDevice = (req, res, next) ->\n auth = req.header('authorization')\n [err, is...
coffeescript
chosen
[ { "from": "human", "value": "Add a script for getting Captain Quail from Hubot.\n" }, { "from": "gpt", "value": "# Description:\n# The Adventures of Captain Quail, now in you chat!\n#\n# Dependencies:\n# \"htmlparser\": \"1.7.6\"\n# \"soupselect\": \"0.2.0\"\n#\n# Configuration:\n# None\...
coffeescript
chosen
[ { "from": "system", "value": "Make focus state distinct until changed on Focusable objects" }, { "from": "human", "value": "Mixin = require 'mixto'\n\nmodule.exports =\nclass Focusable extends Mixin\n @included: ->\n @property 'focusContext'\n @behavior 'focused', ->\n @$focusContext...
coffeescript
chosen
[ { "from": "system", "value": "Sort installed packages by name\n" }, { "from": "human", "value": "ConfigPanel = require 'config-panel'\nPackageConfigView = require 'package-config-view'\n\n### Internal ###\n\nmodule.exports =\nclass InstalledPackagesConfigPanel extends ConfigPanel\n @content: ->...
coffeescript
chosen
[ { "from": "human", "value": "AC: Add rough outline for UI interaction test suite\n" }, { "from": "gpt", "value": "describe \"UI interactions\", ->\n\n describe \"Tags\", ->\n\n say \"I click on a tag\", ->\n\n it \"should show up in the tag list\", ->\n\n it \"should only show stor...
coffeescript
chosen
[ { "from": "system", "value": "Add test for plugins.on|off overrides\n" }, { "from": "human", "value": "rewire = require 'rewire'\nhelpers = rewire '../src/helpers'\n\ndescribe 'helpers', ->\n describe 'replaceConfigSlashes()', ->\n it 'should replace slashes with backslashes in config', ->\n...
coffeescript
chosen
[ { "from": "human", "value": "Add initial test for list view\n" }, { "from": "gpt", "value": "Helper = require './spec-helper'\nProjectsListView = require '../lib/projects-list-view'\nProject = require '../lib/project'\n{$} = require 'atom-space-pen-views'\n\ndescribe \"List View\", ->\n [listVi...
coffeescript
chosen
[ { "from": "human", "value": "Add a LifecycleEvents mixin for Rails style callback chains.\n" }, { "from": "gpt", "value": "Batman.LifecycleEvents =\n initialize: ->\n @::fireLifecycleEvent = fire\n\n lifecycleEvent: (eventName, normalizeFunction) ->\n beforeName = \"before#{Batman.helper...
coffeescript
chosen
[ { "from": "system", "value": "Support more browsers with indexOf\n" }, { "from": "human", "value": "require('backbone').$ = $\n$ ->\n if location.pathname is '/2016-year-in-art'\n require('../apps/editorial_features/components/eoy/client.coffee').init\n else if location.pathname.includes('/...
coffeescript
chosen
[ { "from": "human", "value": "Add tests for the registerTemplates function\n" }, { "from": "gpt", "value": "chai = require 'chai'\nchai.should()\ncp = require 'child_process'\npack = require '../package.json'\n\ncsv_template_specified = 'node bin/autometa.js -r templates/test.csv'\nejs_template_s...
coffeescript
chosen
[ { "from": "system", "value": "Make pause delete and unpause work" }, { "from": "human", "value": "Model = require './model'\n\nclass Request extends Model\n\n url: => \"#{ env.SINGULARITY_BASE }/#{ constants.apiBase }/requests/request/#{ @get('id') }\"\n\n deletePaused: =>\n $.ajax\...
coffeescript
chosen
[ { "from": "human", "value": "Create component to convert canvas to buffers async\n" }, { "from": "gpt", "value": "noflo = require 'noflo'\n\n# @runtime noflo-nodejs\n# @name CanvasToBuffer\n\nexports.getComponent = ->\n c = new noflo.Component\n\n c.description = 'Convert a canvas to a buffer'...
coffeescript
chosen
[ { "from": "human", "value": "Introduce new specs for latexmk util\n" }, { "from": "gpt", "value": "latexmk = require \"../lib/latexmk\"\n\ndescribe \"latexmk\", ->\n describe \"run\", ->\n xit \"...\", ->\n return\n\n describe \"constructArgs\", ->\n xit \"...\", ->\n return\n\...
coffeescript
chosen
[ { "from": "human", "value": "Add two tests regarding crashes in context switching.\n" }, { "from": "gpt", "value": "assert = require 'assert'\nfs = require 'fs'\n\ndescribe 'contexts', ->\n describe 'setTimeout in fs callback', ->\n it 'does not crash', (done) ->\n fs.readFile __filenam...
coffeescript
chosen