{"id":13490902,"url":"https://github.com/sleepyfox/coffeescript-koans","last_synced_at":"2025-03-28T07:31:33.729Z","repository":{"id":144795182,"uuid":"2229508","full_name":"sleepyfox/coffeescript-koans","owner":"sleepyfox","description":"Koans: learn CoffeeScript by doing it","archived":false,"fork":false,"pushed_at":"2016-08-29T16:21:54.000Z","size":110,"stargazers_count":445,"open_issues_count":1,"forks_count":159,"subscribers_count":10,"default_branch":"master","last_synced_at":"2024-04-14T19:52:17.509Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"CoffeeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sleepyfox.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2011-08-18T18:15:41.000Z","updated_at":"2024-02-17T21:46:55.000Z","dependencies_parsed_at":"2024-01-06T13:59:42.303Z","dependency_job_id":"6d60f5d1-59d2-438b-bf0f-95b49db555a6","html_url":"https://github.com/sleepyfox/coffeescript-koans","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sleepyfox%2Fcoffeescript-koans","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sleepyfox%2Fcoffeescript-koans/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sleepyfox%2Fcoffeescript-koans/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sleepyfox%2Fcoffeescript-koans/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sleepyfox","download_url":"https://codeload.github.com/sleepyfox/coffeescript-koans/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245989134,"owners_count":20705762,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-31T19:00:51.953Z","updated_at":"2025-03-28T07:31:33.355Z","avatar_url":"https://github.com/sleepyfox.png","language":"CoffeeScript","funding_links":[],"categories":["CoffeeScript","Languages"],"sub_categories":["Other Languages"],"readme":"# CoffeeScript Koans\nThe goal of the CoffeeScript koans is to teach you [CoffeeScript](http://coffeescript.org/) programming through actually doing it, in a test-first fashion. \n\nWhen you first run the Koans, you'll be presented with a run-time error and a stack trace indicating where the error occurred. Your goal is to make the error go away. As you fix each error, you should learn something about the CoffeeScript language and functional programming in general.\n\nYour journey towards CoffeeScript enlightenment starts in the Koans folder with the AboutExpects.coffee file. \n\nThese Koans will be very simple, so don't over-think them! As you progress through more Koans, more and more CoffeeScript syntax will be introduced which will allow you to solve more complicated problems and use more advanced techniques.\n\n# Getting Started\n\nThis project requires [Node.js](http://nodejs.org/) - if you haven't already installed it I would recommend installing the Node Version Manager - [NVM](https://github.com/creationix/nvm) - and using that to install Node.\n\t\nInstall dependencies by using npm from the command line:\n\t\n\tnpm install\n\n# Running the Koans\n\nStart with copying the file koans/AboutShould.coffee to the completed-koans/ folder. \n\nRun the tests with [Mocha](http://mochajs.org) on the command line:\n\n\tnpm test\n\nYou should see the following output: \n\n\tAbout Should\n\t    1) should expect true\n\t    - should have filled in values\n\t    - should understand type coercion is fixed\n\t    - should expect equality\n\t    - should assert equality a better way\n\n\t0 passing (7ms) \u003c- this is how long the tests took to run\n\t4 pending\n\t1 failing\n\nYou'll see that one of the tests is failing, and that the other 4 have been temporarily disabled (marked as 'pending').  \n\nEdit the AboutShould.coffee file (your copy in the completed-koans/ folder) with the editor or IDE of your choice and follow the directions to fix the problem in the first test.\n\nWhen you think you've fixed the problem, run the tests again.\n\n\tnpm test\n\nWhen that test passes, enable the next pending test. Rinse and repeat until all tests turn green, simples :-)\n\nWhen you're done with AboutShould.coffee, copy another file from the koans/ folder to the completed-koans/ folder and start work on that.\n\nI would suggest trying them in the following order, but it is not prescriptive:\n\n1. AboutShould.coffee\n1. AboutFunctions.coffee\n1. AboutArrays.coffee\n1. AboutMutability.coffee\n1. AboutObjects.coffee\n1. AboutInheritance.coffee\n1. AboutHigherOrderFunctions.coffee\n1. AboutApplyingWhatWeHaveLearnt.coffee\n\nIf you want to just test a single test file, you can do it like this: (remember to add in the name of your file)\n\n\tmocha --compilers coffee:coffee-script/register -R spec completed-koans/FILE-NAME-GOES-HERE.coffee\n\nIf you want mocha to watch your files for changes and rerun the tests automagically when you save changes to a test file, simply use:\n\n\tnpm run watch\n\nHave fun, and I hope you enjoy playing with CoffeeScript!\n\n# Endorse this project \nTo say 'thanks' please endorse this project on [Coderwall](http://coderwall.com) by clicking the button below:\n\n[![endorse](https://api.coderwall.com/sleepyfox/endorsecount.png)](https://coderwall.com/sleepyfox)\n\nOr, if you happen to be in London, please drop by for a chat and buy me a beer!\n\n# Inspirations \u0026 thanks\n\n* _David Laing \u0026 Greg Malcolm_ - for their JavaScript/Jasmine port of the Ruby koans\n* _Edgecase_ - for the great Ruby Koans\n* _Jeremy Ashkenas and the CoffeeScript crew on GitHub_ - for making CoffeeScript in the first place\n* _Douglas Crockford_ - for JavaScript; the good bits\n* _Daniel P. Friedman \u0026 Matthias Felleisen_ - for 'The Little LISPer' book, where it all started\n\n# License (legal deed)\n\nThe text below is a human-readable summary of (and not a substitute for) the license, contained in the LICENSE file.\n\n* * * * *\n\n![CC BY-NC-SA 4.0](http://i.creativecommons.org/l/by-nc-sa/3.0/88x31.png)\n\nCreative Commons Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0)\n\nYou are free to:\n\n* Share — copy and redistribute the material in any medium or format\n* Adapt — remix, transform, and build upon the material\n\n_The licensor cannot revoke these freedoms as long as you follow the license terms._\n\nUnder the following terms:\n\n* Attribution — You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.\n* NonCommercial — You may not use the material for commercial purposes.\n* ShareAlike — If you remix, transform, or build upon the material, you must distribute your contributions under the same license as the original.\n* No additional restrictions — You may not apply legal terms or technological measures that legally restrict others from doing anything the license permits.\n\nNotices:\n\nYou do not have to comply with the license for elements of the material in the public domain or where your use is permitted by an applicable exception or limitation.\nNo warranties are given. The license may not give you all of the permissions necessary for your intended use. For example, other rights such as publicity, privacy, or moral rights may limit how you use the material.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsleepyfox%2Fcoffeescript-koans","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsleepyfox%2Fcoffeescript-koans","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsleepyfox%2Fcoffeescript-koans/lists"}