{"id":17262841,"url":"https://github.com/jpwilliams/gitree","last_synced_at":"2025-04-09T11:09:35.865Z","repository":{"id":41113771,"uuid":"100627859","full_name":"jpwilliams/gitree","owner":"jpwilliams","description":"Print a directory tree that shows Git status and ignores files dictated by .gitignore.","archived":false,"fork":false,"pushed_at":"2025-04-01T13:54:10.000Z","size":177,"stargazers_count":51,"open_issues_count":18,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-01T14:41:24.209Z","etag":null,"topics":["added","diff","directory","git","modified","renamed","status","tree","untracked"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/jpwilliams.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":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-08-17T17:16:54.000Z","updated_at":"2024-10-13T16:27:39.000Z","dependencies_parsed_at":"2023-12-02T00:23:06.687Z","dependency_job_id":"eaafc0aa-eb76-4cc2-8325-ba3af4216ee5","html_url":"https://github.com/jpwilliams/gitree","commit_stats":{"total_commits":118,"total_committers":7,"mean_commits":"16.857142857142858","dds":"0.35593220338983056","last_synced_commit":"f22cb9f8c1eec9ab554514edd1658eb8bdc1b23f"},"previous_names":[],"tags_count":23,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpwilliams%2Fgitree","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpwilliams%2Fgitree/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpwilliams%2Fgitree/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpwilliams%2Fgitree/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jpwilliams","download_url":"https://codeload.github.com/jpwilliams/gitree/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248027406,"owners_count":21035594,"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":["added","diff","directory","git","modified","renamed","status","tree","untracked"],"created_at":"2024-10-15T07:54:51.071Z","updated_at":"2025-04-09T11:09:35.845Z","avatar_url":"https://github.com/jpwilliams.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @jpwilliams/gitree\n\nPrint a directory tree that shows Git status and ignores files dictated by `.gitignore`.\n\n``` sh\n$ npm i -g @jpwilliams/gitree\n$ gitree\n\n# OR\n\n$ npx @jpwilliams/gitree\n```\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://user-images.githubusercontent.com/1736957/65135842-8783e780-d9fe-11e9-887b-3e04381795ac.png\"\u003e\n\u003c/p\u003e\n\n# What?\n\n`gitree` works very similarly to [tree](https://linux.die.net/man/1/tree) but only lists files related to the current git repository.\n\nLike Git, `gitree` only tracks _files_, so empty directories will never be listed. If you wish to push an empty folder to a Git repository, add an empty `.gitignore` or `.gitkeep` file to the directory and commit it.\n\n# What does it show?\n\n`gitree` shows any files that your repository's `.gitignore` files allows you to see, marking them with useful statuses like the ones in the screenshot above.\n\n# What if it's not a Git repository?\n\nIt won't work. You must be somewhere within a Git repository to list any files. If you just want a basic tree view _without_ Git integration, consider the built-in `tree` command for Linux/Windows or the [`tree` homebrew formula](http://brewformulas.org/Tree) for Mac OSX.\n\n# What else can it do?\n\nJust this stuff:\n\n``` \nUsage: gitree [options] [dir]\n\n\nOptions:\n\n  -V, --version           output the version number\n  -m, --modified          only show modified files\n  -t, --tracked           only show tracked files\n  -c, --collapse          collapse directory nodes that contain a single child\n  -d, --devicons          print matching devicons next to files\n  -I, --ignore \u003cpattern\u003e  do not list files that match the given pattern\n  -h, --help              output usage information\n```\n\n_Note that for devicons to work, you must have a font with devicon glyphs installed. A good place to start is [Nerd Fonts](https://github.com/ryanoasis/nerd-fonts)._\n\n# Can it get any cooler?\n\nThere's a built-in alias, `gt`. Fantabulous, eh?\n\n# Alternatives\n\nThe wonderful [ogham/exa](https://github.com/ogham/exa) can print a similar tree **without** detailed change information/filtering with:\n\n``` sh\nexa --git-ignore --tree --all --icons --ignore-glob .git\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpwilliams%2Fgitree","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjpwilliams%2Fgitree","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpwilliams%2Fgitree/lists"}