{"id":17242771,"url":"https://github.com/imcuttle/directory-tree","last_synced_at":"2026-03-02T11:33:34.870Z","repository":{"id":11011608,"uuid":"67988343","full_name":"imcuttle/directory-tree","owner":"imcuttle","description":"get directory tree string on node. ","archived":false,"fork":false,"pushed_at":"2022-01-07T14:03:37.000Z","size":10,"stargazers_count":8,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-10T10:09:49.126Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/imcuttle.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":"2016-09-12T07:56:11.000Z","updated_at":"2020-12-23T09:29:25.000Z","dependencies_parsed_at":"2022-08-07T06:01:01.651Z","dependency_job_id":null,"html_url":"https://github.com/imcuttle/directory-tree","commit_stats":null,"previous_names":["moyuyc/directory-tree"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imcuttle%2Fdirectory-tree","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imcuttle%2Fdirectory-tree/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imcuttle%2Fdirectory-tree/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imcuttle%2Fdirectory-tree/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/imcuttle","download_url":"https://codeload.github.com/imcuttle/directory-tree/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248814617,"owners_count":21165796,"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-15T06:14:01.600Z","updated_at":"2026-03-02T11:33:34.820Z","avatar_url":"https://github.com/imcuttle.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# directory-tree\n\nprint your directory on shell and clipboard.\n\n## Get Started\n\n- Bash\n```sh\nnpm i -g print-dir\npdir -h\npdir [.] [-t ./theme.json] [--igd \"node,theme\"] [--sort dir] [-o ./out.txt] [-m 5]\n```\n\n- Package\n```js\nvar dirTree  = require('print-dir')\n\nlet treeData = dirTree({\n    dir: '.',\n    theme: {\n       \"node\": \"├── \",\n       \"pipe\": \"│   \",\n       \"last\": \"└── \",\n       \"indent\": \"    \",\n       \"dir_suffix\": \"/\"\n    },\n    maxLev: 2,\n    ignoresFile: [],\n    ignoresDir: [],\n    prefix: \" \",\n    isLine: false, // don't print line by line\n    sort: \"\"\n})\n/*\n return \ntreeData.treeString\ntreeData.infoString\ntreeData.fileNum\ntreeData.dirNum\n*/\n```\n\n## Default Options\n\n```js\nconst default_options = {\n\n    t: path.resolve(__dirname, \"./themes/default.json\"), // theme of char\n    _: [process.cwd()],           // directory\n    igf: \"\",                    // ignores files (regular expression matching)\n    igd: \"\",                    // ignores dirs (regular expression matching)\n    prefix: '',                 // prefix of each line\n    pa: false,                  // print all at once\n    sort: ''                    // file sort by \"file\"/\"dir\", default is sort by filename.\n    // o: \"./out.txt\"           // store where\n    //m: 1                      // max Level\n\n}\n```\n\n## Default Theme\n\n```json\n{\n    \"node\": \"├── \",\n    \"pipe\": \"│   \",\n    \"last\": \"└── \",\n    \"indent\": \"    \",\n    \"dir_suffix\": \"/\"\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimcuttle%2Fdirectory-tree","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fimcuttle%2Fdirectory-tree","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimcuttle%2Fdirectory-tree/lists"}