{"id":19364464,"url":"https://github.com/math2001/foldfunctions","last_synced_at":"2025-07-01T01:34:55.425Z","repository":{"id":74806135,"uuid":"94655632","full_name":"math2001/FoldFunctions","owner":"math2001","description":"Sublime Text plugin to fold functions. And it supports functions with arguments on more than one line!","archived":false,"fork":false,"pushed_at":"2017-06-27T06:11:04.000Z","size":292,"stargazers_count":12,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-23T14:39:41.011Z","etag":null,"topics":["fold","plugin","python","sublime-text"],"latest_commit_sha":null,"homepage":"","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/math2001.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":"2017-06-18T00:03:05.000Z","updated_at":"2023-02-22T13:30:06.000Z","dependencies_parsed_at":"2024-01-21T04:29:08.815Z","dependency_job_id":"ebe47e5d-0b86-4c58-be48-3d967ae33239","html_url":"https://github.com/math2001/FoldFunctions","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/math2001/FoldFunctions","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/math2001%2FFoldFunctions","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/math2001%2FFoldFunctions/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/math2001%2FFoldFunctions/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/math2001%2FFoldFunctions/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/math2001","download_url":"https://codeload.github.com/math2001/FoldFunctions/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/math2001%2FFoldFunctions/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262879542,"owners_count":23378633,"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":["fold","plugin","python","sublime-text"],"created_at":"2024-11-10T07:37:28.632Z","updated_at":"2025-07-01T01:34:55.395Z","avatar_url":"https://github.com/math2001.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FoldFunctions\n\nThis package folds every functions in the current file, so that you can have a global view of it, and then unfold a few, so that you don't have to scroll a lot, skipping over the functions you're not interested in at the moment.\n\nFor now, the following language are supported:\n\n- Python :heart:\n- JavaScript\n\nThe good part is that it supports arguments on  multiple lines, like so (in this case, it's python):\n\n```python\ndef my_function(argument_number_one, argument_number_two,\n                argument_number_three):\n    print('It works!!')\n\n    for i in range(10):\n        print('It really does!')\n```\n\n![Example of folding with this package - FoldFunctions - through the command palette of Sublime Text](fold-functions.gif)\n\n## Installation\n\nBecause it is not available on package control for now, you have to add this repo \"manually\" to your list.\n\n### Using package control\n\n1. Open up the command palette (`ctrl+shift+p`), and find `Package Control: Add Repository`. Then enter the URL of this repo: `https://github.com/math2001/FoldFunctions` in the input field.\n2. Open up the command palette again and find `Package Control: Install Package`, and just search for `FoldFunctions`. (just a normal install)\n\n### Using the command line\n\n```bash\ncd \"%APPDATA%\\Sublime Text 3\\Packages\"             # on window\ncd ~/Library/Application\\ Support/Sublime\\ Text\\ 3 # on mac\ncd ~/.config/sublime-text-3                        # on linux\n\ngit clone \"https://github.com/math2001/FoldFunctions\"\n```\n\n\u003e Which solution do I choose?\n\nIt depends of your needs:\n\n- If you intend to just use FoldFunctions, then pick the first solution (Package Control), **you'll get automatic update**.\n- On the opposite side, if you want to tweak it, use the second solution. Note that, to get updates, you'll have to `git pull`\n\n## Usage\n\nThe command is accessible from the command palette. \n\n- \u003ckbd\u003ectrl+shift+p\u003c/kbd\u003e\n- Search for `Fold Functions`\n- hit \u003ckbd\u003eenter\u003c/kbd\u003e\n\nNote: The caption will be the same, whichever supported language file you are editing, but the actual command will change. :wink:\n\n### Adding a key binding\n\nIt's up to you, but I prefer to have this command bound to this command, in my case, \u003ckbd\u003ealt+f\u003c/kbd\u003e. So, here's what I've done:\n\n\n```json\n{\n    \"keys\": [\"alt+f\"],\n    \"command\": \"fold_python_functions\",\n    \"context\": [\n        {\"key\": \"selector\", \"operand\": \"source.python\"}\n    ]\n},\n{\n    \"keys\": [\"alt+f\"],\n    \"command\": \"fold_javascript_functions\",\n    \"context\": [\n        {\"key\": \"selector\", \"operand\": \"source.js\"}\n    ]\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmath2001%2Ffoldfunctions","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmath2001%2Ffoldfunctions","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmath2001%2Ffoldfunctions/lists"}