{"id":13394795,"url":"https://github.com/chubin/cheat.sh","last_synced_at":"2026-03-01T09:33:51.731Z","repository":{"id":37561765,"uuid":"90563585","full_name":"chubin/cheat.sh","owner":"chubin","description":"the only cheat sheet you need","archived":false,"fork":false,"pushed_at":"2025-08-01T10:34:23.000Z","size":4713,"stargazers_count":39745,"open_issues_count":136,"forks_count":1838,"subscribers_count":580,"default_branch":"master","last_synced_at":"2025-08-01T12:51:11.104Z","etag":null,"topics":["cheatsheet","cli","command-line","curl","documentation","examples","hacktoberfest2021","help","terminal","tldr"],"latest_commit_sha":null,"homepage":"https://cheat.sh/","language":"Python","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/chubin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","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,"zenodo":null}},"created_at":"2017-05-07T21:40:56.000Z","updated_at":"2025-08-01T11:19:16.000Z","dependencies_parsed_at":"2022-07-11T03:00:24.337Z","dependency_job_id":"34adb094-6f89-4e2a-8e29-b9b6d486295c","html_url":"https://github.com/chubin/cheat.sh","commit_stats":{"total_commits":738,"total_committers":60,"mean_commits":12.3,"dds":0.4092140921409214,"last_synced_commit":"571377f2f79422398a701cb1864487124ec3dcc6"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/chubin/cheat.sh","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chubin%2Fcheat.sh","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chubin%2Fcheat.sh/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chubin%2Fcheat.sh/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chubin%2Fcheat.sh/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chubin","download_url":"https://codeload.github.com/chubin/cheat.sh/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chubin%2Fcheat.sh/sbom","scorecard":{"id":281864,"data":{"date":"2025-08-11","repo":{"name":"github.com/chubin/cheat.sh","commit":"b714a5f0d56427924a7871f083fd05e7ede6b0e4"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.4,"checks":[{"name":"Maintained","score":7,"reason":"8 commit(s) and 1 issue activity found in the last 90 days -- score normalized to 7","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":3,"reason":"Found 7/19 approved changesets -- score normalized to 3","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/tests-macos.yml:1","Warn: no topLevel permission defined: .github/workflows/tests-ubuntu.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/tests-macos.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/chubin/cheat.sh/tests-macos.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/tests-ubuntu.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/chubin/cheat.sh/tests-ubuntu.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/tests-ubuntu.yml:29: update your workflow using https://app.stepsecurity.io/secureworkflow/chubin/cheat.sh/tests-ubuntu.yml/master?enable=pin","Warn: containerImage not pinned by hash: Dockerfile:1: pin your Docker image by updating alpine:3.14 to alpine:3.14@sha256:0f2d5c38dd7a4f4f733e688e3a6733cb5ab1ac6e3cb4603a5dd564e5bfb80eed","Warn: pipCommand not pinned by hash: Dockerfile:10-13","Warn: pipCommand not pinned by hash: Dockerfile:10-13","Warn: pipCommand not pinned by hash: .github/workflows/tests-ubuntu.yml:19","Info:   0 out of   3 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   3 pipCommand dependencies pinned","Info:   0 out of   1 containerImage dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 19 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"14 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: PYSEC-2024-48 / GHSA-fj7x-q9j7-g6q6","Warn: Project is vulnerable to: PYSEC-2018-66 / GHSA-562c-5r94-xh97","Warn: Project is vulnerable to: PYSEC-2019-179 / GHSA-5wv5-4vpf-pj6m","Warn: Project is vulnerable to: PYSEC-2023-62 / GHSA-m2qf-hxjv-5gpq","Warn: Project is vulnerable to: PYSEC-2023-177 / GHSA-x7m3-jprg-wc5g","Warn: Project is vulnerable to: PYSEC-2023-117 / GHSA-mrwq-x4v8-fh7p","Warn: Project is vulnerable to: PYSEC-2021-142 / GHSA-8q59-q68h-6hv4","Warn: Project is vulnerable to: PYSEC-2018-49 / GHSA-rprw-h62v-c2w7","Warn: Project is vulnerable to: PYSEC-2014-14 / GHSA-652x-xj99-gmcc","Warn: Project is vulnerable to: GHSA-9hjg-9r4m-mvj7","Warn: Project is vulnerable to: GHSA-9wx4-h78v-vm56","Warn: Project is vulnerable to: PYSEC-2014-13 / GHSA-cfj3-7x9c-4p3h","Warn: Project is vulnerable to: PYSEC-2018-28 / GHSA-x84v-xcm2-53pg","Warn: Project is vulnerable to: PYSEC-2022-43017 / GHSA-qwmp-2cf2-g9g6"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-17T16:05:25.601Z","repository_id":37561765,"created_at":"2025-08-17T16:05:25.602Z","updated_at":"2025-08-17T16:05:25.602Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29965664,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-01T09:33:09.965Z","status":"ssl_error","status_checked_at":"2026-03-01T09:25:48.915Z","response_time":124,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["cheatsheet","cli","command-line","curl","documentation","examples","hacktoberfest2021","help","terminal","tldr"],"created_at":"2024-07-30T17:01:31.821Z","updated_at":"2026-03-01T09:33:51.717Z","avatar_url":"https://github.com/chubin.png","language":"Python","readme":"\n\n![cheat.sh logo](http://cheat.sh/files/big-logo-v2-fixed.png)\n\nUnified access to the best community driven cheat sheets repositories of the world.\n\nLet's imagine for a moment that there is such a thing as an ideal cheat sheet.\nWhat should it look like?\nWhat features should it have?\n\n* **Concise** — It should only contain the things you need, and nothing else.\n* **Fast** — It should be possible to use it instantly.\n* **Comprehensive** — It should contain answers for every possible question.\n* **Universal** — It should be available everywhere, anytime, without any preparations.\n* **Unobtrusive** — It should not distract you from your main task.\n* **Tutoring** — It should help you to learn the subject.\n* **Inconspicuous** — It should be possible to use it completely unnoticed.\n\nSuch a thing exists! It's easy to [install](#installation) and there's even [auto-complete](#tab-completion).\n\n\n## Features\n\n**cheat.sh**\n\n* Has a simple curl/browser/editor interface.\n* Covers 56 programming languages, several DBMSes, and more than 1000 most important UNIX/Linux commands.\n* Provides access to the best community driven cheat sheets repositories in the world, on par with StackOverflow.\n* Available everywhere, no installation needed, but can be installed for offline usage.\n* Ultrafast, returns answers within 100 ms, as a rule.\n* Has a convenient command line client, `cht.sh`, that is very advantageous and helpful, though not mandatory.\n* Can be used directly from code editors, without opening a browser and not switching your mental context.\n* Supports a special stealth mode where it can be used fully invisibly without ever touching a key and making sounds.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src='https://cheat.sh/files/demo-curl.gif'/\u003e\n\u003c/p\u003e\n\n## Contents\n\n* [Features](#features)\n* [Usage](#usage)\n* [Command line client, cht.sh](#command-line-client-chtsh)\n  * [Installation](#installation)\n  * [Client usage](#client-usage)\n  * [Tab-completion](#tab-completion)\n    - [Bash Tab completion](#bash-tab-completion)\n    - [ZSH Tab completion](#zsh-tab-completion)\n  * [Stealth mode](#stealth-mode)\n  * [Windows command line client](#windows-command-line-client)\n* [Self-Hosting](#self-hosting)\n  * [Docker](#docker)\n* [Editors integration](#editors-integration)\n  * [Vim](#vim)\n  * [Emacs](#emacs)\n  * [Visual Studio Code](#visual-studio-code)\n  * [Sublime](#sublime)\n  * [IntelliJ IDEA](#intellij-idea)\n  * [QT Creator](#qtcreator)\n* [Special pages](#special-pages)\n* [Search](#search)\n* [Programming languages cheat sheets](#programming-languages-cheat-sheets)\n* [Cheat sheets sources](#cheat-sheets-sources)\n* [How to contribute](#how-to-contribute)\n  * [How to edit a cheat sheet](#how-to-edit-a-cheat-sheet)\n  * [How to add a cheat sheet](#how-to-add-a-cheat-sheet)\n  * [How to add a cheat sheet repository](#how-to-add-a-cheat-sheet-repository)\n\n## Usage\n\nTo get a cheat sheet for a UNIX/Linux command from a command line, query the service using `curl` or any other HTTP/HTTPS client\nspecifying the name of the command in the query:\n\n```\n    curl cheat.sh/tar\n    curl cht.sh/curl\n    curl https://cheat.sh/rsync\n    curl https://cht.sh/tr\n```\nAs you can see, you can use both HTTPS and HTTP to access the service, and both the long (cheat.sh) and the short (cht.sh) service names.\n\nHere `tar`, `curl`, `rsync`, and `tr` are names of the UNIX/Linux commands you want to get cheat sheets for.\n\nIf you don't know the name of the command you need, you can search for it using the `~KEYWORD` notation.\nFor example, to see how you can make `snapshots` of a filesystem/volume/something else:\n```\n    curl cht.sh/~snapshot\n```\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src='https://cheat.sh/files/cht.sh-url-structure.png'/\u003e\n\u003c/p\u003e\n\nThe programming language cheat sheets are located in special namespaces dedicated to them.\n\n```\n    curl cht.sh/go/Pointers\n    curl cht.sh/scala/Functions\n    curl cht.sh/python/lambda\n```\n\nTo get the list of available programming language cheat sheets, use the special query `:list`:\n\n```\n    curl cht.sh/go/:list\n```\n\nAlmost each programming language has a special page named `:learn`\nthat describes the language basics (that's a direct mapping from the *\"Learn X in Y\"* project).\nIt could be a good starting point if you've just started learning a language.\n\nIf there is no cheat sheet for a programming language query (and it is almost always the case),\nit is generated on the fly, based on available cheat sheets and answers on StackOverflow.\nOf course, there is no guarantee that the returned cheat sheet will be a 100% hit, but it is almost always exactly what you are looking for.\n\nTry these (and your own) queries to get the impression of that, what the answers look like:\n```\n    curl cht.sh/go/reverse+a+list\n    curl cht.sh/python/random+list+elements\n    curl cht.sh/js/parse+json\n    curl cht.sh/lua/merge+tables\n    curl cht.sh/clojure/variadic+function\n```\n\nIf you don't like an answer for your queries, you can pick another one. For that, repeat the query with an additional parameter `/1`, `/2` etc. appended:\n\n```\n    curl cht.sh/python/random+string\n    curl cht.sh/python/random+string/1\n    curl cht.sh/python/random+string/2\n```\n\nCheat sheets are formatted as code of the queried programming language (at least we are trying our best to do so)\nso they can be pasted into a program in this language directly. Text comments, if there are any, are formatted according to the language syntax.\n\n```lua\n    $ curl cht.sh/lua/table+keys\n    -- lua: retrieve list of keys in a table\n\n    local keyset={}\n    local n=0\n\n    for k,v in pairs(tab) do\n      n=n+1\n      keyset[n]=k\n    end\n\n    --[[\n       [ Note that you cannot guarantee any order in keyset. If you want the\n       [ keys in sorted order, then sort keyset with table.sort(keyset).\n       [ \n       [ [lhf] [so/q/12674345] [cc by-sa 3.0]\n       ]]\n\n```\n\nIf you don't need text comments in the answer, you can eliminate them\nusing a special option `\\?Q`:\n```lua\n    $ curl cht.sh/lua/table+keys\\?Q\n    local keyset={}\n    local n=0\n\n    for k,v in pairs(tab) do\n      n=n+1\n      keyset[n]=k\n    end\n```\n\nAnd if you don't need syntax highlighting, switch it off using `\\?T`.\nYou can combine the options together:\n\n```\n    curl cht.sh/go/reverse+a+list\\?Q\n    curl cht.sh/python/random+list+elements\\?Q\n    curl cht.sh/js/parse+json\\?Q\n    curl cht.sh/lua/merge+tables\\?QT\n    curl cht.sh/clojure/variadic+function\\?QT\n```\n\nFull list of all options described below and in `/:help`.\n\nTry your own queries. Follow these rules:\n\n1. Try to be more specific (`/python/append+file` is better than `/python/file` and `/python/append`).\n2. Ask practical question if possible (yet theoretical question are possible too).\n3. Ask programming language questions only; specify the name of the programming language as the section name.\n4. Separate words with `+` instead of spaces.\n5. Do not use special characters, they are ignored anyway.\n6. If you want to eliminate cheat sheets containing some word, add it to the query with `+-`: `python/multiply+matrices+-numpy`\n\nRead more about the programming languages queries below.\n\n----\n\n## Command line client, cht.sh\n\nThe cheat.sh service has its own command line client (`cht.sh`) that\nhas several useful features compared to querying the service directly with `curl`:\n\n* Special shell mode with a persistent queries context and readline support.\n* Queries history.\n* Clipboard integration.\n* Tab completion support for shells (bash, fish, zsh).\n* Stealth mode.\n\n### Installation\n\nTo install the client:\n\n```bash\nPATH_DIR=\"$HOME/bin\"  # or another directory on your $PATH\nmkdir -p \"$PATH_DIR\"\ncurl https://cht.sh/:cht.sh \u003e \"$PATH_DIR/cht.sh\"\nchmod +x \"$PATH_DIR/cht.sh\"\n```\n\nor to install it globally (for all users):\n\n```bash\ncurl -s https://cht.sh/:cht.sh | sudo tee /usr/local/bin/cht.sh \u0026\u0026 sudo chmod +x /usr/local/bin/cht.sh\n```\n\nNote: The package \"rlwrap\" is a required dependency to run in shell mode. Install this using `sudo apt install rlwrap`\n\n### Client usage\n\nNow, you can use `cht.sh` instead of `curl`, and write your queries in more natural way,\nwith spaces instead of `+`:\n\n```\n    $ cht.sh go reverse a list\n    $ cht.sh python random list elements\n    $ cht.sh js parse json\n```\n\nIt is even more convenient to start the client in a special shell mode:\n```\n    $ cht.sh --shell\n    cht.sh\u003e go reverse a list\n```\n\nIf all your queries are about the same language, you can change the context\nand spare repeating the programming language name:\n```\n    $ cht.sh --shell\n    cht.sh\u003e cd go\n    cht.sh/go\u003e reverse a list\n```\nor even start the client in this context:\n```\n    $ cht.sh --shell go\n    cht.sh/go\u003e reverse a list\n    ...\n    cht.sh/go\u003e join a list\n    ...\n```\n\nIf you want to change the context, you can do it with the `cd` command,\nor if you want do a single query for some other language, just prepend it with `/`:\n\n```\n    $ cht.sh --shell go\n    ...\n    cht.sh/go\u003e /python dictionary comprehension\n    ...\n```\n\nIf you want to copy the last answer into the clipboard, you can\nuse the `c` (`copy`) command, or `C` (`ccopy`, without comments).\n\n```\n    cht.sh/python\u003e append file\n    #  python - How do you append to a file?\n\n    with open(\"test.txt\", \"a\") as myfile:\n        myfile.write(\"appended text\")\n    cht.sh/python\u003e C\n    copy: 2 lines copied to the selection\n```\n\nType `help` for other internal `cht.sh` commands.\n\n```\n\tcht.sh\u003e help\n\thelp    - show this help\n\thush    - do not show the 'help' string at start anymore\n\tcd LANG - change the language context\n\tcopy    - copy the last answer in the clipboard (aliases: yank, y, c)\n\tccopy   - copy the last answer w/o comments (cut comments; aliases: cc, Y, C)\n\texit    - exit the cheat shell (aliases: quit, ^D)\n\tid [ID] - set/show an unique session id (\"reset\" to reset, \"remove\" to remove)\n\tstealth - stealth mode (automatic queries for selected text)\n\tupdate  - self update (only if the scriptfile is writeable)\n\tversion - show current cht.sh version\n\t/:help  - service help\n\tQUERY   - space separated query staring (examples are below)\n\t\t\t\t  cht.sh\u003e python zip list\n\t\t\t\t  cht.sh/python\u003e zip list\n\t\t\t\t  cht.sh/go\u003e /python zip list\n```\n\nThe `cht.sh` client has its configuration file which is located at `~/.cht.sh/cht.sh.conf`\n(location of the file can be overridden by the environment variable `CHTSH_CONF`).\nUse it to specify query options that you would use with each query.\nFor example, to switch syntax highlighting off create the file with the following\ncontent:\n\n```bash\nCHTSH_QUERY_OPTIONS=\"T\"\n```\n\nOr if you want to use a special syntax highlighting theme:\n\n```bash\nCHTSH_QUERY_OPTIONS=\"style=native\"\n```\n\n(`curl cht.sh/:styles-demo` to see all supported styles).\n\nOther cht.sh configuration parameters:\n\n```bash\nCHTSH_CURL_OPTIONS=\"-A curl\"        # curl options used for cht.sh queries\nCHTSH_URL=https://cht.sh            # URL of the cheat.sh server\n```\n\n### Tab completion\n\n\n#### Bash Tab completion\n\nTo activate tab completion support for `cht.sh`, add the `:bash_completion` script to your `~/.bashrc`:\n\n```bash\n    curl https://cheat.sh/:bash_completion \u003e ~/.bash.d/cht.sh\n    . ~/.bash.d/cht.sh\n    # and add . ~/.bash.d/cht.sh to ~/.bashrc\n```\n\n#### ZSH Tab completion\n\nTo activate tab completion support for `cht.sh`, add the `:zsh` script to the *fpath* in your `~/.zshrc`:\n\n```zsh\n    curl https://cheat.sh/:zsh \u003e ~/.zsh.d/_cht\n    echo 'fpath=(~/.zsh.d/ $fpath)' \u003e\u003e ~/.zshrc\n    # Open a new shell to load the plugin\n```\n\n----\n\n### Stealth mode\n\nBeing used fully unnoticed is one of the most important property of any cheat sheet.\n\ncheat.sh can be used completely unnoticed too. The cheat.sh client, `cht.sh`, has\na special mode, called **stealth mode**. Using that, you don't even need to touch your\nkeyboard to open a cheat sheet.\n\nIn this mode, as soon as you select some text with the mouse (and thus adding it\ninto the selection buffer of X Window System or into the clipboard) it's used\nas a query string for cheat.sh, and the correspondent cheat sheet is automatically shown.\n\nLet's imagine, that you are having an online interview, where your interviewer asks you\nsome questions using a shared document (say Google Docs) and you are supposed\nto write your coding answers there (it's possible too that you'll type in the questions\non your own, just to show to the interviewer that you've heard it right).\n\nWhen using the stealth mode of `cht.sh`, the only thing you need to do in order to see\na cheat sheet for some question, is to select the question using the mouse.\nIf you don't want any text in the answers and the only thing you need is code,\nuse the `Q` option when starting the stealth mode.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src='https://cheat.sh/files/stealth-mode.gif'/\u003e\n\u003c/p\u003e\n\n```\nYou: Hi!                                            | $ cht.sh --shell python\nShe: Hi!                                            | cht.sh/python\u003e stealth Q\nShe: Are you ready for a small interview?           | stealth: you are in the stealth mode; select any text\nShe: Just a couple of questions                     | stealth: selections longer than 5 words are ignored\nShe: We will talk about python                      | stealth: query arguments: ?Q\nShe: Let's start from something simple.             | stealth: use ^C to leave this mode\nShe: Do you know how to reverse a list in python?   |\nYou: Sure                                           |\nYou: (selecting \"reverse a list\")                   | stealth: reverse a list\n                                                    | reverse_lst = lst[::-1]\nYou: lst[::-1]?                                     |\nShe: Good.                                          |\nShe: Do you know how to chain a list of lists?      |\nYou: (selecting \"chain a list of lists\")            | stealth: chain a list of lists\n                                                    | import itertools\n                                                    | a = [[\"a\",\"b\"], [\"c\"]]\n                                                    | print list(itertools.chain.from_iterable(a))\nYou: May I use external modules?                    |\nShe: What module do you want to use?                |\nYou: itertools                                      |\nShe: Yes, you may use it                            |\nYou: Ok, then:                                      |\nYou: itertools.chain.from_iterable(a)               |\nShe: Good. Let's try something harder.              |\nShe: What about quicksort implementation?           |\nYou: (selecting \"quicksort implementation\")         | stealth: quicksort implementation\nYou: Let me think about it.                         | (some big and clumsy lowlevel implementation shown)\nYou: Well...(starting typing it in)                 | def sort(array=[12,4,5,6,7,3,1,15]):\n                                                    |     less = []\nShe: (seeing your ugly pascal style)                |     equal = []\nShe: Could you write it more concise?               |     greater = []\n                                                    |     if len(array) \u003e 1:\nYou: What do you mean?                              |         pivot = array[0]\n                                                    |         for x in array:\nShe: I mean,                                        |             if x \u003c pivot: less.append(x)\nShe: do you really need all these ifs and fors?     |             if x == pivot: equal.append(x)\nShe: Could you maybe just use filter instead?       |             if x \u003e pivot: greater.append(x)\n                                                    |         return sort(less)+equal+sort(greater)\nYou: quicksort with filter?                         |     else:\n                                                    |         return array\nShe: Yes                                            |\nYou: (selecting \"quicksort with filter\")            | stealth: quicksort with filter\nYou: Ok, I will try.                                | return qsort(filter(lt, L[1:]))+[pivot] \\\nYou: Something like this?                           |     +qsort(filter(ge, L[1:]))\nYou: qsort(filter(lt, L[1:]))+[pivot] \\             |\n       + qsort(filter(ge, L[1:]))                   |\n                                                    |\nShe: Yes! Perfect! Exactly what I wanted to see!    |\n                                                    |\n\n```\n\nOf course, this is just for fun, and you should never cheat in your coding interviews,\nbecause you know what happens when you do.\n\n![when you lie in your interview](http://cheat.sh/files/when-you-lie-katze.png)\n\n### Windows command line client\n\nYou can access cheat.sh from Windows command line too.\n\nUse cheat.sh command line client for that: [`cht.exe`](https://github.com/tpanj/cht.exe).\nIt supports:\n\n* output colorization;\n* command line options;\n* its own configuration file.\n\nYou can also use [`scoop`](https://github.com/lukesampson/scoop) command-line installer for Windows to get it:\n```batch\nscoop install cht\n```\n\n----\n\n## Self-Hosting\n\n### Docker\n\nCurrently, the easiest way to get a self-hosted instance running is by using\nthe `docker-compose.yml` file.\n\n    docker-compose up\n\nThis builds and runs the image with baked in cheatsheets and starts the app\nand a Redis instance to back it, making the service available at\nhttp://localhost:8002 This is currently an early implementation and should\nprobably not be used for anything outside of internal/dev/personal use right\nnow.\n\n## Editors integration\n\nYou can use *cheat.sh* directly from the editor\n(*Emacs*, *Sublime*, *Vim*, and *Visual Studio Code* are currently supported;\nnot all features are supported by all plugins though; see below).\nInstead of opening your browser, googling, browsing Stack Overflow\nand eventually copying the code snippets you need into the clipboard\nand later pasting them into the editor,\nyou can achieve the same instantly and without leaving the editor at all!\n\nHere is what it looks like in Vim:\n\n1. If you have a question while editing a program, you can just type\nyour question directly in the buffer and press `\u003cleader\u003eKK`. You will get\nthe answer to your question in pager. (with `\u003cleader\u003eKB` you'll get the answer\nin a separate buffer).\n\n2. If you like the answer, you can manually paste it from the buffer or\nthe pager, or if you are lazy you can use `\u003cleader\u003eKP` to paste it below/under\nyour question (or replace you question using `\u003cleader\u003eKR`). If you want the\nanswer without the comments, `\u003cleader\u003eKC` replays the last query\ntoggling them.\n\nIf you use some static analysis plugin such as *syntastic* (for Vim), you can use\nits warning and error messages as cheat.sh queries: place the cursor on the problem line\nand press `\u003cleader\u003eKE`: explanation for the warning will be opened in a new buffer.\n\nFeatures supported by cheat.sh plugins for different editors:\n\n|Feature            |Emacs|Sublime|Vim|VSCode|IDEA|QtCreator|\n|-------------------|-----|-------|---|------|----|---------|\n|Command queries    |✓    |✓      |✓  |✓     |✓   |✓        |\n|Queries from buffer|     |       |✓  |✓     |    |✓        |\n|Toggle comments    |     |       |✓  |✓     |✓   |✓        |\n|Prev/next answer   |     |       |✓  |✓     |✓   |✓        |\n|Multiple answers   |     |✓      |   |      |✓   |         |\n|Warnings as queries|     |       |✓  |      |    |         |\n|Queries history    |     |       |✓  |✓     |    |         |\n|Session id         |     |       |✓  |      |    |         |\n|Configurable server|✓    |       |✓  |✓     |    |✓        |\n\n### Vim\n\n* [cheat.sh-vim](https://github.com/dbeniamine/cheat.sh-vim) — Vim support\n\nHere is Vim configuration example:\n\n```vim\n\" some configuration above ...\n\nlet mapleader=\" \"\n\ncall vundle#begin()\nBundle 'gmarik/vundle'\nBundle 'scrooloose/syntastic'\nBundle 'dbeniamine/cheat.sh-vim'\ncall vundle#end()\n\nlet g:syntastic_javascript_checkers = [ 'jshint' ]\nlet g:syntastic_ocaml_checkers = ['merlin']\nlet g:syntastic_python_checkers = ['pylint']\nlet g:syntastic_shell_checkers = ['shellcheck']\n\n\" some configuration below ...\n```\n\nIn this example, several Vim plugins are used:\n\n* [gmarik/vundle](https://github.com/VundleVim/Vundle.vim) — Vim plugin manager\n* [scrooloose/syntastic](https://github.com/vim-syntastic/syntastic) — Syntax checking plugin\n* [cheat.sh-vim](https://github.com/dbeniamine/cheat.sh-vim) — Vim support\n\nSyntastic shows warnings and errors (found by code analysis tools: `jshint`, `merlin`, `pylint`, `shellcheck` etc.),\nand `cheat.sh-vim` shows you explanations for the errors and warnings\nand answers on programming languages queries written in the editor.\n\nWatch a demo, where the most important features of the cheat.sh Vim plugin are shown (5 Min):\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src='https://cheat.sh/files/vim-demo.gif'/\u003e\n\u003c/p\u003e\n\nOr, if you want to scroll and/or pause, the same on YouTube:\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"http://www.youtube.com/watch?feature=player_embedded\u0026v=xyf6MJ0y-z8\n  \" target=\"_blank\"\u003e\u003cimg src=\"http://img.youtube.com/vi/xyf6MJ0y-z8/0.jpg\" \n  alt=\"cheat.sh-vim: Using cheat.sh from vim\" width=\"700\" height=\"490\" border=\"10\" /\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003c!-- [![asciicast](https://asciinema.org/a/c6QRIhus7np2OOQzmQ2RNXzRZ.png)](https://asciinema.org/a/c6QRIhus7np2OOQzmQ2RNXzRZ) --\u003e\n\n### Emacs\n\n* [cheat-sh.el](https://github.com/davep/cheat-sh.el) — Emacs support (available also at cheat.sh/:emacs)\n* cheat.sh/:emacs-ivy — Emacs support for ivy users\n\n[![asciicast](https://asciinema.org/a/3xvqwrsu9g4taj5w526sb2t35.png)](https://asciinema.org/a/3xvqwrsu9g4taj5w526sb2t35)\n\n\n### Visual Studio Code\n\n* [vscode-snippet](https://github.com/mre/vscode-snippet)\n* Install it from [VSCode Marketplace](https://marketplace.visualstudio.com/items?itemName=vscode-snippet.Snippet)\n\nUsage: \n\n1. Hit \u003ckbd\u003e⌘ Command\u003c/kbd\u003e + \u003ckbd\u003e⇧ Shift\u003c/kbd\u003e + \u003ckbd\u003ep\u003c/kbd\u003e\n2. Run `Snippet: Find`.\n3. Type your query and hit enter.\n\n[![vscode-snippet](https://cheat.sh/files/vscode-snippet-demo.gif)](https://github.com/mre/vscode-snippet)\n\n*(GIF courtesy: Matthias Endler, @mre)*\n\n### Sublime\n\n* [cheat.sh-sublime-plugin](https://github.com/gauravk-in/cheat.sh-sublime-plugin/)\n\nUsage:\n\n1.  Write your query string.\n2.  Select the query string.\n3.  Press \u003ckbd\u003eCmd\u003c/kbd\u003e + \u003ckbd\u003e⇧ Shift\u003c/kbd\u003e + \u003ckbd\u003eB\u003c/kbd\u003e to replace the selected query string by the answer generated from `cht.sh`.\n\n[![cheat.sh-sublime-plugin-demo](https://cheat.sh/files/demo-sublime.gif)](https://github.com/gauravk-in/cheat.sh-sublime-plugin)\n\n*(GIF courtesy: Gaurav Kukreja, @gauravk-in)*\n\n### IntelliJ IDEA \n\n* [idea-cheatsh-plugin](https://github.com/szymonprz/idea-cheatsh-plugin)\n* Install from [idea plugins marketplace](https://plugins.jetbrains.com/plugin/11942-cheat-sh-code-snippets) \n\nUsage: \n\n1. Write query string\n2. Select the query string\n3. Press keyboard shortcut \u003ckbd\u003eAlt\u003c/kbd\u003e + \u003ckbd\u003eC\u003c/kbd\u003e , \u003ckbd\u003eS\u003c/kbd\u003e to replace the selected query string by the answer\n\n[![idea-cheatsh-plugin](https://cheat.sh/files/idea-demo.gif)](https://github.com/szymonprz/idea-cheatsh-plugin)\n\n*(GIF courtesy: Szymon Przebierowski, @szymonprz)*\n\n### QtCreator\n\n* [cheatsh-qtcreator](https://github.com/pozemka/cheatsh-qtcreator)\n\nCurrent features:\n\n*    search word under cursor\n*    search selected\n*    query search\n*    disable comments\n*    paste answer (?TQ version)\n*    custom server URL\n*    custom search context (default is cpp)\n*    hotkeys and menu\n\n[![cheatsh-qtcreator](https://user-images.githubusercontent.com/1259724/73876361-ecce5d00-4867-11ea-9f75-c5b127a9739c.gif)](https://github.com/pozemka/cheatsh-qtcreator)\n\n*(GIF courtesy: Pozemka, @pozemka)*\n\n## Special pages\n\nThere are several special pages that are not cheat sheets.\nTheir names start with colon and have special meaning.\n\n\nGetting started:\n\n```\n    :help               description of all special pages and options\n    :intro              cheat.sh introduction, covering the most important usage questions\n    :list               list all cheat sheets (can be used in a subsection too: /go/:list)\n```\n\nCommand line client `cht.sh` and shells support:\n```\n    :cht.sh             code of the cht.sh client\n    :bash_completion    bash function for tab completion\n    :bash               bash function and tab completion setup\n    :fish               fish function and tab completion setup\n    :zsh                zsh function and tab completion setup\n```\n\nEditors support:\n\n```\n    :vim                cheat.sh support for Vim\n    :emacs              cheat.sh function for Emacs\n    :emacs-ivy          cheat.sh function for Emacs (uses ivy)\n```\n\nOther pages:\n\n```\n    :post               how to post new cheat sheet\n    :styles             list of color styles\n    :styles-demo        show color styles usage examples\n    :random             fetches a random page (can be used in a subsection too: /go/:random)\n```\n\n## Search\n\nTo search for a keyword, use the query:\n\n```\n    /~keyword\n```\n\nIn this case search is not recursive — it is conducted only in a page of the specified level.\nFor example:\n\n```\n    /~snapshot          look for snapshot in the first level cheat sheets\n    /scala/~currying     look for currying in scala cheat sheets\n```\n\nFor a recursive search in all cheat sheets, use double slash:\n\n```\n    /~snapshot/r         look for snapshot in all cheat sheets\n```\n\nYou can use special search options after the closing slash:\n\n```\n    /~shot/bi           case insensitive (i), word boundaries (b)\n```\n\nList of search options:\n\n```\n    i   case insensitive search\n    b   word boundaries\n    r   recursive search\n```\n\n## Programming languages cheat sheets\n\nCheat sheets related to programming languages\nare organized in namespaces (subdirectories), that are named according\nto the programming language.\n\nFor each supported programming language\nthere are several special cheat sheets: its own sheet, `hello`, `:list` and `:learn`.\nSay for lua it will look like:\n\n```\n    lua\n    lua/hello\n    lua/:list\n    lua/:learn\n```\n\nSome languages has the one-liners-cheat sheet, `1line`:\n\n```\n    perl/1line\n```\n* `hello` describes how you can start with the language — install it if needed, build and run its programs, and it shows the \"Hello world\" program written in the language;\n* `:list` shows all topics related to the language\n* `:learn` shows a learn-x-in-minutes language cheat sheet perfect for getting started with the language.\n* `1line` is a collection of one-liners in this language\n* `weirdness` is a collection of examples of weird things in this language\n\n![cheat.sh usage](http://cheat.sh/files/supported-languages-c++.png)\n\nAt the moment, cheat.sh covers the 58 following programming languages (alphabetically sorted):\n\n|Prefix     |Language  |Basics|One-liners|Weirdness|StackOverflow|\n|-----------|----------|------|----------|---------|-------------|\n|`arduino/` |Arduino   |      |          |         |✓            |\n|`assembly/`|Assembly  |      |          |         |✓            |\n|`awk/`     |AWK       |✓     |          |         |✓            |\n|`bash/`    |Bash      |✓     |          |         |✓            |\n|`basic/`   |BASIC     |      |          |         |✓            |\n|`bf/`      |Brainfuck |✓     |          |         |✓            |\n|`c/`       |C         |✓     |          |         |✓            |\n|`chapel/`  |Chapel    |✓     |          |         |✓            |\n|`clean/`   |Clean     |      |          |         |✓            |\n|`clojure/` |Clojure   |✓     |          |         |✓            |\n|`coffee/`  |CoffeeScript|✓   |          |         |✓            |\n|`cpp/`     |C++       |✓     |          |         |✓            |\n|`csharp/`  |C#        |✓     |          |         |✓            |\n|`d/`       |D         |✓     |          |         |✓            |\n|`dart/`    |Dart      |✓     |          |         |✓            |\n|`delphi/`  |Dephi     |      |          |         |✓            |\n|`dylan/`   |Dylan     |✓     |          |         |✓            |\n|`eiffel/`  |Eiffel    |      |          |         |✓            |\n|`elixir/`  |Elixir    |✓     |          |         |✓            |\n|`elisp/`   |ELisp     |✓     |          |         |✓            |\n|`elm/`     |Elm       |✓     |          |         |✓            |\n|`erlang/`  |Erlang    |✓     |          |         |✓            |\n|`factor/`  |Factor    |✓     |          |         |✓            |\n|`fortran/` |Fortran   |✓     |          |         |✓            |\n|`forth/`   |Forth     |✓     |          |         |✓            |\n|`fsharp/`  |F#        |✓     |          |         |✓            |\n|`go/`      |Go        |✓     |          |         |✓            |\n|`groovy/`  |Groovy    |✓     |          |         |✓            |\n|`haskell/` |Haskell   |✓     |          |         |✓            |\n|`java/`    |Java      |✓     |          |         |✓            |\n|`js/`      |JavaScript|✓     |✓         |✓        |✓            |\n|`julia/`   |Julia     |✓     |          |         |✓            |\n|`kotlin/`  |Kotlin    |✓     |          |         |✓            |\n|`latex/`   |LaTeX     |✓     |          |         |✓            |\n|`lisp/`    |Lisp      |✓     |          |         |✓            |\n|`lua/`     |Lua       |✓     |          |         |✓            |\n|`matlab/`  |MATLAB    |✓     |          |         |✓            |\n|`nim/`     |Nim       |✓     |          |         |✓            |\n|`ocaml/`   |OCaml     |✓     |          |         |✓            |\n|`octave/`  |Octave    |✓     |          |         |✓            |\n|`perl/`    |Perl      |✓     |✓         |         |✓            |\n|`perl6/`   |Perl 6    |✓     |✓         |         |✓            |\n|`php/`     |PHP       |✓     |          |         |✓            |\n|`pike/`    |Pike      |      |          |         |✓            |\n|`python/`  |Python    |✓     |✓         |         |✓            |\n|`python3/` |Python 3  |✓     |          |         |✓            |\n|`r/`       |R         |✓     |          |         |✓            |\n|`racket/`  |Racket    |✓     |          |         |✓            |\n|`ruby/`    |Ruby      |✓     |          |         |✓            |\n|`rust/`    |Rust      |✓     |          |         |✓            |\n|`scala/`   |Scala     |✓     |          |         |✓            |\n|`scheme/`  |Scheme    |✓     |          |         |✓            |\n|`solidity/`|Solidity  |✓     |          |         |✓            |\n|`swift/`   |Swift     |✓     |          |         |✓            |\n|`tcsh/`    |Tcsh      |✓     |          |         |✓            |\n|`tcl/`     |Tcl       |✓     |          |         |✓            |\n|`objective-c/`|Objective-C|✓ |          |         |✓            |\n|`vb/`      |VisualBasic|✓    |          |         |✓            |\n|`vbnet/`   |VB.Net    |✓     |          |         |✓            |\n\nAnd several other topics, that are though related to programming,\nare not programming languages:\n\n|Prefix     |Topic     |Basics|StackOverflow|\n|-----------|----------|------|-------------|\n|`cmake/`   |CMake     |✓     |✓            |\n|`django/`  |Django    |      |✓            |\n|`flask/`   |Flask     |      |✓            |\n|`git/`     |Git       |✓     |✓            |\n\n## Cheat sheets sources\n\nInstead of creating yet another mediocre cheat sheet repository,\nwe are concentrating our efforts on creation of a unified\nmechanism to access selected existing well developed and good maintained\ncheat sheet repositories covering topics of our interest:\nprogramming and operating systems usage.\n\n*cheat.sh* uses selected community driven cheat sheet repositories\nand information sources, maintained by thousands of users, developers and authors\nall over the world\n(in the *Users* column number of contributors/number of stars is shown):\n\n| Cheat sheets            | Repository                                                                          | C/U*                                                                                                                    | Stars                                                                                                    | Creation Date |\n|-------------------------|-------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------|---------------|\n| UNIX/Linux, programming | [cheat.sheets](https://github.com/chubin/cheat.sheets)                              | ![](https://img.shields.io/github/contributors-anon/chubin/cheat.sheets?label=%F0%9F%91%A5\u0026labelColor=white)            | ![](https://img.shields.io/github/stars/chubin/cheat.sheets?label=%E2%AD%90\u0026labelColor=white)            | May 1, 2017   |\n| UNIX/Linux commands     | [tldr-pages/tldr](https://github.com/tldr-pages/tldr)                               | ![](https://img.shields.io/github/contributors-anon/tldr-pages/tldr?label=%F0%9F%91%A5\u0026labelColor=white)                | ![](https://img.shields.io/github/stars/tldr-pages/tldr?label=%E2%AD%90\u0026labelColor=white)                | Dec 8, 2013   |\n| UNIX/Linux commands     | [cheat/cheat](https://github.com/cheat/cheat)                                       | ![](https://img.shields.io/github/contributors-anon/cheat/cheat?label=%F0%9F%91%A5\u0026labelColor=white)                    | ![](https://img.shields.io/github/stars/cheat/cheat?label=%E2%AD%90\u0026labelColor=white)                    | Jul 28, 2013  |\n| Programming languages   | [adambard/learnxinyminutes-docs](https://github.com/adambard/learnxinyminutes-docs) | ![](https://img.shields.io/github/contributors-anon/adambard/learnxinyminutes-docs?label=%F0%9F%91%A5\u0026labelColor=white) | ![](https://img.shields.io/github/stars/adambard/learnxinyminutes-docs?label=%E2%AD%90\u0026labelColor=white) | Jun 23, 2013  |\n| Go                      | [a8m/go-lang-cheat-sheet](https://github.com/a8m/go-lang-cheat-sheet)               | ![](https://img.shields.io/github/contributors-anon/a8m/go-lang-cheat-sheet?label=%F0%9F%91%A5\u0026labelColor=white)        | ![](https://img.shields.io/github/stars/a8m/go-lang-cheat-sheet?label=%E2%AD%90\u0026labelColor=white)        | Feb 9, 2014   |\n| Perl                    | [pkrumnis/perl1line.txt](https://github.com/pkrumins/perl1line.txt)                 | ![](https://img.shields.io/github/contributors-anon/pkrumins/perl1line.txt?label=%F0%9F%91%A5\u0026labelColor=white)         | ![](https://img.shields.io/github/stars/pkrumins/perl1line.txt?label=%E2%AD%90\u0026labelColor=white)         | Nov 4, 2011   |\n| Programming languages   | [StackOverflow](https://stackoverflow.com)                                          | [14M](https://stackexchange.com/leagues/1/alltime/stackoverflow)                                                        | N/A                                                                                                      | Sep 15, 2008  |\n\n\u003csup\u003e(*) C/U — contributors for GitHub repositories, Users for Stackoverflow\u003c/sup\u003e\n\nPie diagram reflecting cheat sheets sources distribution (by number of cheat sheets on cheat.sh originating from a repository):\n\n![cheat.sh cheat sheets repositories](http://cheat.sh/files/stat-2017-06-05.png)\n\n## How to contribute\n\n### How to edit a cheat sheet\n\nIf you want to edit a cheat.sh cheat sheet, you should edit it in the upstream repository.\nYou will find the name of the source repository in a browser when you open a cheat sheet.\nThere are two github buttons at the bottom of the page: the second one is the button\nof the repository, which belongs the current cheat sheet.\n\nYou can edit the cheat sheet directly in your browser (you need a github account for it).\nThere is an edit button in the top right corner. If you click on it, an editor will be open.\nThere you will change the cheat sheet (under the hood: the upstream repository is forked, your changes are\ncommitted in the forked repository, a pull request to the upstream repository owner is sent).\n\n![cheat.sh cheat sheets repositories](http://cheat.sh/files/edit-cheat-sheet.png)\n\n### How to add a cheat sheet\n\nIf you want to add a cheat sheet, you have one of the following\nways:\n\n* Add it to one of the external cheat sheets repositories; you should decide on your own what is the best repository for your cheat sheet;\n* Add it to the local cheat.sh repository ([cheat.sheets](https://github.com/chubin/cheat.sheets)) on github (fork, commit, pull request);\n* Post it on cheat.sh using curl or a web browser ([cheat.sh/:post](http://cheat.sh/:post)).\n\nIf you want to change an existing cheat sheet,\nyou have to find the original repository (when you open a cheat sheet in a browser,\nyou see the repository's github button in the bottom of the cheat sheet),\nthe cheat sheet is coming from, and change it there.\nAfter some time the changes will be synchronized on cheat.sh.\n\n### How to add a cheat sheet repository\n\nIf you want to add a cheat sheet repository to cheat.sh, please open an issue:\n\n* [Add a new repository](https://github.com/chubin/cheat.sh/issues/new)\n\nPlease specify the name of the repository, and give its short description.\n\n\n## Installation and standalone usage\n\nYou don't need to install anything, to start using *cheat.sh*.\n\nThere are two cases, when you want to install *cheat.sh* locally:\n\n1. You plan to use it off-line, without Internet access;\n2. You want to use your own cheat sheets (additionally, or as a replacement).\n\nInstallation process in described in details here: [cheat.sh standalone installation](doc/standalone.md)\n","funding_links":[],"categories":["HarmonyOS","Python","大数据处理","Tools and Utilities","Documentation","Cheatsheets and Quick References","Utilities","工具和库","Cheat sheets","Tool","Spotlight","Python (1887)","计算机编程 数据结构与算法","[](#table-of-contents) Table of contents","cli","📦 Everything in one place","Vim (text editor)","Shell","Event discovery","Linux"],"sub_categories":["Windows Manager","JSON only","COVID-19","Misc","网络服务_其他","[](#font-indenfication)Font Indenfication","Conditional Statements","Shell Utils","Other"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchubin%2Fcheat.sh","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchubin%2Fcheat.sh","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchubin%2Fcheat.sh/lists"}