{"id":18649686,"url":"https://github.com/manojlds/pslinq","last_synced_at":"2025-04-11T14:32:18.049Z","repository":{"id":19449650,"uuid":"22693799","full_name":"manojlds/pslinq","owner":"manojlds","description":"LINQ (LINQ2Objects) for Powershell","archived":false,"fork":false,"pushed_at":"2020-11-29T21:59:27.000Z","size":263,"stargazers_count":76,"open_issues_count":2,"forks_count":14,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-03-25T14:44:38.500Z","etag":null,"topics":["linq","powershell"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/manojlds.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-08-06T18:38:54.000Z","updated_at":"2025-01-10T05:47:49.000Z","dependencies_parsed_at":"2022-07-10T08:01:03.221Z","dependency_job_id":null,"html_url":"https://github.com/manojlds/pslinq","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/manojlds%2Fpslinq","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/manojlds%2Fpslinq/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/manojlds%2Fpslinq/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/manojlds%2Fpslinq/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/manojlds","download_url":"https://codeload.github.com/manojlds/pslinq/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248419753,"owners_count":21100245,"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":["linq","powershell"],"created_at":"2024-11-07T06:39:54.699Z","updated_at":"2025-04-11T14:32:13.039Z","avatar_url":"https://github.com/manojlds.png","language":"C#","funding_links":[],"categories":["Commandline Productivity"],"sub_categories":[],"readme":"#pslinq\n\nLINQ for Powershell.\n\n##Available cmdlets\n\nThe following cmdlets are available as of now:\n\n[Aggregate-List](#aggregate-list)\n\n[All-List](#all-list)\n\n[Any-List](#any-list)\n\n[Except-List](#except-list)\n\n[First-List](#first-list)\n\n[Intersect-List](#intersect-list)\n\n[Repeat-List](#repeat-list)\n\n[SelectMany-List](#selectmany-list)\n\n[Single-List](#single-list)\n\n[Skip-List](#skip-list)\n\n[SkipWhile-List](#skipwhile-list)\n\n[Take-List](#take-list)\n\n[TakeWhile-List](#takewhile-list)\n\n[Union-List](#union-list)\n\n[Zip-List](#zip-list)\n\nBased on [MoreLinq](https://code.google.com/p/morelinq/wiki/OperatorsOverview):\n\n[TakeEvery-List](#takeevery-list)\n\n\n###Aggregate-List\n\nExamples:\n\nSum:\n\n```powershell\n1..10 | Aggregate-List { $input + $acc} -seed 10\n#65\n```\n\nProduct:\n\n```powershell\n1..10 | Aggregate-List { $acc * $input } -seed 1\n```\n\nString reverse:\n\n```powershell\n\"abcdefg\" -split '' | Aggregate-List { $input + $acc }\n#gfedcba\n```\n\n###All-List\n\nExamples:\n\n```powershell\n1..10 | All-List { $input -le 6 }\n#False\n```\n\n###Any-List\n\nExamples:\n\n```powershell\n1..10 | Any-List { $input -eq 5 }\n#True\n```\n\n###Except-List\n\nExamples:\n\n```powershell\n1..10 | Except-List 1,3,5,7\n#2\n#4\n#6\n#8\n#9\n#10\n```\n\n###First-List\n\nExamples:\n\n```powershell\n1..10 | First-List { $input -eq 5 }\n#5\n1..10 | First-List { $input -eq 11 }\n#Throws exception\n```\n\n###Intersect-List\n\nExample:\n\n```powershell\n1..10 | Intersect-List $(5..15)\n#5\n#6\n#7\n#8\n#9\n#10\n```\n\n###Repeat-List\n\nExample:\n\n```powershell\n1..3 | Repeat-List 2\n#1\n#1\n#2\n#2\n#3\n#3\n```\n\n###SelectMany-List\n\nExample:\n\n```powershell\n\"abc\", \"def\" | SelectMany-List { $input.ToCharArray() }\n#a\n#b\n#c\n#d\n#e\n#f\n```\n\n###Single-List\n\nExample:\n\n```powershell\n1..10 | Single-List { $input -eq 5 }\n#5\n1..10 | Single-List { $input -ge 5 }\n#Throws exception\n1..10 | Single-List { $input -eq 11 }\n#Throws exception\n```\n\n###Skip-List\n\nExample:\n\n```powershell\n1..10 | Skip-List 6\n#7\n#8\n#9\n#10\n```\n\n###SkipWhile-List\n\nExample:\n\n```powershell\n1..10 | SkipWhile-List { $input -le 8 }\n#9\n#10\n```\n\n###Take-List\n\nExample:\n\n```powershell\n1..10 | Take-List 3\n#1\n#2\n#3\n\n1..10 | Skip-List 3 | Take-List 3\n#4\n#5\n#6\n```\n\n###TakeWhile-List\n\nExample:\n\n```powershell\n1..10 | TakeWhile-List { $input -lt 4 }\n#1\n#2\n#3\n```\n\n###Union-List\n\nExample:\n\n```powershell\n\"a\", \"b\", \"c\" | Union-List \"c\", \"d\"\n#a\n#b\n#c\n#d\n```\n\n###Zip-List\n\nExample:\n\n```powershell\n\"a\", \"b\", \"c\" | Zip-List $(1..4) { $first + $second }\n#a1\n#b2\n#c3\n\n\"a\", \"b\", \"c\" | Zip-List $(1..3) { $first * $second }\n#a\n#bb\n#ccc\n```\n\n##Based on MoreLinq:\n\n###TakeEvery-List\n\n```powershell\n1..10 | TakeEvery-List 2\n#2\n#4\n#6\n#8\n#10\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmanojlds%2Fpslinq","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmanojlds%2Fpslinq","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmanojlds%2Fpslinq/lists"}