{"id":24782755,"url":"https://github.com/csgn/lamda","last_synced_at":"2025-03-24T05:43:12.866Z","repository":{"id":246775769,"uuid":"822627088","full_name":"csgn/lamda","owner":"csgn","description":"Lamda is a minimal functional programming library for Scala.","archived":false,"fork":false,"pushed_at":"2025-01-28T15:49:59.000Z","size":1967,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-01-28T16:36:01.236Z","etag":null,"topics":["scala","typeclasses"],"latest_commit_sha":null,"homepage":"https://csgn.github.io/lamda/latest/api/lamda","language":"Scala","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/csgn.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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-07-01T13:52:39.000Z","updated_at":"2025-01-28T15:50:05.000Z","dependencies_parsed_at":null,"dependency_job_id":"b3e05926-7cec-4060-a69d-d24f20e2d46f","html_url":"https://github.com/csgn/lamda","commit_stats":null,"previous_names":["kattulib/kuram","lamdalib/kuram","csgn/lamda"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csgn%2Flamda","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csgn%2Flamda/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csgn%2Flamda/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csgn%2Flamda/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/csgn","download_url":"https://codeload.github.com/csgn/lamda/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245217791,"owners_count":20579297,"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":["scala","typeclasses"],"created_at":"2025-01-29T11:25:12.866Z","updated_at":"2025-03-24T05:43:12.840Z","avatar_url":"https://github.com/csgn.png","language":"Scala","readme":"# Lamda\n\nLamda is a minimal functional programming library for Scala.\n\n## Getting Lamda\nLamda is not a published project. If you want to use the library,\nyou should clone the project and publish it locally as on the following command:\n```bash\n# on interactive sbt shell\nsbt:lamda\u003e publishLocal\n\n# on bash\n$ sbt publishLocal\n```\n\nThen you can add the library in the library dependencies as others.\n```scala\nlibraryDependencies += \"csgn\" %% \"lamda-core\" % \"1.0.0-SNAPSHOT\"\n```\n\n## Run Tests\nYou can run all tests as on the following command:\n```bash\n# on interactive sbt shell\nsbt:lamda\u003e tests/test\n\n# on bash\n$ sbt tests/test\n```\n\nIf you want to run specific test:\n```bash\n# on interactive sbt shell\nsbt:lamda\u003e tests/testOnly *FunctorSuite\n\n# on bash\n$ sbt \"tests/testOnly *FunctorSuite\"\n```\n\n## Quick Start\n```scala\nimport lamda._                      // will import all typeclasses\nimport lamda.Functor                // will import Functor typeclass\nimport lamda.syntax.all._           // will import all ops\nimport lamda.syntax.functor._       // will import Functor's ops\nimport lamda.instances.all._        // will import all instances\nimport lamda.instances.list._       // will import list's instances\nimport lamda.implicits._            // will import all ops and instances\n```\n\n```scala\nimport lamda._\nimport lamda.implicits._\n\nscala\u003e List(1, 2, 3).fmap(_ * 2)\nres0: List[Int] = List(2, 4, 6)\n\nscala\u003e Monoid[Option[Int]].combine(Some(1), Some(2))\nres1: Option[Int] = Some(3)\n\nscala\u003e Apply[Option].productR(Some(1), Some(2))\nres2: Option[Int] = Some(2)\n\nscala\u003e Some(1) \u003c* Some(2)\nres3: Option[Int] = Some(1)\n```\n\n\n## Type classes\n```mermaid\nflowchart BT\n    %% Typeclasses\n        Semigroup[\"Semigroup (combine)\"]\n        Monoid[\"Monoid (empty)\"]\n\n        Monad[\"Monad\"]\n\n        Applicative[\"Applicative (pure)\"]\n        FlatMap[\"FlatMap (flatMap)\"]\n\n        Apply[\"Apply (ap)\"]\n\n        Semigroupal[\"Semigroupal (product)\"]\n        Functor[\"Functor (map)\"]\n    %% %\n\n\n\n    %% Relations\n        Monoid --\u003e Semigroup\n\n        Monad --\u003e Applicative \u0026 FlatMap --\u003e Apply --\u003e Semigroupal \u0026 Functor\n    %% %\n```\n\n# License\n```\nMIT License\n\nCopyright (c) 2024 csgn\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcsgn%2Flamda","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcsgn%2Flamda","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcsgn%2Flamda/lists"}