{"id":15755479,"url":"https://github.com/paradite/2-letter-commands","last_synced_at":"2026-01-08T19:03:28.070Z","repository":{"id":73968536,"uuid":"594461312","full_name":"paradite/2-letter-commands","owner":"paradite","description":null,"archived":false,"fork":false,"pushed_at":"2023-01-28T16:35:53.000Z","size":6,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-06T12:33:16.661Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"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/paradite.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-01-28T16:17:32.000Z","updated_at":"2023-10-13T17:47:15.000Z","dependencies_parsed_at":"2023-03-01T05:00:30.499Z","dependency_job_id":null,"html_url":"https://github.com/paradite/2-letter-commands","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/paradite%2F2-letter-commands","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paradite%2F2-letter-commands/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paradite%2F2-letter-commands/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paradite%2F2-letter-commands/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/paradite","download_url":"https://codeload.github.com/paradite/2-letter-commands/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246436380,"owners_count":20776995,"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-10-04T08:22:07.293Z","updated_at":"2026-01-08T19:03:23.038Z","avatar_url":"https://github.com/paradite.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# 2-Letter Commands\n\nI was doing `fg` and `bg` today and got curious on how many valid 2-letter commands are there on a UNIX (macOS) system.\n\nSo I made a command that lists them (to my best knowledge):\n\n```\n$ ls -1 /usr/bin/ /usr/sbin/ /bin/ /sbin/ | awk 'length == 2' | sort\naa\nab\nac\nar\nas\nat\nbc\nbg\ncc\ncd\ncp\ncu\ndc\ndd\ndf\ndu\ned\nex\nfc\nfg\nid\nld\nln\nlp\nls\nm4\nmg\nmv\nnc\nnl\nnm\nod\npl\npp\npr\nps\nri\nrm\nrs\nsa\nsh\nsu\ntr\nul\nvi\nwc\n```\n\nI also counted them:\n\n```\n$ ls -1 /usr/bin/ /usr/sbin/ /bin/ /sbin/ | awk 'length == 2' | sort | wc -l\n      46\n```\n\nThere are 46 of them. 45 if you don't count `m4` which contains a digit not a letter.\n\nTotal number of possible combinations of 2 letters are 26 * 26 = 676.\n\nSo the chance of a random combination being a valid command is 45 / 676 = 6.66%.\n\nThat's pretty high.\n\n---\n\nPRs are welcomed!\n\nA brief explanation of what each of them do would be nice. Some of them can be found [here](https://www.davekb.com/browse_computer_tips:linux_two_letter_commands:txt).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparadite%2F2-letter-commands","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fparadite%2F2-letter-commands","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparadite%2F2-letter-commands/lists"}